"I am the Lord thy God who brought you out of the land of Egypt out of the house of slavery and you shall have no other gods before me"
That's not a mistranslation, that's the entire first commandment. The old testament openly acknowledges the "existence" of competing deities.
Remember that when this was written down for the first time, it was super strange to have only one all powerful God. There were hundreds of gods that the Jews would have been at least aware of. Even if the whole Exodus thing is not accurate to Jewish history in particular, which it likely isn't, no one but the Jews had only one God they prayed to. At the time, you prayed to whoever you thought got that particular job done. The first commandment says no, set them all aside and worship me and me alone.
Which is exactly why the second commandment is about not making idols.
Also the whole Egypt thing was probably the Hitites, who got diaspora'd and many of whom probably ended up finding the Jewish people and integrated with them. There's literally 0 physical evidence of large scale Jewish enslavement in ancient Egypt.
The old testament is full of kinda fucked up, ~~borderline~~ abusive demands.
NVM he has you cut the tip of your dick off as an act of devotion it's full on abusive.