Skip to content

Commit

Permalink
python.org -> pypi.org
Browse files Browse the repository at this point in the history
  • Loading branch information
wimglenn committed Aug 28, 2018
1 parent a60f375 commit b5ac81a
Show file tree
Hide file tree
Showing 4 changed files with 12 additions and 12 deletions.
2 changes: 1 addition & 1 deletion run.py
Original file line number Diff line number Diff line change
Expand Up @@ -143,7 +143,7 @@ def get_elapsed():
return PackageResult(name, version, 0, 'SKIPPED', 'Skipped', description,
get_elapsed())

client = ServerProxy('https://pypi.python.org/pypi')
client = ServerProxy('https://pypi.org/pypi')
basename = download_package(client, name, version)
if basename is None:
status_code, output = 1, 'No sdist found'
Expand Down
10 changes: 5 additions & 5 deletions templates/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ <h1>pytest Plugins Compatibility</h1>
<p>This page shows results of compatibility tests between <a href="https://pytest.org">pytest</a> plugins
against different versions of the python interpreter.
</p>
<p>The plugins are listed and tested automatically from <a href="https://pypi.python.org/pypi">pypi</a>.
<p>The plugins are listed and tested automatically from <a href="https://pypi.org/">PyPI</a>.
For more information, please see <a href="https://github.com/pytest-dev/plugincompat">
https://github.com/pytest-dev/plugincompat</a>.
</p>
Expand All @@ -20,9 +20,9 @@ <h1>pytest Plugins Compatibility</h1>
<strong>Note:</strong> although some may appear as "broken" keep in mind
that all dependencies may not be installed during testing, particularly
if a dependency is too big or requires a dedicated server (such
as <a href="https://pypi.python.org/pypi/pytest-jira">pytest-jira</a>,
as <a href="https://pypi.org/project/pytest-jira">pytest-jira</a>,
which requires a jira server, or
<a href="https://pypi.python.org/pypi/pytest-qt">pytest-qt</a>,
<a href="https://pypi.org/project/pytest-qt">pytest-qt</a>,
which requires PyQt or PySide, both which take a long time to install).
Take the information you find here with a grain of salt, and rely on
each plugin's homepage for up-to-date compatibility information.
Expand All @@ -42,7 +42,7 @@ <h1>pytest Plugins Compatibility</h1>
<tbody>
{% for lib_name in lib_names %}
<tr>
<td><a href="https://pypi.python.org/pypi/{{ lib_name.rsplit('-', 1)[0] }}">{{ lib_name }}</a></td>
<td><a href="https://pypi.org/project/{{ lib_name.rsplit('-', 1)[0] }}">{{ lib_name }}</a></td>
<td>{{ descriptions[lib_name]}}</td>
{% for python_ver in python_versions %}
<td>
Expand All @@ -66,7 +66,7 @@ <h1>pytest Plugins Compatibility</h1>
{% for lib_name in lib_names %}
<a id="{{lib_name}}"/>
<table class="striped rounded metro">
<caption><a href="https://pypi.python.org/pypi/{{ lib_name.rsplit('-', 1)[0] }}">{{ lib_name }}</a></caption>
<caption><a href="https://pypi.org/project/{{ lib_name.rsplit('-', 1)[0] }}">{{ lib_name }}</a></caption>
<thead>
<tr>
<th>pytest</th>
Expand Down
2 changes: 1 addition & 1 deletion templates/status_help.html
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ <h3>/status/:name/</h3>
</li>
</ul>

<p>For example, to query the status of plugin <a href="https://pypi.python.org/pypi/{{ name }}">{{ name }}</a> for
<p>For example, to query the status of plugin <a href="https://pypi.org/project/{{ name }}">{{ name }}</a> for
python 3.3 and pytest version 2.4.2, hit this url:</p>

<code>/status/{{ name }}?py=py33&pytest=2.4.2</code>
10 changes: 5 additions & 5 deletions update_index.py
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@
import sys
from distutils.version import LooseVersion

if sys.version_info[0] == 3:
if sys.version_info >= (3,):
from xmlrpc.client import ServerProxy
else:
from xmlrpclib import ServerProxy
Expand All @@ -31,12 +31,12 @@


def iter_plugins(client):
'''
"""
Returns an iterator of (name, latest version, summary) from PyPI.
:param client: xmlrpclib.ServerProxy
:param search: package names to search for
'''
"""
# previously we used the more efficient "search" XMLRPC method, but
# that stopped returning all results after a while
package_names = [x for x in client.list_packages()
Expand Down Expand Up @@ -82,7 +82,7 @@ def write_plugins_index(file_name, plugins):
contents = json.dumps(plugin_contents, indent=2, separators=(',', ': '),
sort_keys=True)
if os.path.isfile(file_name):
if sys.version_info[0] < (3,):
if sys.version_info < (3,):
mode = 'rU'
else:
# universal newlines is enabled by default, and specifying it
Expand All @@ -102,7 +102,7 @@ def write_plugins_index(file_name, plugins):


def main():
client = ServerProxy('https://pypi.python.org/pypi')
client = ServerProxy('https://pypi.org/pypi')
plugins = sorted(iter_plugins(client))

if write_plugins_index(INDEX_FILE_NAME, plugins):
Expand Down

0 comments on commit b5ac81a

Please sign in to comment.