forked from ess-dmsc/python-streaming-data-types
-
Notifications
You must be signed in to change notification settings - Fork 0
create isis-streaming-data-types #2
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
Open
rerpha
wants to merge
3
commits into
main
Choose a base branch
from
isis_streaming_data_types
base: main
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Open
Changes from all commits
Commits
Show all changes
3 commits
Select commit
Hold shift + click to select a range
File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file was deleted.
Oops, something went wrong.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,10 @@ | ||
| version: 2 | ||
| updates: | ||
| - package-ecosystem: "pip" | ||
| directory: "/" | ||
| schedule: | ||
| interval: "daily" | ||
| - package-ecosystem: "github-actions" | ||
| directory: "/" | ||
| schedule: | ||
| interval: "daily" |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,48 @@ | ||
| # This workflow will install Python dependencies, run tests and lint with a single version of Python | ||
| # For more information see: https://docs.github.com/en/actions/automating-builds-and-tests/building-and-testing-python | ||
|
|
||
| name: Python application | ||
|
|
||
| on: | ||
| workflow_call: | ||
| push: | ||
| branches: [ "main" ] | ||
| pull_request: | ||
| branches: [ "main" ] | ||
|
|
||
| jobs: | ||
| call-workflow: | ||
| uses: ISISComputingGroup/reusable-workflows/.github/workflows/linters.yml@main | ||
| with: | ||
| compare-branch: origin/main | ||
| python-ver: '3.13' | ||
| runs-on: 'ubuntu-latest' | ||
| tests: | ||
| strategy: | ||
| matrix: | ||
| version: ['3.12', '3.13', '3.14'] | ||
| os: ["ubuntu-latest", "windows-latest"] | ||
| runs-on: ${{ matrix.os }} | ||
| steps: | ||
| - uses: actions/checkout@v6 | ||
| - name: Install uv and set the python version | ||
| uses: astral-sh/setup-uv@v7 | ||
| with: | ||
| python-version: ${{ matrix.version }} | ||
| - name: Install dependencies | ||
| run: uv sync --all-extras --dev | ||
| - name: Test with pytest | ||
| run: uv run pytest tests | ||
| results: | ||
| if: ${{ always() }} | ||
| runs-on: ubuntu-latest | ||
| name: Final Results | ||
| needs: [tests, call-workflow] | ||
| steps: | ||
| - run: exit 1 | ||
| # see https://stackoverflow.com/a/67532120/4907315 | ||
| if: >- | ||
| ${{ | ||
| contains(needs.*.result, 'failure') | ||
| || contains(needs.*.result, 'cancelled') | ||
| }} | ||
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,9 @@ | ||
| name: lint-and-test-nightly | ||
| on: | ||
| schedule: | ||
| - cron: "0 0 * * *" | ||
| workflow_dispatch: | ||
|
|
||
| jobs: | ||
| lint-and-test-nightly: | ||
| uses: ./.github/workflows/Lint-and-test.yml |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,92 @@ | ||
| name: Publish Python distribution to PyPI | ||
| on: push | ||
| jobs: | ||
| lint-and-test: | ||
| if: github.ref_type == 'tag' | ||
| name: Run linter and tests | ||
| uses: ./.github/workflows/Lint-and-test.yml | ||
| build: | ||
| needs: lint-and-test | ||
| if: github.ref_type == 'tag' | ||
| name: build distribution | ||
| runs-on: ubuntu-latest | ||
|
|
||
| steps: | ||
| - uses: actions/checkout@v6 | ||
| - name: Set up Python | ||
| uses: actions/setup-python@v6 | ||
| with: | ||
| python-version: "3.13" | ||
| - name: Install pypa/build | ||
| run: >- | ||
| python3 -m | ||
| pip install | ||
| build | ||
| --user | ||
| - name: Build a binary wheel and a source tarball | ||
| run: python3 -m build | ||
| - name: Store the distribution packages | ||
| uses: actions/upload-artifact@v6 | ||
| with: | ||
| name: python-package-distributions | ||
| path: dist/ | ||
| publish-to-pypi: | ||
| name: >- | ||
| Publish Python distribution to PyPI | ||
| if: github.ref_type == 'tag' | ||
| needs: [lint-and-test, build] | ||
| runs-on: ubuntu-latest | ||
| environment: | ||
| name: release | ||
| url: https://pypi.org/p/isis-streaming-data-types | ||
| permissions: | ||
| id-token: write # IMPORTANT: mandatory for trusted publishing | ||
| steps: | ||
| - name: Download all the dists | ||
| uses: actions/download-artifact@v7 | ||
| with: | ||
| name: python-package-distributions | ||
| path: dist/ | ||
| - name: Publish distribution to PyPI | ||
| uses: pypa/gh-action-pypi-publish@release/v1 | ||
| github-release: | ||
| name: >- | ||
| Sign the Python distribution with Sigstore | ||
| and upload them to GitHub Release | ||
| needs: [lint-and-test, build, publish-to-pypi] | ||
| runs-on: ubuntu-latest | ||
|
|
||
| permissions: | ||
| contents: write # IMPORTANT: mandatory for making GitHub Releases | ||
| id-token: write # IMPORTANT: mandatory for sigstore | ||
|
|
||
| steps: | ||
| - name: Download all the dists | ||
| uses: actions/download-artifact@v7 | ||
| with: | ||
| name: python-package-distributions | ||
| path: dist/ | ||
| - name: Sign the dists with Sigstore | ||
| uses: sigstore/gh-action-sigstore-python@v3.2.0 | ||
| with: | ||
| inputs: >- | ||
| ./dist/*.tar.gz | ||
| ./dist/*.whl | ||
| - name: Create GitHub Release | ||
| env: | ||
| GITHUB_TOKEN: ${{ github.token }} | ||
| run: >- | ||
| gh release create | ||
| '${{ github.ref_name }}' | ||
| --repo '${{ github.repository }}' | ||
| --notes "" | ||
| - name: Upload artifact signatures to GitHub Release | ||
| env: | ||
| GITHUB_TOKEN: ${{ github.token }} | ||
| # Upload to GitHub Release using the `gh` CLI. | ||
| # `dist/` contains the built packages, and the | ||
| # sigstore-produced signatures and certificates. | ||
| run: >- | ||
| gh release upload | ||
| '${{ github.ref_name }}' dist/** | ||
| --repo '${{ github.repository }}' |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -136,3 +136,5 @@ dmypy.json | |
| # VSCode | ||
| .vscode | ||
|
|
||
|
|
||
| src/streaming_data_types/_version.py | ||
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,99 @@ | ||
| [build-system] | ||
| requires = ["setuptools", "setuptools_scm>=8"] | ||
| build-backend = "setuptools.build_meta" | ||
|
|
||
|
|
||
| [project] | ||
| name = "isis_streaming_data_types" | ||
| dynamic = ["version"] | ||
| description = "Python utilities for handling ISIS streamed data" | ||
| readme = "README.md" | ||
| requires-python = ">=3.12" | ||
| license-files = ["LICENSE"] | ||
|
|
||
| authors = [ | ||
| {name = "ISIS Experiment Controls", email = "ISISExperimentControls@stfc.ac.uk" } | ||
| ] | ||
| maintainers = [ | ||
| {name = "ISIS Experiment Controls", email = "ISISExperimentControls@stfc.ac.uk" } | ||
| ] | ||
|
|
||
| # Classifiers help users find your project by categorizing it. | ||
| # | ||
| # For a list of valid classifiers, see https://pypi.org/classifiers/ | ||
| classifiers = [ | ||
| # How mature is this project? Common values are | ||
| # 3 - Alpha | ||
| # 4 - Beta | ||
| # 5 - Production/Stable | ||
| "Development Status :: 3 - Alpha", | ||
| "Intended Audience :: Developers", | ||
|
|
||
| # Specify the Python versions you support here. In particular, ensure | ||
| # that you indicate you support Python 3. These classifiers are *not* | ||
| # checked by "pip install". See instead "requires-python" key in this file. | ||
| "Programming Language :: Python :: 3", | ||
| "Programming Language :: Python :: 3.12", | ||
| "Programming Language :: Python :: 3.13", | ||
| "Programming Language :: Python :: 3.14", | ||
| "Programming Language :: Python :: 3 :: Only", | ||
| ] | ||
|
|
||
| dependencies = [ | ||
| "flatbuffers", | ||
| "numpy>2" | ||
| ] | ||
|
|
||
| [project.optional-dependencies] | ||
| dev = [ | ||
| "ruff>=0.8", | ||
| "pyright", | ||
| "pytest", | ||
| "pytest-cov", | ||
| ] | ||
|
|
||
| [project.urls] | ||
| "Homepage" = "https://github.com/isiscomputinggroup/isis_streaming_data_types" | ||
| "Bug Reports" = "https://github.com/isiscomputinggroup/isis_streaming_data_types/issues" | ||
| "Source" = "https://github.com/isiscomputinggroup/isis_streaming_data_types" | ||
|
|
||
| [tool.pytest.ini_options] | ||
| testpaths = "tests" | ||
| asyncio_mode = "auto" | ||
| addopts = "--cov --cov-report=html -vv" | ||
|
|
||
| [tool.coverage.run] | ||
| branch = true | ||
| source = ["src"] | ||
|
|
||
| [tool.coverage.report] | ||
| fail_under = 100 | ||
| exclude_lines = [ | ||
| "pragma: no cover", | ||
| "if TYPE_CHECKING:", | ||
| "if typing.TYPE_CHECKING:", | ||
| "@abstractmethod", | ||
| ] | ||
|
|
||
| [tool.coverage.html] | ||
| directory = "coverage_html_report" | ||
|
|
||
| [tool.pyright] | ||
| include = ["src", "tests"] | ||
| reportConstantRedefinition = true | ||
| reportDeprecated = true | ||
| reportInconsistentConstructor = true | ||
| reportMissingParameterType = true | ||
| reportMissingTypeArgument = true | ||
| reportUnnecessaryCast = true | ||
| reportUnnecessaryComparison = true | ||
| reportUnnecessaryContains = true | ||
| reportUnnecessaryIsInstance = true | ||
| reportUntypedBaseClass = true | ||
| reportUntypedClassDecorator = true | ||
| reportUntypedFunctionDecorator = true | ||
|
|
||
| [tool.setuptools_scm] | ||
| version_file = "src/streaming_data_types/_version.py" | ||
|
|
||
|
|
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.