barcodes: replace viivakoodi with python-barcode

python-barcode is yet another clone of the PyPI barcode library, but
which is still developped compared to viivakoodi.

The author provides Python 3.7 support in the last release, which is a
nice to have.  However, since this dependency requires at least Python
3.5, we have to align our minimum supported version to 3.5 too, and drop
near EOL Python 2.7 support.

Signed-off-by: Romain Porte <microjoe@microjoe.org>
This commit is contained in:
Romain Porte 2019-10-07 07:25:28 +02:00
parent 4955fe3264
commit 599bd6c9e4
No known key found for this signature in database
GPG Key ID: 2FFF63F5851B03E2
5 changed files with 6 additions and 9 deletions

View File

@ -29,8 +29,6 @@ matrix:
osx_image: xcode10.2 osx_image: xcode10.2
language: shell language: shell
env: TOXENV=py37 ESCPOS_CAPABILITIES_FILE=/Users/travis/build/python-escpos/python-escpos/capabilities-data/dist/capabilities.json env: TOXENV=py37 ESCPOS_CAPABILITIES_FILE=/Users/travis/build/python-escpos/python-escpos/capabilities-data/dist/capabilities.json
- python: 3.4
env: TOXENV=py34
- python: 3.5 - python: 3.5
env: TOXENV=py35 env: TOXENV=py35
- python: 3.6 - python: 3.6

View File

@ -47,7 +47,7 @@ This library makes use of:
* `Pillow <https://github.com/python-pillow/Pillow>`_ for image printing * `Pillow <https://github.com/python-pillow/Pillow>`_ for image printing
* `qrcode <https://github.com/lincolnloop/python-qrcode>`_ for the generation of QR-codes * `qrcode <https://github.com/lincolnloop/python-qrcode>`_ for the generation of QR-codes
* `pyserial <https://github.com/pyserial/pyserial>`_ for serial printers * `pyserial <https://github.com/pyserial/pyserial>`_ for serial printers
* `viivakoodi <https://github.com/kxepal/viivakoodi>`_ for the generation of barcodes * `python-barcode <https://github.com/WhyNotHugo/python-barcode>`_ for the generation of barcodes
Documentation and Usage Documentation and Usage
----------------------- -----------------------

View File

@ -5,4 +5,4 @@ pyserial
sphinx-rtd-theme sphinx-rtd-theme
setuptools-scm setuptools-scm
docutils>=0.12 docutils>=0.12
viivakoodi python-barcode>=0.11.0,<1

View File

@ -62,7 +62,6 @@ setup(
'Operating System :: OS Independent', 'Operating System :: OS Independent',
'Programming Language :: Python', 'Programming Language :: Python',
'Programming Language :: Python :: 3', 'Programming Language :: Python :: 3',
'Programming Language :: Python :: 3.4',
'Programming Language :: Python :: 3.5', 'Programming Language :: Python :: 3.5',
'Programming Language :: Python :: 3.6', 'Programming Language :: Python :: 3.6',
'Programming Language :: Python :: 3.7', 'Programming Language :: Python :: 3.7',
@ -82,7 +81,7 @@ setup(
'argparse', 'argparse',
'argcomplete', 'argcomplete',
'future', 'future',
'viivakoodi>=0.8' 'python-barcode>=0.9.1,<1'
], ],
setup_requires=[ setup_requires=[
'setuptools_scm', 'setuptools_scm',

View File

@ -1,5 +1,5 @@
[tox] [tox]
envlist = py34, py35, py36, py37, docs, flake8 envlist = py35, py36, py37, docs, flake8
[testenv] [testenv]
deps = nose deps = nose
@ -11,7 +11,7 @@ deps = nose
pytest-cov pytest-cov
pytest-mock pytest-mock
hypothesis!=3.56.9,<4 hypothesis!=3.56.9,<4
viivakoodi python-barcode
commands = py.test --cov escpos commands = py.test --cov escpos
passenv = ESCPOS_CAPABILITIES_PICKLE_DIR ESCPOS_CAPABILITIES_FILE CI TRAVIS TRAVIS_* APPVEYOR APPVEYOR_* CODECOV_* passenv = ESCPOS_CAPABILITIES_PICKLE_DIR ESCPOS_CAPABILITIES_FILE CI TRAVIS TRAVIS_* APPVEYOR APPVEYOR_* CODECOV_*
@ -20,7 +20,7 @@ basepython = python
changedir = doc changedir = doc
deps = sphinx>=1.5.1 deps = sphinx>=1.5.1
setuptools_scm setuptools_scm
viivakoodi python-barcode
commands = sphinx-build -W -b html -d {envtmpdir}/doctrees . {envtmpdir}/html commands = sphinx-build -W -b html -d {envtmpdir}/doctrees . {envtmpdir}/html
[testenv:flake8] [testenv:flake8]