pip doesn't grab latest version of tweepy? - python

Using 'pip install tweepy' I get version 1.7.1 of tweepy which is quite old and certainly doesn't support oauth.
Has a new version of the package not been published?
It's still under active development. Do I need pull the source from GIT? I'm just surprised there isn't a newer package. Am I missing something?
Thanks.

1.7.1 is the latest version on pypi, and the last tag listed in on github. I'd say pip is doing exactly what it's supposed to be doing.

Related

Is there any documentation about spyder reports?

I just found out about spyder-reports which can both generate the python code and the HTML output from the .mdw file. I installed it with pip, but then I didn't found any way to work with it. I am using spyder 4.1.3 with python 3.6.4, and nothing changed in the interface, opening a .mdw file doesn't seem to propose anything.. How does this plugin work?
Is there any documentation, examples, I could use to figure out how it works?
Unfortunately, no. According to their GitHub issues:
Sorry, this plugin is unmaintained now and it's not compatible with the latest release of Pweave. We'll come back to it after we release Spyder 4.
and
This plugin is unmaintained and not compatible with the latest release of Pweave. To help update it or see the status of that work, visit this link.
Your best bet at this time is to uninstall since the installation downgrades some packages:
pip uninstall spyder-reports
or
conda uninstall spyder-reports
Sources:
https://github.com/spyder-ide/spyder-reports/issues/76
https://github.com/nathancarter/spyder-reports/commit/5fcddd1503e17b5db8df6f0dbe7444f1698824a6

Why is there a pip package in pip?

So I was looking through PyPI and I found this: https://pypi.org/project/pip/
What is the reason for this? Why does this exist, and why would it be useful?? Isnt it kinda recursive in a way?
pip can update itself to a newer version and has a bootstrapper called get-pip.py to install it for the first time. Since recent Python versions have it pre-installed, upgrading is usually all that is needed to get the latest version of pip.
See https://pip.pypa.io/en/stable/installing.
Why is there a pip package in pip?
I think you're conflating the following two tools:
PyPI (https://pypi.org) is a repository for hosting Python packages
pip (https://pypi.org/p/pip) is an installer that downloads packages from PyPI

Why isn't pip installing the latest version of a package, even when a newer version is on PyPI?

I was trying to upgrade to the latest version of a package I had installed with pip, but for some reason it won't get the latest version. I've tried uninstalling the package in question, or even reinstalling pip entirely, but it still refuses to get the latest version from PyPI. When I try to pin the package version (e.g. pip install package==0.10.0) it says that it "Could not find a version that satisfies the requirement package==0.10.0 (from versions: ...)"
pip search package even acknowledges that the installed version isn't the latest, labeling the two versions for me.
I've seen other questions with external files or local versions, but I've tried the respective solutions (--allow-external doesn't exist anymore, and --no-cache-dir doesn't help) and I'm still stuck on the older version.
I was trying to upgrade Quart. Maybe other packages have something else going on.
In this particular case, Quart had dropped support for Python 3.6 (the version I had installed) and only supported 3.7 or later. (This was a fairly recent change to the project, so I just didn't see the news.)
However, when attempting to install a package only supported by a later Python, pip doesn't really explain why it couldn't find a version to satisfy the requirement - instead, it just lists all the versions that should work with the current Python, without indicating that more exist and just can't be installed.
The only real options to fix are:
Update your Python to meet the package's requirements
Ask/help the maintainer to backport the package to the version you have.

How to download previous version of Werkzeug

How do I download previous version of Werkzeug from a trusted site?
Here is what I have tried:
1) I went to this link:
http://werkzeug.pocoo.org/docs/0.9/installation/#installing-a-released-version
and clicked on the "Download Page" link.
It took me to the 0.10.4 download page.
2) I googled "Werkzeug download 0.9" and only got references to 0.10. There was a download link to a versioneye.com site that I don't know if I can trust.
I need to download the previous version because 0.10.x dropped support for support for OpenSSL.
[edit] I have to download rather than install from pip because I don't have access to pip on the old machine I am installing on. It is old, hence the complications.
[edit] I had to use the older version because 0.10.x dropped support for the OpenSSL package in favor of ssl built into Python 2.7.9. I was stuck on Python 2.7.5 so I wanted to continue to use OpenSSL package. I think they made the right decision to drop support as the majority of people can upgrade to 2.7.9.
You can install an old package with pip:
pip install Werkzeug==0.9.6
Building on f43d65's comment, I have refined it to these steps which include making sure it is coming from a reliable source:
goto the official website: http://werkzeug.pocoo.org/
click link to official github account: https://github.com/mitsuhiko/werkzeug
click on releases tab: https://github.com/mitsuhiko/werkzeug/releases
Note: the instructions make sure that the download is coming from the official source.
go in pycharm settings and then in interprator click on + there in packages and then search for werkzeug there, after click on versions and choose old version. it did work for me.

Who updates pip package versions?

I was having problems with one package not doing what I read in it's documentation, until I noticed that pip installed a outdated version.
On the pip package page it would seem like it was last update 2014, but when I installed, the package files were versioned mid 2013.
How does updating pip packages work and who should be doing it? The project maintainer (on github, or on pip pages?)?
All packages that can be downloaded with PIP are actually hosted on the Python Package Index. The Python organization collaborates with project maintainers to host the projects.
The problem with having outdated packages on pip that do not align with the documentation and current state on github can be really annoying. Despite that you did not ask for a workaround I would like to contribute one in case that other users might land on this page looking for such.
First uninstall the package you installed via pip before:
pip uninstall package
Next install the latest version directly from the github repo:
pip install git+https://github.com/user/package.git
The cool thing about this is that you can still manage your packages with pip but your not limited by what version is available on the Python Package Index.

Categories

Resources