Skip to content

Commit 7397d14

Browse files
authored
Release 23.6 (#59)
* New code for HanXin * Use Python3 as default * Fix `make test-tox` command * Upgrade min Python version to 3.11
1 parent aef8646 commit 7397d14

32 files changed

Lines changed: 800 additions & 36 deletions

.editorconfig

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,10 @@ end_of_line = lf
99
insert_final_newline = true
1010
trim_trailing_whitespace = true
1111

12+
[*.yml]
13+
indent_style = space
14+
indent_size = 2
15+
1216
[*.py]
1317
indent_style = space
1418
indent_size = 4

.github/workflows/python-latest.yml

Lines changed: 8 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -9,14 +9,14 @@ on:
99
jobs:
1010
# Define the job to run before your matrix job
1111
get-python-versions:
12-
runs-on: ubuntu-20.04
12+
runs-on: ubuntu-latest
1313
outputs:
1414
python-matrix: ${{ steps.get-python-versions-action.outputs.latest-python-versions }}
1515
steps:
1616
- uses: snok/latest-python-versions@v1
1717
id: get-python-versions-action
1818
with:
19-
min-version: '3.10'
19+
min-version: '3.11'
2020

2121
test:
2222
needs: [get-python-versions]
@@ -26,6 +26,8 @@ jobs:
2626
operating-system: [ ubuntu-latest, windows-latest, macOS-latest ]
2727
python-version: ${{ fromJson(needs.get-python-versions.outputs.python-matrix) }}
2828

29+
continue-on-error: true
30+
2931
steps:
3032
- uses: actions/checkout@v3
3133
- name: Set up Python on ${{ matrix.operating-system }}
@@ -34,12 +36,12 @@ jobs:
3436
python-version: ${{ matrix.python-version }}
3537
- name: Install dependencies
3638
run: |
37-
python3 -m pip install -r requirements.txt -r test-requirements.txt
39+
python -m pip install -r requirements.txt -r test-requirements.txt
3840
- name: Lint
3941
run: |
40-
python3 -m black --line-length=120 --check .
41-
python3 -m check_python_versions --expect 2.7,3.5- --only setup.py
42+
python -m black --line-length=120 --check .
43+
python -m check_python_versions --expect 2.7,3.5- --only setup.py
4244
- name: Test
4345
env:
4446
TEST_CONFIGURATION_ACCESS_TOKEN: ${{ secrets.TEST_CONFIGURATION_ACCESS_TOKEN }}
45-
run: python3 -Werror -m pytest
47+
run: python -Werror -m pytest

.github/workflows/python-package.yml

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -11,12 +11,13 @@ on:
1111

1212
jobs:
1313
build:
14-
14+
# See https://raw.githubusercontent.com/actions/python-versions/main/versions-manifest.json
15+
# for awailable Python versions on ubuntu
1516
runs-on: ubuntu-20.04
1617
strategy:
1718
matrix:
1819
# see https://www.python.org/downloads/
19-
python-version: ['2.7', '3.5', '3.10']
20+
python-version: [ '3.5', '3.11' ]
2021

2122
steps:
2223
- uses: actions/checkout@v3

.github/workflows/twine-check.yml

Lines changed: 25 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,25 @@
1+
name: Check Python package
2+
3+
on:
4+
push:
5+
branches: [ main ]
6+
pull_request:
7+
branches: [ main ]
8+
9+
jobs:
10+
twine-check:
11+
runs-on: ubuntu-latest
12+
13+
steps:
14+
- uses: actions/checkout@v3
15+
- name: Set up Python
16+
uses: actions/setup-python@v4
17+
with:
18+
python-version: '3.x'
19+
20+
- name: Set up Requirements
21+
run: python -m pip install -r publish-requirements.txt
22+
- name: Build dist
23+
run: python setup.py sdist bdist_wheel --universal
24+
- name: Check
25+
run: python -m twine check dist/* --strict

Dockerfile

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,10 +2,10 @@
22
# docker build github.com/aspose-barcode-cloud/aspose-barcode-cloud-python -t barcode-cloud-python:$(git describe --tags)
33
# docker run barcode-cloud-python:$(git describe --tags) publish -e "TEST_CONFIGURATION_ACCESS_TOKEN=" -e "TWINE_PASSWORD="
44

5-
FROM python:2-buster
5+
FROM python:3
66

77
RUN apt-get update \
8-
&& apt-get install -y python3-pip \
8+
&& apt-get install -y python-pip \
99
&& rm -rf /var/lib/apt/lists/*
1010

1111
WORKDIR /aspose-barcode-cloud-python

Makefile

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -18,11 +18,11 @@ clean-pyc:
1818

1919
.PHONY: dist
2020
dist:
21-
python3 setup.py sdist bdist_wheel --universal
21+
python setup.py sdist bdist_wheel --universal
2222

2323
.PHONY: format
2424
format:
25-
python3 -m black --line-length=120 -v $(SRC) tests
25+
python -m black --line-length=120 -v $(SRC) tests
2626

2727
.PHONY: format_doc
2828
format_doc:
@@ -38,7 +38,7 @@ init:
3838

3939
.PHONY: init-docker
4040
init-docker:
41-
python3 -m pip install -r publish-requirements.txt -r requirements.txt
41+
python -m pip install -r publish-requirements.txt -r requirements.txt
4242

4343
.PHONY: lint
4444
lint:
@@ -49,11 +49,11 @@ lint:
4949

5050
.PHONY: publish
5151
publish: check_git test-tox dist
52-
python3 -m twine upload dist/*
52+
python -m twine upload dist/*
5353

5454
.PHONY: publish-docker
5555
publish-docker: init-docker unittest dist
56-
python3 -m twine upload dist/* --verbose
56+
python -m twine upload dist/* --verbose
5757

5858
.PHONY: test
5959
test:
@@ -65,15 +65,15 @@ cover:
6565

6666
.PHONY: unittest
6767
unittest:
68-
python3 -Werror -m unittest discover -v
68+
python -Werror -m unittest discover -v
6969

7070
.PHONY: test-example
7171
test-example:
7272
python -Werror example.py
7373

7474
.PHONY: test-tox
7575
test-tox:
76-
python3 -m tox $(SRC)
76+
python -m tox $(SRC)
7777

7878
.PHONY: after-gen
7979
after-gen: format format_doc

README.md

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55
[![PyPI](https://img.shields.io/pypi/v/aspose-barcode-cloud)](https://pypi.org/project/aspose-barcode-cloud/)
66

77
- API version: 3.0
8-
- Package version: 23.5.0
8+
- Package version: 23.6.0
99

1010
## Demo applications
1111

@@ -21,7 +21,6 @@ This repository contains Aspose.BarCode Cloud SDK for Python source code. This S
2121

2222
Supported Python versions:
2323

24-
- Python 2.7
2524
- Python 3.5+
2625

2726
To use these SDKs, you will need Client Id and Client Secret which can be looked up at [Aspose Cloud Dashboard](https://dashboard.aspose.cloud/applications) (free registration in Aspose Cloud is required for this).
@@ -181,6 +180,10 @@ Class | Method | HTTP request | Description
181180
- [FontStyle](docs/FontStyle.md)
182181
- [GeneratorParams](docs/GeneratorParams.md)
183182
- [GeneratorParamsList](docs/GeneratorParamsList.md)
183+
- [HanXinEncodeMode](docs/HanXinEncodeMode.md)
184+
- [HanXinErrorLevel](docs/HanXinErrorLevel.md)
185+
- [HanXinParams](docs/HanXinParams.md)
186+
- [HanXinVersion](docs/HanXinVersion.md)
184187
- [ITF14BorderType](docs/ITF14BorderType.md)
185188
- [ITFParams](docs/ITFParams.md)
186189
- [MacroCharacter](docs/MacroCharacter.md)

aspose_barcode_cloud/__init__.py

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -86,6 +86,10 @@
8686
from aspose_barcode_cloud.models.font_style import FontStyle
8787
from aspose_barcode_cloud.models.generator_params import GeneratorParams
8888
from aspose_barcode_cloud.models.generator_params_list import GeneratorParamsList
89+
from aspose_barcode_cloud.models.han_xin_encode_mode import HanXinEncodeMode
90+
from aspose_barcode_cloud.models.han_xin_error_level import HanXinErrorLevel
91+
from aspose_barcode_cloud.models.han_xin_params import HanXinParams
92+
from aspose_barcode_cloud.models.han_xin_version import HanXinVersion
8993
from aspose_barcode_cloud.models.itf14_border_type import ITF14BorderType
9094
from aspose_barcode_cloud.models.itf_params import ITFParams
9195
from aspose_barcode_cloud.models.macro_character import MacroCharacter

aspose_barcode_cloud/api_client.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -90,13 +90,13 @@ def __init__(self, configuration=None, header_name=None, header_value=None, cook
9090
self.rest_client = RESTClientObject(configuration)
9191
self.default_headers = {
9292
"x-aspose-client": "python sdk",
93-
"x-aspose-client-version": "23.5.0",
93+
"x-aspose-client-version": "23.6.0",
9494
}
9595
if header_name is not None:
9696
self.default_headers[header_name] = header_value
9797
self.cookie = cookie
9898
# Set default User-Agent.
99-
self.user_agent = "Aspose-Barcode-SDK/23.5.0/python"
99+
self.user_agent = "Aspose-Barcode-SDK/23.6.0/python"
100100

101101
def __del__(self):
102102
self.rest_client.close()

aspose_barcode_cloud/configuration.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -286,7 +286,7 @@ def to_debug_report(self):
286286
"OS: {env}\n"
287287
"Python Version: {pyversion}\n"
288288
"Version of the API: 3.0\n"
289-
"SDK Package Version: 23.5.0".format(env=sys.platform, pyversion=sys.version)
289+
"SDK Package Version: 23.6.0".format(env=sys.platform, pyversion=sys.version)
290290
)
291291

292292
@staticmethod

0 commit comments

Comments
 (0)