Monkey Patching - Antigravity Pro Login Loop: Stuck on “Sign into Google”

Okay! Same Problem as everyone else posting here.

I am on Linux (Ubuntu), basically the same Problem:
Opens Antigravity → Tries to Login → Gets redirected to Browser → After Login on the Browser, redirecting to the App.

It fails in the last step where after successful Oauth in the Browser the success call wasn’t being passed onto the Application (or atleast thats what it felt)

After few unsuccessful debugs , I opened Antigravity via the terminal with the command:

/usr/share/antigravity/antigravity --open-url “antigravity://oauth-success”

I could see the logs behind Antigravity:

[main 2026-03-19T17:06:07.003Z] [BrowserOnboardingClientMainService] Starting browser onboarding server
[main 2026-03-19T17:06:07.013Z] [BrowserOnboardingClientServer] Browser onboarding server started on ``http://localhost:46527
[main 2026-03-19T17:06:07.160Z] update#setState idle
[main 2026-03-19T17:06:37.161Z] update#setState checking for updates
[main 2026-03-19T17:06:37.487Z] update#setState idle

However, whenever I tried to click the redirect to the application after successful login , I could see some error logs like:

[main 2026-03-19T17:07:21.052Z] [uncaught exception in main]: TypeError: Do not know how to serialize a BigInt
[main 2026-03-19T17:07:21.053Z] TypeError: Do not know how to serialize a BigInt
at JSON.stringify ()
at vD (file:///usr/share/antigravity/resources/app/out/main.js:31:11765)
at nve.o (file:///usr/share/antigravity/resources/app/out/main.js:31:14636)
at nve.m (file:///usr/share/antigravity/resources/app/out/main.js:31:14511)
at wW.value (file:///usr/share/antigravity/resources/app/out/main.js:32:265)
at jt.C (file:///usr/share/antigravity/resources/app/out/main.js:30:2348)
at jt.D (file:///usr/share/antigravity/resources/app/out/main.js:30:2418)
at jt.fire (file:///usr/share/antigravity/resources/app/out/main.js:30:2635)
at wW.value (file:///usr/share/antigravity/resources/app/out/main.js:28:7100)
at jt.C (file:///usr/share/antigravity/resources/app/out/main.js:30:2348)
at jt.fire (file:///usr/share/antigravity/resources/app/out/main.js:30:2566)
at tce.R (file:///usr/share/antigravity/resources/app/out/main.js:1445:45593)
at process.processTicksAndRejections (node:internal/process/task_queues:105:5)
at async file:///usr/share/antigravity/resources/app/out/main.js:1445:41998
[main 2026-03-19T17:07:21.054Z] [uncaught exception in main]: TypeError: Do not know how to serialize a BigInt
[main 2026-03-19T17:07:21.054Z] TypeError: Do not know how to serialize a BigInt

As you can see there is some issue in the main.js file with JSON.stringify while serializing BigInt.

So, I tried monkey patching it by pre-pending

BigInt.prototype.toJSON = function() { return this.toString() };

at the top of the file main.js

Restarted Antigravity the same way and was able to get a successful Login Message after Oauth from the browser.

Just hope it helps someone !!!

1 Like

Adding additional images in support !

Hello @SammyB, welcome to AI Forum!

Thank you for bringing the issue to our attention and sharing the workaround. Our engineering team is currently investigating the matter, and we appreciate your patience as we work toward a resolution.