As per Exodus Chapter 4:22 And you shall say to Pharaoh, 'So said the Lord, "My firstborn son is Israel." '
All Jews are sons of G-d.
Ezra was a Jew and a high status religious Jewish figure, and that makes him a son of G-d as per Torah. Right ?
Quran addresses the Jews living in Medina at that time and their religious concepts. They never raised a question at that time that it was a wrong allegation that they believed Ezra as son of G-d. Later they migrated from Medina and might have joined/merged with other denominations and changed or reformed their concepts.
Quran addresses altogether different issues in the context verses where Ezra/Jesus have been mentioned.
If you were to take this line altogether out of context, that would make sense. But as it literally says, side by side, that Jews regard Ezra as the Son of God, and Christians regard Jesus as the Son of God, heavily implying that it means it in the same way.
This is further supported by the fact that it is saying Ezra specifically. Ezra wasn't being discussed in this part of the Qur'an, so why randomly pick some Jewish figure and say he is the Son of God, if it was referring to all Jews as being Son of God?
This is rather like me trying to say that Hindus worship many deities by saying 'Hindus worship Lord Murugan'. It wouldn't in any way get across what I was trying to do.
The most reasonable conclusion seems to be that whoever originated this part of the Qur'an made the mistake that Jews worshipped an individual as Son of God in the same way as the Christians. Or that they made this allegation to villify the Jews.
As for the Jews of Medina not objecting to this claim: how would you know? Would the Islamic scholars have recorded diligently the fact that a bunch of kufr had said their Holy Book was wrong?
I suppose one could postulate that the Jewish community in Medina at the time were of some sect which thought Ezra was the Son of God, strange as it would be for this idea to emerge again surrounding a different Messiah. But if you want to squeeze everything into the Qur'an, fair enough.
But of the three I put forth, I think Qur'an 23:14 is the most damning.