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
Uploading to PyPi and other sources #22
Comments
Thank you for the offer! Let's discuss about that when the package is a bit closer to something constituting a release. To comment on the progress, I'd say in addition to returning dataclass models from the client, most of the work is in documentation and tests. Functionality is already beyond the original Spotipy. |
An update: we are a lot closer to a usable package now. More or less every line of the package is now executed by the test suite. And the client is tested against the live Spotify server. This means the model-based client is at least a lot more reliable than it was. The test cases are not anything special though. They would need to be expanded to try different combinations of arguments. With regards to the package name considerations, I have made a request to PyPI to transfer the I haven't figured out what to do with the old version and version numbers yet if the transfer is successful. My current plan is to update the package to the plamere repository version, which has been the source of many complaints in the issues. And along with that issue some warnings (deprecations or such) about the next major release. That would give this package a version number of 3 and development of would continue on from there. |
Good to know! I didn't know PyPi let you transfer names. That plan sounds good to me. As long as it's not an abrupt change that would break other packages it should be fine. Also, a small thing I noticed that I don't consider big enough to open an issue for, is that maybe |
Thanks! No abrupt changes, agreed. It would benefit no one. Yeah, |
@marioortizmanero In #42 you mentioned a name transfer in the Arch repositories too. Is "spotipy" currently reserved? And would you enlighten me a bit, it's completely separate from PyPI, right? So, do you have any information on what's the share between installs from AUR and PyPI/pip? But yes, I would appreciate you hosting the package there very much! |
Yes, spotipy is currently the old API: https://aur.archlinux.org/packages/python-spotipy/ The AUR is just another different repository for Arch Linux users. It's intended to be separate from PyPi, meaning that the dependencies are other packages from the AUR too. Here's what we call the PKGBUILD, aka the installation script. You just list the dependencies from the AUR and run a |
Update planI think we'll have to go a bit bass-ackwards with the release. The current version on PyPI is 2.4.4, which reportedly does not reflect the state of the original repository. An old version of the package along with documentation should be available for users that don't want to migrate. To release this final version of the original package a legacy RTD site should be available.
Then let's let things settle for a couple of weeks and...
|
After thinking about it, the name change on all these platforms is probably going to be hard, I'm not sure if it's worth it. Many outdated modules and programs will stop working even with the warnings on new downloads. Specially because using this new API isn't possible if you're using Python <3.7, which is a majority. Maybe we should get more opinions from the original github repo before doing anything else. But if you still want to do the rename, I'll submit a request on the AUR soon. |
I have been somewhat hesitant as well. It can break things. That being said I have two arguments: The package is better off requiring 3.7
The package should take over the spotipy name
Some questions:
|
With this explanation the idea sounds much better to me. Specially because if the PyPi guys are okay with it, it's for a reason. And they have much more experience with this. As long as the old API still has a place in PyPi so that it can still be used, it should be okay, I guess. AFAIK the name change on the AUR shouldn't be too hard, I'll keep you updated. I'm not sure if the new release should have warnings too. It depends on how long this process is. But it's a good idea. |
Here's the thread: https://lists.archlinux.org/pipermail/aur-general/2019-October/035493.html I'm not too experienced with this but let's see how it goes :^) |
Here's what the PKGBUILD would look like: # Maintainer: Mario O.M. <marioortizmanero@gmail.com>
pkgname=python-spotipy
pkgver=3.0.0
pkgrel=1
pkgdesc="Client for the Spotify Web API"
arch=("any")
url="https://github.com/felix-hilden/spotipy"
license=("custom:MIT")
depends=("python>=3.7" "python-requests")
makedepends=("python-setuptools")
source=("https://github.com/felix-hilden/spotipy/archive/${pkgver}.tar.gz")
build() {
cd "spotipy-$pkgver"
python setup.py build
}
package() {
cd "spotipy-$pkgver"
python setup.py install --root="$pkgdir" --optimize=1 --skip-build
install -Dm644 LICENSE "$pkgdir/usr/share/licenses/$pkgname/LICENSE"
}
Edit: Okay I updated the script with what you answered |
Looks good, but the description could be the same as will be in PyPI: "Client for the Spotify Web API". The first release will be 3.0 if nothing too surprising happens during the PyPI transfer. A requests version could be pinned down, I'll look into it. Releases will be named conventionally, |
By the way, it'd also be a good idea to let the Spotify devs know in spotify/web-api |
Good idea, I'll do that on first release. |
Since there seem to be some stalling/many "ifs" regarding transferring of ownerships, and since this library is already kind of backward incompatible with the "original"
|
I was a bit conflicted too on the name change, but here are some counterpoints:
Of course these are just options to consider and we're all up for discussion here. It's only my opinion after all, and I'm not even the owner of this repo :) |
Thank you both! The most important deal for me is addressing the problems in old Spotipy and taking care of its users who are often left confused. Many users have complained about the repo being out of sync with PyPI and to be frank, at least after the playlist API changes somewhere early 2019 the library is quite obsolete. And as I've pointed out in a number of issues and comments, and as Mario mentioned, the library is still popular! This rewrite is still based on Plamere's code, even though lots of refactoring has been done. Starting a third Spotify library (Spotipy, pyfy and this) and waiting for users to discover it would be a waste in my opinion. Thousands of users would continue to download the obsolete version and discover out-of-sync documentation. So,
Let me know what you think and if you have any further concerns. |
Spotipy has been transferred on PyPI! |
Wait, already? That's awesome! :) So now we have to wait for Read The Docs, right? Is there something else that can be done for now besides the deprecation warnings? |
To release the new old versions (2.4.5 and 2.5) we need a stable link to the old documentation. So any release to PyPI has to wait for RTD as well. That's 19.12. or later. And the Plamere repo should be informed at some point as well. I'll add that to the todo list. |
@felix-hilden Any way to install this package using
|
I think I may have missed your point, SHxKM, about the immediate visibility of a new name. Or at least there is one more argument to be made in favor of having another name. Users that have gotten used to the fact that But this doesn't tip the scale for me. |
@felix-hilden fair enough. I actually use the old spotipy in a fairly popular web app and would be bummed to upgrade and have everything break (in tests of course), then sometime after figure out the whole library has changed. But you’re the one currently doing all the hard work and it’s safe to say you have more dev experience than me, so take my advice with a grain of salt. |
@felix-hilden you can't just replace a library that's being downloaded hundreds of time daily and make it fully backward-incompatible. That would mean that 100% of existing apps and examples on the web that suggest to do People are free to create forks, one alternative fork for spotipy seems to be https://github.com/Harrison97/spotipy. You can also create your own fork. If your library is not a fork, it's a new library, not a replacement. @marioortizmanero's idea to use spotipy3 would be OK in my opinion. |
A good way of getting more opinions on this would be posting an issue in the original repo or in an already existing one. We should warn there before releasing it anyway. |
I second posting about this to the original repository. But first, let's cut the hostility and find some common ground. I'd like to find the correct way to proceed. No solution will fully satisfy everyone, we all have our own horse in the race some way or another. Exaggerated statements like "100 % of apps would break" are obviously incorrect merely by the fact that this will be Python 3.7+ only. One could hit back with another low blow by saying that Plamere's own examples of searching for items without authentication don't work. My worry is exactly that: hundreds of people downloading the package and being left confused, daily. So let's try finding that common ground.
On the topic of choosing another potential name, let it be known that I really dislike naming things Side note, everything breaking would of course be avoided by pinning down the version: SHxKM, did you manage to install the package with pipenv? I could look into it a bit more if there's something we can do to make it installable from GitHub. After releasing its value will of course diminish a lot but if pipenv is gaining traction, we could try to support it. |
@felix-hilden no, and honestly I just moved to using |
@felix-hilden I saw that plamere is active on Twitter https://twitter.com/plamere, did you try to reach out with your current concerns? |
Thats too bad, SHxKM, well perhaps it can be considered some other time. When transferring ownership of the package, Plamere was contacted via Twitter and pinged on GitHub. He did not respond. I take it that he is not intetested in discussing the future of his own package. What did you think about my points? And this is for everyone, not just @stephanebruckert. |
@felix-hilden - I always tend to take the path with the least (potential) drama. How similar is this spotipy to the old one? From my initial usage, not overly, and in a good way. But again, maybe I’m looking at it too narrowly. |
I like that principle. If there is no other more important deciding factor I'd also like to minimise drama. But I don't think it is the highest value of all. This package is similar in spirit and feel, but streamlined. Most notable changes in the client and authentication modules are renaming methods and classes, making them more consistent, implementing the remaining endpoints and splitting some methods that were hard to call right without a careful read of the argument descriptions, like Scope, sender, and serialise modules were not present in the old version and are not necessarily needed. The util module was expanded beyond just prompting for a user token. |
One approach to deprecating the package could be to let the two clients co-exist for a while, for example as |
Here is my estimate of what the average user would experience when publishing 3.0. Not aware of the rewriteNew individual user or app developerA working library and comprehensive documentation, outdated resources elsewhere on the web. Old individual userScripts breaking after an update. Most likely they will discover that there is no
they will be informed of what took place and either downgrade or modify their code. Old app developerTests or even app breaking if the tests are not comprehensive enough, confused users complaining after they manually update Spotipy. Like the individual users they will discover the rewrite and update their dependencies and code accordingly. Aware of the rewriteThings could be a lot better though. If they upgrade to the deprecation notice version, they will be able to prepare for the change. So maybe a few weeks of notice isn't enough. A month perhaps? These steps required to react to the update seem reasonable to me. In the absence of comments and opinions of others, particularly @stephanebruckert, I'll assume the concerns raised were properly addressed and that we agree to continue as planned. |
This is a similar situation to the Python 2 deprecation. Python 2 was outdated and needed some serious changes and the only way to do this was by using a new not-backwards-compatible version. Of course, this had its ups and downs but I think overall the community ended up winning with it. It can be annoying to "rewrite" one of your projects from one version to another, but you have to do it in order to keep your app updated. You can always modify But the deprecation has to be long enough for everyone to know. You should post this in the old repo as soon as possible IMO. |
I can't follow everything being said and I'm not the one deciding anyway, though I have my own opinion. This is why it's probably better to raise this with the wider community at https://github.com/plamere/spotipy than here in the background. It will open different subjects that haven't been discussed objectively, such as:
Please also let the community know that:
|
Thank you both for the comments! I'll move the notice/discussion earlier on the plan and post an issue to discuss this. But to answer the some of your points Stephane, Plamere really has abandoned the package, which was disappointing to me as well, not to mention the people raising issues on the repo. There are many other rewrites and forks, but none of them are in active development. One of them however, Harrison's fork, is almost as popular though slowly falling behind. |
The issue has been posted here! |
I pinned Requests to |
I have now handed Spotipy back to the original owner, as he suddenly became available again. This library will continue as another thing. Next up:
@marioortizmanero This won't be |
Sure! I'm still going to use this library for my personal proyect, and it's awesome enough to be in the AUR :) |
Fantastic, thank you! Actually, that made me think. We could have a showcase of some projects that use this library somewhere, that'd be really cool. Users could submit their applications and be inspired from others. A positive feedback loop for the package. Maybe in the documentation index, right after the feature list? |
Sure, sounds like a great idea. I could add mine if you want, then. The positioning you suggested also seems adequate :) |
|
On the AUR too! Please make sure everything is correct :) https://aur.archlinux.org/packages/python-tekore/ It was wonderfully easy to upload! AFAIK there isn't a python-dataclasses package because Arch Linux uses Python 3.8, so that part isn't needed. |
Fantastic! Fair enough, so dropping the Python requirement down to 3.6 isn't sensible either? What if someone purposefully installs 3.6 on their machine? I imagine other dependencies might affect the decision. Are |
If someone is still using 3.6, it's probably inside a virtual environment, which has easy access to |
Version 1.0.0 has been released and spotify informed in spotify/web-api#1429. It's been a long discussion, but I'm happy to finally close it. I thought about the showcase for applications a bit more, and decided it was not such a good idea after all. I'd still love to show off them somewhere, but to have them in our source could be a pain eventually - having to update the links and remove broken ones and such. There could be some sort of community put up somewhere. That would be a good place for Q&A and these kinds of fun stuff. |
Great! I've updated the AUR repo as well. |
I'm creating this issue to keep track of this API progress. I know it's too early to release it but this is helpful for people who want to use it via PyPi in their project. It'd also need a new name, as I told you in the original spotipy thread.
Also, I wanted to let you know that once it's done I can take care of uploading and maintaining it in the AUR repos.
The text was updated successfully, but these errors were encountered: