apsbits 1.0.0rc2__tar.gz

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (96) hide show
  1. apsbits-1.0.0rc2/.github/ISSUE_TEMPLATE/bug_report.md +30 -0
  2. apsbits-1.0.0rc2/.github/ISSUE_TEMPLATE/config.yml +1 -0
  3. apsbits-1.0.0rc2/.github/ISSUE_TEMPLATE/feature_request.md +20 -0
  4. apsbits-1.0.0rc2/.github/ISSUE_TEMPLATE/other.md +10 -0
  5. apsbits-1.0.0rc2/.github/ISSUE_TEMPLATE/question-issue-template.md +10 -0
  6. apsbits-1.0.0rc2/.github/PULL_REQUEST_TEMPLATE.md +16 -0
  7. apsbits-1.0.0rc2/.github/dependabot.yml +12 -0
  8. apsbits-1.0.0rc2/.github/workflows/code.yml +164 -0
  9. apsbits-1.0.0rc2/.github/workflows/docs.yml +72 -0
  10. apsbits-1.0.0rc2/.github/workflows/init_repo.sh +23 -0
  11. apsbits-1.0.0rc2/.github/workflows/init_repo.yml +36 -0
  12. apsbits-1.0.0rc2/.github/workflows/pypi.yml +58 -0
  13. apsbits-1.0.0rc2/.github/workflows/template_sync.yml +35 -0
  14. apsbits-1.0.0rc2/.gitignore +177 -0
  15. apsbits-1.0.0rc2/.pre-commit-config.yaml +32 -0
  16. apsbits-1.0.0rc2/.templatesyncignore +5 -0
  17. apsbits-1.0.0rc2/LICENSE +48 -0
  18. apsbits-1.0.0rc2/PKG-INFO +349 -0
  19. apsbits-1.0.0rc2/README.md +239 -0
  20. apsbits-1.0.0rc2/apsbits.egg-info/PKG-INFO +349 -0
  21. apsbits-1.0.0rc2/apsbits.egg-info/SOURCES.txt +94 -0
  22. apsbits-1.0.0rc2/apsbits.egg-info/dependency_links.txt +1 -0
  23. apsbits-1.0.0rc2/apsbits.egg-info/entry_points.txt +2 -0
  24. apsbits-1.0.0rc2/apsbits.egg-info/requires.txt +42 -0
  25. apsbits-1.0.0rc2/apsbits.egg-info/top_level.txt +1 -0
  26. apsbits-1.0.0rc2/docs/Makefile +20 -0
  27. apsbits-1.0.0rc2/docs/make.bat +35 -0
  28. apsbits-1.0.0rc2/docs/resources/create-repository-name.webp +0 -0
  29. apsbits-1.0.0rc2/docs/resources/create-repository-owner.webp +0 -0
  30. apsbits-1.0.0rc2/docs/resources/use-this-template-button.webp +0 -0
  31. apsbits-1.0.0rc2/docs/source/_static/.gitkeep +0 -0
  32. apsbits-1.0.0rc2/docs/source/api/callbacks.rst +16 -0
  33. apsbits-1.0.0rc2/docs/source/api/configs.rst +44 -0
  34. apsbits-1.0.0rc2/docs/source/api/core.rst +19 -0
  35. apsbits-1.0.0rc2/docs/source/api/devices.rst +309 -0
  36. apsbits-1.0.0rc2/docs/source/api/index.rst +42 -0
  37. apsbits-1.0.0rc2/docs/source/api/plans.rst +15 -0
  38. apsbits-1.0.0rc2/docs/source/api/startup.rst +19 -0
  39. apsbits-1.0.0rc2/docs/source/api/utils.rst +28 -0
  40. apsbits-1.0.0rc2/docs/source/conf.py +87 -0
  41. apsbits-1.0.0rc2/docs/source/console.rst +62 -0
  42. apsbits-1.0.0rc2/docs/source/demo.ipynb +232 -0
  43. apsbits-1.0.0rc2/docs/source/guides/dm.md +85 -0
  44. apsbits-1.0.0rc2/docs/source/guides/index.rst +13 -0
  45. apsbits-1.0.0rc2/docs/source/guides/template_sync.rst +133 -0
  46. apsbits-1.0.0rc2/docs/source/index.rst +71 -0
  47. apsbits-1.0.0rc2/docs/source/install.rst +70 -0
  48. apsbits-1.0.0rc2/docs/source/license.rst +6 -0
  49. apsbits-1.0.0rc2/docs/source/logging_config.rst +76 -0
  50. apsbits-1.0.0rc2/docs/source/notebook.rst +63 -0
  51. apsbits-1.0.0rc2/docs/source/qserver.rst +94 -0
  52. apsbits-1.0.0rc2/docs/source/script.rst +49 -0
  53. apsbits-1.0.0rc2/docs/source/sessions.rst +15 -0
  54. apsbits-1.0.0rc2/pyproject.toml +233 -0
  55. apsbits-1.0.0rc2/qserver/qs-config.yml +51 -0
  56. apsbits-1.0.0rc2/qserver/qs_host.sh +234 -0
  57. apsbits-1.0.0rc2/qserver/user_group_permissions.yaml +46 -0
  58. apsbits-1.0.0rc2/setup.cfg +4 -0
  59. apsbits-1.0.0rc2/src/apsbits/__init__.py +18 -0
  60. apsbits-1.0.0rc2/src/apsbits/_version.py +21 -0
  61. apsbits-1.0.0rc2/src/apsbits/core/__init__.py +11 -0
  62. apsbits-1.0.0rc2/src/apsbits/core/best_effort_init.py +38 -0
  63. apsbits-1.0.0rc2/src/apsbits/core/catalog_init.py +29 -0
  64. apsbits-1.0.0rc2/src/apsbits/core/run_engine_init.py +71 -0
  65. apsbits-1.0.0rc2/src/apsbits/demo_instrument/README.md +1 -0
  66. apsbits-1.0.0rc2/src/apsbits/demo_instrument/__init__.py +3 -0
  67. apsbits-1.0.0rc2/src/apsbits/demo_instrument/callbacks/__init__.py +1 -0
  68. apsbits-1.0.0rc2/src/apsbits/demo_instrument/callbacks/nexus_data_file_writer.py +60 -0
  69. apsbits-1.0.0rc2/src/apsbits/demo_instrument/callbacks/spec_data_file_writer.py +93 -0
  70. apsbits-1.0.0rc2/src/apsbits/demo_instrument/configs/__init__.py +1 -0
  71. apsbits-1.0.0rc2/src/apsbits/demo_instrument/configs/devices.yml +52 -0
  72. apsbits-1.0.0rc2/src/apsbits/demo_instrument/configs/devices_aps_only.yml +6 -0
  73. apsbits-1.0.0rc2/src/apsbits/demo_instrument/configs/iconfig.yml +81 -0
  74. apsbits-1.0.0rc2/src/apsbits/demo_instrument/configs/logging.yml +41 -0
  75. apsbits-1.0.0rc2/src/apsbits/demo_instrument/devices/__init__.py +1 -0
  76. apsbits-1.0.0rc2/src/apsbits/demo_instrument/plans/__init__.py +8 -0
  77. apsbits-1.0.0rc2/src/apsbits/demo_instrument/plans/dm_plans.py +111 -0
  78. apsbits-1.0.0rc2/src/apsbits/demo_instrument/plans/sim_plans.py +69 -0
  79. apsbits-1.0.0rc2/src/apsbits/demo_instrument/startup.py +63 -0
  80. apsbits-1.0.0rc2/src/apsbits/tests/__init__.py +1 -0
  81. apsbits-1.0.0rc2/src/apsbits/tests/conftest.py +32 -0
  82. apsbits-1.0.0rc2/src/apsbits/tests/test_device_factories.py +44 -0
  83. apsbits-1.0.0rc2/src/apsbits/tests/test_general.py +83 -0
  84. apsbits-1.0.0rc2/src/apsbits/tests/test_stored_dict.py +139 -0
  85. apsbits-1.0.0rc2/src/apsbits/utils/__init__.py +1 -0
  86. apsbits-1.0.0rc2/src/apsbits/utils/aps_functions.py +67 -0
  87. apsbits-1.0.0rc2/src/apsbits/utils/config_loaders.py +61 -0
  88. apsbits-1.0.0rc2/src/apsbits/utils/context_aware.py +187 -0
  89. apsbits-1.0.0rc2/src/apsbits/utils/controls_setup.py +113 -0
  90. apsbits-1.0.0rc2/src/apsbits/utils/create_new_instrument.py +144 -0
  91. apsbits-1.0.0rc2/src/apsbits/utils/helper_functions.py +113 -0
  92. apsbits-1.0.0rc2/src/apsbits/utils/logging_setup.py +211 -0
  93. apsbits-1.0.0rc2/src/apsbits/utils/make_devices_yaml.py +127 -0
  94. apsbits-1.0.0rc2/src/apsbits/utils/metadata.py +101 -0
  95. apsbits-1.0.0rc2/src/apsbits/utils/sim_creator.py +199 -0
  96. apsbits-1.0.0rc2/src/apsbits/utils/stored_dict.py +192 -0
@@ -0,0 +1,30 @@
1
+ ---
2
+ name: Bug report
3
+ about: Create a report to help us improve
4
+ title: ''
5
+ labels: 'bug'
6
+ assignees: ''
7
+
8
+ ---
9
+
10
+ **Describe the bug**
11
+ A clear and concise description of what the bug is.
12
+
13
+ **To Reproduce**
14
+ Steps to reproduce the behavior:
15
+ 1. Code with explanation
16
+ 2. How to run code
17
+ 3. The error
18
+
19
+ **Expected behavior**
20
+ A clear and concise description of what you expected to happen.
21
+
22
+ **Screenshots**
23
+ If applicable, add screenshots to help explain your problem.
24
+
25
+ **Environment (please complete the following information):**
26
+ - OS: [e.g. Linux]
27
+ - Package versions implicated in the error (torch, mdlearn versions, etc)
28
+
29
+ **Additional context**
30
+ Add any other context about the problem here.
@@ -0,0 +1 @@
1
+ blank_issues_enabled: false
@@ -0,0 +1,20 @@
1
+ ---
2
+ name: Feature request
3
+ about: Suggest an idea for this project
4
+ title: ''
5
+ labels: 'enhancement'
6
+ assignees: ''
7
+
8
+ ---
9
+
10
+ **Is your feature request related to a problem? Please describe.**
11
+ A clear and concise description of what the problem is. Ex. I'm always frustrated when [...]
12
+
13
+ **Describe the solution you'd like**
14
+ A clear and concise description of what you want to happen.
15
+
16
+ **Describe alternatives you've considered**
17
+ A clear and concise description of any alternative solutions or features you've considered.
18
+
19
+ **Additional context**
20
+ Add any other context or screenshots about the feature request here.
@@ -0,0 +1,10 @@
1
+ ---
2
+ name: Other issue template
3
+ about: Any issue that does not fit the other templates
4
+ title: ''
5
+ labels: ''
6
+ assignees: ''
7
+
8
+ ---
9
+
10
+ **Description**
@@ -0,0 +1,10 @@
1
+ ---
2
+ name: Question issue template
3
+ about: Ask a question about how to use mdlearn
4
+ title: ''
5
+ labels: question
6
+ assignees: ''
7
+
8
+ ---
9
+
10
+ **Describe the question**
@@ -0,0 +1,16 @@
1
+ # Description
2
+
3
+ Please include a summary of the change and (optionally) which issue is fixed. Please also include
4
+ relevant motivation and context.
5
+
6
+ Fixes # (issue)
7
+
8
+ ## Type of change
9
+
10
+ Choose which options apply, and delete the ones which do not apply.
11
+
12
+ - Bug fix (non-breaking change that fixes an issue)
13
+ - New feature (non-breaking change that adds functionality)
14
+ - Breaking change (fix or feature that would cause existing functionality to not work as expected)
15
+ - Documentation update
16
+ - Code maintenance/cleanup
@@ -0,0 +1,12 @@
1
+ # Set update schedule for GitHub Actions
2
+ # https://docs.github.com/en/code-security/dependabot/working-with-dependabot/keeping-your-actions-up-to-date-with-dependabot
3
+ # https://docs.github.com/code-security/dependabot/dependabot-version-updates/configuration-options-for-the-dependabot.yml-file
4
+
5
+ version: 2
6
+ updates:
7
+
8
+ - package-ecosystem: "github-actions"
9
+ directory: "/"
10
+ schedule:
11
+ # Check for updates to GitHub Actions every week
12
+ interval: "weekly"
@@ -0,0 +1,164 @@
1
+ name: Unit Tests & Code Coverage
2
+
3
+ on:
4
+ # Triggers the workflow on push or pull request events but only for the main branch
5
+ push:
6
+ branches:
7
+ - main
8
+ pull_request:
9
+ branches:
10
+ - main
11
+ workflow_dispatch: # allow manual triggering
12
+
13
+ defaults:
14
+ run:
15
+ shell: bash -l {0}
16
+
17
+ jobs:
18
+ lint:
19
+ name: Code style
20
+ runs-on: ubuntu-latest
21
+
22
+ steps:
23
+ - uses: actions/checkout@v4
24
+
25
+ - uses: actions/setup-python@v5
26
+ with:
27
+ python-version: "3.11"
28
+
29
+ - name: Upgrade pip & test with pre-commit
30
+ run: |
31
+ set -vxeuo pipefail
32
+ python -m pip install --upgrade pip
33
+ python -m pip install pre-commit
34
+ pre-commit run --all-files
35
+
36
+ test-matrix:
37
+ name: Python ${{ matrix.python-version }} # - Redis ${{ matrix.redis-version }}
38
+ runs-on: ubuntu-latest
39
+ needs: lint
40
+ strategy:
41
+ matrix:
42
+ python-version:
43
+ - "3.11"
44
+ - "3.12"
45
+ # - "3.13" waiting for upstream packages
46
+ # redis-version:
47
+ # # - "6"
48
+ # - "7"
49
+ max-parallel: 5
50
+ env:
51
+ DISPLAY: ":99.0"
52
+
53
+ steps:
54
+ - uses: actions/checkout@v4
55
+
56
+ - name: Install OS libraries to test Linux PyQt apps
57
+ run: |
58
+ sudo apt update -y
59
+ sudo apt install -y \
60
+ libxcb-icccm4 \
61
+ libxcb-image0 \
62
+ libxcb-keysyms1 \
63
+ libxcb-randr0 \
64
+ libxcb-render-util0 \
65
+ libxcb-xinerama0 \
66
+ libxcb-xfixes0 \
67
+ libxkbcommon-x11-0 \
68
+ screen \
69
+ x11-utils \
70
+ xvfb
71
+
72
+ # FIXME: conflicts if redis is running on host (local runners)
73
+ # - name: Start Redis
74
+ # uses: supercharge/redis-github-action@1.7.0
75
+ # with:
76
+ # redis-version: ${{ matrix.redis-version }}
77
+ # redis-remove-container: true # false by default
78
+
79
+ - name: Create environment Python ${{ matrix.python-version }} # - Redis ${{ matrix.redis-version }}
80
+ # needed for Unpack step
81
+ uses: mamba-org/setup-micromamba@v2
82
+ with:
83
+ cache-environment: true
84
+ cache-environment-key: env-key-${{ matrix.python-version }}
85
+ condarc: |
86
+ channels:
87
+ - conda-forge
88
+ - nodefaults
89
+ channel-priority: flexible
90
+ # environment-file: environment.yml
91
+ environment-name: anaconda-test-env-py-${{ matrix.python-version }} # -${{ matrix.redis-version }}
92
+ create-args: >-
93
+ coveralls
94
+ pytest
95
+ pytest-cov
96
+ pytest-qt
97
+ pytest-xvfb
98
+ python=${{ matrix.python-version }}
99
+ setuptools-scm
100
+ pyqt>5.15
101
+ pyepics
102
+
103
+ - name: Install this package with pip
104
+ shell: bash -l {0}
105
+ run: |
106
+ set -vxeuo pipefail
107
+ pip install -e .
108
+
109
+ - name: Run tests with pytest & coverage
110
+ shell: bash -l {0}
111
+ run: |
112
+ set -vxeuo pipefail
113
+ coverage run --concurrency=thread --parallel-mode -m pytest -vvv --exitfirst .
114
+ coverage combine
115
+ coverage report --precision 3
116
+
117
+ - name: Upload coverage data to coveralls.io
118
+ shell: bash -l {0}
119
+ run: |
120
+ set -vxeuo pipefail
121
+ micromamba list coveralls
122
+ which coveralls
123
+ coveralls debug
124
+ if [ "${GITHUB_TOKEN}" != "" ]; then
125
+ # only upload from GitHub runner
126
+ coveralls --service=github
127
+ else
128
+ echo "No credentials for upload to coveralls."
129
+ fi
130
+ env:
131
+ GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
132
+ COVERALLS_FLAG_NAME: ${{ matrix.python-version }} # -${{ matrix.redis-version }}
133
+ COVERALLS_PARALLEL: true
134
+
135
+ - name: IPython Startup Test
136
+ shell: bash -l {0}
137
+ run: |
138
+ set -vxeuo pipefail
139
+ ipython -c "from apsbits.demo_instrument.startup import *; RE(make_devices())"
140
+
141
+ # https://coveralls-python.readthedocs.io/en/latest/usage/configuration.html#github-actions-support
142
+ coveralls:
143
+ name: Report unit test coverage to coveralls
144
+ needs: test-matrix
145
+ runs-on: ubuntu-latest
146
+ container: python:3-slim
147
+
148
+ steps:
149
+ - name: Gather coverage and report to Coveralls
150
+ run: |
151
+ set -vxeuo pipefail
152
+ echo "Finally!"
153
+ pip3 install --upgrade coveralls
154
+ # debug mode: output prepared json and reported files list to stdout
155
+ # https://coveralls-python.readthedocs.io/en/latest/troubleshooting.html
156
+ coveralls debug
157
+ if [ "${GITHUB_TOKEN}" != "" ]; then
158
+ # only upload from GitHub runner
159
+ coveralls --service=github --finish
160
+ else
161
+ echo "No credentials for upload to coveralls."
162
+ fi
163
+ env:
164
+ GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
@@ -0,0 +1,72 @@
1
+ name: Publish Sphinx docs to GitHub Pages
2
+ # see: https://github.com/marketplace/actions/sphinx-to-github-pages
3
+
4
+ on:
5
+ # Build the docs on pushes to main branch, PRs to main branch, and new tags.
6
+ # Publish only on demand.
7
+ push:
8
+ branches:
9
+ - main
10
+ tags:
11
+ - '*' # all tags
12
+ pull_request:
13
+ branches:
14
+ - main
15
+ workflow_dispatch: # allow manual triggering
16
+ inputs:
17
+ deploy:
18
+ description: 'Deploy documentation'
19
+ type: boolean
20
+ required: true
21
+ default: false
22
+
23
+ defaults:
24
+ run:
25
+ shell: bash -l {0}
26
+
27
+ jobs:
28
+
29
+ pages:
30
+ name: Publish documentation
31
+ runs-on: ubuntu-latest
32
+
33
+ steps:
34
+
35
+ - name: Deploy Information
36
+ if: ${{ github.event.inputs.deploy }}
37
+ run: |
38
+ echo "The docs will be published from this workflow run."
39
+
40
+ - name: Install pandoc
41
+ run: |
42
+ set -vxeuo pipefail
43
+ sudo apt-get update
44
+ sudo apt-get -y install pandoc
45
+
46
+ - name: Set time zone
47
+ run: echo "TZ=America/Chicago" >> "$GITHUB_ENV"
48
+
49
+ - name: Checkout
50
+ uses: actions/checkout@v4
51
+ with:
52
+ fetch-depth: 0 # required for push to dest repo
53
+
54
+ - uses: actions/setup-python@v5
55
+ with:
56
+ python-version: "3.11"
57
+
58
+ - name: Install our package
59
+ run: pip install -e .[doc]
60
+
61
+ - name: Sphinx
62
+ id: deployment
63
+ run: make -C docs html
64
+
65
+ - name: Publish (push gh-pages branch) only on demand
66
+ uses: peaceiris/actions-gh-pages@v4
67
+ if: ${{ github.event.inputs.deploy }}
68
+ with:
69
+ publish_branch: gh-pages
70
+ github_token: ${{ secrets.GITHUB_TOKEN }}
71
+ publish_dir: docs/build/html
72
+ force_orphan: true
@@ -0,0 +1,23 @@
1
+ #!/usr/bin/env bash
2
+
3
+ full_name=$1
4
+
5
+ echo $full_name
6
+
7
+ repo=$(echo $full_name | awk -F '/' '{print $2}')
8
+
9
+ # Sanitize the repo name to be a valid Python package name
10
+ sanitized_repo=$(echo "$repo" | sed 's/[^a-zA-Z0-9_-]/_/g')
11
+
12
+ original_repo="APSBITS"
13
+
14
+ echo $sanitized_repo
15
+ echo $original_repo
16
+
17
+ sed -i "s/$original_repo/$sanitized_repo/g" README.md
18
+
19
+ # Call the create_new_instrument function
20
+ python3 -m apsbits.utils.create_new_instrument "${sanitized_repo}_instrument" "src/."
21
+
22
+ rm -rf .github/workflows/init_repo.sh
23
+ rm -rf .github/workflows/init_repo.yml
@@ -0,0 +1,36 @@
1
+ # name: Init repo
2
+ # on: [push]
3
+
4
+ # permissions:
5
+ # contents: write # Enables pushing commits back to repository
6
+
7
+ # jobs:
8
+ # rename-project:
9
+ # if: ${{ github.repository != 'bcda-aps/apsbits' }}
10
+ # runs-on: ubuntu-latest
11
+ # steps:
12
+ # - uses: actions/checkout@v4
13
+ # with:
14
+ # fetch-depth: 0
15
+ # ref: ${{ github.head_ref }}
16
+
17
+ # - name: Set up Python
18
+ # uses: actions/setup-python@v5
19
+ # with:
20
+ # python-version: '3.x'
21
+
22
+ # - name: Install dependencies
23
+ # run: |
24
+ # python -m pip install --upgrade pip
25
+ # pip install -e . --no-deps
26
+ # pip install toml pyyaml
27
+ # - name: Run init_repo.sh
28
+ # run: |
29
+ # set -vxeuo pipefail
30
+ # bash .github/workflows/init_repo.sh ${{ github.repository }}
31
+
32
+ # - uses: stefanzweifel/git-auto-commit-action@v5
33
+ # with:
34
+ # commit_message: "✅ Ready to clone and code."
35
+ # push_options: --force
36
+ # tagging_message: 'v1.0.0'
@@ -0,0 +1,58 @@
1
+ name: Publish Python 🐍 distributions 📦 to PyPI and TestPyPI
2
+
3
+ on:
4
+ # Triggers the workflow on push events but only for the main branch
5
+ push:
6
+ branches:
7
+ - main
8
+ tags:
9
+ - "*" # all tags
10
+
11
+ permissions:
12
+ id-token: write
13
+ contents: read
14
+
15
+ jobs:
16
+ build-n-publish:
17
+ name: Build and publish Python 🐍 distributions 📦 to PyPI and TestPyPI
18
+ runs-on: ubuntu-latest
19
+
20
+ steps:
21
+ - uses: actions/checkout@v4
22
+ - name: Set up Python
23
+ uses: actions/setup-python@v5
24
+ with:
25
+ python-version: "3.11"
26
+
27
+ - name: Install pypa/build
28
+ run: >-
29
+ python -m
30
+ pip install
31
+ build
32
+ --user
33
+ - name: Build a binary wheel and a source tarball
34
+ run: >-
35
+ python -m
36
+ build
37
+ --sdist
38
+ --wheel
39
+ --outdir dist/
40
+ .
41
+
42
+ - name: Install twine
43
+ run: >-
44
+ python -m
45
+ pip install
46
+ twine
47
+
48
+ - name: Check package metadata
49
+ run: >-
50
+ twine check dist/*
51
+
52
+ - name: Publish distribution 📦 to PyPI
53
+ if: startsWith(github.ref, 'refs/tags')
54
+ uses: pypa/gh-action-pypi-publish@release/v1
55
+ with:
56
+ user: __token__
57
+ # password: ${{ secrets.PYPI_API_TOKEN }}
58
+ verbose: true
@@ -0,0 +1,35 @@
1
+ name: template_sync
2
+
3
+ # see: https://github.com/AndreasAugustin/actions-template-sync
4
+
5
+ on:
6
+ # cronjob trigger
7
+ schedule:
8
+ # 12:10 AM GMT on the first day of every month
9
+ - cron: "10 0 1 * *"
10
+ # manual trigger
11
+ workflow_dispatch:
12
+
13
+ env:
14
+ TEMPLATE_REPO: BCDA-APS/APSBITS
15
+
16
+ jobs:
17
+ repo-sync:
18
+ if: ${{ github.repository != 'bcda-aps/apsbits' }}
19
+ runs-on: ubuntu-latest
20
+ permissions:
21
+ contents: write
22
+ pull-requests: write
23
+
24
+ steps:
25
+ # To use this repository's private action, you must check out the repository
26
+ - name: Checkout
27
+ uses: actions/checkout@v4
28
+ with:
29
+ token: ${{ secrets.GH_PAT }} # `GH_PAT` is a secret that contains your PAT
30
+
31
+ - name: actions-template-sync
32
+ uses: AndreasAugustin/actions-template-sync@v2
33
+ with:
34
+ source_repo_path: ${{ env.TEMPLATE_REPO }}
35
+ upstream_branch: main
@@ -0,0 +1,177 @@
1
+ # Byte-compiled / optimized / DLL files
2
+ __pycache__/
3
+ *.py[cod]
4
+ *$py.class
5
+
6
+ # C extensions
7
+ *.so
8
+
9
+ # Distribution / packaging
10
+ .Python
11
+ build/
12
+ develop-eggs/
13
+ dist/
14
+ downloads/
15
+ eggs/
16
+ .eggs/
17
+ lib/
18
+ lib64/
19
+ parts/
20
+ sdist/
21
+ var/
22
+ wheels/
23
+ share/python-wheels/
24
+ *.egg-info/
25
+ .installed.cfg
26
+ *.egg
27
+ MANIFEST
28
+
29
+ # PyInstaller
30
+ # Usually these files are written by a python script from a template
31
+ # before PyInstaller builds the exe, so as to inject date/other infos into it.
32
+ *.manifest
33
+ *.spec
34
+
35
+ # Installer logs
36
+ pip-log.txt
37
+ pip-delete-this-directory.txt
38
+
39
+ # Unit test / coverage reports
40
+ htmlcov/
41
+ .tox/
42
+ .nox/
43
+ .coverage
44
+ .coverage.*
45
+ .cache
46
+ nosetests.xml
47
+ coverage.xml
48
+ *.cover
49
+ *.py,cover
50
+ .hypothesis/
51
+ .pytest_cache/
52
+ cover/
53
+
54
+ # Translations
55
+ *.mo
56
+ *.pot
57
+
58
+ # Django stuff:
59
+ *.log
60
+ local_settings.py
61
+ db.sqlite3
62
+ db.sqlite3-journal
63
+
64
+ # Flask stuff:
65
+ instance/
66
+ .webassets-cache
67
+
68
+ # Scrapy stuff:
69
+ .scrapy
70
+
71
+ # Sphinx documentation
72
+ docs/_build/
73
+
74
+ # PyBuilder
75
+ .pybuilder/
76
+ target/
77
+
78
+ # Jupyter Notebook
79
+ .ipynb_checkpoints
80
+
81
+ # IPython
82
+ profile_default/
83
+ ipython_config.py
84
+
85
+ # pyenv
86
+ # For a library or package, you might want to ignore these files since the code is
87
+ # intended to run in multiple environments; otherwise, check them in:
88
+ # .python-version
89
+
90
+ # pipenv
91
+ # According to pypa/pipenv#598, it is recommended to include Pipfile.lock in version control.
92
+ # However, in case of collaboration, if having platform-specific dependencies or dependencies
93
+ # having no cross-platform support, pipenv may install dependencies that don't work, or not
94
+ # install all needed dependencies.
95
+ #Pipfile.lock
96
+
97
+ # poetry
98
+ # Similar to Pipfile.lock, it is generally recommended to include poetry.lock in version control.
99
+ # This is especially recommended for binary packages to ensure reproducibility, and is more
100
+ # commonly ignored for libraries.
101
+ # https://python-poetry.org/docs/basic-usage/#commit-your-poetrylock-file-to-version-control
102
+ #poetry.lock
103
+
104
+ # pdm
105
+ # Similar to Pipfile.lock, it is generally recommended to include pdm.lock in version control.
106
+ #pdm.lock
107
+ # pdm stores project-wide configurations in .pdm.toml, but it is recommended to not include it
108
+ # in version control.
109
+ # https://pdm.fming.dev/latest/usage/project/#working-with-version-control
110
+ .pdm.toml
111
+ .pdm-python
112
+ .pdm-build/
113
+
114
+ # PEP 582; used by e.g. github.com/David-OConnor/pyflow and github.com/pdm-project/pdm
115
+ __pypackages__/
116
+
117
+ # Celery stuff
118
+ celerybeat-schedule
119
+ celerybeat.pid
120
+
121
+ # SageMath parsed files
122
+ *.sage.py
123
+
124
+ # Environments
125
+ .env
126
+ .venv
127
+ env/
128
+ venv/
129
+ ENV/
130
+ env.bak/
131
+ venv.bak/
132
+
133
+ # Spyder project settings
134
+ .spyderproject
135
+ .spyproject
136
+
137
+ # Rope project settings
138
+ .ropeproject
139
+
140
+ # mkdocs documentation
141
+ /site
142
+
143
+ # mypy
144
+ .mypy_cache/
145
+ .dmypy.json
146
+ dmypy.json
147
+
148
+ # Pyre type checker
149
+ .pyre/
150
+
151
+ # pytype static type analyzer
152
+ .pytype/
153
+
154
+ # Cython debug symbols
155
+ cython_debug/
156
+
157
+ # PyCharm
158
+ # JetBrains specific template is maintained in a separate JetBrains.gitignore that can
159
+ # be found at https://github.com/github/gitignore/blob/main/Global/JetBrains.gitignore
160
+ # and can be added to the global gitignore or merged into this file. For a more nuclear
161
+ # option (not recommended) you can uncomment the following to ignore the entire idea folder.
162
+ #.idea/
163
+
164
+ # setuptools_scm
165
+ _version.py
166
+
167
+ # Developer content
168
+ dev_*
169
+
170
+ qserver/existing_plans_and_devices.yaml
171
+ .vscode/
172
+ .logs/
173
+ *.dat
174
+ *.hdf
175
+
176
+ # Local Run Engine metadata dictionary
177
+ .re_md_dict.yml