aqtinstall
aqtinstall copied to clipboard
Don't suggest that users file a bug report unless they are using the newest version
Is your feature request related to a problem? Please describe.
Currently, aqtinstall
requests that users file a bug report any time that it raises an exception that it cannot recover from. Quite frequently, we get bug reports for bugs that we have already fixed. It would be nice if aqtinstall
would only display the PLEASE FILE A BUG REPORT
message when the user is using the most recent version of aqtinstall
.
Describe the solution you'd like
When an exception is raised that aqtinstall
does not know how to handle, aqtinstall
should first check with PyPI to find out if there's a newer version available. If there is, aqtinstall
should print PLEASE USE THE NEWEST AQTINSTALL
instead. It should only request that users file a bug report if aqtinstall
is already on the newest version.
Describe alternatives you've considered Add an empty checkbox to the "Bug Report" issue template that asks users if they are using the newest version of aqtinstall. Use a bot to automatically close any bug reports where the user has not checked the box.
Additional context None
You can fetch a list of releases via JSON api here: https://pypi.org/pypi/aqtinstall/json
People in certain parts of the world may not have easy access to PyPI.
Here are two result pages of the PING test to "pypi.org":
DateTime | Screenshot on Archive Today | URL to Archive Today |
---|---|---|
6 May 2023 17:07:39 UTC | ![]() |
https://archive.today/1ywgd |
14 May 2023 04:51:49 UTC | ![]() |
https://archive.today/9L03A |
On the webpage (open the URL, not the screenshot), you can find the word "美国", the USA, has the "<1ms" latency. It's good, I think.
Thanks, GFW (Great Firewall - Wikipedia).
Good point. There are also these two JSON apis that might work:
- https://api.github.com/repos/miurahr/aqtinstall/tags
- https://api.github.com/repos/miurahr/aqtinstall/releases
We could make a "best effort" attempt: check either pypi or github and use the other as a fallback. If both attempts fail, maybe it makes sense to print the "File a bug report" message anyway?
We could make a "best effort" attempt: check either pypi or github and use the other as a fallback. If both attempts fail, maybe it makes sense to print the "File a bug report" message anyway?
Agree.
The procedure could be as follows:
- Error occurs.
- Check version within a limited time.
- If the running aqtinstall is old, say "PLEASE USE THE NEWEST AQTINSTALL AND TRY AGAIN".
- If it's the latest version, say "please file a bug report".
- If no version info obtained, say "please check the GitHub page to see if there is newer version and try again... if the error persists, file a bug report".