Closed tauchmi closed 4 weeks ago
So Hot Chocolate never composes a schema?
The backend system that is failing is not using hot chocolate.
Then it's not possible as the GraphQL server would need to be able to expose the error to BCP. If the server does that you can have a look at the new operations tab that also shows the introspection queries and their errors.
cc @rstaib @artola
Well, the thing is the introspection queries do not indicate an error. In e.g. Altair I do get a message like "invalid schema" but also without more information.
The endpoint was corrected and Altair is working, but BCP still indicates an error (red dot) and schema unavailable.
@tauchmi which version of BCP?
7.0.0
And what do you see in the log panel?
Hmmm strange. Here in the log console we can see that the introspection query went successful. Could you please click the schema reload icon and see what is happening in the console?
Ahhh and please check the result of the last log entry Introspection: http://localhost:5000/graphql
The request is showing a 200
status code but it could be that the GraphQL response contains errors.
If that is the case we could extract the error and show it in the console as well
The logs do not indicate or contain any errors on the schema reload, but still bcp ist not able to display the schema.
Is the source code of bcp public?
No the source code is not public. it's a free to use tool though. There is something strange ongoing. Could you please make sure that you have saved all your documents, then click the sync button in the footer, sign-out from BCP, remove the IndexedDB for BCP and then refresh the browser.
A few more questions:
Deleting the database fixed the issue!
I guess when the api had an issue, this persisted in the database and did not refresh after correcting it?
Unfortunately I cannot share the result. I hope you would not ask ;) The server is graphql.net 2.0.0-alpha something
Okay, so it works now after following my steps I assume? I will check then why the introspection result get stuck in the DB.
That's correct.
I'm not 100% sure what the issue was, it seems a name was used multiple times for types and/or query.
I'm having the same issue. If I change the schema, I'm getting 'Schema unavailkable' error.
Deleting Indexed-Db fixes the problem.
I'm using BCP 15.0.4, DB version 19
Oh, I noticed, that there was indeed something wrong with my schema. Some types were apparently using space characters in names:
Names must only contain [_a-zA-Z0-9] but "technologymonitoring_ai climate_job market - ai_countries_per_month_Filter" does not.
It would be nice if BCP could warn about such things instead of simply failing.
@rstaib can this one be closed?
@michaelstaib Yeah, can be closed now.
Product
Banana Cake Pop
Is your feature request related to a problem?
I have multiple graphql schemas which come from different systems, one seems to be invalid. Banana Cake Pop does show a red button in the reload schema button top right but gives no further clues. The "Schema Reference" tab shows "Schema unavailable". No further information on what the problem is.
The solution you'd like
The system providing a section with information what the problem is (duplicate naming, etc.) or at least a console.log with a bit of information.