Closed Arian8Ultra closed 1 month ago
here is my other device on the same exact project
do i need to install anything?
No, you don't need to install anything.
The explorer is included as an iframe - do you maybe have any privacy plugins installed that might block that iframe?
my browser is clean installed i tried on chrome, fire fox and also edge but nothing works and all of them are just installed and also my run in explorer is disabled
@Arian8Ultra can you right-click in the extension and "Inspect"? This should bring up another devtools pane that lets you inspect the Apollo Client Devtools extension. If you do this, do you see errors in the JavaScript console there by chance?
im seeing these: devtools-1727126757536.log
How strange! I've never seen that kind of error. We don't have a live-metrics
file anywhere in the extension so I'm not sure where that is coming from. Do you perhaps have some kind of system extension enabled that might have an effect here?
i just have quilbot and apollo is it possible that some privacy setting in edge or chrome is preventing apollo from working correctly?
im not sure but this might be the problem: Unknown VE context: chrome-extension://jdkknkkbebbapilgoeccciglkfbmbnfmApollo
Perhaps? Can you try opening the explorer in its own tab? I'd be curious if this is loading for you: https://explorer.embed.apollographql.com/
the link that you provide is working:
Interesting! Would you mind opening a support ticket using the link in that screenshot? Unfortunately I'm not on the team that owns this codebase since its an iframe into our embedded explorer. I'll raise the issue internally with the team as well.
i deleted my last comment because it worked again (the link) it was my network problem but the code was : 426b525e59e24e89bed90e34a769e6c2
I will Thanks a lot
in the end i have a question: in what condition the run in explorer is disabled?
it should help me to fix this maybe
It looks like it will be disabled if its unable to setup the iframe for the embedded explorer: https://github.com/apollographql/apollo-client-devtools/blob/5a75c417233ec321bb6f8770dd61635238d2748f/src/application/components/Queries/RunInExplorerButton.tsx#L26
This is set from the Explorer tab in App.tsx
: https://github.com/apollographql/apollo-client-devtools/blob/5a75c417233ec321bb6f8770dd61635238d2748f/src/application/App.tsx#L272
which itself is called if we are able to get a message from the underlying iframe: https://github.com/apollographql/apollo-client-devtools/blob/5a75c417233ec321bb6f8770dd61635238d2748f/src/application/components/Explorer/Explorer.tsx#L155-L162
My guess is that since your machine is unable to setup the iframe, it can't receive the message, so the button remains disabled.
That is very very helpful I will check it and come back to you
If it would help to run the extension locally so you can add logging to the code, check out the instructions from this comment: https://github.com/apollographql/apollo-client-devtools/issues/1396#issuecomment-2139999099 (I really gotta move these to the README 🙃)
I made an iframe in my project with the url you provided and i got this: Access to fetch at 'https://studio-ui-deployments.apollographql.com/build/iframeIdentitySync.html' from origin 'https://explorer.embed.apollographql.com' has been blocked by CORS policy: No 'Access-Control-Allow-Origin' header is present on the requested resource. If an opaque response serves your needs, set the request's mode to 'no-cors' to fetch the resource with CORS disabled.
Can you use the full URL that we do in the devtools to check to see if this is still the case? In the extension, we route the network requests through your actual Apollo Client instance connected to devtools, so the fetch happens in the top frame. Here is the URL:
where EMBEDDABLE_EXPLORER_URL
is https://explorer.embed.apollographql.com/ and color
is "dark" (feel free to omit the graphRef
if you're not logged into Apollo Studio).
That sendRequestsFrom=parent
part of the URL tells the embedded explorer to send the request as a window.postMessage
instead of a network request. I wouldn't expect network requests to work using this URL, but I'd be curious if you're still seeing CORS issues with this.
I tried it again with the full url as you said, and this was the result :
Access to fetch at 'https://studio-ui-deployments.apollographql.com/build/iframeIdentitySync.html' from origin 'https://explorer.embed.apollographql.com' has been blocked by CORS policy: No 'Access-Control-Allow-Origin' header is present on the requested resource. If an opaque response serves your needs, set the request's mode to 'no-cors' to fetch the resource with CORS disabled. StrategyHandler.js:160
Uncaught (in promise) TypeError: Failed to fetch
at W.fetch (StrategyHandler.js:160:35)
at F._handleInstall (PrecacheStrategy.js:143:40)
at F._handle (PrecacheStrategy.js:71:31)
at async F._getResponse (Strategy.js:144:13)
and here is my test code for the iframe:
<iframe
id="embedded-explorer"
className="w-full h-full border-none bg-black-100"
src={"https://explorer.embed.apollographql.com?sendRequestsFrom=parent&shouldPersistState=false&showHeadersAndEnvVars=false&shouldShowGlobalHeader=false&parentSupportsSubscriptions=true&theme=dark"}
/>
and when i open the first url in the error i will get this: Error: Forbidden Your client does not have permission to get URL /build/iframeIdentitySync.html from this server.
I found the problem
my DNS server was the problem and the sync of the iframe was interrupted by it
I just used a vpn and every thing is working I also tried google's DNS and it worked too
Unfortunately I have no way to reproduce this, so at this point I'm not even sure how to begin figuring this out. It's odd to me that you're seeing different error messages from the devtools errors and the raw iframe you're using here.
If you're willing to help out and dive in a bit deeper since you're able to reproduce it on your machine, that would be greatly appreciated. Clone this repo and use the steps outlined in https://github.com/apollographql/apollo-client-devtools/issues/1396#issuecomment-2139999099 in order to run the extension locally. Perhaps having access to the raw code can help get a bit closer to the issue.
Oh awesome! Seems I posted my comment too soon 😆. Thats fantastic!
I'm so sorry about it thanks a lot
Do you have any feedback for the maintainers? Please tell us by taking a one-minute survey. Your responses will help us understand Apollo Client usage and allow us to serve you better.
No problem! I'm just glad you were able to figure it out. At least this leaves a paper trail for anyone else that may stumble into the same issue. Have a great rest of your day!
I have devtool on my other device and it work flawlessly but in my new device everything is working except Explorer and its blanked out
@apollo/client
version3.8.8
Apollo Client Devtools version
4.18.6