spoc 0.2.0__tar.gz → 0.2.3__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.
- spoc-0.2.3/PKG-INFO +76 -0
- spoc-0.2.3/README.md +51 -0
- spoc-0.2.3/pyproject.toml +87 -0
- spoc-0.2.3/src/spoc/__about__.py +5 -0
- {spoc-0.2.0 → spoc-0.2.3}/src/spoc/__init__.py +12 -8
- {spoc-0.2.0 → spoc-0.2.3}/src/spoc/installer.py +1 -1
- {spoc-0.2.0 → spoc-0.2.3}/src/spoc/workers.py +47 -32
- spoc-0.2.0/.github/workflows/release.yml +0 -43
- spoc-0.2.0/.gitignore +0 -132
- spoc-0.2.0/.prettierignore +0 -1
- spoc-0.2.0/.pylintrc +0 -638
- spoc-0.2.0/MANIFEST.in +0 -5
- spoc-0.2.0/PKG-INFO +0 -19
- spoc-0.2.0/README-DEVS.md +0 -31
- spoc-0.2.0/README.md +0 -7
- spoc-0.2.0/docs/.gitignore +0 -1
- spoc-0.2.0/docs/custom_theme/css/extra.css +0 -57
- spoc-0.2.0/docs/custom_theme/main.html +0 -14
- spoc-0.2.0/docs/docs/api/framework.md +0 -31
- spoc-0.2.0/docs/docs/api/utils.md +0 -19
- spoc-0.2.0/docs/docs/api/workers.md +0 -19
- spoc-0.2.0/docs/docs/assets/images/logo.png +0 -0
- spoc-0.2.0/docs/docs/assets/images/title.png +0 -0
- spoc-0.2.0/docs/docs/constants.md +0 -91
- spoc-0.2.0/docs/docs/getting-started/component.md +0 -53
- spoc-0.2.0/docs/docs/getting-started/framework.md +0 -65
- spoc-0.2.0/docs/docs/getting-started/overview.md +0 -49
- spoc-0.2.0/docs/docs/getting-started/plugins.md +0 -21
- spoc-0.2.0/docs/docs/getting-started/project.md +0 -223
- spoc-0.2.0/docs/docs/getting-started/testing.md +0 -21
- spoc-0.2.0/docs/docs/index.md +0 -156
- spoc-0.2.0/docs/macros.py +0 -50
- spoc-0.2.0/docs/mkdocs.yml +0 -145
- spoc-0.2.0/pyproject.toml +0 -46
- spoc-0.2.0/scripts/docs.py +0 -84
- spoc-0.2.0/scripts/linter.py +0 -125
- spoc-0.2.0/scripts/tests.py +0 -59
- spoc-0.2.0/tests/__init__.py +0 -0
- spoc-0.2.0/tests/apps/demo/__init__.py +0 -0
- spoc-0.2.0/tests/apps/demo/commands.py +0 -16
- spoc-0.2.0/tests/apps/demo/middleware.py +0 -9
- spoc-0.2.0/tests/apps/demo/views.py +0 -6
- spoc-0.2.0/tests/config/__init__.py +0 -4
- spoc-0.2.0/tests/config/settings.py +0 -17
- spoc-0.2.0/tests/config/spoc.toml +0 -15
- spoc-0.2.0/tests/framework/__init__.py +0 -12
- spoc-0.2.0/tests/framework/components.py +0 -39
- spoc-0.2.0/tests/framework/framework.py +0 -65
- spoc-0.2.0/tests/main.py +0 -92
- spoc-0.2.0/uv.lock +0 -857
- {spoc-0.2.0 → spoc-0.2.3}/LICENSE +0 -0
- {spoc-0.2.0 → spoc-0.2.3}/src/spoc/components.py +0 -0
- {spoc-0.2.0 → spoc-0.2.3}/src/spoc/framework.py +0 -0
- {spoc-0.2.0 → spoc-0.2.3}/src/spoc/importer/__init__.py +0 -0
- {spoc-0.2.0 → spoc-0.2.3}/src/spoc/importer/base.py +0 -0
- {spoc-0.2.0 → spoc-0.2.3}/src/spoc/importer/frozendict.py +0 -0
- {spoc-0.2.0 → spoc-0.2.3}/src/spoc/importer/get_spoc.py +0 -0
- {spoc-0.2.0 → spoc-0.2.3}/src/spoc/importer/tools.py +0 -0
- {spoc-0.2.0 → spoc-0.2.3}/src/spoc/importer/types.py +0 -0
- {spoc-0.2.0 → spoc-0.2.3}/src/spoc/inject.py +0 -0
- {spoc-0.2.0 → spoc-0.2.3}/src/spoc/py.typed +0 -0
- {spoc-0.2.0 → spoc-0.2.3}/src/spoc/singleton.py +0 -0
- {spoc-0.2.0 → spoc-0.2.3}/src/spoc/toml_core.py +0 -0
spoc-0.2.3/PKG-INFO
ADDED
|
@@ -0,0 +1,76 @@
|
|
|
1
|
+
Metadata-Version: 2.1
|
|
2
|
+
Name: spoc
|
|
3
|
+
Version: 0.2.3
|
|
4
|
+
Summary: Elastic Framework Builder
|
|
5
|
+
Keywords: modular design,python framework,extensible framework,plugin management
|
|
6
|
+
Author-Email: hlop3z <23062270+hlop3z@users.noreply.github.com>
|
|
7
|
+
License: MIT
|
|
8
|
+
Classifier: Development Status :: 4 - Beta
|
|
9
|
+
Classifier: Intended Audience :: Developers
|
|
10
|
+
Classifier: Intended Audience :: Information Technology
|
|
11
|
+
Classifier: License :: OSI Approved :: MIT License
|
|
12
|
+
Classifier: Operating System :: OS Independent
|
|
13
|
+
Classifier: Programming Language :: Python :: 3.12
|
|
14
|
+
Classifier: Topic :: Internet
|
|
15
|
+
Classifier: Topic :: Software Development :: Libraries :: Application Frameworks
|
|
16
|
+
Classifier: Topic :: Software Development :: Libraries :: Python Modules
|
|
17
|
+
Classifier: Topic :: Software Development :: Libraries
|
|
18
|
+
Classifier: Topic :: Software Development
|
|
19
|
+
Classifier: Typing :: Typed
|
|
20
|
+
Project-URL: Homepage, https://github.com/hlop3z/spoc/
|
|
21
|
+
Project-URL: Documentation, https://hlop3z.github.io/spoc/
|
|
22
|
+
Project-URL: Repository, https://github.com/hlop3z/spoc/
|
|
23
|
+
Requires-Python: >=3.12
|
|
24
|
+
Description-Content-Type: text/markdown
|
|
25
|
+
|
|
26
|
+
# Welcome to **SPOC**
|
|
27
|
+
|
|
28
|
+
<img src="https://raw.githubusercontent.com/hlop3z/spoc/main/docs/docs/assets/images/title.png" alt="title-image" width="100%" />
|
|
29
|
+
|
|
30
|
+
---
|
|
31
|
+
|
|
32
|
+

|
|
33
|
+

|
|
34
|
+

|
|
35
|
+

|
|
36
|
+

|
|
37
|
+
|
|
38
|
+
---
|
|
39
|
+
|
|
40
|
+
**SPOC** is a foundational framework designed to create dynamic and adaptable **`frameworks`**. It involves defining a schema for your **project**(s) and building upon that schema to create a flexible and powerful Application.
|
|
41
|
+
|
|
42
|
+
---
|
|
43
|
+
|
|
44
|
+
## Links
|
|
45
|
+
|
|
46
|
+
- [PyPi](https://pypi.org/project/spoc)
|
|
47
|
+
- [Github](https://github.com/hlop3z/spoc)
|
|
48
|
+
- [Read the Documents](https://hlop3z.github.io/spoc/)
|
|
49
|
+
|
|
50
|
+
---
|
|
51
|
+
|
|
52
|
+
## Example
|
|
53
|
+
|
|
54
|
+
```python
|
|
55
|
+
from typing import Any
|
|
56
|
+
import spoc
|
|
57
|
+
|
|
58
|
+
MODULES = ["models", "views"]
|
|
59
|
+
|
|
60
|
+
class MyFramework(spoc.Base):
|
|
61
|
+
components: Any
|
|
62
|
+
plugins: Any
|
|
63
|
+
|
|
64
|
+
def init(self):
|
|
65
|
+
"""__init__ Replacement"""
|
|
66
|
+
app = spoc.init(MODULES)
|
|
67
|
+
|
|
68
|
+
# Assign components and plugins from the initialized app
|
|
69
|
+
self.components = app.components
|
|
70
|
+
self.plugins = app.plugins
|
|
71
|
+
|
|
72
|
+
@staticmethod
|
|
73
|
+
def keys():
|
|
74
|
+
"""Define a list of keys relevant to the framework"""
|
|
75
|
+
return ("components", "plugins")
|
|
76
|
+
```
|
spoc-0.2.3/README.md
ADDED
|
@@ -0,0 +1,51 @@
|
|
|
1
|
+
# Welcome to **SPOC**
|
|
2
|
+
|
|
3
|
+
<img src="https://raw.githubusercontent.com/hlop3z/spoc/main/docs/docs/assets/images/title.png" alt="title-image" width="100%" />
|
|
4
|
+
|
|
5
|
+
---
|
|
6
|
+
|
|
7
|
+

|
|
8
|
+

|
|
9
|
+

|
|
10
|
+

|
|
11
|
+

|
|
12
|
+
|
|
13
|
+
---
|
|
14
|
+
|
|
15
|
+
**SPOC** is a foundational framework designed to create dynamic and adaptable **`frameworks`**. It involves defining a schema for your **project**(s) and building upon that schema to create a flexible and powerful Application.
|
|
16
|
+
|
|
17
|
+
---
|
|
18
|
+
|
|
19
|
+
## Links
|
|
20
|
+
|
|
21
|
+
- [PyPi](https://pypi.org/project/spoc)
|
|
22
|
+
- [Github](https://github.com/hlop3z/spoc)
|
|
23
|
+
- [Read the Documents](https://hlop3z.github.io/spoc/)
|
|
24
|
+
|
|
25
|
+
---
|
|
26
|
+
|
|
27
|
+
## Example
|
|
28
|
+
|
|
29
|
+
```python
|
|
30
|
+
from typing import Any
|
|
31
|
+
import spoc
|
|
32
|
+
|
|
33
|
+
MODULES = ["models", "views"]
|
|
34
|
+
|
|
35
|
+
class MyFramework(spoc.Base):
|
|
36
|
+
components: Any
|
|
37
|
+
plugins: Any
|
|
38
|
+
|
|
39
|
+
def init(self):
|
|
40
|
+
"""__init__ Replacement"""
|
|
41
|
+
app = spoc.init(MODULES)
|
|
42
|
+
|
|
43
|
+
# Assign components and plugins from the initialized app
|
|
44
|
+
self.components = app.components
|
|
45
|
+
self.plugins = app.plugins
|
|
46
|
+
|
|
47
|
+
@staticmethod
|
|
48
|
+
def keys():
|
|
49
|
+
"""Define a list of keys relevant to the framework"""
|
|
50
|
+
return ("components", "plugins")
|
|
51
|
+
```
|
|
@@ -0,0 +1,87 @@
|
|
|
1
|
+
[build-system]
|
|
2
|
+
requires = [
|
|
3
|
+
"pdm-backend",
|
|
4
|
+
]
|
|
5
|
+
build-backend = "pdm.backend"
|
|
6
|
+
|
|
7
|
+
[project]
|
|
8
|
+
name = "spoc"
|
|
9
|
+
dynamic = []
|
|
10
|
+
description = "Elastic Framework Builder"
|
|
11
|
+
requires-python = ">=3.12"
|
|
12
|
+
readme = "README.md"
|
|
13
|
+
authors = [
|
|
14
|
+
{ name = "hlop3z", email = "23062270+hlop3z@users.noreply.github.com" },
|
|
15
|
+
]
|
|
16
|
+
classifiers = [
|
|
17
|
+
"Development Status :: 4 - Beta",
|
|
18
|
+
"Intended Audience :: Developers",
|
|
19
|
+
"Intended Audience :: Information Technology",
|
|
20
|
+
"License :: OSI Approved :: MIT License",
|
|
21
|
+
"Operating System :: OS Independent",
|
|
22
|
+
"Programming Language :: Python :: 3.12",
|
|
23
|
+
"Topic :: Internet",
|
|
24
|
+
"Topic :: Software Development :: Libraries :: Application Frameworks",
|
|
25
|
+
"Topic :: Software Development :: Libraries :: Python Modules",
|
|
26
|
+
"Topic :: Software Development :: Libraries",
|
|
27
|
+
"Topic :: Software Development",
|
|
28
|
+
"Typing :: Typed",
|
|
29
|
+
]
|
|
30
|
+
keywords = [
|
|
31
|
+
"modular design",
|
|
32
|
+
"python framework",
|
|
33
|
+
"extensible framework",
|
|
34
|
+
"plugin management",
|
|
35
|
+
]
|
|
36
|
+
dependencies = []
|
|
37
|
+
version = "0.2.3"
|
|
38
|
+
|
|
39
|
+
[project.license]
|
|
40
|
+
text = "MIT"
|
|
41
|
+
|
|
42
|
+
[project.urls]
|
|
43
|
+
Homepage = "https://github.com/hlop3z/spoc/"
|
|
44
|
+
Documentation = "https://hlop3z.github.io/spoc/"
|
|
45
|
+
Repository = "https://github.com/hlop3z/spoc/"
|
|
46
|
+
|
|
47
|
+
[project.scripts]
|
|
48
|
+
spoc-init = "spoc:start_project"
|
|
49
|
+
|
|
50
|
+
[tool.pdm]
|
|
51
|
+
distribution = true
|
|
52
|
+
|
|
53
|
+
[tool.pdm.version]
|
|
54
|
+
source = "file"
|
|
55
|
+
path = "src/spoc/__about__.py"
|
|
56
|
+
|
|
57
|
+
[tool.pdm.build]
|
|
58
|
+
excludes = [
|
|
59
|
+
"tests",
|
|
60
|
+
]
|
|
61
|
+
|
|
62
|
+
[tool.pdm.dev-dependencies]
|
|
63
|
+
lint = [
|
|
64
|
+
"pyright>=1.1.377",
|
|
65
|
+
"mypy>=1.11.1",
|
|
66
|
+
"isort>=5.13.2",
|
|
67
|
+
"black>=24.8.0",
|
|
68
|
+
"pylint>=3.2.6",
|
|
69
|
+
"ruff>=0.6.2",
|
|
70
|
+
"bandit>=1.7.9",
|
|
71
|
+
"watchdog>=4.0.2",
|
|
72
|
+
"ssort>=0.13.0",
|
|
73
|
+
]
|
|
74
|
+
docs = [
|
|
75
|
+
"mkdocs>=1.6.0",
|
|
76
|
+
"mkdocs-material>=9.5.32",
|
|
77
|
+
"mkdocs-macros-plugin>=1.0.5",
|
|
78
|
+
"mkdocstrings[python]>=0.25.2",
|
|
79
|
+
"termynal>=0.12.1",
|
|
80
|
+
]
|
|
81
|
+
test = [
|
|
82
|
+
"pytest>=7.1.2",
|
|
83
|
+
"pytest-json-report>=1.5.0",
|
|
84
|
+
]
|
|
85
|
+
|
|
86
|
+
[tool.pdm.scripts]
|
|
87
|
+
test = "pytest -rA tests/test_main.py"
|
|
@@ -2,11 +2,18 @@
|
|
|
2
2
|
"""
|
|
3
3
|
# Elastic Frameworks
|
|
4
4
|
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
5
|
+
SPOC is a foundational framework designed to create dynamic and adaptable frameworks.
|
|
6
|
+
It involves defining a schema for your project(s) and
|
|
7
|
+
building upon that schema to create a flexible and powerful Application.
|
|
8
8
|
|
|
9
|
-
|
|
9
|
+
This module provides an example of how to create a framework by extending the `spoc.Base` class.
|
|
10
|
+
It demonstrates the initialization process using `spoc.init` with a list of modules,
|
|
11
|
+
and shows how to access and manage various components and plugins within the framework.
|
|
12
|
+
|
|
13
|
+
## Example
|
|
14
|
+
|
|
15
|
+
To create a custom framework,
|
|
16
|
+
extend the `spoc.Base` class and initialize it using `spoc.init` with a list of desired modules:
|
|
10
17
|
|
|
11
18
|
```python
|
|
12
19
|
from typing import Any
|
|
@@ -29,7 +36,7 @@ class MyFramework(spoc.Base):
|
|
|
29
36
|
@staticmethod
|
|
30
37
|
def keys():
|
|
31
38
|
# Define a list of keys relevant to the framework
|
|
32
|
-
return ("components", "plugins"
|
|
39
|
+
return ("components", "plugins")
|
|
33
40
|
```
|
|
34
41
|
"""
|
|
35
42
|
|
|
@@ -58,9 +65,6 @@ try:
|
|
|
58
65
|
except ImportError:
|
|
59
66
|
pass
|
|
60
67
|
|
|
61
|
-
# Version
|
|
62
|
-
__version__ = "0.2.0"
|
|
63
|
-
|
|
64
68
|
__all__ = (
|
|
65
69
|
# Globals
|
|
66
70
|
"base_dir",
|
|
@@ -70,44 +70,45 @@ class AbstractWorker(ABC):
|
|
|
70
70
|
|
|
71
71
|
def run(self) -> None:
|
|
72
72
|
"""Run Worker"""
|
|
73
|
+
self.before()
|
|
73
74
|
if inspect.iscoroutinefunction(self.server):
|
|
74
75
|
# Async Server
|
|
75
|
-
|
|
76
|
-
self.before_async()
|
|
77
|
-
self.agent.run(self.run_async())
|
|
78
|
-
except KeyboardInterrupt:
|
|
79
|
-
pass
|
|
80
|
-
except asyncio.CancelledError:
|
|
81
|
-
pass
|
|
76
|
+
self.agent.run(self.run_async())
|
|
82
77
|
else:
|
|
83
78
|
# Sync Server
|
|
84
|
-
|
|
85
|
-
self.before_sync()
|
|
86
|
-
self.run_sync()
|
|
87
|
-
except KeyboardInterrupt:
|
|
88
|
-
pass
|
|
79
|
+
self.run_sync()
|
|
89
80
|
|
|
90
|
-
def
|
|
91
|
-
"""Setup before running
|
|
92
|
-
|
|
93
|
-
def before_sync(self) -> None:
|
|
94
|
-
"""Setup before running synchronous server."""
|
|
81
|
+
def before(self) -> None:
|
|
82
|
+
"""Setup before running server."""
|
|
95
83
|
|
|
96
84
|
def run_sync(self) -> None:
|
|
97
85
|
"""Run Synchronous Worker"""
|
|
98
86
|
self.on_event("startup")
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
87
|
+
job = threading.Thread(target=self.server)
|
|
88
|
+
job.daemon = True
|
|
89
|
+
job.start()
|
|
90
|
+
# Dummy Loop
|
|
91
|
+
while self.active:
|
|
92
|
+
try:
|
|
93
|
+
time.sleep(1)
|
|
94
|
+
except KeyboardInterrupt:
|
|
95
|
+
pass
|
|
96
|
+
# After Stop
|
|
97
|
+
self.on_event("shutdown")
|
|
103
98
|
|
|
104
99
|
async def run_async(self) -> None:
|
|
105
100
|
"""Run Asynchronous Worker"""
|
|
101
|
+
loop = asyncio.get_running_loop()
|
|
106
102
|
await self.on_event("startup")
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
103
|
+
loop.create_task(self.server())
|
|
104
|
+
# Dummy Loop
|
|
105
|
+
while self.active:
|
|
106
|
+
try:
|
|
107
|
+
await asyncio.sleep(1)
|
|
108
|
+
except (KeyboardInterrupt, asyncio.CancelledError):
|
|
109
|
+
pass
|
|
110
|
+
# After Stop
|
|
111
|
+
await self.on_event("shutdown")
|
|
111
112
|
|
|
112
113
|
def stop(self):
|
|
113
114
|
"""Stop Worker"""
|
|
@@ -134,8 +135,8 @@ class BaseProcess(AbstractWorker, multiprocessing.Process):
|
|
|
134
135
|
class AsyncProcess(spoc.BaseProcess):
|
|
135
136
|
agent: Any = asyncio # Example: `uvloop`
|
|
136
137
|
|
|
137
|
-
def
|
|
138
|
-
... #
|
|
138
|
+
def before(self) -> None:
|
|
139
|
+
... # Set uvloop.EventLoopPolicy()
|
|
139
140
|
|
|
140
141
|
async def on_event(self, event_type: str):
|
|
141
142
|
...
|
|
@@ -174,8 +175,8 @@ class BaseThread(AbstractWorker, threading.Thread):
|
|
|
174
175
|
class AsyncThread(spoc.BaseThread):
|
|
175
176
|
agent: Any = asyncio # Example: `uvloop`
|
|
176
177
|
|
|
177
|
-
def
|
|
178
|
-
... #
|
|
178
|
+
def before(self) -> None:
|
|
179
|
+
... # Set uvloop.EventLoopPolicy()
|
|
179
180
|
|
|
180
181
|
async def on_event(self, event_type: str):
|
|
181
182
|
...
|
|
@@ -256,8 +257,20 @@ class BaseServer(ABC):
|
|
|
256
257
|
"""
|
|
257
258
|
cls.workers.extend(workers)
|
|
258
259
|
|
|
260
|
+
@staticmethod
|
|
261
|
+
def _disable_exit_signal() -> None:
|
|
262
|
+
"""Wait for cleanup to complete."""
|
|
263
|
+
|
|
264
|
+
def handler(*_):
|
|
265
|
+
"""Ctrl+C pressed."""
|
|
266
|
+
|
|
267
|
+
# Temporarily ignore Ctrl+C
|
|
268
|
+
signal.signal(signal.SIGINT, handler)
|
|
269
|
+
|
|
259
270
|
@classmethod
|
|
260
|
-
def start(
|
|
271
|
+
def start(
|
|
272
|
+
cls, infinite_loop: bool = True, timeout: int = 5, forced_delay: int = 1
|
|
273
|
+
) -> None:
|
|
261
274
|
"""
|
|
262
275
|
Start all added workers and optionally keep a loop running until interrupted.
|
|
263
276
|
"""
|
|
@@ -292,13 +305,15 @@ class BaseServer(ABC):
|
|
|
292
305
|
while True:
|
|
293
306
|
time.sleep(1)
|
|
294
307
|
except KeyboardInterrupt:
|
|
308
|
+
# Disable (Ctrl + C)
|
|
309
|
+
cls._disable_exit_signal()
|
|
295
310
|
# Before Shutdown
|
|
296
311
|
cls.on_event("before_shutdown")
|
|
297
|
-
cls.stop(force_stop=True, forced_delay=
|
|
312
|
+
cls.stop(force_stop=True, timeout=timeout, forced_delay=forced_delay)
|
|
298
313
|
|
|
299
314
|
@classmethod
|
|
300
315
|
def stop(
|
|
301
|
-
cls, timeout: int = 5, force_stop: bool = False, forced_delay: int =
|
|
316
|
+
cls, timeout: int = 5, force_stop: bool = False, forced_delay: int = 1
|
|
302
317
|
) -> None:
|
|
303
318
|
"""
|
|
304
319
|
Stop all running workers.
|
|
@@ -1,43 +0,0 @@
|
|
|
1
|
-
name: Upload Release to PyPI
|
|
2
|
-
|
|
3
|
-
# on: workflow_dispatch
|
|
4
|
-
on:
|
|
5
|
-
workflow_dispatch: # Manually triggered
|
|
6
|
-
push:
|
|
7
|
-
tags:
|
|
8
|
-
- v* # Automatically triggered on tags that match the pattern
|
|
9
|
-
|
|
10
|
-
permissions:
|
|
11
|
-
contents: read
|
|
12
|
-
|
|
13
|
-
jobs:
|
|
14
|
-
pypi-publish:
|
|
15
|
-
name: Publish to PyPI
|
|
16
|
-
runs-on: ubuntu-latest
|
|
17
|
-
|
|
18
|
-
environment:
|
|
19
|
-
name: pypi
|
|
20
|
-
url: https://pypi.org/p/spoc
|
|
21
|
-
|
|
22
|
-
permissions:
|
|
23
|
-
contents: read # Required for accessing repository contents
|
|
24
|
-
id-token: write # Required for GitHub Actions OIDC authentication
|
|
25
|
-
|
|
26
|
-
steps:
|
|
27
|
-
- name: Checkout Repository
|
|
28
|
-
uses: actions/checkout@v4
|
|
29
|
-
|
|
30
|
-
- name: Set up Python Environment
|
|
31
|
-
uses: actions/setup-python@v5
|
|
32
|
-
with:
|
|
33
|
-
python-version-file: "pyproject.toml"
|
|
34
|
-
|
|
35
|
-
- name: Install UV
|
|
36
|
-
run: curl -LsSf https://astral.sh/uv/0.3.5/install.sh | sh
|
|
37
|
-
|
|
38
|
-
- name: Build Python Package
|
|
39
|
-
run: uvx --from build pyproject-build --installer uv
|
|
40
|
-
|
|
41
|
-
- name: Publish to PyPI
|
|
42
|
-
uses: pypa/gh-action-pypi-publish@release/v1
|
|
43
|
-
# run: uvx twine upload dist/*
|
spoc-0.2.0/.gitignore
DELETED
|
@@ -1,132 +0,0 @@
|
|
|
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
|
-
pip-wheel-metadata/
|
|
24
|
-
share/python-wheels/
|
|
25
|
-
*.egg-info/
|
|
26
|
-
.installed.cfg
|
|
27
|
-
*.egg
|
|
28
|
-
MANIFEST
|
|
29
|
-
|
|
30
|
-
# PyInstaller
|
|
31
|
-
# Usually these files are written by a python script from a template
|
|
32
|
-
# before PyInstaller builds the exe, so as to inject date/other infos into it.
|
|
33
|
-
*.manifest
|
|
34
|
-
*.spec
|
|
35
|
-
|
|
36
|
-
# Installer logs
|
|
37
|
-
pip-log.txt
|
|
38
|
-
pip-delete-this-directory.txt
|
|
39
|
-
|
|
40
|
-
# Unit test / coverage reports
|
|
41
|
-
htmlcov/
|
|
42
|
-
.tox/
|
|
43
|
-
.nox/
|
|
44
|
-
.coverage
|
|
45
|
-
.coverage.*
|
|
46
|
-
.cache
|
|
47
|
-
nosetests.xml
|
|
48
|
-
coverage.xml
|
|
49
|
-
*.cover
|
|
50
|
-
*.py,cover
|
|
51
|
-
.hypothesis/
|
|
52
|
-
.pytest_cache/
|
|
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
|
-
target/
|
|
76
|
-
|
|
77
|
-
# Jupyter Notebook
|
|
78
|
-
.ipynb_checkpoints
|
|
79
|
-
|
|
80
|
-
# IPython
|
|
81
|
-
profile_default/
|
|
82
|
-
ipython_config.py
|
|
83
|
-
|
|
84
|
-
# pyenv
|
|
85
|
-
.python-version
|
|
86
|
-
|
|
87
|
-
# pipenv
|
|
88
|
-
# According to pypa/pipenv#598, it is recommended to include Pipfile.lock in version control.
|
|
89
|
-
# However, in case of collaboration, if having platform-specific dependencies or dependencies
|
|
90
|
-
# having no cross-platform support, pipenv may install dependencies that don't work, or not
|
|
91
|
-
# install all needed dependencies.
|
|
92
|
-
#Pipfile.lock
|
|
93
|
-
|
|
94
|
-
# PEP 582; used by e.g. github.com/David-OConnor/pyflow
|
|
95
|
-
__pypackages__/
|
|
96
|
-
|
|
97
|
-
# Celery stuff
|
|
98
|
-
celerybeat-schedule
|
|
99
|
-
celerybeat.pid
|
|
100
|
-
|
|
101
|
-
# SageMath parsed files
|
|
102
|
-
*.sage.py
|
|
103
|
-
|
|
104
|
-
# Environments
|
|
105
|
-
.env
|
|
106
|
-
.venv
|
|
107
|
-
env/
|
|
108
|
-
venv/
|
|
109
|
-
ENV/
|
|
110
|
-
env.bak/
|
|
111
|
-
venv.bak/
|
|
112
|
-
|
|
113
|
-
# Spyder project settings
|
|
114
|
-
.spyderproject
|
|
115
|
-
.spyproject
|
|
116
|
-
|
|
117
|
-
# Rope project settings
|
|
118
|
-
.ropeproject
|
|
119
|
-
|
|
120
|
-
# mkdocs documentation
|
|
121
|
-
/site
|
|
122
|
-
|
|
123
|
-
# mypy
|
|
124
|
-
.mypy_cache/
|
|
125
|
-
.dmypy.json
|
|
126
|
-
dmypy.json
|
|
127
|
-
|
|
128
|
-
# Pyre type checker
|
|
129
|
-
.pyre/
|
|
130
|
-
.pdm-python
|
|
131
|
-
.pdm.toml
|
|
132
|
-
pdm.lock
|
spoc-0.2.0/.prettierignore
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
docs/docs/api/**/*.md
|