-
Notifications
You must be signed in to change notification settings - Fork 2
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add troubleshooting link to documentation when publish/failure
occurs
#2546
Conversation
publish/failure
occurs
docs/troubleshooting.md
Outdated
It is likely due to Posit Connect, on the server you are deploying to, being | ||
older than the version that introduced support for the `type` set in your | ||
configuration file. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This section is good, but we should have a section above it with other common type mismatches. This is definitely one possible one — and folks who use our inspection is only one of two possible situations they could get themselves into, but there is also the possibility that someone edited the config file to put some other type that's unknown.
I would structure it like this:
There's an issue with the type ...
Unknown / unset
type
In this scenario you will need to find the type and set it...
Using a
type
that isn't supported by your serverConnect might be out of date ...
A typo in
type
If you hand edited the configuration file, you might have had a typo in the type field. Check that.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This section is good, but we should have a section above it with other common type mismatches.
Thank you, and fantastic idea. I added two more sections in 0a100d6
I kept the organization of
### Errors
> Exact error text
#### Solutions
let me know if you think that is working well.
The two sections I added capture:
- The "Failed to deploy. The Configuration has a schema error" which occurs when there is a typo, missing section (like no
[python]
section when the Configuration is set totype = "python-fastapi"
for example), or incorrect values - A new solution section under "Unrecognized app mode" when using
type = 'unknown'
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Aside from Jon suggestions, looks good to me 👍
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Jon's recommendations make sense to me.
d378c81
to
0a100d6
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This looks great, thanks for this!
e9be268
to
c4c8573
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Changes look great to me.
This PR adds:
docs/index.md
window.showErrorMessage
call onpublish/failure
to include a new "See Troubleshooting docs for help."Preview
Intent
Resolves #2476
Type of Change
Approach
I only included the troubleshooting link at our
window.showErrorMessage
call frompublish/failure
as opposed to always showing the Troubleshooting link because the only content in our troubleshooting doc has to do with publish failure.As we add more to the document we can easily replace
window.showErrorMessage
usage with usage of the newshowErrorMessageWithTroubleshoot
helper I created here.I can change this based on feedback on this PR.
User Impact
Users will now see a handy Troubleshoot docs link when deploying to a Connect server without Gradio support - and really for any
publish/failure
error message they receive.Directions for Reviewers
The easiest way I found to test this is to change our two schemas to support a type that is not supported like
"nonsense"
.Then use that in a configuration file and attempt to deploy - leading to the error notification above. Note that the app mode isn't listed. That is due to #2542