Then the exclusions are law, not a 'gentlemen's agreement'?
Seriously, the world was a racist, racist place back then. Jews and others faced quotas in universities until after WWII.
We didn't allow hardly any Jews into the country from Germany when the Nazis took over (we being Canada and the US), even given a) the clear and present threat, b) the fact that many were well educated and would be a constructive addition to society, and c) that they were showing up on our side of the Atlantic in overcrowded, slaveship level crowded, leaky boats, and they were still turned away.
The Gentlemen's Agreement MAY have been the most liberal option available. I don't know, but I THINK most other plausible outcomes would have been worse.