-
Notifications
You must be signed in to change notification settings - Fork 1.6k
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
Rework, refactor, revamp web-ui #1872
Conversation
Change download link on `/spotdl/console/web.py`
But we still have to check if we aren't running an outdated version of web ui. Maybe add a file in the web repo with version, and a flag to force the update of web ui. Also consider implementing web ui version check in the flag that checks for updates. |
I'm currently working on the web-ui. It gets the version from the package.json, which then bundles as string in the static files. Which then compares it to the latest version number and informs the user if they're running an outdated web-ui, allows them to update. |
Please allow me to convert this to a draft. |
@xnetcat I added a function that gets the current web-ui version and the latest version from github api. Will update the files if not latest, before starting the server. |
PR looks good, but I am thinking that maybe I should convert it to PR for web-ui rework.? |
Of course. If you think its the appropriate. |
Just letting you know that if you need help with anything let me know! |
Ahh I didn't know you needed #1865. Merging it right now. |
Actually i need help. I'm trying to add |
what do you need it for? |
Its not related to web-ui rework. LOL. Im implementing it in the desktop app. Please take a look at this. And #1779 will be in the desktop app, not in the web-ui rework. I have some ideas but can't really implement it in Python(no knowledge on syntax and modules to use). But I can do it in Rust, so. |
gj with #1779 few questions though. why CD to downloads, why does it need elevated perms? |
When link with custom uri is clicked, example spotdl://https://open.spotify.com/track/5sICkBXVmaCQk5aISGR3x1?si=8f3379819fb24ecf It opens a new cmd window, then execute Also if we remove the cmd start and just execute the
I think registering a winreg key needs elevated access. I tried it with no elevation it gives a permission error. |
thanks for explaining, maybe try adding some info about where songs are being downloaded when using uri opener etc and maybe add some logging to Inform users on what's happening. |
When a url like this and opens a cmd window like this Its exactly the About the download folder maybe we can add the user's preferred path when installing like |
or get a module path then create a path to script and start it with the python or something. traversing all $PATH directories isn't the best idea someone might be running |
I used print insted of the logger. For some reason the logger doesnt output on cmd when registering the winreg key, but it does work on PermissionError block. I like to reiterate that I'm noob in python so I need help in this 🤣 |
Ill try this. Another use case is if the user is using a downloaded compile exe. |
yeah that's what I've meant by spotdl.exe |
logging is not initialized at this point of cli lifecycle. it's totally fine to use prints here |
there's already a |
In description the So the uri command will be
If you really prefer the Hope you get what im meaning |
file name is not required when passing a directory path to the --output flag |
Oh I didnt know that. So we can just pass the output folder? |
Ok I think I get what you mean now. Since we have to CD first, browser will show an alert with trying to open the windows command processor message. Maybe try doing |
Having spotdl as the first argument wont launch a cmd window. No idea why. |
This issue has been automatically marked stale because there hasn't been any activity for the last 30 days. |
This issue has been automatically marked stale because there hasn't been any activity for the last 30 days. |
Title
Use existing web-ui dist dir files
Description
Add a feat that checks if the dist dir already exists, use it instead, if not download the dist dir.
Related Issue
#1871
Motivation and Context
I like to reduce the server startup time. Also reduce internet data transmission.
How Has This Been Tested?
Some external pytest and running
spotdl
in poetry shell, as instructed in contributing.mdScreenshots (if appropriate)
running
spotdl web
with existing dist dirrunning
spotdl web
with non-existing (deleted or first time user) dist dirTypes of Changes
Checklist
PS Had one error on
mypy
test but its not related to my changes :BREAKING CHANGE
Need to add release on the web-ui repo(currently none). A function checks for updates base on latest release on web-ui repo.