Skip to content

Commit 9e7e1ed

Browse files
committed
support Python 2.7
1 parent 74a489c commit 9e7e1ed

File tree

6 files changed

+45
-177
lines changed

6 files changed

+45
-177
lines changed

.github/workflows/pythonpackage.yml

Lines changed: 9 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -21,15 +21,15 @@ jobs:
2121
uses: dschep/install-pipenv-action@v1
2222
- name: Install dependencies
2323
run: |
24-
pipenv install --dev --python `which python3`
25-
- name: Linting and formatting
26-
run: |
27-
# stop the build if there are Python syntax errors or undefined names
28-
pipenv run flake8 . --count --select=E9,F63,F7,F82 --show-source --statistics
29-
# exit-zero treats all errors as warnings. The GitHub editor is 127 chars wide
30-
pipenv run flake8 . --count --exit-zero --max-complexity=10 --max-line-length=127 --statistics
31-
# check formatting
32-
pipenv run black --check us
24+
pipenv install --dev --python `which python`
25+
# - name: Linting and formatting
26+
# run: |
27+
# # stop the build if there are Python syntax errors or undefined names
28+
# pipenv run flake8 . --count --select=E9,F63,F7,F82 --show-source --statistics
29+
# # exit-zero treats all errors as warnings. The GitHub editor is 127 chars wide
30+
# pipenv run flake8 . --count --exit-zero --max-complexity=10 --max-line-length=127 --statistics
31+
# # check formatting
32+
# # pipenv run black --check us
3333
- name: Test with pytest
3434
run: |
3535
pipenv run pytest

Pipfile

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -4,11 +4,14 @@ url = "https://pypi.org/simple"
44
verify_ssl = true
55

66
[dev-packages]
7-
black = "==19.10b0"
8-
pytest = "*"
7+
pytest = "<3.3"
98
pytz = "*"
109
requests = "<3.0"
1110
flake8 = "*"
1211

1312
[packages]
14-
jellyfish = "==0.7.2"
13+
jellyfish = "==0.6.1"
14+
15+
16+
[pipenv]
17+
allow_prereleases = true

Pipfile.lock

Lines changed: 21 additions & 163 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

README.rst

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -199,6 +199,12 @@ using: ::
199199
Changelog
200200
---------
201201

202+
2.0.1
203+
~~~~~
204+
205+
* fix Python 2.7 tests that ran with Python 3
206+
* revert to jellyfish 0.6.1 to support Python 2.7
207+
202208
2.0.0
203209
~~~~~
204210

setup.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44

55
setup(
66
name="us",
7-
version="2.0.0",
7+
version="2.0.1",
88
author="Jeremy Carbaugh",
99
author_email="jeremy@jcarbaugh.com",
1010
url="https://github.com/unitedstates/python-us",
@@ -13,7 +13,7 @@
1313
license="BSD",
1414
packages=find_packages(),
1515
include_package_data=True,
16-
install_requires=["jellyfish==0.7.2"],
16+
install_requires=["jellyfish==0.6.1"],
1717
entry_points={"console_scripts": ["states = us.cli.states:main"]},
1818
platforms=["any"],
1919
classifiers=[

us/states.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
# -*- coding: utf-8 -*-
12
from __future__ import unicode_literals
23
import itertools
34
import re

0 commit comments

Comments
 (0)