Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Not yet reviewed #38

Draft
wants to merge 383 commits into
base: reviewed
Choose a base branch
from
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
383 commits
Select commit Hold shift + click to select a range
811f51a
Expand test coverage.
BenediktBurger Dec 18, 2023
4b6410b
Merge branch 'development' of https://github.com/pymeasure/pyleco int…
BenediktBurger Dec 18, 2023
505388d
Fix linting.
BenediktBurger Dec 19, 2023
e19996b
Fix typos.
BenediktBurger Dec 20, 2023
9883318
Rename adress to address in Coordinator.
BenediktBurger Dec 20, 2023
1dc255f
Fix more typos.
BenediktBurger Dec 20, 2023
249643c
Expand Readme with examples.
BenediktBurger Dec 20, 2023
eca86d6
Add set_full_name to datapublisher.
BenediktBurger Jan 2, 2024
3e6d38f
Create register on name change method in listener.
BenediktBurger Jan 2, 2024
34b7314
Merge remote-tracking branch 'origin/main' into development
BenediktBurger Jan 3, 2024
39babab
Prepare message handler for communicatorProtocol.
BenediktBurger Jan 5, 2024
9b0cc42
Make the MessageHandler distinguish requested messages.
BenediktBurger Jan 8, 2024
45913a5
Add ask_message to messagehandler.
BenediktBurger Jan 8, 2024
97d902b
Rework MessageHandler to comply with the Communicator.
BenediktBurger Jan 8, 2024
2e6eafe
Remove deprecated ask from director.
BenediktBurger Jan 8, 2024
dfe1750
Fix linting.
BenediktBurger Jan 8, 2024
498545a
Fix typo.
BenediktBurger Jan 10, 2024
0fa3732
Fix MessageHandler sign_in.
BenediktBurger Jan 11, 2024
f3564c0
Add full_name to communicator.
BenediktBurger Jan 11, 2024
22ce4cf
Add units to datalogger
BenediktBurger Jan 11, 2024
d3b6207
Fix type hints.
BenediktBurger Jan 11, 2024
5cc3039
Rename logHandler
BenediktBurger Jan 16, 2024
62523be
Add changelog entries.
BenediktBurger Jan 16, 2024
000245b
Add a getting started tutorial.
BenediktBurger Jan 18, 2024
8611d96
Fix links in getting started
BenediktBurger Jan 18, 2024
d3efbb1
Improve qt listener.
BenediktBurger Jan 18, 2024
17a09b7
Skip tests if qtpy is not installed.
BenediktBurger Jan 18, 2024
e2c0b99
Cleanup.
BenediktBurger Jan 19, 2024
f6b9442
Add Python 3.12
BenediktBurger Jan 22, 2024
a4b5a95
Skip acceptance tests under macOS, see #18
BenediktBurger Jan 22, 2024
75608ea
Bump pyzmq version.
BenediktBurger Jan 22, 2024
076dabd
Merge pull request #22 from pymeasure/new-ci
BenediktBurger Jan 22, 2024
088d743
Modify Readme and changelog for branch switch.
BenediktBurger Jan 24, 2024
1dd57e1
Merge pull request #10 from pymeasure/development
BenediktBurger Jan 24, 2024
d2b7b91
Update copyright.
BenediktBurger Jan 24, 2024
ecc9f41
minor changes and clarifications to getting started
bklebel Jan 28, 2024
1d820b3
minor change to getting started
bklebel Jan 28, 2024
86287be
Merge pull request #24 from bklebel/main
BenediktBurger Jan 29, 2024
44ddf06
Add permissions to CI code coverage.
BenediktBurger Jan 29, 2024
39415de
Merge pull request #26 from pymeasure/fix-CI
BenediktBurger Jan 29, 2024
a227f47
small changes in the README.md, in part to test the CI of PR's
bklebel Jan 29, 2024
151c587
Merge pull request #27 from bklebel/main
BenediktBurger Jan 29, 2024
b764484
Adjust permissions for CI.
BenediktBurger Jan 29, 2024
39eb4af
Merge pull request #29 from pymeasure/fix-CI
BenediktBurger Jan 29, 2024
54495dc
Remove deprecated code.
BenediktBurger Jan 30, 2024
9701789
Move republisher to extras repo.
BenediktBurger Jan 30, 2024
38d2693
Merge pull request #33 from pymeasure/cleanup
BenediktBurger Jan 30, 2024
b0b9590
Refine project classifiers
BenediktBurger Jan 31, 2024
f3a721d
Make code coverage comment optional.
BenediktBurger Jan 31, 2024
ce35915
Merge pull request #34 from BenediktBurger/cleanup
BenediktBurger Jan 31, 2024
3d8347e
Add codecov to CI
BenediktBurger Jan 30, 2024
dd2a799
Add token.
BenediktBurger Jan 30, 2024
3d8baeb
Remove old code coverage code
BenediktBurger Jan 31, 2024
ab7ba64
Merge pull request #32 from BenediktBurger/add-codecov
BenediktBurger Jan 31, 2024
bd98319
Add uploading workflow on published release.
BenediktBurger Jan 29, 2024
1f2a115
Fix badges.
BenediktBurger Jan 31, 2024
565c8a5
Reword readme for release.
BenediktBurger Feb 1, 2024
2904d72
Write Changelog for release.
BenediktBurger Feb 1, 2024
8b50a86
Use release environment.
BenediktBurger Feb 1, 2024
a20c977
Merge pull request #30 from pymeasure/add-publish-CI
BenediktBurger Feb 1, 2024
f88da5e
Add date to changelog.
BenediktBurger Feb 1, 2024
1dc6662
Merge pull request #37 from pymeasure/v0.1.0-release
BenediktBurger Feb 1, 2024
9aff2d2
Add interpret_rpc_response to communicatorprotocol.
BenediktBurger Feb 2, 2024
a8b1928
Add read_rpc_response to director.
BenediktBurger Feb 2, 2024
4c95d39
Cleanup of old code.
BenediktBurger Feb 2, 2024
c834131
Use new features
BenediktBurger Feb 2, 2024
baf378e
Improve documentation.
BenediktBurger Feb 2, 2024
54f7d2b
Merge pull request #44 from pymeasure/improve-communicator
BenediktBurger Feb 6, 2024
76780b2
Remove legacy code from extended message handler
BenediktBurger Feb 5, 2024
f569e23
Rework MessageHandler read_message
BenediktBurger Feb 5, 2024
6bf0c88
Add buffered_messages to Communcator
BenediktBurger Feb 5, 2024
7490f13
Base MessageHandler and Communicator on same base class.
BenediktBurger Feb 5, 2024
4656c71
Communicator is explicit on failed sign in, tests fixed.
BenediktBurger Feb 5, 2024
04d8a0f
Rename connection to socket.
BenediktBurger Feb 5, 2024
61ee42d
Base communicator and message handler even more on same base.
BenediktBurger Feb 6, 2024
7969714
Move BaseCommunicator to its own file.
BenediktBurger Feb 6, 2024
0acf503
Fix test_starter_live.
BenediktBurger Feb 6, 2024
65eaf4d
Expand Communicator test coverage.
BenediktBurger Feb 6, 2024
a777f6a
Add changelog.
BenediktBurger Feb 6, 2024
8e95f03
Merge pull request #48 from pymeasure/Rework-Communicator
BenediktBurger Feb 6, 2024
e02a70b
Rework Coordinator handle message.
BenediktBurger Feb 5, 2024
1a39db7
Merge pull request #50 from pymeasure/rework-Coordinator
BenediktBurger Feb 6, 2024
8f338f4
Fix DataLogger to start a timer, even if not specified explicitly.
BenediktBurger Feb 8, 2024
eaa8eaa
Merge pull request #51 from pymeasure/Fix-datalogger
BenediktBurger Feb 8, 2024
bb8afaa
Add vs code settings to gitignore.
BenediktBurger Feb 11, 2024
998313e
Merge branch 'main' of github.com:pymeasure/pyleco into main
BenediktBurger Feb 11, 2024
6f6a184
Split read_message in reading and error checking parts.
BenediktBurger Feb 9, 2024
c2505e4
Rework MessageHandler and PipeHandler.
BenediktBurger Feb 9, 2024
8576eb9
Add changelog
BenediktBurger Feb 9, 2024
44831b8
Add Pipecommands and expand tests.
BenediktBurger Feb 9, 2024
a785f9f
Fix Message representation
BenediktBurger Feb 12, 2024
29fcf5e
Rework message handler and qt listener.
BenediktBurger Feb 12, 2024
6521a32
Merge pull request #52 from pymeasure/Rework-message-handler
BenediktBurger Feb 13, 2024
1deed71
Add coordinators and starter as executable scripts.
BenediktBurger Feb 13, 2024
5f12389
Merge pull request #53 from pymeasure/install-scripts
BenediktBurger Feb 13, 2024
97a0d1b
Changelog for 0.2.0
BenediktBurger Feb 13, 2024
744b881
Fix qt_listener for python 3.9
BenediktBurger Feb 13, 2024
bfb2509
Rework BaseCommunicator
BenediktBurger Feb 13, 2024
1e6d6ef
Add test.
BenediktBurger Feb 13, 2024
f0b2572
Merge pull request #55 from pymeasure/fix-message-handler
BenediktBurger Feb 13, 2024
dc9c2c6
v0.2.1 changelog
BenediktBurger Feb 13, 2024
cb0328b
Bump setup-python version in publishing action.
Feb 14, 2024
b981cd7
Fix: Timeout issue
BenediktBurger Feb 14, 2024
ab5e983
Add json content types.
BenediktBurger Feb 14, 2024
68a33e3
Fix Coordinator message handling.
BenediktBurger Feb 14, 2024
237d8e2
Add content types to MessageHandler
BenediktBurger Feb 14, 2024
61a3598
Add tests.
BenediktBurger Feb 14, 2024
7eb55a5
Create v0.2.2 changelog
BenediktBurger Feb 14, 2024
ef56a34
Merge pull request #58 from pymeasure/fix-coordinator
BenediktBurger Feb 14, 2024
4cc7cca
Add codecov configuration.
BenediktBurger Feb 21, 2024
b8c8917
Add future annotations to all necessary files.
BenediktBurger Feb 26, 2024
d6b941b
Add json-objects as replacement for jsonrpc2-objects.
BenediktBurger Feb 26, 2024
c1219fe
Change RPCGenerator to use json-objects, remove dependencies.
BenediktBurger Feb 26, 2024
7b7cc1d
Add RPCServer replacement for openrpc package.
BenediktBurger Feb 26, 2024
e114de7
Rename `cls` to `device_class` parameter.
BenediktBurger Feb 26, 2024
5bb6f25
Add Python 3.8 compatibility.
BenediktBurger Feb 26, 2024
0c168d9
Bump CI actions versions.
BenediktBurger Feb 26, 2024
05bc939
Merge pull request #62 from pymeasure/fix-CI
BenediktBurger Feb 26, 2024
b2f3747
Fix typing.
BenediktBurger Feb 26, 2024
9503f81
Fix typing.
BenediktBurger Feb 26, 2024
d73b323
Fix tests.
BenediktBurger Feb 26, 2024
d1003b2
Add changelog.
BenediktBurger Feb 26, 2024
549f628
Improve documentation.
BenediktBurger Feb 26, 2024
52c8afa
Fix Actor to accept deprecated cls argument.
BenediktBurger Feb 27, 2024
d99ae22
Add test condition.
BenediktBurger Feb 27, 2024
d337a29
Merge pull request #63 from pymeasure/remove-json-dependency
BenediktBurger Mar 1, 2024
b5f29d6
Merge branch 'main' into old-python
BenediktBurger Mar 1, 2024
db1e795
Merge pull request #64 from pymeasure/old-python
BenediktBurger Mar 1, 2024
0550385
Move content of pyleco.errors to json_utils.errors and json_utils.jso…
BenediktBurger Mar 4, 2024
da76c33
Adjust codebase to new places.
BenediktBurger Mar 4, 2024
a9dbfd8
Add changelog.
BenediktBurger Mar 4, 2024
5b3b193
Fix message creation.
BenediktBurger Mar 4, 2024
20d57c0
Merge pull request #65 from pymeasure/reorganize_json_objects
BenediktBurger Mar 7, 2024
4050455
Rework buffer
BenediktBurger Mar 7, 2024
bee9e91
Fix base communicator and add tests.
BenediktBurger Mar 8, 2024
8ce0c42
Add changes to message handler and tests.
BenediktBurger Mar 8, 2024
e642f4c
Rework pipe handler.
BenediktBurger Mar 8, 2024
3744905
Rename conversation id check.
BenediktBurger Mar 11, 2024
f7f5ba0
Improve documentation.
BenediktBurger Mar 11, 2024
7850331
Fix base_communicator bug to not use self.timeout for timeout==0.
BenediktBurger Mar 11, 2024
6f4e1d5
Merge pull request #66 from pymeasure/rework-pipe-handler
BenediktBurger Mar 12, 2024
e0a6852
Stopping listener closes handler which closes communicators.
BenediktBurger Mar 13, 2024
c0c29ad
Improve test framework.
BenediktBurger Mar 13, 2024
0b60808
Merge pull request #67 from pymeasure/fix-listener-stoppage
BenediktBurger Mar 13, 2024
7a2a591
Changelog for v0.3.0
BenediktBurger Mar 13, 2024
646ccfd
Add Zenodo DOI to readme
BenediktBurger Mar 19, 2024
6867ff6
Fix Coordinator to not use period in hostname as namespace.
BenediktBurger Mar 25, 2024
0ce18cf
Merge pull request #69 from pymeasure/fix-coordinator-hostname
BenediktBurger Mar 27, 2024
3bed785
Fix data_logger timer.
BenediktBurger Apr 9, 2024
02f44ca
Move default empty dictionaries to init.
BenediktBurger Apr 10, 2024
b169d49
Make not written list a debug log entry, not an error.
BenediktBurger Apr 10, 2024
5238d1c
Add lock for list access.
BenediktBurger Apr 10, 2024
a4ee43b
Merge pull request #70 from pymeasure/fix-data-logger
BenediktBurger Apr 12, 2024
f4e6705
Change state from Alpha to Beta.
BenediktBurger Apr 10, 2024
9bd20f7
Changelog for 0.3.1
BenediktBurger Apr 12, 2024
0be28f2
Bump codedov version
BenediktBurger Apr 29, 2024
393a30c
Fix coordinator utils typing.
BenediktBurger Apr 29, 2024
e3ade0f
Do not use xml
BenediktBurger Apr 29, 2024
ce9f380
Fix linting.
BenediktBurger Apr 30, 2024
c66873a
Merge pull request #73 from pymeasure/bump-codecov
BenediktBurger Apr 30, 2024
c5b5cfb
Add test for uuidv7 generation.
BenediktBurger Apr 30, 2024
6eb2f31
Fix tests and conversation_id_to_datetime
BenediktBurger May 4, 2024
87421e1
Switch from uuid7 package to uuid6 package.
BenediktBurger May 4, 2024
b2a3b74
Fix environment.
BenediktBurger May 4, 2024
4b54a75
Create CITATION.cff
BenediktBurger May 6, 2024
8066c00
Update CITATION.cff
BenediktBurger May 6, 2024
bf70200
Merge pull request #75 from pymeasure/fix-uuidv7
BenediktBurger May 6, 2024
dcef98f
Changelog for v0.3.2
BenediktBurger May 7, 2024
294aca0
Initial version of RELEASE.md
BenediktBurger May 13, 2024
5235b4d
Add Anaconda version badge to readme
BenediktBurger May 13, 2024
8d0719c
Add graphical documentation of a setup.
BenediktBurger May 14, 2024
c8be51b
Rework getting started with flow charts.
BenediktBurger May 15, 2024
9ebb869
Add Contributing.md file.
BenediktBurger May 15, 2024
96f5e98
Merge pull request #80 from pymeasure/improve-documentation
BenediktBurger May 16, 2024
6bf454e
Add tests for starter.
BenediktBurger May 16, 2024
e8e056f
Add tests for legacy code.
BenediktBurger May 16, 2024
c8833a7
Expand tests for test.py
BenediktBurger May 16, 2024
ba40751
Test director methods.
BenediktBurger May 16, 2024
a88271a
Fix tests and typing.
BenediktBurger May 16, 2024
4b3d071
Merge pull request #81 from pymeasure/expand-test-coverage
BenediktBurger May 16, 2024
8292a0d
Update release.md with citation.cff and conda-forge steps.
BenediktBurger May 21, 2024
175ec8c
Bump setuptools_scm version
BenediktBurger May 21, 2024
cd0bf05
Merge pull request #79 from pymeasure/release-workflow
BenediktBurger May 21, 2024
6ec8873
Make communicator return binary objects.
BenediktBurger May 22, 2024
4a49863
Make MessageHandler capable for binary objects.
BenediktBurger May 22, 2024
055d0fa
Add additional_payload to Message.
BenediktBurger May 22, 2024
0db80a1
Refactor Director.ask_message
BenediktBurger May 22, 2024
df75c6a
Modify formatting with ruff
BenediktBurger May 27, 2024
7bc5c87
Add parameter for extract binary response
BenediktBurger May 27, 2024
baa5797
Add additional_payload option to ask_rpc
BenediktBurger May 27, 2024
0bbe03e
Add additional payload options to director
BenediktBurger May 27, 2024
17c9e2a
Add acceptance test for binary transfer.
BenediktBurger May 27, 2024
a32402a
Return all additional payload frames.
BenediktBurger May 27, 2024
ad66400
Update Director (and Fake) to changes.
BenediktBurger May 27, 2024
d970d39
Tiny changes.
BenediktBurger May 27, 2024
30f9a97
Add link to rendered documentation
BenediktBurger May 28, 2024
cb62581
Return either json value or json and binary
BenediktBurger May 29, 2024
d2d5ad8
Add a method to register binary methods.
BenediktBurger May 29, 2024
c53d71c
Modify docstring of binary method.
BenediktBurger Jun 1, 2024
6ba7917
Explicitly state whether to return binary values.
BenediktBurger Jun 4, 2024
453db24
State type of binary method in docstring.
BenediktBurger Jun 5, 2024
ef51d47
Improve documentation
BenediktBurger Jun 11, 2024
39ca4c5
Make data_message similar to message
BenediktBurger Jun 11, 2024
8e3d82e
Add binary sending to data publisher
BenediktBurger Jun 11, 2024
bbd1c53
Fix creation of binary method
BenediktBurger Jun 12, 2024
775b579
Make proxy server terminate on error
BenediktBurger Jun 18, 2024
7f96a14
Reformat code.
BenediktBurger Jun 18, 2024
f7588ec
Fix listener documentation.
BenediktBurger Jun 19, 2024
252c25e
Update readme
BenediktBurger Jun 19, 2024
6ba4c19
Add changelog entry.
BenediktBurger Jun 19, 2024
ca94ef5
Merge pull request #82 from pymeasure/binary_payload
BenediktBurger Jun 19, 2024
ce3eadd
Merge pull request #88 from pymeasure/fix-documentation
BenediktBurger Jun 19, 2024
2fd377f
make proxy server main callable and stoppable.
BenediktBurger Jun 19, 2024
85949c2
Add tests for proxy_server
BenediktBurger Jun 19, 2024
22349d8
Improve proxy_server documentation
BenediktBurger Jun 19, 2024
862234c
Disable test_proxy_server
BenediktBurger Jun 19, 2024
cc496b7
Merge pull request #86 from pymeasure/update-proxy
BenediktBurger Jun 19, 2024
079d842
Fix actor
BenediktBurger May 29, 2024
c60aadb
Initial version of locking actor.
BenediktBurger May 29, 2024
d6f4b55
Add tests
BenediktBurger May 29, 2024
1435536
Improve tests.
BenediktBurger Jun 1, 2024
3ae8731
Tests expanded
BenediktBurger Jun 1, 2024
5b5811e
Add LockingDirector with tests.
BenediktBurger Jun 1, 2024
6aa25bb
Fix starter test
BenediktBurger Jun 19, 2024
ff8b159
Adjust locking actor to new development
BenediktBurger Jun 19, 2024
e0890c2
Add tests for unlocking
BenediktBurger Jun 19, 2024
560e5d7
Merge pull request #84 from pymeasure/locking_actor
BenediktBurger Jun 19, 2024
498abcc
Changelog for v0.4.0
BenediktBurger Jun 19, 2024
eb62368
Fix typo.
BenediktBurger Jun 19, 2024
66631b6
Pin ruff version
BenediktBurger Jul 9, 2024
e7a1872
Update punctuation in README.md
BenediktBurger Aug 20, 2024
6209ce2
Fix tests for new openrpc version and adjust our own server.
BenediktBurger Aug 20, 2024
30b307b
Merge pull request #95 from pymeasure/fix-open-rpc
BenediktBurger Aug 20, 2024
f143f3b
Add support for Python 313
BenediktBurger Oct 15, 2024
6c2282c
Make openrpc optional
BenediktBurger Oct 29, 2024
0440eed
Fix documentation python version.
BenediktBurger Oct 29, 2024
45f7e18
Merge pull request #98 from pymeasure/py313
BenediktBurger Oct 29, 2024
4e3a46c
Switch to maintained ruff -action repository.
BenediktBurger Nov 19, 2024
54bda60
Merge pull request #99 from pymeasure/fix-ruff-CI
BenediktBurger Nov 19, 2024
b869d82
Expand RPCServer tests
BenediktBurger Nov 20, 2024
8b43e31
Add batch message type.
BenediktBurger Nov 20, 2024
10059ef
Add supported python versions to readme via shield.
BenediktBurger Nov 20, 2024
1f03a8d
Improve inner workings of RPCServer.
BenediktBurger Nov 20, 2024
49f39ca
Fix not defined name
BenediktBurger Nov 20, 2024
66d2aa9
Merge pull request #103 from pymeasure/add-python-versions
BenediktBurger Nov 20, 2024
003def0
Improve BatchObject to force type for all methods.
BenediktBurger Nov 20, 2024
15094a1
Merge pull request #102 from pymeasure/rework-rpc-server
BenediktBurger Nov 20, 2024
24c8e8d
Increase starter test coverage.
BenediktBurger Nov 20, 2024
6906297
Increase extended message handler tests.
BenediktBurger Nov 20, 2024
247c8ff
Merge pull request #104 from pymeasure/increase-test-coverage
BenediktBurger Nov 20, 2024
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
79 changes: 28 additions & 51 deletions .github/workflows/pyleco_CI.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,22 +13,24 @@ jobs:
run:
shell: bash -l {0}
steps:
- uses: actions/checkout@v3
- uses: actions/checkout@v4
with:
fetch-depth: 0
- name: Install pyleco requirements
uses: mamba-org/setup-micromamba@v1
with:
environment-file: environment.yml
create-args: python=3.10
cache-environment-key: pylatest-ubuntu-latest-mamba-${{ env.CACHE_NUMBER }}-${{ hashFiles('environment.yml') }}
cache-downloads: false
- name: Python and Mamba version
run: |
python --version
micromamba info
- name: Lint with ruff
uses: chartboost/ruff-action@v1
uses: astral-sh/ruff-action@v1
with:
version: 0.4.10 # ruff-action@v1 is broken in regard to ruff 0.5.0
args: --extend-select=E9,F63,F7,F82 --show-source
- uses: ammaraskar/sphinx-problem-matcher@master
- name: Generate docs
Expand All @@ -43,14 +45,15 @@ jobs:
run: |
echo "::add-matcher::.github/sphinx.json"
make doctest SPHINXOPTS="-W --keep-going"

type_checking:
name: Static Type Checking
runs-on: "ubuntu-latest"
defaults:
run:
shell: bash -l {0}
steps:
- uses: actions/checkout@v3
- uses: actions/checkout@v4
with:
fetch-depth: 0
- name: Install pyleco requirements
Expand All @@ -65,14 +68,15 @@ jobs:
run: pip install mypy
- name: Run mypy
run: mypy .

test_coverage:
name: Code Coverage
name: Code Coverage on codecov
runs-on: "ubuntu-latest"
defaults:
run:
shell: bash -l {0}
steps:
- uses: actions/checkout@v3
- uses: actions/checkout@v4
with:
fetch-depth: 0
- name: Install pyleco requirements
Expand All @@ -87,49 +91,17 @@ jobs:
# If the pytest problem matcher stops working because of bad paths, do an editable install
run: pip install -e .[dev] # editable for covtest
- name: Test for Coverage
run: pytest --junitxml=pytest.xml --cov-report=term-missing:skip-covered --cov=pyleco | tee pytest-coverage.txt
- name: Pytest Coverage Comment
id: coverageComment
uses: MishaKav/pytest-coverage-comment@main
run: pytest --cov=pyleco --cov-report=xml
- name: Upload coverage to Codecov
uses: codecov/codecov-action@v4
with:
pytest-coverage-path: ./pytest-coverage.txt
title: Coverage Report
badge-title: PyLECO Coverage
hide-badge: false
hide-report: false
create-new-comment: false
hide-comment: false
report-only-changed-files: false
remove-link-from-badge: false
unique-id-for-comment: python3
junitxml-path: ./pytest.xml
junitxml-title: Coverage Summary
- name: Check output coverage
run: |
echo "Coverage Percantage - ${{ steps.coverageComment.outputs.coverage }}"
echo "Coverage Color - ${{ steps.coverageComment.outputs.color }}"
echo "Coverage Html - ${{ steps.coverageComment.outputs.coverageHtml }}"

echo "Coverage Warnings - ${{ steps.coverageComment.outputs.warnings }}"

echo "Coverage Errors - ${{ steps.coverageComment.outputs.errors }}"
echo "Coverage Failures - ${{ steps.coverageComment.outputs.failures }}"
echo "Coverage Skipped - ${{ steps.coverageComment.outputs.skipped }}"
echo "Coverage Tests - ${{ steps.coverageComment.outputs.tests }}"
echo "Coverage Time - ${{ steps.coverageComment.outputs.time }}"
token: ${{ secrets.CODECOV_TOKEN }}
fail_ci_if_error: true
files: ./coverage.xml,!./cache
flags: unittests
name: codecov-umbrella
verbose: true

echo "Not Success Test Info - ${{ steps.coverageComment.outputs.notSuccessTestInfo }}"

- name: Create the Badge
uses: schneegans/[email protected]
with:
auth: ${{ secrets.pyleco_coverage_gist_secret }}
gistID: 7a8a7b874b62ed803eb56ca04830bede
filename: pyleco-coverage.json
label: Coverage Report
message: ${{ steps.coverageComment.outputs.coverage }}
color: ${{ steps.coverageComment.outputs.color }}
namedLogo: python
test:
name: Python ${{ matrix.python-version }}, ${{ matrix.os }}
runs-on: ${{ matrix.os }}
Expand All @@ -140,9 +112,9 @@ jobs:
fail-fast: true
matrix:
os: ["ubuntu-latest", "macos-latest", "windows-latest"]
python-version: ["3.9", "3.10", "3.11"]
python-version: ["3.8", "3.9", "3.10", "3.11", "3.12", "3.13"]
steps:
- uses: actions/checkout@v3
- uses: actions/checkout@v4
with:
fetch-depth: 0
- name: Install pyleco requirements
Expand All @@ -159,13 +131,18 @@ jobs:
run: pip install .[dev]
- name: Pyleco version
run: python -c "import pyleco;print(pyleco.__version__)"
- name: Run pytest with xvfb
- name: Run pytest under Linux with xvfb
if: runner.os == 'Linux'
run: |
echo "::add-matcher::.github/pytest.json"
xvfb-run -a pytest
- name: Run pytest
if: runner.os != 'Linux'
- name: Run pytest under Windows
if: runner.os == 'Windows'
run: |
echo "::add-matcher::.github/pytest.json"
pytest
- name: Run pytest under Mac without acceptance tests
if: runner.os == 'macOS'
run: |
echo "::add-matcher::.github/pytest.json"
pytest --ignore=tests/acceptance_tests
31 changes: 31 additions & 0 deletions .github/workflows/python-publish.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,31 @@
# This workflow will upload a Python Package using Twine when a release is created
# For more information see: https://help.github.com/en/actions/language-and-framework-guides/using-python-with-github-actions#publishing-to-package-registries

name: Build and Upload Python Package

on:
release:
types: [published]

jobs:
deploy:

runs-on: ubuntu-latest
environment: release
permissions:
id-token: write # IMPORTANT: this permission is mandatory for trusted publishing

steps:
- uses: actions/checkout@v4
- name: Set up Python
uses: actions/setup-python@v5
with:
python-version: '3.x'
- name: Install dependencies
run: |
python -m pip install --upgrade pip
pip install build twine
- name: Build package
run: python -m build
- name: Publish package
uses: pypa/[email protected]
3 changes: 3 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -114,6 +114,9 @@ venv.bak/
.spyderproject
.spyproject

# VS code project settings
.vscode/*

# Rope project settings
.ropeproject

Expand Down
180 changes: 180 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,180 @@
# CHANGELOG

## [Unreleased]

### Changed

* Openrpc is optional (available via `openrpc` option) for Python 3.13 onwards.

### Added

* Support for Python 3.13


## [0.4.0] 2024-06-19

_Binary data handling facilitated with utility functions._

### Changed
* Proxy_server stops if binding failed ([#86](https://github.com/pymeasure/pyleco/pull/86))

### Added

* Add convenience functions for using additional frames for binary payload ([#82](https://github.com/pymeasure/pyleco/pull/82))
* Improve getting_started and readme documentation ([#80](https://github.com/pymeasure/pyleco/pull/80))
* Add RELEASE.md ([#79](https://github.com/pymeasure/pyleco/pull/79))
* Add locking actor ([#84](https://github.com/pymeasure/pyleco/pull/84))

### Fixed

* Fix listener documentation ([#88](https://github.com/pymeasure/pyleco/pull/88))

**Full Changelog**: https://github.com/pymeasure/pyleco/compare/v0.3.2...v0.4.0


## [0.3.2] 2024-05-07

### Fixed

* Fix dependency on outdated UUIDv7 generating library to `uuid6` package ([#75](https://github.com/pymeasure/pyleco/pull/75))
* Fix codecov CI ([#73](https://github.com/pymeasure/pyleco/pull/73))

**Full Changelog**: https://github.com/pymeasure/pyleco/compare/v0.3.1...v0.3.2


## [0.3.1] 2024-04-12

### Fixed

* Fix `Coordinator` to not use period in hostname as namespace ([#69](https://github.com/pymeasure/pyleco/pull/69))
* Fix `DataLogger` timer ([#70](https://github.com/pymeasure/pyleco/pull/70))

**Full Changelog**: https://github.com/pymeasure/pyleco/compare/v0.3.0...v0.3.1


## [0.3.0] 2024-03-13

_Use self defined objects instead of jsonrpc2-objects and jsonrpc2-pyclient._

### Changed

- Rename `cls` parameter to `device_class` in `Actor` and `TransparentDirector`.
- Substitute `jsonrpc2-objects` and `jsonrpc2-pyclient` by self written objects ([#65](https://github.com/pymeasure/pyleco/pull/65))
- Move error definitions from `pyleco.errors` to `pyleco.json_utils.errors` ([#63](https://github.com/pymeasure/pyleco/pull/63))
- Move `pyleco.errors.CommunicationError` to `pyleco.json_utils.errors` ([#63](https://github.com/pymeasure/pyleco/pull/63))
- Deprecate `generate_error_with_data` in favor of `DataError.from_error` class method ([#63](https://github.com/pymeasure/pyleco/pull/63))
- Python requirement lowered to Python 3.8 ([#64](https://github.com/pymeasure/pyleco/pull/64))
- Rework the message buffer in the base communicator and harmonize with pipe handler's buffer ([#66](https://github.com/pymeasure/pyleco/pull/66))
- Bump CI actions versions for node.js 20 ([#62](https://github.com/pymeasure/pyleco/pull/62))

### Added

- Add __future__.annotations to all files, which need it for annotations for Python 3.7/3.8.
- Add self written `RPCServer` as alternative to openrpc package.

### Deprecated

- Deprecate `pyleco.errors` in favor of `json_utils.errors` and `json_utils.json_objects`.
- Deprecate to use `CommunicatorPipe.buffer`, use `message_buffer` instead.

### Fixed

- Fix Listener's communcator did not know, when listening stopped ([#67](https://github.com/pymeasure/pyleco/pull/67))

**Full Changelog**: https://github.com/pymeasure/pyleco/compare/v0.2.2...v0.3.0


## [0.2.2] - 2024-02-14

### Fixed

- Fix Communicator to distinguish correctly different json rpc messages ([#57](https://github.com/pymeasure/pyleco/issues/57))
- Fix MessageHandler not distinguish correctly batch requests ([#56](https://github.com/pymeasure/pyleco/issues/56))
- Bump setup-python action version to v5

**Full Changelog**: https://github.com/pymeasure/pyleco/compare/v0.2.1...v.0.2.2


## [0.2.1] - 2024-02-13

### Fixed

- Fix BaseCommunciator to hand over message, if it is an error message (#55)

**Full Changelog**: https://github.com/pymeasure/pyleco/compare/v0.2.0...v.0.2.1


## [0.2.0] - 2024-02-13

_Several deprecated parts are removed and inner workings are changed._

### Changed

- **Breaking:** change `MessageHandler.handle_commands` to `handle_message` ([#44](https://github.com/pymeasure/pyleco/pull/44))
- **Breaking:** change PipeHandler inner workings of handling messages ([#44](https://github.com/pymeasure/pyleco/pull/44))
- Add `BaseCommunicator` as a base class for Communicator and MessageHandler ([#48](https://github.com/pymeasure/pyleco/pull/48))
- Refactor the Coordinator `handle_commands` ([#50](https://github.com/pymeasure/pyleco/pull/50))

### Added

- Add the `Coordinator`, the `proxy_server`, and the `starter` as scripts to the command line ([#53](https://github.com/pymeasure/pyleco/pull/53))

### Removed

- **Breaking:** remove `Coordinator.ask_raw` (#48)
- **Breaking:** remove legacy subscription messages from extended message handler (#48)

### Fixed

- Fix DataLogger to start a timer, even if not specified explicitly ([#51](https://github.com/pymeasure/pyleco/pull/51))

**Full Changelog**: https://github.com/pymeasure/pyleco/compare/v0.1.0...v.0.2.0


## [0.1.0] - 2024-02-01

### Changed

- Change message and protocols according to LECO change ([`9d74731da`](https://github.com/pymeasure/pyleco/commit/9d74731da06d147b1773f1f411bd943a36b4a83d)) (@BenediktBurger)
- Change Coordinator's `fname` to `full_name` ([`f3564c0`](https://github.com/pymeasure/pyleco/commit/f3564c08f04ed63bbab5b1100560e7b50239d83c)) (@BenediktBurger)

### Added

- Add compatibility with Python 3.9 ([`18abb87`](https://github.com/pymeasure/pyleco/commit/18abb87fea259f9e87411d88cca92a886bbd62b4)) (@BenediktBurger)
- Add compatibility with Python 3.12 ([#22](https://github.com/pymeasure/pyleco/pull/22)) (@BenediktBurger)
- Add more tests.
- Add more functionality to internal protocol and test suite ([`42e107c5cb90`](https://github.com/pymeasure/pyleco/commit/42e107c5cb90704dbb99ef1c5a50be739f3acf85)) (@BenediktBurger)
- Add Communicator functionality to the MessageHandler by distinguishing messages. (`9b0cc42`, `45913a5`, `97d902b`) (@BenediktBurger)
- Add CI for testing ([#22](https://github.com/pymeasure/pyleco/pull/22), [#7](https://github.com/pymeasure/pyleco/pull/7), #34, #29, #26) (@BenediktBurger)
- Add codecov code coverage calculation to CI ([#32](https://github.com/pymeasure/pyleco/pull/32)) (@BenediktBurger)
- Add `GETTING_STARTED.md` with a tutorial ([`000245b`](https://github.com/pymeasure/pyleco/commit/000245b7d693336a36b3f8bb5b0d0fe13a1bd6a7)) ([#24](https://github.com/pymeasure/pyleco/pull/24)) (@BenediktBurger, @bklebel)

### Removed

- **Breaking:** remove deprecated `Publisher` (use `DataPublisher` instead); move `Republisher` and `ExtendedPublisher` to pyleco-extras package ([#33](https://github.com/pymeasure/pyleco/pull/33)) (@BenediktBurger)
- **Breaking:** remove deprecated `call_method_rpc` and `call_method_rpc_async`

### Fixed

- Fix typos, also in variable / method names


## [alpha-0.0.1] - 2023-12-12

_Initial alpha version, complies with [LECO protocol alpha-0.0.1](https://github.com/pymeasure/leco-protocol/releases/tag/alpha-0.0.1)_

### New Contributors

@BenediktBurger, @bilderbuchi, @bklebel


[unreleased]: https://github.com/pymeasure/pyleco/compare/v0.4.0...HEAD
[0.4.0]: https://github.com/pymeasure/pyleco/releases/tag/v0.4.0
[0.3.2]: https://github.com/pymeasure/pyleco/releases/tag/v0.3.2
[0.3.1]: https://github.com/pymeasure/pyleco/releases/tag/v0.3.1
[0.3.0]: https://github.com/pymeasure/pyleco/releases/tag/v0.3.0
[0.2.2]: https://github.com/pymeasure/pyleco/releases/tag/v0.2.2
[0.2.1]: https://github.com/pymeasure/pyleco/releases/tag/v0.2.1
[0.2.0]: https://github.com/pymeasure/pyleco/releases/tag/v0.2.0
[0.1.0]: https://github.com/pymeasure/pyleco/releases/tag/v0.1.0
[alpha-0.0.1]: https://github.com/pymeasure/pyleco/releases/tag/alpha-0.0.1
Loading