Last modified: 2014-05-27 01:51:38 UTC
Intention: I'm building a script to upload into Internet Archive pdf files that need some previous painful manipulation (converting into tiffs, then cropped, splitted and sometines rotated); a good set of metadata (those needed for a good Book template) could be uploaded too. Reproducible: Didn't try
I forgot to report the main information! Python package that allows Internet Archive management can be found here: https://pypi.python.org/pypi/internetarchive
After migrating into eqiad, local installation of internetarchive gives an ImportError and doesn't run any more. The new message into eqiad is: from requests.auth import AuthBase ImportError: cannot import name AuthBase pip doesn't run in eqiad so we can't even try to fix the issue; careful global installation is needed.
Have you tried installing the Python package in your home directory? Is that possible?
I tried, but pip seems lacking into eqiad; internetarchive installation is not simple, i.e. I got often a (random!) ImportError message when running my test python script with jsub, while I never got it running the same by itsource prompt. So, a global, careful installation of internetarchive module is a good idea; I think that a better idea could be, to integrate it into pywikibot, given the interest of IA for wikisource projects and possible automatic alignment of IA-Common-Wikidata-Wikisource metadata.
I see that the bug is now assigned to marc Pelletier: thanks for attention! :-)
virtualenv --no-site-packages env echo "source $HOME/env/bin/activate" >> .bashrc source $HOME/env/bin/activate pip install internetarchive ---- This will work, if you're interested in using virtualenv.
I furiusly browsed python doc to see what virtualenv is; it doesn't seems something so alarming, I'll try. Thanks MZMcBride.
@MZMcBride: Great: env, pip, internetarchive, OpalLib.py running! Thanks again.
Please add to <https://wikitech.wikimedia.org/wiki/Nova_Resource:Tools/Help#My_Tool_requires_a_package_that_is_not_currently_installed_in_Tool_Labs._How_can_I_add_it.3F>
Re-prioritizing since this only needs documentation.