switch to python 3.12 (#582)
* switch to python 3.12 * 3.11 on RTD * fix SyntaxWarning (regex strings were invalid partially)
This commit is contained in:
parent
e4f4844983
commit
3a8af8a6f5
|
@ -12,7 +12,7 @@ jobs:
|
|||
runs-on: windows-latest
|
||||
strategy:
|
||||
matrix:
|
||||
python-version: ['3.10', '3.11']
|
||||
python-version: ['3.11', '3.12']
|
||||
|
||||
steps:
|
||||
- uses: actions/checkout@v4
|
||||
|
|
|
@ -15,7 +15,7 @@ jobs:
|
|||
runs-on: ubuntu-latest
|
||||
strategy:
|
||||
matrix:
|
||||
python-version: ['3.8', '3.9', '3.10', '3.11']
|
||||
python-version: ['3.8', '3.9', '3.10', '3.11', '3.12']
|
||||
|
||||
steps:
|
||||
- uses: actions/checkout@v4
|
||||
|
|
|
@ -22,6 +22,7 @@ classifiers =
|
|||
Programming Language :: Python :: 3.9
|
||||
Programming Language :: Python :: 3.10
|
||||
Programming Language :: Python :: 3.11
|
||||
Programming Language :: Python :: 3.12
|
||||
Programming Language :: Python :: Implementation :: CPython
|
||||
Topic :: Software Development :: Libraries :: Python Modules
|
||||
Topic :: Office/Business :: Financial :: Point-Of-Sale
|
||||
|
|
|
@ -249,23 +249,26 @@ BARCODE_TYPE_B: Dict[str, bytes] = {
|
|||
|
||||
#: supported barcode formats
|
||||
BARCODE_FORMATS = {
|
||||
"UPC-A": ([(11, 12)], "^[0-9]{11,12}$"),
|
||||
"UPC-E": ([(7, 8), (11, 12)], "^([0-9]{7,8}|[0-9]{11,12})$"),
|
||||
"EAN13": ([(12, 13)], "^[0-9]{12,13}$"),
|
||||
"EAN8": ([(7, 8)], "^[0-9]{7,8}$"),
|
||||
"CODE39": ([(1, 255)], "^([0-9A-Z \$\%\+\-\.\/]+|\*[0-9A-Z \$\%\+\-\.\/]+\*)$"),
|
||||
"ITF": ([(2, 255)], "^([0-9]{2})+$"),
|
||||
"NW7": ([(1, 255)], "^[A-Da-d][0-9\$\+\-\.\/\:]+[A-Da-d]$"),
|
||||
"CODABAR": ([(1, 255)], "^[A-Da-d][0-9\$\+\-\.\/\:]+[A-Da-d]$"), # Same as NW7
|
||||
"CODE93": ([(1, 255)], "^[\\x00-\\x7F]+$"),
|
||||
"CODE128": ([(2, 255)], "^\{[A-C][\\x00-\\x7F]+$"),
|
||||
"GS1-128": ([(2, 255)], "^\{[A-C][\\x00-\\x7F]+$"), # same as CODE128
|
||||
"GS1 DATABAR OMNIDIRECTIONAL": ([(13, 13)], "^[0-9]{13}$"),
|
||||
"GS1 DATABAR TRUNCATED": ([(13, 13)], "^[0-9]{13}$"), # same as GS1 omnidirectional
|
||||
"GS1 DATABAR LIMITED": ([(13, 13)], "^[01][0-9]{12}$"),
|
||||
"UPC-A": ([(11, 12)], r"^[0-9]{11,12}$"),
|
||||
"UPC-E": ([(7, 8), (11, 12)], r"^([0-9]{7,8}|[0-9]{11,12})$"),
|
||||
"EAN13": ([(12, 13)], r"^[0-9]{12,13}$"),
|
||||
"EAN8": ([(7, 8)], r"^[0-9]{7,8}$"),
|
||||
"CODE39": ([(1, 255)], r"^([0-9A-Z \$\%\+\-\.\/]+|\*[0-9A-Z \$\%\+\-\.\/]+\*)$"),
|
||||
"ITF": ([(2, 255)], r"^([0-9]{2})+$"),
|
||||
"NW7": ([(1, 255)], r"^[A-Da-d][0-9\$\+\-\.\/\:]+[A-Da-d]$"),
|
||||
"CODABAR": ([(1, 255)], r"^[A-Da-d][0-9\$\+\-\.\/\:]+[A-Da-d]$"), # Same as NW7
|
||||
"CODE93": ([(1, 255)], r"^[\x00-\x7F]+$"),
|
||||
"CODE128": ([(2, 255)], r"^\{[A-C][\x00-\x7F]+$"),
|
||||
"GS1-128": ([(2, 255)], r"^\{[A-C][\x00-\x7F]+$"), # same as CODE128
|
||||
"GS1 DATABAR OMNIDIRECTIONAL": ([(13, 13)], r"^[0-9]{13}$"),
|
||||
"GS1 DATABAR TRUNCATED": (
|
||||
[(13, 13)],
|
||||
r"^[0-9]{13}$",
|
||||
), # same as GS1 omnidirectional
|
||||
"GS1 DATABAR LIMITED": ([(13, 13)], r"^[01][0-9]{12}$"),
|
||||
"GS1 DATABAR EXPANDED": (
|
||||
[(2, 255)],
|
||||
"^\([0-9][A-Za-z0-9 \!\"\%\&'\(\)\*\+\,\-\.\/\:\;\<\=\>\?\_\{]+$",
|
||||
r"^\([0-9][A-Za-z0-9 \!\"\%\&'\(\)\*\+\,\-\.\/\:\;\<\=\>\?\_\{]+$",
|
||||
),
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue