Skip to content

Commit 9c854f4

Browse files
authored
Merge pull request #96 from RIPE-NCC/python_upgrade
Python upgrade to 3.10-3.13
2 parents a1ad023 + 5e30973 commit 9c854f4

16 files changed

Lines changed: 83 additions & 128 deletions
Lines changed: 32 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,32 @@
1+
# This workflow will install Python dependencies, run tests and lint with a variety of Python versions
2+
# For more information see: https://help.github.com/actions/language-and-framework-guides/using-python-with-github-actions
3+
4+
name: Python package
5+
6+
on:
7+
push:
8+
branches: [ '*' ]
9+
pull_request:
10+
branches: [ $default-branch ]
11+
12+
jobs:
13+
build:
14+
15+
runs-on: ubuntu-latest
16+
strategy:
17+
fail-fast: false
18+
matrix:
19+
python-version: ["3.10", "3.11", "3.12", "3.13"]
20+
21+
steps:
22+
- uses: actions/checkout@v2
23+
- name: Set up Python ${{ matrix.python-version }}
24+
uses: actions/setup-python@v2
25+
with:
26+
python-version: ${{ matrix.python-version }}
27+
- name: Install dependencies
28+
run: |
29+
python -m pip install --upgrade pip
30+
python -m pip install tox
31+
- name: tox
32+
run: tox

.travis.yml

Lines changed: 0 additions & 12 deletions
This file was deleted.

CHANGES.rst

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,9 @@
11
Changelog
22
=========
3+
* 2.0.0
4+
* Official supported Python versions changed to 3.10, 3.11, 3.12 and 3.13
5+
* Removed test on invalid country codes in SSL certs, in line with the behaviour of the cryptography library
6+
* Reinstated integration with readthedocs.io
37
* 1.3.1
48
* Ping edge case fix
59
* Add py37 testing

README.rst

Lines changed: 0 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -31,17 +31,6 @@ Better yet, make sure you get ujson and sphinx installed with it:
3131
3232
$ pip install ripe.atlas.sagan[fast,doc]
3333
34-
Troubleshooting
35-
~~~~~~~~~~~~~~~
36-
37-
Some setups (like MacOS) have trouble with building the dependencies required
38-
for reading SSL certificates. If you don't care about SSL stuff and only want to
39-
use sagan to say, parse traceroute or DNS results, then you can do the following:
40-
41-
.. code:: bash
42-
43-
$ SAGAN_WITHOUT_SSL=1 pip install ripe.atlas.sagan
44-
4534
Quickstart: How To Use It
4635
-------------------------
4736

docs/installation.rst

Lines changed: 0 additions & 25 deletions
Original file line numberDiff line numberDiff line change
@@ -66,28 +66,3 @@ you can always do that too. Simply un-tar the file and run the following in the
6666
same directory as ``setup.py``.::
6767

6868
$ python setup.py install
69-
70-
71-
.. _installation-troubleshooting:
72-
73-
Troubleshooting
74-
---------------
75-
76-
Some setups (like MacOS) have trouble with building the dependencies required
77-
for reading SSL certificates. If you don't care about SSL stuff and only want
78-
to use sagan to say, parse traceroute or DNS results, then you can do the following:
79-
80-
$ SAGAN_WITHOUT_SSL=1 pip install ripe.atlas.sagan
81-
82-
More information can also be found `here`_.
83-
84-
If you *do* care about SSL and have to use a Mac, then `this issue`_ will likely
85-
be of assistance. Essentially, you will need to uninstall Xcode (if it's
86-
installed already), then attempt to use ``gcc``. This will trigger the OS to
87-
ask if you want to install the Xcode compilation tools. Click ``install``, and
88-
when that's finished, install Sagan with this command:
89-
90-
$ CFLAGS="-I/usr/include" pip install ripe.atlas.sagan
91-
92-
.. _here: https://cryptography.io/en/latest/installation/
93-
.. _this issue: https://github.com/RIPE-NCC/ripe.atlas.sagan/issues/52

ripe/atlas/sagan/version.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,4 +13,4 @@
1313
# You should have received a copy of the GNU General Public License
1414
# along with this program. If not, see <http://www.gnu.org/licenses/>.
1515

16-
__version__ = "1.3.1"
16+
__version__ = "2.0.0"

setup.py

Lines changed: 38 additions & 46 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
11
import os
2+
from os.path import abspath, dirname, join
23
from setuptools import setup
34

45
__version__ = None
@@ -8,55 +9,46 @@
89
install_requires = [
910
"python-dateutil",
1011
"pytz",
12+
"cryptography",
1113
]
1214

13-
tests_require = ["nose"]
14-
15-
if "SAGAN_WITHOUT_SSL" not in os.environ:
16-
install_requires.append("cryptography")
17-
1815
# Allow setup.py to be run from any path
1916
os.chdir(os.path.normpath(os.path.join(os.path.abspath(__file__), os.pardir)))
2017

21-
readme_path = os.path.join(os.path.dirname(__file__), "README.rst")
22-
changelog_path = os.path.join(os.path.dirname(__file__), "CHANGES.rst")
18+
# Get proper long description for package
19+
current_dir = dirname(abspath(__file__))
20+
description = open(join(current_dir, "README.rst")).read()
21+
changes = open(join(current_dir, "CHANGES.rst")).read()
22+
long_description = "\n\n".join([description, changes])
2323

24-
# Get the long description from README.md
25-
with open(readme_path) as readme:
26-
with open(changelog_path) as changelog:
27-
setup(
28-
name="ripe.atlas.sagan",
29-
version=__version__,
30-
packages=["ripe", "ripe.atlas", "ripe.atlas.sagan"],
31-
namespace_packages=["ripe", "ripe.atlas"],
32-
include_package_data=True,
33-
license="GPLv3",
34-
description="A parser for RIPE Atlas measurement results",
35-
long_description="{readme}\n\n{changelog}".format(
36-
readme=readme.read(),
37-
changelog=changelog.read()
38-
),
39-
url="https://github.com/RIPE-NCC/ripe.atlas.sagan",
40-
download_url="https://github.com/RIPE-NCC/ripe.atlas.sagan",
41-
author="The RIPE Atlas Team",
42-
author_email="atlas@ripe.net",
43-
maintainer="The RIPE Atlas Team",
44-
maintainer_email="atlas@ripe.net",
45-
install_requires=install_requires,
46-
tests_require=tests_require,
47-
extras_require={
48-
"fast": ["ujson"],
49-
"doc": ["sphinx"]
50-
},
51-
test_suite="nose.collector",
52-
classifiers=[
53-
"Operating System :: POSIX",
54-
"Operating System :: Unix",
55-
"Programming Language :: Python",
56-
"Programming Language :: Python :: 2.7",
57-
"Programming Language :: Python :: 3.5",
58-
"Programming Language :: Python :: 3.6",
59-
"Programming Language :: Python :: 3.7",
60-
"Topic :: Internet :: WWW/HTTP",
61-
],
62-
)
24+
setup(
25+
name="ripe.atlas.sagan",
26+
version=__version__,
27+
packages=["ripe", "ripe.atlas", "ripe.atlas.sagan"],
28+
namespace_packages=["ripe", "ripe.atlas"],
29+
include_package_data=True,
30+
license="GPLv3",
31+
description="A parser for RIPE Atlas measurement results",
32+
long_description=long_description,
33+
url="https://github.com/RIPE-NCC/ripe.atlas.sagan",
34+
download_url="https://github.com/RIPE-NCC/ripe.atlas.sagan",
35+
author="The RIPE Atlas Team",
36+
author_email="atlas@ripe.net",
37+
maintainer="The RIPE Atlas Team",
38+
maintainer_email="atlas@ripe.net",
39+
install_requires=install_requires,
40+
extras_require={
41+
"fast": ["ujson"],
42+
"doc": ["sphinx"]
43+
},
44+
classifiers=[
45+
"Operating System :: POSIX",
46+
"Operating System :: Unix",
47+
"Programming Language :: Python",
48+
"Programming Language :: Python :: 3.10",
49+
"Programming Language :: Python :: 3.11",
50+
"Programming Language :: Python :: 3.12",
51+
"Programming Language :: Python :: 3.13",
52+
"Topic :: Internet :: WWW/HTTP",
53+
],
54+
)

tests/__init__.py

Lines changed: 0 additions & 22 deletions
Original file line numberDiff line numberDiff line change
@@ -1,22 +0,0 @@
1-
# Copyright (c) 2015 RIPE NCC
2-
#
3-
# This program is free software: you can redistribute it and/or modify
4-
# it under the terms of the GNU General Public License as published by
5-
# the Free Software Foundation, either version 3 of the License, or
6-
# (at your option) any later version.
7-
#
8-
# This program is distributed in the hope that it will be useful,
9-
# but WITHOUT ANY WARRANTY; without even the implied warranty of
10-
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
11-
# GNU General Public License for more details.
12-
#
13-
# You should have received a copy of the GNU General Public License
14-
# along with this program. If not, see <http://www.gnu.org/licenses/>.
15-
16-
from .ping import *
17-
from .traceroute import *
18-
from .dns import *
19-
from .ssl import *
20-
from .http import *
21-
from .ntp import *
22-
from .wifi import *
File renamed without changes.
File renamed without changes.

0 commit comments

Comments
 (0)