-
Notifications
You must be signed in to change notification settings - Fork 3
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
Detect ManimGL version #102
Conversation
This reverts commit 7db0edd.
@bhoov Feel free to already play a bit around with these changes and check if many different scenarios work for you (e.g. also clicking away from a pop-up and trying to outsmart the logic I've written). With regards to the code, I might do some more refactoring (of my newly written code) before I turn the draft PR to a regular one that can be reviewed. |
As I plan to refactor some code and lint it, I'm merging this now. Feel free to open issues if something is not working with it or if you don't like how I realized the version detection. |
Closes #97
We detect the ManimGL version that the user is using. While in theory this is just issuing the command
manimgl --version
, there is soo much more that we have to do to ensure a nice user-flow and to handle all kinds of errors and particular situations. See the code for more details. What matters for the caller is that we can now do this (don't forget theawait
⚠):in order to require specific versions for some features, e.g. reloading or
--autoreload
.This method also takes care of showing respective warning messages etc. As a bonus feature, we call the GitHub API and if it returns something valid back, we show the user what the latest release version of Manim is.
Users can also switch ManimGL versions without having to reload VSCode. You just have to use the command
Redetect Manim version
. I've also removed the check manim version command from the walkthrough and instead use that newRedetect Manim version
command there.Refactoring
Since we needed some terminal-related methods also in a new file, I moved those methods from the Manim Shell to a new Terminal utility class.