throttle-controller 0.3.0__tar.gz → 0.3.1__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.
- {throttle_controller-0.3.0 → throttle_controller-0.3.1}/.github/workflows/pypi-publish.yml +7 -15
- {throttle_controller-0.3.0 → throttle_controller-0.3.1}/.github/workflows/python-test.yml +10 -18
- {throttle_controller-0.3.0 → throttle_controller-0.3.1}/.gitignore +5 -9
- throttle_controller-0.3.1/.gitignore.in +5 -0
- {throttle_controller-0.3.0 → throttle_controller-0.3.1}/LICENSE +1 -1
- {throttle_controller-0.3.0/throttle_controller.egg-info → throttle_controller-0.3.1}/PKG-INFO +17 -12
- throttle_controller-0.3.1/pyproject.toml +67 -0
- throttle_controller-0.3.1/setup.cfg +4 -0
- throttle_controller-0.3.1/throttle_controller/__init__.py +7 -0
- {throttle_controller-0.3.0 → throttle_controller-0.3.1}/throttle_controller/_version.py +2 -2
- {throttle_controller-0.3.0 → throttle_controller-0.3.1/throttle_controller.egg-info}/PKG-INFO +17 -12
- {throttle_controller-0.3.0 → throttle_controller-0.3.1}/throttle_controller.egg-info/SOURCES.txt +1 -2
- throttle_controller-0.3.1/throttle_controller.egg-info/requires.txt +1 -0
- {throttle_controller-0.3.0 → throttle_controller-0.3.1}/throttle_controller.egg-info/top_level.txt +0 -1
- throttle_controller-0.3.1/uv.lock +407 -0
- throttle_controller-0.3.0/.gitignore.in +0 -10
- throttle_controller-0.3.0/poetry.lock +0 -509
- throttle_controller-0.3.0/pyproject.toml +0 -52
- throttle_controller-0.3.0/setup.cfg +0 -46
- throttle_controller-0.3.0/throttle_controller/__init__.py +0 -5
- throttle_controller-0.3.0/throttle_controller.egg-info/requires.txt +0 -7
- {throttle_controller-0.3.0 → throttle_controller-0.3.1}/.coveragerc +0 -0
- {throttle_controller-0.3.0 → throttle_controller-0.3.1}/.github/renovate.json5 +0 -0
- {throttle_controller-0.3.0 → throttle_controller-0.3.1}/.github/workflows/gitignore-in.yml +0 -0
- {throttle_controller-0.3.0 → throttle_controller-0.3.1}/.github/workflows/happy.yml +0 -0
- {throttle_controller-0.3.0 → throttle_controller-0.3.1}/.github/workflows/spellcheck.yml +0 -0
- {throttle_controller-0.3.0 → throttle_controller-0.3.1}/README.md +0 -0
- {throttle_controller-0.3.0 → throttle_controller-0.3.1}/tests/__init__.py +0 -0
- {throttle_controller-0.3.0 → throttle_controller-0.3.1}/tests/test_simple.py +0 -0
- {throttle_controller-0.3.0 → throttle_controller-0.3.1}/tests/test_utils_interval.py +0 -0
- {throttle_controller-0.3.0 → throttle_controller-0.3.1}/throttle_controller/protocol.py +0 -0
- {throttle_controller-0.3.0 → throttle_controller-0.3.1}/throttle_controller/py.typed +0 -0
- {throttle_controller-0.3.0 → throttle_controller-0.3.1}/throttle_controller/simple.py +0 -0
- {throttle_controller-0.3.0 → throttle_controller-0.3.1}/throttle_controller/utils/__init__.py +0 -0
- {throttle_controller-0.3.0 → throttle_controller-0.3.1}/throttle_controller/utils/interval.py +0 -0
- {throttle_controller-0.3.0 → throttle_controller-0.3.1}/throttle_controller.egg-info/dependency_links.txt +0 -0
|
@@ -22,24 +22,16 @@ jobs:
|
|
|
22
22
|
with:
|
|
23
23
|
python-version: ${{ env.python_version }}
|
|
24
24
|
|
|
25
|
-
- name: Set up
|
|
26
|
-
uses:
|
|
25
|
+
- name: Set up uv
|
|
26
|
+
uses: astral-sh/setup-uv@v5
|
|
27
27
|
|
|
28
|
-
- name:
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
key: ${{ runner.os }}-build-${{ env.python_version }}-${{ hashFiles('**/poetry.lock') }}
|
|
33
|
-
restore-keys: |
|
|
34
|
-
${{ runner.os }}-build-${{ env.python_version }}-${{ hashFiles('**/poetry.lock') }}
|
|
35
|
-
${{ runner.os }}-build-${{ env.python_version }}-
|
|
36
|
-
${{ runner.os }}-
|
|
37
|
-
|
|
38
|
-
- run: poetry install
|
|
28
|
+
- name: Install dependencies
|
|
29
|
+
run: |
|
|
30
|
+
uv python pin ${{ env.python_version }}
|
|
31
|
+
uv sync
|
|
39
32
|
|
|
40
33
|
- name: Build
|
|
41
|
-
|
|
42
|
-
run: poetry run poe build
|
|
34
|
+
run: uv build
|
|
43
35
|
|
|
44
36
|
- name: Publish distribution to Test PyPI
|
|
45
37
|
uses: pypa/gh-action-pypi-publish@release/v1
|
|
@@ -25,28 +25,20 @@ jobs:
|
|
|
25
25
|
with:
|
|
26
26
|
python-version: "${{ matrix.python }}"
|
|
27
27
|
|
|
28
|
-
- name: Set up
|
|
29
|
-
uses:
|
|
30
|
-
|
|
31
|
-
- name: Cache
|
|
32
|
-
uses: actions/cache@v4
|
|
33
|
-
with:
|
|
34
|
-
path: ~/.cache/pypoetry/virtualenvs
|
|
35
|
-
key: ${{ runner.os }}-build-${{ matrix.python }}-${{ hashFiles('**/poetry.lock') }}
|
|
36
|
-
restore-keys: |
|
|
37
|
-
${{ runner.os }}-build-${{ matrix.python }}-${{ hashFiles('**/poetry.lock') }}
|
|
38
|
-
${{ runner.os }}-build-${{ matrix.python }}-
|
|
39
|
-
${{ runner.os }}-
|
|
28
|
+
- name: Set up uv
|
|
29
|
+
uses: astral-sh/setup-uv@v5
|
|
40
30
|
|
|
41
31
|
- name: Install dependencies
|
|
42
|
-
run:
|
|
32
|
+
run: |
|
|
33
|
+
uv python pin ${{ matrix.python }}
|
|
34
|
+
uv sync
|
|
43
35
|
|
|
44
36
|
- name: Lint
|
|
45
|
-
run:
|
|
37
|
+
run: uv run poe check
|
|
46
38
|
|
|
47
39
|
- name: Check Python version
|
|
48
40
|
run: |
|
|
49
|
-
actual_version=$(
|
|
41
|
+
actual_version=$(uv run python --version)
|
|
50
42
|
expected_version="Python ${{ matrix.python }}"
|
|
51
43
|
if [ "$actual_version" == *"$expected_version"* ]; then
|
|
52
44
|
echo "Expected $expected_version, but got $actual_version"
|
|
@@ -54,14 +46,14 @@ jobs:
|
|
|
54
46
|
fi
|
|
55
47
|
|
|
56
48
|
- name: Test
|
|
57
|
-
run:
|
|
49
|
+
run: uv run poe test
|
|
58
50
|
|
|
59
51
|
- name: Coverage
|
|
60
|
-
run:
|
|
52
|
+
run: uv run poe coverage-xml
|
|
61
53
|
|
|
62
54
|
- name: Upload coverage report to Codecov
|
|
63
55
|
if: matrix.python == '3.13'
|
|
64
|
-
uses: codecov/codecov-action@
|
|
56
|
+
uses: codecov/codecov-action@v5
|
|
65
57
|
with:
|
|
66
58
|
token: ${{ secrets.CODECOV_TOKEN }}
|
|
67
59
|
files: ./coverage.xml
|
|
@@ -2,12 +2,10 @@
|
|
|
2
2
|
# Generated by gitignore.in
|
|
3
3
|
# Edit .gitignore.in instead of this file
|
|
4
4
|
# Run `gitignore.in` to build .gitignore
|
|
5
|
-
# #!/usr/bin/env bash
|
|
6
|
-
# # `gibo list' and `gi list'
|
|
7
5
|
# -----------------------------------------------------------------------------
|
|
8
6
|
# gibo dump Linux
|
|
9
7
|
### Generated by gibo (https://github.com/simonwhitaker/gibo)
|
|
10
|
-
### https://raw.github.com/github/gitignore/
|
|
8
|
+
### https://raw.github.com/github/gitignore/4488915eec0b3a45b5c63ead28f286819c0917de/Global/Linux.gitignore
|
|
11
9
|
|
|
12
10
|
*~
|
|
13
11
|
|
|
@@ -25,7 +23,7 @@
|
|
|
25
23
|
# -----------------------------------------------------------------------------
|
|
26
24
|
# gibo dump Windows
|
|
27
25
|
### Generated by gibo (https://github.com/simonwhitaker/gibo)
|
|
28
|
-
### https://raw.github.com/github/gitignore/
|
|
26
|
+
### https://raw.github.com/github/gitignore/4488915eec0b3a45b5c63ead28f286819c0917de/Global/Windows.gitignore
|
|
29
27
|
|
|
30
28
|
# Windows thumbnail cache files
|
|
31
29
|
Thumbs.db
|
|
@@ -54,7 +52,7 @@ $RECYCLE.BIN/
|
|
|
54
52
|
# -----------------------------------------------------------------------------
|
|
55
53
|
# gibo dump macOS
|
|
56
54
|
### Generated by gibo (https://github.com/simonwhitaker/gibo)
|
|
57
|
-
### https://raw.github.com/github/gitignore/
|
|
55
|
+
### https://raw.github.com/github/gitignore/4488915eec0b3a45b5c63ead28f286819c0917de/Global/macOS.gitignore
|
|
58
56
|
|
|
59
57
|
# General
|
|
60
58
|
.DS_Store
|
|
@@ -85,7 +83,7 @@ Temporary Items
|
|
|
85
83
|
# -----------------------------------------------------------------------------
|
|
86
84
|
# gibo dump Python
|
|
87
85
|
### Generated by gibo (https://github.com/simonwhitaker/gibo)
|
|
88
|
-
### https://raw.github.com/github/gitignore/
|
|
86
|
+
### https://raw.github.com/github/gitignore/4488915eec0b3a45b5c63ead28f286819c0917de/Python.gitignore
|
|
89
87
|
|
|
90
88
|
# Byte-compiled / optimized / DLL files
|
|
91
89
|
__pycache__/
|
|
@@ -195,10 +193,8 @@ ipython_config.py
|
|
|
195
193
|
#pdm.lock
|
|
196
194
|
# pdm stores project-wide configurations in .pdm.toml, but it is recommended to not include it
|
|
197
195
|
# in version control.
|
|
198
|
-
# https://pdm.fming.dev
|
|
196
|
+
# https://pdm.fming.dev/#use-with-ide
|
|
199
197
|
.pdm.toml
|
|
200
|
-
.pdm-python
|
|
201
|
-
.pdm-build/
|
|
202
198
|
|
|
203
199
|
# PEP 582; used by e.g. github.com/David-OConnor/pyflow and github.com/pdm-project/pdm
|
|
204
200
|
__pypackages__/
|
{throttle_controller-0.3.0/throttle_controller.egg-info → throttle_controller-0.3.1}/PKG-INFO
RENAMED
|
@@ -1,11 +1,21 @@
|
|
|
1
|
-
Metadata-Version: 2.
|
|
1
|
+
Metadata-Version: 2.2
|
|
2
2
|
Name: throttle-controller
|
|
3
|
-
Version: 0.3.
|
|
3
|
+
Version: 0.3.1
|
|
4
4
|
Summary: A simple throttling controller
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
5
|
+
Author-email: Yui KITSU <kitsuyui+github@kitsuyui.com>
|
|
6
|
+
License: Copyright 2022-2025 Kitsu Yui
|
|
7
|
+
|
|
8
|
+
Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met:
|
|
9
|
+
|
|
10
|
+
1. Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer.
|
|
11
|
+
|
|
12
|
+
2. Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution.
|
|
13
|
+
|
|
14
|
+
3. Neither the name of the copyright holder nor the names of its contributors may be used to endorse or promote products derived from this software without specific prior written permission.
|
|
15
|
+
|
|
16
|
+
THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
|
17
|
+
|
|
18
|
+
Project-URL: Homepage, https://github.com/kitsuyui/python-throttle-controller
|
|
9
19
|
Classifier: Development Status :: 3 - Alpha
|
|
10
20
|
Classifier: License :: OSI Approved :: BSD License
|
|
11
21
|
Classifier: Programming Language :: Python :: 3.9
|
|
@@ -17,12 +27,7 @@ Classifier: Intended Audience :: Developers
|
|
|
17
27
|
Requires-Python: >=3.9
|
|
18
28
|
Description-Content-Type: text/markdown
|
|
19
29
|
License-File: LICENSE
|
|
20
|
-
|
|
21
|
-
Requires-Dist: pytest; extra == "dev"
|
|
22
|
-
Requires-Dist: black; extra == "dev"
|
|
23
|
-
Requires-Dist: isort; extra == "dev"
|
|
24
|
-
Requires-Dist: flake8; extra == "dev"
|
|
25
|
-
Requires-Dist: mypy; extra == "dev"
|
|
30
|
+
Requires-Dist: typing-extensions
|
|
26
31
|
|
|
27
32
|
# throttle-controller
|
|
28
33
|
|
|
@@ -0,0 +1,67 @@
|
|
|
1
|
+
[project]
|
|
2
|
+
name = "throttle-controller"
|
|
3
|
+
dynamic = ["version"]
|
|
4
|
+
requires-python = ">=3.9"
|
|
5
|
+
dependencies = ["typing-extensions"]
|
|
6
|
+
description = "A simple throttling controller"
|
|
7
|
+
readme = {file = "README.md", content-type = "text/markdown"}
|
|
8
|
+
license = { file = "LICENSE" }
|
|
9
|
+
authors = [
|
|
10
|
+
{name = "Yui KITSU", email = "kitsuyui+github@kitsuyui.com"}
|
|
11
|
+
]
|
|
12
|
+
classifiers = [
|
|
13
|
+
"Development Status :: 3 - Alpha",
|
|
14
|
+
"License :: OSI Approved :: BSD License",
|
|
15
|
+
"Programming Language :: Python :: 3.9",
|
|
16
|
+
"Programming Language :: Python :: 3.10",
|
|
17
|
+
"Programming Language :: Python :: 3.11",
|
|
18
|
+
"Programming Language :: Python :: 3.12",
|
|
19
|
+
"Programming Language :: Python :: 3.13",
|
|
20
|
+
"Intended Audience :: Developers",
|
|
21
|
+
]
|
|
22
|
+
|
|
23
|
+
[project.urls]
|
|
24
|
+
Homepage = "https://github.com/kitsuyui/python-throttle-controller"
|
|
25
|
+
|
|
26
|
+
[tool.setuptools]
|
|
27
|
+
package-data = { "throttle_controller" = ["py.typed"], "*" = ["README.md, LICENSE"] }
|
|
28
|
+
package-dir = { "throttle_controller" = "throttle_controller" }
|
|
29
|
+
|
|
30
|
+
[tool.uv]
|
|
31
|
+
dev-dependencies = [
|
|
32
|
+
"pytest",
|
|
33
|
+
"pytest-cov",
|
|
34
|
+
"poethepoet",
|
|
35
|
+
"setuptools-scm",
|
|
36
|
+
"ruff",
|
|
37
|
+
"mypy",
|
|
38
|
+
]
|
|
39
|
+
|
|
40
|
+
[build-system]
|
|
41
|
+
requires = [
|
|
42
|
+
"setuptools", "setuptools_scm"
|
|
43
|
+
]
|
|
44
|
+
build-backend = "setuptools.build_meta"
|
|
45
|
+
|
|
46
|
+
[tool.setuptools_scm]
|
|
47
|
+
write_to = "throttle_controller/_version.py"
|
|
48
|
+
version_scheme = "only-version"
|
|
49
|
+
local_scheme = "no-local-version"
|
|
50
|
+
|
|
51
|
+
[tool.poe.tasks]
|
|
52
|
+
test = "pytest"
|
|
53
|
+
coverage-xml = "pytest --cov=throttle_controller --doctest-modules --cov-report=xml"
|
|
54
|
+
format = "ruff format throttle_controller"
|
|
55
|
+
check = [
|
|
56
|
+
{ cmd = "ruff check throttle_controller" },
|
|
57
|
+
{ cmd = "mypy throttle_controller tests" },
|
|
58
|
+
]
|
|
59
|
+
build = [
|
|
60
|
+
{ cmd = "python -m build"}
|
|
61
|
+
]
|
|
62
|
+
[tool.mypy]
|
|
63
|
+
strict = true
|
|
64
|
+
ignore_missing_imports = false
|
|
65
|
+
|
|
66
|
+
[tool.ruff]
|
|
67
|
+
line-length = 79
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
from .protocol import ThrottleController
|
|
2
|
+
from .simple import SimpleThrottleController
|
|
3
|
+
|
|
4
|
+
# https://packaging-guide.openastronomy.org/en/latest/advanced/versioning.html
|
|
5
|
+
from ._version import __version__
|
|
6
|
+
|
|
7
|
+
__all__ = ["ThrottleController", "SimpleThrottleController", "__version__"]
|
{throttle_controller-0.3.0 → throttle_controller-0.3.1/throttle_controller.egg-info}/PKG-INFO
RENAMED
|
@@ -1,11 +1,21 @@
|
|
|
1
|
-
Metadata-Version: 2.
|
|
1
|
+
Metadata-Version: 2.2
|
|
2
2
|
Name: throttle-controller
|
|
3
|
-
Version: 0.3.
|
|
3
|
+
Version: 0.3.1
|
|
4
4
|
Summary: A simple throttling controller
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
5
|
+
Author-email: Yui KITSU <kitsuyui+github@kitsuyui.com>
|
|
6
|
+
License: Copyright 2022-2025 Kitsu Yui
|
|
7
|
+
|
|
8
|
+
Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met:
|
|
9
|
+
|
|
10
|
+
1. Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer.
|
|
11
|
+
|
|
12
|
+
2. Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution.
|
|
13
|
+
|
|
14
|
+
3. Neither the name of the copyright holder nor the names of its contributors may be used to endorse or promote products derived from this software without specific prior written permission.
|
|
15
|
+
|
|
16
|
+
THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
|
17
|
+
|
|
18
|
+
Project-URL: Homepage, https://github.com/kitsuyui/python-throttle-controller
|
|
9
19
|
Classifier: Development Status :: 3 - Alpha
|
|
10
20
|
Classifier: License :: OSI Approved :: BSD License
|
|
11
21
|
Classifier: Programming Language :: Python :: 3.9
|
|
@@ -17,12 +27,7 @@ Classifier: Intended Audience :: Developers
|
|
|
17
27
|
Requires-Python: >=3.9
|
|
18
28
|
Description-Content-Type: text/markdown
|
|
19
29
|
License-File: LICENSE
|
|
20
|
-
|
|
21
|
-
Requires-Dist: pytest; extra == "dev"
|
|
22
|
-
Requires-Dist: black; extra == "dev"
|
|
23
|
-
Requires-Dist: isort; extra == "dev"
|
|
24
|
-
Requires-Dist: flake8; extra == "dev"
|
|
25
|
-
Requires-Dist: mypy; extra == "dev"
|
|
30
|
+
Requires-Dist: typing-extensions
|
|
26
31
|
|
|
27
32
|
# throttle-controller
|
|
28
33
|
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
typing-extensions
|