Question: Antigravity XKCD when Naming Provider Antigravity? #3984

Closed
opened 2026-02-16 17:42:11 -05:00 by yindo · 5 comments
Owner

Originally created by @EvanZhouDev on GitHub (Dec 29, 2025).

Originally assigned to: @rekram1-node on GitHub.

Question

When you name a model provider "antigravity" and attempt to run OpenCode by sending a prompt to any model in that provider, it will open a new browser window with the Antigravity XKCD given that the provider request fails.
Assuming this is a easter egg, but why does this happen?
Would dig through the code myself to find out, but asking here felt easier 😄

Originally created by @EvanZhouDev on GitHub (Dec 29, 2025). Originally assigned to: @rekram1-node on GitHub. ### Question When you name a model provider "antigravity" and attempt to run OpenCode by sending a prompt to any model in that provider, it will open a new browser window with the [Antigravity XKCD](https://xkcd.com/353/) given that the provider request fails. Assuming this is a easter egg, but why does this happen? Would dig through the code myself to find out, but asking here felt easier 😄
yindo closed this issue 2026-02-16 17:42:11 -05:00
Author
Owner

@rekram1-node commented on GitHub (Dec 29, 2025):

no idea

@rekram1-node commented on GitHub (Dec 29, 2025): no idea
Author
Owner

@addidotlol commented on GitHub (Dec 31, 2025):

Ran into this too, seems to be that when you set a create a provider with the name of antigravity and don't specify an NPM package, it will import the antigravity library from npm, which opens the xkcd

https://github.com/sst/opencode/blob/a6d225558cddffdc9720724b044c3c7780a87ea0/packages/opencode/src/provider/provider.ts#L916-L924

@addidotlol commented on GitHub (Dec 31, 2025): Ran into this too, seems to be that when you set a create a provider with the name of `antigravity` and don't specify an NPM package, it will import the `antigravity` library from npm, [which opens the xkcd ](https://www.npmjs.com/package/antigravity?activeTab=code) https://github.com/sst/opencode/blob/a6d225558cddffdc9720724b044c3c7780a87ea0/packages/opencode/src/provider/provider.ts#L916-L924
Author
Owner

@rekram1-node commented on GitHub (Dec 31, 2025):

Oh lol it shouldnt do that we should default to openai compat if not specified imo

@rekram1-node commented on GitHub (Dec 31, 2025): Oh lol it shouldnt do that we should default to openai compat if not specified imo
Author
Owner

@EvanZhouDev commented on GitHub (Dec 31, 2025):

Ah, thanks @addidotlol for figuring that out. I guessed that it was something like that, but it didn't occur to me that it would be automatically downloading stuff from NPM...

@rekram1-node, I feel like this current behavior could be potentially dangerous if some malicious NPM package was typed in...

Closing for now. Happy new year everyone!

@EvanZhouDev commented on GitHub (Dec 31, 2025): Ah, thanks @addidotlol for figuring that out. I guessed that it was something like that, but it didn't occur to me that it would be automatically downloading stuff from NPM... @rekram1-node, I feel like this current behavior could be potentially dangerous if some malicious NPM package was typed in... Closing for now. Happy new year everyone!
Author
Owner

@rekram1-node commented on GitHub (Dec 31, 2025):

Yeah im gonna change that

@rekram1-node commented on GitHub (Dec 31, 2025): Yeah im gonna change that
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: anomalyco/opencode#3984