stinger-ipc 0.0.4__tar.gz → 0.0.5__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.
- {stinger_ipc-0.0.4/stinger_ipc.egg-info → stinger_ipc-0.0.5}/PKG-INFO +2 -1
- {stinger_ipc-0.0.4 → stinger_ipc-0.0.5}/pyproject.toml +4 -3
- {stinger_ipc-0.0.4 → stinger_ipc-0.0.5/stinger_ipc.egg-info}/PKG-INFO +2 -1
- stinger_ipc-0.0.5/stinger_ipc.egg-info/entry_points.txt +4 -0
- {stinger_ipc-0.0.4 → stinger_ipc-0.0.5}/stinger_ipc.egg-info/requires.txt +1 -0
- {stinger_ipc-0.0.4 → stinger_ipc-0.0.5}/stingeripc/tools/markdown_generator.py +13 -6
- stinger_ipc-0.0.5/stingeripc/tools/python_generator.py +49 -0
- stinger_ipc-0.0.4/stinger_ipc.egg-info/entry_points.txt +0 -4
- stinger_ipc-0.0.4/stingeripc/tools/python_generator.py +0 -39
- {stinger_ipc-0.0.4 → stinger_ipc-0.0.5}/LICENSE +0 -0
- {stinger_ipc-0.0.4 → stinger_ipc-0.0.5}/README.md +0 -0
- {stinger_ipc-0.0.4 → stinger_ipc-0.0.5}/setup.cfg +0 -0
- {stinger_ipc-0.0.4 → stinger_ipc-0.0.5}/stinger_ipc.egg-info/SOURCES.txt +0 -0
- {stinger_ipc-0.0.4 → stinger_ipc-0.0.5}/stinger_ipc.egg-info/dependency_links.txt +0 -0
- {stinger_ipc-0.0.4 → stinger_ipc-0.0.5}/stinger_ipc.egg-info/top_level.txt +0 -0
- {stinger_ipc-0.0.4 → stinger_ipc-0.0.5}/stingeripc/__init__.py +0 -0
- {stinger_ipc-0.0.4 → stinger_ipc-0.0.5}/stingeripc/args.py +0 -0
- {stinger_ipc-0.0.4 → stinger_ipc-0.0.5}/stingeripc/asyncapi.py +0 -0
- {stinger_ipc-0.0.4 → stinger_ipc-0.0.5}/stingeripc/components.py +0 -0
- {stinger_ipc-0.0.4 → stinger_ipc-0.0.5}/stingeripc/connection.py +0 -0
- {stinger_ipc-0.0.4 → stinger_ipc-0.0.5}/stingeripc/exceptions.py +0 -0
- {stinger_ipc-0.0.4 → stinger_ipc-0.0.5}/stingeripc/interface.py +0 -0
- {stinger_ipc-0.0.4 → stinger_ipc-0.0.5}/stingeripc/lang_symb.py +0 -0
- {stinger_ipc-0.0.4 → stinger_ipc-0.0.5}/stingeripc/templates/cpp/CMakeLists.txt.jinja2 +0 -0
- {stinger_ipc-0.0.4 → stinger_ipc-0.0.5}/stingeripc/templates/cpp/examples/client_main.cpp.jinja2 +0 -0
- {stinger_ipc-0.0.4 → stinger_ipc-0.0.5}/stingeripc/templates/cpp/examples/server_main.cpp.jinja2 +0 -0
- {stinger_ipc-0.0.4 → stinger_ipc-0.0.5}/stingeripc/templates/cpp/include/broker.hpp.jinja2 +0 -0
- {stinger_ipc-0.0.4 → stinger_ipc-0.0.5}/stingeripc/templates/cpp/include/client.hpp.jinja2 +0 -0
- {stinger_ipc-0.0.4 → stinger_ipc-0.0.5}/stingeripc/templates/cpp/include/enums.hpp.jinja2 +0 -0
- {stinger_ipc-0.0.4 → stinger_ipc-0.0.5}/stingeripc/templates/cpp/include/ibrokerconnection.hpp.jinja2 +0 -0
- {stinger_ipc-0.0.4 → stinger_ipc-0.0.5}/stingeripc/templates/cpp/include/property_structs.hpp.jinja2 +0 -0
- {stinger_ipc-0.0.4 → stinger_ipc-0.0.5}/stingeripc/templates/cpp/include/return_types.hpp.jinja2 +0 -0
- {stinger_ipc-0.0.4 → stinger_ipc-0.0.5}/stingeripc/templates/cpp/include/server.hpp.jinja2 +0 -0
- {stinger_ipc-0.0.4 → stinger_ipc-0.0.5}/stingeripc/templates/cpp/include/structs.hpp.jinja2 +0 -0
- {stinger_ipc-0.0.4 → stinger_ipc-0.0.5}/stingeripc/templates/cpp/src/broker.cpp.jinja2 +0 -0
- {stinger_ipc-0.0.4 → stinger_ipc-0.0.5}/stingeripc/templates/cpp/src/client.cpp.jinja2 +0 -0
- {stinger_ipc-0.0.4 → stinger_ipc-0.0.5}/stingeripc/templates/cpp/src/server.cpp.jinja2 +0 -0
- {stinger_ipc-0.0.4 → stinger_ipc-0.0.5}/stingeripc/templates/markdown/index.md.jinja2 +0 -0
- {stinger_ipc-0.0.4 → stinger_ipc-0.0.5}/stingeripc/templates/python/__init__.py.jinja2 +0 -0
- {stinger_ipc-0.0.4 → stinger_ipc-0.0.5}/stingeripc/templates/python/client.py.jinja2 +0 -0
- {stinger_ipc-0.0.4 → stinger_ipc-0.0.5}/stingeripc/templates/python/connection.py.jinja2 +0 -0
- {stinger_ipc-0.0.4 → stinger_ipc-0.0.5}/stingeripc/templates/python/interface_types.py.jinja2 +0 -0
- {stinger_ipc-0.0.4 → stinger_ipc-0.0.5}/stingeripc/templates/python/method_codes.py.jinja2 +0 -0
- {stinger_ipc-0.0.4 → stinger_ipc-0.0.5}/stingeripc/templates/python/pyproject.toml.jinja2 +0 -0
- {stinger_ipc-0.0.4 → stinger_ipc-0.0.5}/stingeripc/templates/python/server.py.jinja2 +0 -0
- {stinger_ipc-0.0.4 → stinger_ipc-0.0.5}/stingeripc/templates/rust/Cargo.toml.jinja2 +0 -0
- {stinger_ipc-0.0.4 → stinger_ipc-0.0.5}/stingeripc/templates/rust/client/Cargo.toml.jinja2 +0 -0
- {stinger_ipc-0.0.4 → stinger_ipc-0.0.5}/stingeripc/templates/rust/client/examples/client.rs.jinja2 +0 -0
- {stinger_ipc-0.0.4 → stinger_ipc-0.0.5}/stingeripc/templates/rust/client/src/lib.rs.jinja2 +0 -0
- {stinger_ipc-0.0.4 → stinger_ipc-0.0.5}/stingeripc/templates/rust/connection/Cargo.toml.jinja2 +0 -0
- {stinger_ipc-0.0.4 → stinger_ipc-0.0.5}/stingeripc/templates/rust/connection/examples/pub_and_recv.rs.jinja2 +0 -0
- {stinger_ipc-0.0.4 → stinger_ipc-0.0.5}/stingeripc/templates/rust/connection/src/handler.rs.jinja2 +0 -0
- {stinger_ipc-0.0.4 → stinger_ipc-0.0.5}/stingeripc/templates/rust/connection/src/lib.rs.jinja2 +0 -0
- {stinger_ipc-0.0.4 → stinger_ipc-0.0.5}/stingeripc/templates/rust/connection/src/payloads.rs.jinja2 +0 -0
- {stinger_ipc-0.0.4 → stinger_ipc-0.0.5}/stingeripc/templates/rust/server/Cargo.toml.jinja2 +0 -0
- {stinger_ipc-0.0.4 → stinger_ipc-0.0.5}/stingeripc/templates/rust/server/examples/server.rs.jinja2 +0 -0
- {stinger_ipc-0.0.4 → stinger_ipc-0.0.5}/stingeripc/templates/rust/server/src/lib.rs.jinja2 +0 -0
- {stinger_ipc-0.0.4 → stinger_ipc-0.0.5}/stingeripc/tools/__init__.py +0 -0
- {stinger_ipc-0.0.4 → stinger_ipc-0.0.5}/stingeripc/tools/rust_generator.py +0 -0
- {stinger_ipc-0.0.4 → stinger_ipc-0.0.5}/stingeripc/topic.py +0 -0
- {stinger_ipc-0.0.4 → stinger_ipc-0.0.5}/tests/test_args.py +0 -0
- {stinger_ipc-0.0.4 → stinger_ipc-0.0.5}/tests/test_enum.py +0 -0
- {stinger_ipc-0.0.4 → stinger_ipc-0.0.5}/tests/test_examples.py +0 -0
- {stinger_ipc-0.0.4 → stinger_ipc-0.0.5}/tests/test_interface.py +0 -0
- {stinger_ipc-0.0.4 → stinger_ipc-0.0.5}/tests/test_signal.py +0 -0
- {stinger_ipc-0.0.4 → stinger_ipc-0.0.5}/tests/test_topics.py +0 -0
@@ -1,6 +1,6 @@
|
|
1
1
|
Metadata-Version: 2.4
|
2
2
|
Name: stinger-ipc
|
3
|
-
Version: 0.0.
|
3
|
+
Version: 0.0.5
|
4
4
|
Summary: Tools to create code to do IPC over MQTT
|
5
5
|
Requires-Python: >=3.12
|
6
6
|
Description-Content-Type: text/markdown
|
@@ -11,6 +11,7 @@ Requires-Dist: pydantic>=2.11.7
|
|
11
11
|
Requires-Dist: pyyaml>=6.0.2
|
12
12
|
Requires-Dist: ruamel-yaml>=0.18.14
|
13
13
|
Requires-Dist: stringcase>=1.2.0
|
14
|
+
Requires-Dist: typer>=0.16.1
|
14
15
|
Requires-Dist: yamlloader>=1.5.1
|
15
16
|
Dynamic: license-file
|
16
17
|
|
@@ -1,6 +1,6 @@
|
|
1
1
|
[project]
|
2
2
|
name = "stinger-ipc"
|
3
|
-
version = "0.0.
|
3
|
+
version = "0.0.5"
|
4
4
|
description = "Tools to create code to do IPC over MQTT"
|
5
5
|
readme = "README.md"
|
6
6
|
requires-python = ">=3.12"
|
@@ -11,6 +11,7 @@ dependencies = [
|
|
11
11
|
"pyyaml>=6.0.2",
|
12
12
|
"ruamel-yaml>=0.18.14",
|
13
13
|
"stringcase>=1.2.0",
|
14
|
+
"typer>=0.16.1",
|
14
15
|
"yamlloader>=1.5.1",
|
15
16
|
]
|
16
17
|
|
@@ -41,6 +42,6 @@ stingeripc = [
|
|
41
42
|
]
|
42
43
|
|
43
44
|
[project.scripts]
|
44
|
-
pythongen = "stingeripc.tools.python_generator:
|
45
|
+
pythongen = "stingeripc.tools.python_generator:run"
|
45
46
|
rustgen = "stingeripc.tools.rust_generator:main"
|
46
|
-
markdowngen = "stingeripc.tools.markdown_generator:
|
47
|
+
markdowngen = "stingeripc.tools.markdown_generator:run"
|
@@ -1,6 +1,6 @@
|
|
1
1
|
Metadata-Version: 2.4
|
2
2
|
Name: stinger-ipc
|
3
|
-
Version: 0.0.
|
3
|
+
Version: 0.0.5
|
4
4
|
Summary: Tools to create code to do IPC over MQTT
|
5
5
|
Requires-Python: >=3.12
|
6
6
|
Description-Content-Type: text/markdown
|
@@ -11,6 +11,7 @@ Requires-Dist: pydantic>=2.11.7
|
|
11
11
|
Requires-Dist: pyyaml>=6.0.2
|
12
12
|
Requires-Dist: ruamel-yaml>=0.18.14
|
13
13
|
Requires-Dist: stringcase>=1.2.0
|
14
|
+
Requires-Dist: typer>=0.16.1
|
14
15
|
Requires-Dist: yamlloader>=1.5.1
|
15
16
|
Dynamic: license-file
|
16
17
|
|
@@ -1,12 +1,15 @@
|
|
1
1
|
import os
|
2
2
|
import sys
|
3
3
|
from jacobsjinjatoo import templator as jj2
|
4
|
-
|
4
|
+
import os.path
|
5
|
+
import typer
|
6
|
+
from typing_extensions import Annotated
|
5
7
|
from stingeripc import StingerInterface
|
8
|
+
from rich import print
|
9
|
+
from pathlib import Path
|
6
10
|
|
7
|
-
def main():
|
8
|
-
|
9
|
-
outdir = sys.argv[2]
|
11
|
+
def main(inname: Annotated[Path, typer.Argument(exists=True, file_okay=True, dir_okay=False, readable=True)], outdir: Annotated[Path, typer.Argument(file_okay=False, dir_okay=True, writable=True, readable=True)]):
|
12
|
+
print(f"[bold green]Reading:[/bold green] {inname}")
|
10
13
|
with open(inname, "r") as f:
|
11
14
|
stinger = StingerInterface.from_yaml(f)
|
12
15
|
params = {
|
@@ -19,7 +22,11 @@ def main():
|
|
19
22
|
for output_file in [
|
20
23
|
"index.md",
|
21
24
|
]:
|
25
|
+
print(f"[bold red]GENERATING:[/bold red] {output_file}")
|
22
26
|
t.render_template(f"{output_file}.jinja2", output_file, **params)
|
23
27
|
|
24
|
-
|
25
|
-
main
|
28
|
+
def run():
|
29
|
+
typer.run(main)
|
30
|
+
|
31
|
+
if __name__ == "__main__":
|
32
|
+
run()
|
@@ -0,0 +1,49 @@
|
|
1
|
+
from jacobsjinjatoo import templator as jj2
|
2
|
+
from jacobsjinjatoo import stringmanip
|
3
|
+
import sys
|
4
|
+
import os.path
|
5
|
+
import typer
|
6
|
+
from typing_extensions import Annotated
|
7
|
+
from stingeripc import StingerInterface
|
8
|
+
from rich import print
|
9
|
+
from pathlib import Path
|
10
|
+
|
11
|
+
def main(inname: Annotated[Path, typer.Argument(exists=True, file_okay=True, dir_okay=False, readable=True)], outdir: Annotated[Path, typer.Argument(file_okay=False, dir_okay=True, writable=True, readable=True)]):
|
12
|
+
|
13
|
+
print(f"[bold green]Reading:[/bold green] {inname}")
|
14
|
+
with open(inname, "r") as f:
|
15
|
+
stinger = StingerInterface.from_yaml(f)
|
16
|
+
params = {
|
17
|
+
"stinger": stinger,
|
18
|
+
}
|
19
|
+
t = jj2.CodeTemplator(output_dir=os.path.dirname(outdir))
|
20
|
+
t.add_template_dir(
|
21
|
+
os.path.join(os.path.dirname(__file__), "../templates", "python")
|
22
|
+
)
|
23
|
+
for output_file in [
|
24
|
+
"pyproject.toml",
|
25
|
+
]:
|
26
|
+
print(f"[bold red]Generating:[/bold red] {output_file}")
|
27
|
+
t.render_template(f"{output_file}.jinja2", os.path.join(outdir, output_file), **params)
|
28
|
+
|
29
|
+
package_name = f"{stringmanip.lower_camel_case(stinger.name).lower()}ipc"
|
30
|
+
generated_pkg_dir = os.path.join(outdir, package_name)
|
31
|
+
print(f"[bold red]Making Directory:[/bold red] {generated_pkg_dir}")
|
32
|
+
os.makedirs(generated_pkg_dir, exist_ok=True)
|
33
|
+
for output_file in [
|
34
|
+
"server.py",
|
35
|
+
"client.py",
|
36
|
+
"connection.py",
|
37
|
+
"__init__.py",
|
38
|
+
"method_codes.py",
|
39
|
+
]:
|
40
|
+
print(f"[bold red]Generating:[/bold red] {output_file}")
|
41
|
+
t.render_template(f"{output_file}.jinja2", os.path.join(generated_pkg_dir, output_file), **params)
|
42
|
+
|
43
|
+
t.render_template("interface_types.py.jinja2", os.path.join(generated_pkg_dir, f"{stinger.get_enum_module_name()}.py"), **params)
|
44
|
+
|
45
|
+
def run():
|
46
|
+
typer.run(main)
|
47
|
+
|
48
|
+
if __name__ == "__main__":
|
49
|
+
run()
|
@@ -1,39 +0,0 @@
|
|
1
|
-
from jacobsjinjatoo import templator as jj2
|
2
|
-
from jacobsjinjatoo import stringmanip
|
3
|
-
import sys
|
4
|
-
import os.path
|
5
|
-
|
6
|
-
from stingeripc import StingerInterface
|
7
|
-
|
8
|
-
def main():
|
9
|
-
inname = sys.argv[1]
|
10
|
-
outdir = sys.argv[2]
|
11
|
-
with open(inname, "r") as f:
|
12
|
-
stinger = StingerInterface.from_yaml(f)
|
13
|
-
params = {
|
14
|
-
"stinger": stinger,
|
15
|
-
}
|
16
|
-
t = jj2.CodeTemplator(output_dir=os.path.dirname(outdir))
|
17
|
-
t.add_template_dir(
|
18
|
-
os.path.join(os.path.dirname(__file__), "../templates", "python")
|
19
|
-
)
|
20
|
-
for output_file in [
|
21
|
-
"pyproject.toml",
|
22
|
-
]:
|
23
|
-
t.render_template(f"{output_file}.jinja2", output_file, **params)
|
24
|
-
|
25
|
-
generated_src_dir = os.path.join(outdir, f"{stringmanip.lower_camel_case(stinger.name).lower()}ipc")
|
26
|
-
os.makedirs(generated_src_dir, exist_ok=True)
|
27
|
-
for output_file in [
|
28
|
-
"server.py",
|
29
|
-
"client.py",
|
30
|
-
"connection.py",
|
31
|
-
"__init__.py",
|
32
|
-
"method_codes.py",
|
33
|
-
]:
|
34
|
-
t.render_template(f"{output_file}.jinja2", os.path.join(stinger.name.lower(), output_file), **params)
|
35
|
-
|
36
|
-
t.render_template("interface_types.py.jinja2", os.path.join(stinger.name.lower(), f"{stinger.get_enum_module_name()}.py"), **params)
|
37
|
-
|
38
|
-
if __name__ == "__main__":
|
39
|
-
main()
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
{stinger_ipc-0.0.4 → stinger_ipc-0.0.5}/stingeripc/templates/cpp/examples/client_main.cpp.jinja2
RENAMED
File without changes
|
{stinger_ipc-0.0.4 → stinger_ipc-0.0.5}/stingeripc/templates/cpp/examples/server_main.cpp.jinja2
RENAMED
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
{stinger_ipc-0.0.4 → stinger_ipc-0.0.5}/stingeripc/templates/cpp/include/property_structs.hpp.jinja2
RENAMED
File without changes
|
{stinger_ipc-0.0.4 → stinger_ipc-0.0.5}/stingeripc/templates/cpp/include/return_types.hpp.jinja2
RENAMED
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
{stinger_ipc-0.0.4 → stinger_ipc-0.0.5}/stingeripc/templates/python/interface_types.py.jinja2
RENAMED
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
{stinger_ipc-0.0.4 → stinger_ipc-0.0.5}/stingeripc/templates/rust/client/examples/client.rs.jinja2
RENAMED
File without changes
|
File without changes
|
{stinger_ipc-0.0.4 → stinger_ipc-0.0.5}/stingeripc/templates/rust/connection/Cargo.toml.jinja2
RENAMED
File without changes
|
File without changes
|
{stinger_ipc-0.0.4 → stinger_ipc-0.0.5}/stingeripc/templates/rust/connection/src/handler.rs.jinja2
RENAMED
File without changes
|
{stinger_ipc-0.0.4 → stinger_ipc-0.0.5}/stingeripc/templates/rust/connection/src/lib.rs.jinja2
RENAMED
File without changes
|
{stinger_ipc-0.0.4 → stinger_ipc-0.0.5}/stingeripc/templates/rust/connection/src/payloads.rs.jinja2
RENAMED
File without changes
|
File without changes
|
{stinger_ipc-0.0.4 → stinger_ipc-0.0.5}/stingeripc/templates/rust/server/examples/server.rs.jinja2
RENAMED
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|