Comments (3)
Take a look at gs-pypi-generate-db
. After db is generated, create a git repo in db dir and adapt /etc/g-sorcery/gs-pypi.json
to include your custom db:
"repositories": {
"pypi": {
"repo_uri": "https://pypi.python.org/",
"sync_method": "git",
"db_uri": "file:///path/to/db",
"branch": "master"
}
}
...
from gs-pypi.
Related bug report: https://bugs.gentoo.org/607666
from gs-pypi.
Is this even possible anymore?
# gs-pypi-generate-db test
--2018-08-13 17:20:26-- https://pypi.python.org/pypi?%3Aaction=index
Resolving pypi.python.org... 151.101.124.223, 2a04:4e42:1e::223
Connecting to pypi.python.org|151.101.124.223|:443... connected.
HTTP request sent, awaiting response... 301 Redirect to Primary Domain
Location: https://pypi.org/pypi?%3Aaction=index [following]
--2018-08-13 17:20:26-- https://pypi.org/pypi?%3Aaction=index
Resolving pypi.org... 151.101.64.223, 151.101.192.223, 151.101.128.223, ...
Connecting to pypi.org|151.101.64.223|:443... connected.
HTTP request sent, awaiting response... 301 Moved Permanently
Location: https://pypi.org/pypi/?%3Aaction=index [following]
--2018-08-13 17:20:26-- https://pypi.org/pypi/?%3Aaction=index
Reusing existing connection to pypi.org:443.
HTTP request sent, awaiting response... 301 Moved Permanently
Location: https://pypi.org/ [following]
--2018-08-13 17:20:26-- https://pypi.org/
Reusing existing connection to pypi.org:443.
HTTP request sent, awaiting response... 200 OK
Length: 17271 (17K) [text/html]
Saving to: ‘/tmp/tmp0zlfwza7/packages’
/tmp/tmp0zlfwza7/packages 100%[=================================================================>] 16.87K --.-KB/s in 0.02s
2018-08-13 17:20:26 (1.04 MB/s) - ‘/tmp/tmp0zlfwza7/packages’ saved [17271/17271]
/usr/lib64/python3.5/site-packages/bs4/__init__.py:181: UserWarning: No parser was explicitly specified, so I'm using the best available HTML parser for this system ("lxml"). This usually isn't a problem, but if you run this code on another system, or in a different virtual environment, it may use a different parser and behave differently.
The code that caused this warning is on line 18 of the file /usr/lib/python-exec/python3.5/gs-pypi-generate-db. To get rid of this warning, change code that looks like this:
BeautifulSoup(YOUR_MARKUP})
to this:
BeautifulSoup(YOUR_MARKUP, "lxml")
markup_type=markup_type))
Traceback (most recent call last):
File "/usr/lib/python-exec/python3.5/gs-pypi-generate-db", line 18, in <module>
sys.exit(gs_pypi_generate_db.main())
File "/usr/lib64/python3.5/site-packages/gs_pypi/gs_pypi_generate_db.py", line 68, in main
common_config=config["common_config"])
File "/usr/lib64/python3.5/site-packages/g_sorcery/package_db.py", line 563, in __call__
self.generate_tree(pkg_db, common_config, config)
File "/usr/lib64/python3.5/site-packages/g_sorcery/package_db.py", line 577, in generate_tree
data = self.download_data(common_config, config)
File "/usr/lib64/python3.5/site-packages/g_sorcery/package_db.py", line 595, in download_data
self.process_uri(uri, data)
File "/usr/lib64/python3.5/site-packages/g_sorcery/package_db.py", line 606, in process_uri
data.update(load_remote_file(**uri))
File "/usr/lib64/python3.5/site-packages/g_sorcery/fileutils.py", line 301, in load_remote_file
open_file=open_file, open_mode=open_mode))
File "/usr/lib64/python3.5/site-packages/g_sorcery/fileutils.py", line 258, in _call_parser
data = parser(f)
File "/usr/lib64/python3.5/site-packages/gs_pypi/pypi_db.py", line 62, in parse_data
for entry in packages.find_all("tr")[1:last]:
AttributeError: 'NoneType' object has no attribute 'find_all'
from gs-pypi.
Related Issues (16)
- !!! Repository 'pypi' is missing masters attribute in '/var/lib/layman/pypi/metadata/layout.conf' !!! Set 'masters = gentoo' in this file for future compatibility HOT 1
- PyPI source URLs are broken
- No supported implementation in PYTHON_COMPAT
- Wrong URLs HOT 1
- gs-pypi-generate-db: ERROR 404: Not Found. HOT 1
- Add python3.6 compatibility
- Python versions supported by packages aren't parsed properly.
- Failed to add repo to layman with pyvisa HOT 5
- Use git to update the database HOT 3
- sudo layman --add pypi FAILED HOT 6
- Using gs-pypi for installing wheels (not from PyPI) HOT 1
- DependencyError: no package with name keras found HOT 3
- no package with name skflow found HOT 2
- Resolving dependencies HOT 2
- redundant variables REALNAME and REALVERSION
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from gs-pypi.