The important point is that a person does not need to compromise when contemplating God. The story we've been given explains literally everything. In that story God is all knowing, all powerful, and merciful (Exodus 20:6).
He is all-knowing with what He wants to know. He can read hearts, even see us while we were embryos. Job 37:23 - helps to put God's justice and righteousness in its proper place--
"Understanding the Almighty is beyond our reach;
He is great in power,
And he never violates his justice and abundant righteousness."
Justice would not be compatible with His knowing the outcome of every individual, including that of Adam and Eve, EXCEPT that in His wisdom, He told them that IF they ate from the tree of knowledge of good and evil, they would die. It is not reasonable to imagine that He tells them this knowing full well they would eat and die. That's like a parent telling a child if you skip school today I will punish you, knowing they would skip school. He knew they could or might skip school, but he warned them not to, otherwise...
Similarly, Adam and Eve
could have eaten, He knew that. But to say He knew beforehand that they would does not harmonize with justice.