pyforce-rosie 2.0.0__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.
- pyforce_rosie-2.0.0/.dockerignore +15 -0
- pyforce_rosie-2.0.0/.env.test +1 -0
- pyforce_rosie-2.0.0/.git-blame-ignore-revs +3 -0
- pyforce_rosie-2.0.0/.github/workflows/qa.yml +15 -0
- pyforce_rosie-2.0.0/.github/workflows/release.yml +43 -0
- pyforce_rosie-2.0.0/.gitignore +223 -0
- pyforce_rosie-2.0.0/.pre-commit-config.yaml +23 -0
- pyforce_rosie-2.0.0/.python-version +1 -0
- pyforce_rosie-2.0.0/.readthedocs.yaml +23 -0
- pyforce_rosie-2.0.0/AGENTS.md +47 -0
- pyforce_rosie-2.0.0/CODEOWNERS +1 -0
- pyforce_rosie-2.0.0/DEVELOPMENT.md +390 -0
- pyforce_rosie-2.0.0/Dockerfile +69 -0
- pyforce_rosie-2.0.0/LICENSE +21 -0
- pyforce_rosie-2.0.0/Makefile +66 -0
- pyforce_rosie-2.0.0/PKG-INFO +166 -0
- pyforce_rosie-2.0.0/README.md +142 -0
- pyforce_rosie-2.0.0/assets/logo.svg +4 -0
- pyforce_rosie-2.0.0/docker/nginx.conf +47 -0
- pyforce_rosie-2.0.0/docker/run.sh +27 -0
- pyforce_rosie-2.0.0/docs/about.md +25 -0
- pyforce_rosie-2.0.0/docs/client.md +87 -0
- pyforce_rosie-2.0.0/docs/getting-started.md +136 -0
- pyforce_rosie-2.0.0/docs/how-rosie-works.md +121 -0
- pyforce_rosie-2.0.0/docs/images/logo.svg +4 -0
- pyforce_rosie-2.0.0/docs/images/webrosie.png +0 -0
- pyforce_rosie-2.0.0/docs/index.md +43 -0
- pyforce_rosie-2.0.0/docs/integration.md +88 -0
- pyforce_rosie-2.0.0/docs/javascripts/mathjax.js +19 -0
- pyforce_rosie-2.0.0/docs/motion-control.md +240 -0
- pyforce_rosie-2.0.0/docs/navigation.md +109 -0
- pyforce_rosie-2.0.0/docs/reference.md +3 -0
- pyforce_rosie-2.0.0/docs/robots.md +161 -0
- pyforce_rosie-2.0.0/docs/teaching.md +80 -0
- pyforce_rosie-2.0.0/pyproject.toml +158 -0
- pyforce_rosie-2.0.0/scripts/convert_map.py +69 -0
- pyforce_rosie-2.0.0/scripts/create_remote.py +230 -0
- pyforce_rosie-2.0.0/scripts/worktree.sh +225 -0
- pyforce_rosie-2.0.0/src/rosie/__init__.py +1 -0
- pyforce_rosie-2.0.0/src/rosie/__main__.py +17 -0
- pyforce_rosie-2.0.0/src/rosie/apis/__init__.py +0 -0
- pyforce_rosie-2.0.0/src/rosie/apis/models.py +11 -0
- pyforce_rosie-2.0.0/src/rosie/apis/web/__init__.py +0 -0
- pyforce_rosie-2.0.0/src/rosie/apis/web/models.py +57 -0
- pyforce_rosie-2.0.0/src/rosie/apis/web/routes.py +228 -0
- pyforce_rosie-2.0.0/src/rosie/apis/web/server.py +59 -0
- pyforce_rosie-2.0.0/src/rosie/builtin/maps/house.geojson +23 -0
- pyforce_rosie-2.0.0/src/rosie/builtin/profiles/blubot/profile.toml +40 -0
- pyforce_rosie-2.0.0/src/rosie/builtin/profiles/blubot/thumbnail.png +0 -0
- pyforce_rosie-2.0.0/src/rosie/builtin/profiles/blubot/vector.svg +177 -0
- pyforce_rosie-2.0.0/src/rosie/builtin/profiles/kevin/profile.toml +39 -0
- pyforce_rosie-2.0.0/src/rosie/builtin/profiles/kevin/thumbnail.png +0 -0
- pyforce_rosie-2.0.0/src/rosie/builtin/profiles/kevin/vector.svg +253 -0
- pyforce_rosie-2.0.0/src/rosie/builtin/profiles/ltl/profile.toml +42 -0
- pyforce_rosie-2.0.0/src/rosie/builtin/profiles/ltl/thumbnail.png +0 -0
- pyforce_rosie-2.0.0/src/rosie/builtin/profiles/ltl/vector.svg +217 -0
- pyforce_rosie-2.0.0/src/rosie/builtin/profiles/rovert/profile.toml +40 -0
- pyforce_rosie-2.0.0/src/rosie/builtin/profiles/rovert/thumbnail.png +0 -0
- pyforce_rosie-2.0.0/src/rosie/builtin/profiles/rovert/vector.svg +115 -0
- pyforce_rosie-2.0.0/src/rosie/builtin/profiles/simubot/profile.toml +32 -0
- pyforce_rosie-2.0.0/src/rosie/builtin/profiles/simubot/thumbnail.png +0 -0
- pyforce_rosie-2.0.0/src/rosie/builtin/profiles/simubot/vector.svg +232 -0
- pyforce_rosie-2.0.0/src/rosie/cli.py +96 -0
- pyforce_rosie-2.0.0/src/rosie/client/__init__.py +16 -0
- pyforce_rosie-2.0.0/src/rosie/client/api.py +183 -0
- pyforce_rosie-2.0.0/src/rosie/client/models.py +22 -0
- pyforce_rosie-2.0.0/src/rosie/control/__init__.py +0 -0
- pyforce_rosie-2.0.0/src/rosie/control/models.py +72 -0
- pyforce_rosie-2.0.0/src/rosie/control/movement.py +136 -0
- pyforce_rosie-2.0.0/src/rosie/control/regulation.py +34 -0
- pyforce_rosie-2.0.0/src/rosie/control/teleoperation.py +28 -0
- pyforce_rosie-2.0.0/src/rosie/control/tracking.py +42 -0
- pyforce_rosie-2.0.0/src/rosie/core.py +216 -0
- pyforce_rosie-2.0.0/src/rosie/errors.py +19 -0
- pyforce_rosie-2.0.0/src/rosie/hardware/__init__.py +0 -0
- pyforce_rosie-2.0.0/src/rosie/hardware/buses.py +37 -0
- pyforce_rosie-2.0.0/src/rosie/hardware/drive/__init__.py +19 -0
- pyforce_rosie-2.0.0/src/rosie/hardware/drive/devices/__init__.py +0 -0
- pyforce_rosie-2.0.0/src/rosie/hardware/drive/devices/arduino.py +96 -0
- pyforce_rosie-2.0.0/src/rosie/hardware/drive/devices/md25.py +157 -0
- pyforce_rosie-2.0.0/src/rosie/hardware/drive/devices/virtual.py +69 -0
- pyforce_rosie-2.0.0/src/rosie/hardware/drive/kinematics.py +12 -0
- pyforce_rosie-2.0.0/src/rosie/hardware/drive/models.py +63 -0
- pyforce_rosie-2.0.0/src/rosie/hardware/drive/pid.py +22 -0
- pyforce_rosie-2.0.0/src/rosie/hardware/models.py +19 -0
- pyforce_rosie-2.0.0/src/rosie/hardware/sensors/__init__.py +19 -0
- pyforce_rosie-2.0.0/src/rosie/hardware/sensors/models.py +12 -0
- pyforce_rosie-2.0.0/src/rosie/hardware/sensors/usound.py +207 -0
- pyforce_rosie-2.0.0/src/rosie/localization/__init__.py +0 -0
- pyforce_rosie-2.0.0/src/rosie/localization/odometry.py +40 -0
- pyforce_rosie-2.0.0/src/rosie/models.py +144 -0
- pyforce_rosie-2.0.0/src/rosie/planning/__init__.py +0 -0
- pyforce_rosie-2.0.0/src/rosie/planning/models.py +36 -0
- pyforce_rosie-2.0.0/src/rosie/planning/path.py +25 -0
- pyforce_rosie-2.0.0/src/rosie/planning/search.py +47 -0
- pyforce_rosie-2.0.0/src/rosie/planning/trajectory.py +156 -0
- pyforce_rosie-2.0.0/src/rosie/planning/visibility.py +68 -0
- pyforce_rosie-2.0.0/src/rosie/profile.py +91 -0
- pyforce_rosie-2.0.0/src/rosie/py.typed +0 -0
- pyforce_rosie-2.0.0/src/rosie/recording.py +102 -0
- pyforce_rosie-2.0.0/src/rosie/robot.py +51 -0
- pyforce_rosie-2.0.0/src/rosie/service.py +86 -0
- pyforce_rosie-2.0.0/src/rosie/world/__init__.py +0 -0
- pyforce_rosie-2.0.0/src/rosie/world/maps.py +69 -0
- pyforce_rosie-2.0.0/src/rosie/world/models.py +16 -0
- pyforce_rosie-2.0.0/tests/apis/web/test_routes.py +181 -0
- pyforce_rosie-2.0.0/tests/client/test_api.py +142 -0
- pyforce_rosie-2.0.0/tests/conftest.py +108 -0
- pyforce_rosie-2.0.0/tests/control/test_movement.py +76 -0
- pyforce_rosie-2.0.0/tests/control/test_regulation.py +9 -0
- pyforce_rosie-2.0.0/tests/control/test_teleoperation.py +26 -0
- pyforce_rosie-2.0.0/tests/hardware/drive/devices/test_arduino.py +71 -0
- pyforce_rosie-2.0.0/tests/hardware/drive/devices/test_md25.py +90 -0
- pyforce_rosie-2.0.0/tests/hardware/drive/devices/test_virtual.py +26 -0
- pyforce_rosie-2.0.0/tests/hardware/drive/test_kinematics.py +18 -0
- pyforce_rosie-2.0.0/tests/hardware/drive/test_pid.py +29 -0
- pyforce_rosie-2.0.0/tests/hardware/sensors/test_usound.py +139 -0
- pyforce_rosie-2.0.0/tests/hardware/test_buses.py +55 -0
- pyforce_rosie-2.0.0/tests/planning/test_path.py +66 -0
- pyforce_rosie-2.0.0/tests/planning/test_trajectory.py +45 -0
- pyforce_rosie-2.0.0/tests/test_cli.py +113 -0
- pyforce_rosie-2.0.0/tests/test_core.py +207 -0
- pyforce_rosie-2.0.0/tests/test_main.py +19 -0
- pyforce_rosie-2.0.0/tests/test_profile.py +88 -0
- pyforce_rosie-2.0.0/tests/test_robot.py +164 -0
- pyforce_rosie-2.0.0/tests/test_service.py +141 -0
- pyforce_rosie-2.0.0/tests/world/test_maps.py +81 -0
- pyforce_rosie-2.0.0/uv.lock +1974 -0
- pyforce_rosie-2.0.0/zensical.toml +83 -0
|
@@ -0,0 +1 @@
|
|
|
1
|
+
# Environment for the test suite (pytest-env loads it before collection)
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
name: QA
|
|
2
|
+
|
|
3
|
+
on:
|
|
4
|
+
pull_request:
|
|
5
|
+
push:
|
|
6
|
+
branches: [main]
|
|
7
|
+
|
|
8
|
+
jobs:
|
|
9
|
+
qa:
|
|
10
|
+
uses: gvieralopez/cookie-pyrate/.github/workflows/reusable-qa.yml@v1.1.0
|
|
11
|
+
with:
|
|
12
|
+
cookie-pyrate-ref: v1.1.0
|
|
13
|
+
python-version: "3.15"
|
|
14
|
+
# the client runs on users' own Pythons; the robot's image uses 3.15
|
|
15
|
+
test-python-versions: '["3.12", "3.13", "3.14", "3.15"]'
|
|
@@ -0,0 +1,43 @@
|
|
|
1
|
+
name: Release
|
|
2
|
+
|
|
3
|
+
on:
|
|
4
|
+
workflow_run:
|
|
5
|
+
workflows: ["QA"]
|
|
6
|
+
branches: [main]
|
|
7
|
+
types: [completed]
|
|
8
|
+
|
|
9
|
+
concurrency:
|
|
10
|
+
group: release
|
|
11
|
+
cancel-in-progress: false
|
|
12
|
+
|
|
13
|
+
jobs:
|
|
14
|
+
release:
|
|
15
|
+
if: github.event.workflow_run.conclusion == 'success'
|
|
16
|
+
uses: gvieralopez/cookie-pyrate/.github/workflows/reusable-release.yml@v1.1.0
|
|
17
|
+
permissions:
|
|
18
|
+
contents: write
|
|
19
|
+
packages: write
|
|
20
|
+
with:
|
|
21
|
+
cookie-pyrate-ref: v1.1.0
|
|
22
|
+
create-github-release: true
|
|
23
|
+
attach-distribution: false
|
|
24
|
+
# ghcr.io/pyforce/rosie, with WebRosie (the release in the Dockerfile's WEBROSIE_VERSION)
|
|
25
|
+
publish-docker-image: true
|
|
26
|
+
prepare-next-version: true
|
|
27
|
+
secrets:
|
|
28
|
+
# Created by `make repo`; lets the version bumps land on a protected main.
|
|
29
|
+
RELEASE_SSH_KEY: ${{ secrets.RELEASE_SSH_KEY }}
|
|
30
|
+
|
|
31
|
+
pypi:
|
|
32
|
+
needs: release
|
|
33
|
+
runs-on: ubuntu-latest
|
|
34
|
+
environment:
|
|
35
|
+
name: pypi
|
|
36
|
+
url: https://pypi.org/project/pyforce-rosie/
|
|
37
|
+
permissions:
|
|
38
|
+
contents: read
|
|
39
|
+
id-token: write
|
|
40
|
+
steps:
|
|
41
|
+
- uses: gvieralopez/cookie-pyrate/.github/actions/publish-to-pypi@v1.1.0
|
|
42
|
+
with:
|
|
43
|
+
sha: ${{ needs.release.outputs.sha }}
|
|
@@ -0,0 +1,223 @@
|
|
|
1
|
+
# Byte-compiled / optimized / DLL files
|
|
2
|
+
__pycache__/
|
|
3
|
+
*.py[codz]
|
|
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
|
+
# UV
|
|
98
|
+
# Similar to Pipfile.lock, it is generally recommended to include uv.lock in version control.
|
|
99
|
+
# This is especially recommended for binary packages to ensure reproducibility, and is more
|
|
100
|
+
# commonly ignored for libraries.
|
|
101
|
+
# uv.lock is intentionally committed for reproducible environments.
|
|
102
|
+
|
|
103
|
+
# poetry
|
|
104
|
+
# Similar to Pipfile.lock, it is generally recommended to include poetry.lock in version control.
|
|
105
|
+
# This is especially recommended for binary packages to ensure reproducibility, and is more
|
|
106
|
+
# commonly ignored for libraries.
|
|
107
|
+
# https://python-poetry.org/docs/basic-usage/#commit-your-poetrylock-file-to-version-control
|
|
108
|
+
#poetry.lock
|
|
109
|
+
#poetry.toml
|
|
110
|
+
|
|
111
|
+
# pdm
|
|
112
|
+
# Similar to Pipfile.lock, it is generally recommended to include pdm.lock in version control.
|
|
113
|
+
# pdm recommends including project-wide configuration in pdm.toml, but excluding .pdm-python.
|
|
114
|
+
# https://pdm-project.org/en/latest/usage/project/#working-with-version-control
|
|
115
|
+
#pdm.lock
|
|
116
|
+
#pdm.toml
|
|
117
|
+
.pdm-python
|
|
118
|
+
.pdm-build/
|
|
119
|
+
|
|
120
|
+
# pixi
|
|
121
|
+
# Similar to Pipfile.lock, it is generally recommended to include pixi.lock in version control.
|
|
122
|
+
#pixi.lock
|
|
123
|
+
# Pixi creates a virtual environment in the .pixi directory, just like venv module creates one
|
|
124
|
+
# in the .venv directory. It is recommended not to include this directory in version control.
|
|
125
|
+
.pixi
|
|
126
|
+
|
|
127
|
+
# PEP 582; used by e.g. github.com/David-OConnor/pyflow and github.com/pdm-project/pdm
|
|
128
|
+
__pypackages__/
|
|
129
|
+
|
|
130
|
+
# Celery stuff
|
|
131
|
+
celerybeat-schedule
|
|
132
|
+
celerybeat.pid
|
|
133
|
+
|
|
134
|
+
# Redis
|
|
135
|
+
*.rdb
|
|
136
|
+
*.aof
|
|
137
|
+
*.pid
|
|
138
|
+
|
|
139
|
+
# RabbitMQ
|
|
140
|
+
mnesia/
|
|
141
|
+
rabbitmq/
|
|
142
|
+
rabbitmq-data/
|
|
143
|
+
|
|
144
|
+
# ActiveMQ
|
|
145
|
+
activemq-data/
|
|
146
|
+
|
|
147
|
+
# SageMath parsed files
|
|
148
|
+
*.sage.py
|
|
149
|
+
|
|
150
|
+
# Environments
|
|
151
|
+
.env
|
|
152
|
+
.envrc
|
|
153
|
+
.venv
|
|
154
|
+
env/
|
|
155
|
+
venv/
|
|
156
|
+
ENV/
|
|
157
|
+
env.bak/
|
|
158
|
+
venv.bak/
|
|
159
|
+
|
|
160
|
+
# Spyder project settings
|
|
161
|
+
.spyderproject
|
|
162
|
+
.spyproject
|
|
163
|
+
|
|
164
|
+
# Rope project settings
|
|
165
|
+
.ropeproject
|
|
166
|
+
|
|
167
|
+
# mkdocs documentation
|
|
168
|
+
/site
|
|
169
|
+
|
|
170
|
+
# mypy
|
|
171
|
+
.mypy_cache/
|
|
172
|
+
.dmypy.json
|
|
173
|
+
dmypy.json
|
|
174
|
+
|
|
175
|
+
# Pyre type checker
|
|
176
|
+
.pyre/
|
|
177
|
+
|
|
178
|
+
# pytype static type analyzer
|
|
179
|
+
.pytype/
|
|
180
|
+
|
|
181
|
+
# Cython debug symbols
|
|
182
|
+
cython_debug/
|
|
183
|
+
|
|
184
|
+
# PyCharm
|
|
185
|
+
# JetBrains specific template is maintained in a separate JetBrains.gitignore that can
|
|
186
|
+
# be found at https://github.com/github/gitignore/blob/main/Global/JetBrains.gitignore
|
|
187
|
+
# and can be added to the global gitignore or merged into this file. For a more nuclear
|
|
188
|
+
# option (not recommended) you can uncomment the following to ignore the entire idea folder.
|
|
189
|
+
.idea/
|
|
190
|
+
|
|
191
|
+
# Abstra
|
|
192
|
+
# Abstra is an AI-powered process automation framework.
|
|
193
|
+
# Ignore directories containing user credentials, local state, and settings.
|
|
194
|
+
# Learn more at https://abstra.io/docs
|
|
195
|
+
.abstra/
|
|
196
|
+
|
|
197
|
+
# Visual Studio Code
|
|
198
|
+
# Visual Studio Code specific template is maintained in a separate VisualStudioCode.gitignore
|
|
199
|
+
# that can be found at https://github.com/github/gitignore/blob/main/Global/VisualStudioCode.gitignore
|
|
200
|
+
# and can be added to the global gitignore or merged into this file. However, if you prefer,
|
|
201
|
+
# you could uncomment the following to ignore the entire vscode folder
|
|
202
|
+
.vscode/
|
|
203
|
+
|
|
204
|
+
# Ruff stuff:
|
|
205
|
+
.ruff_cache/
|
|
206
|
+
|
|
207
|
+
# PyPI configuration file
|
|
208
|
+
.pypirc
|
|
209
|
+
|
|
210
|
+
# Marimo
|
|
211
|
+
marimo/_static/
|
|
212
|
+
marimo/_lsp/
|
|
213
|
+
__marimo__/
|
|
214
|
+
|
|
215
|
+
# Streamlit
|
|
216
|
+
.streamlit/secrets.toml
|
|
217
|
+
|
|
218
|
+
# Checkout of the shared Cookie Pyrate actions, made by the CI workflows in the
|
|
219
|
+
# workspace root. It is a separate repository and is linted where it lives.
|
|
220
|
+
.cookie-pyrate/
|
|
221
|
+
|
|
222
|
+
# rosie
|
|
223
|
+
recordings/
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
repos:
|
|
2
|
+
- repo: local
|
|
3
|
+
hooks:
|
|
4
|
+
- id: lint
|
|
5
|
+
name: Ruff Lint
|
|
6
|
+
entry: make lint
|
|
7
|
+
language: system
|
|
8
|
+
types: [python]
|
|
9
|
+
pass_filenames: false
|
|
10
|
+
|
|
11
|
+
- id: format
|
|
12
|
+
name: Ruff Format
|
|
13
|
+
entry: make format
|
|
14
|
+
language: system
|
|
15
|
+
types: [python]
|
|
16
|
+
pass_filenames: false
|
|
17
|
+
|
|
18
|
+
- id: typecheck
|
|
19
|
+
name: Mypy Typecheck
|
|
20
|
+
entry: make typecheck
|
|
21
|
+
language: system
|
|
22
|
+
types: [python]
|
|
23
|
+
pass_filenames: false
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
3.15
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
# Read the Docs builds the documentation with Zensical, from the locked docs group.
|
|
2
|
+
version: 2
|
|
3
|
+
|
|
4
|
+
build:
|
|
5
|
+
os: ubuntu-26.04
|
|
6
|
+
tools:
|
|
7
|
+
# Read the Docs may not offer the project's Python yet; uv installs it from .python-version.
|
|
8
|
+
python: "latest"
|
|
9
|
+
jobs:
|
|
10
|
+
pre_create_environment:
|
|
11
|
+
- asdf plugin add uv
|
|
12
|
+
- asdf install uv latest
|
|
13
|
+
- asdf global uv latest
|
|
14
|
+
create_environment:
|
|
15
|
+
- uv venv "${READTHEDOCS_VIRTUALENV_PATH}"
|
|
16
|
+
install:
|
|
17
|
+
- UV_PROJECT_ENVIRONMENT="${READTHEDOCS_VIRTUALENV_PATH}" uv sync --frozen --no-default-groups --group docs
|
|
18
|
+
build:
|
|
19
|
+
html:
|
|
20
|
+
- UV_PROJECT_ENVIRONMENT="${READTHEDOCS_VIRTUALENV_PATH}" uv run --no-sync zensical build --clean
|
|
21
|
+
post_build:
|
|
22
|
+
- mkdir -p "${READTHEDOCS_OUTPUT}/html"
|
|
23
|
+
- cp -r dist/docs/. "${READTHEDOCS_OUTPUT}/html/"
|
|
@@ -0,0 +1,47 @@
|
|
|
1
|
+
# rosie
|
|
2
|
+
|
|
3
|
+
Modular robot control system
|
|
4
|
+
|
|
5
|
+
Style, conventions and tooling for this project.
|
|
6
|
+
|
|
7
|
+
## Layout
|
|
8
|
+
|
|
9
|
+
1. `src/rosie/{models,errors,__main__}.py`; sub-domains as sub-packages (e.g. `motion/`).
|
|
10
|
+
2. Data structures live in `models.py`, error types in `errors.py`, unless the framework in use recommends a different file structure.
|
|
11
|
+
3. Order functions top-down — callers before callees, private helpers (`_name`) last — so the most important read first.
|
|
12
|
+
4. Do not write docstrings or descriptive comments unless the user asks for them or they provide context that cannot be inferred by reading the code.
|
|
13
|
+
|
|
14
|
+
## Design
|
|
15
|
+
|
|
16
|
+
1. Prefer immutable dataclasses for plain data: `@dataclass(frozen=True)` (add `slots=True` when it fits).
|
|
17
|
+
2. Where a framework owns the type — ORM entities, pydantic models, settings objects — follow its idiom instead of forcing a dataclass.
|
|
18
|
+
3. Avoid default arguments in functions.
|
|
19
|
+
4. If a function takes a bool that drives an `if`, prefer splitting into two functions (one delegating to the other, or factoring out shared logic when it saves ≥2 LoC).
|
|
20
|
+
|
|
21
|
+
## Hygiene
|
|
22
|
+
|
|
23
|
+
1. No commented-out code.
|
|
24
|
+
2. Every `# noqa` must specify a rule code, e.g. `# noqa: E501` and should be avoided unless the user asks for it.
|
|
25
|
+
3. Serialise JSON with `indent=2`.
|
|
26
|
+
4. Wrap any disk I/O in `TemporaryDirectory()` and operate via `Path` objects.
|
|
27
|
+
|
|
28
|
+
## Python
|
|
29
|
+
|
|
30
|
+
1. Always use f-strings, `pathlib`, and idiomatic constructs.
|
|
31
|
+
2. Avoid `open()` for reading or writing — use `Path.read_text()` / `Path.write_text()` / `Path.read_bytes()` / `Path.write_bytes()` (ruff `PTH`).
|
|
32
|
+
3. Never use `print` outside `scripts/`. Use `logger = logging.getLogger(__name__)` at module level (ruff `T20`).
|
|
33
|
+
4. Annotate everything; mypy runs with `disallow_untyped_defs = true`. Use modern typing (`list[...]`, `dict[...]`, `X | None`, `collections.abc.MutableMapping`, etc.).
|
|
34
|
+
|
|
35
|
+
## Tests
|
|
36
|
+
|
|
37
|
+
1. Function-based pytest with `@pytest.mark.parametrize`. No test classes.
|
|
38
|
+
2. The test tree mirrors the package tree: a module at `validation/rules.py` is tested by `tests/validation/test_rules.py`.
|
|
39
|
+
3. Shared fixtures, env dicts and fixture-path constants live in `tests/conftest.py`. Test data under `tests/data/` or `tests/fixtures/`.
|
|
40
|
+
4. `.env.test` holds the suite's baseline environment; `pytest-env` loads it before collection. Override a single variable in a single test with `monkeypatch.setenv` / `monkeypatch.delenv` — never assign to `os.environ` directly, so nothing leaks between tests.
|
|
41
|
+
5. Don't lower the `--cov-fail-under` threshold configured in `pyproject.toml`; add tests instead.
|
|
42
|
+
|
|
43
|
+
## Tooling
|
|
44
|
+
|
|
45
|
+
1. Use **ruff + mypy + pytest** with **uv**.
|
|
46
|
+
2. Standard QA invocation: `make qa` — it covers lint, format, type checks and tests. `make test` runs the suite on its own.
|
|
47
|
+
3. Never call `python3` directly in agent scripts; use `uv run` so inline script metadata can declare dependencies.
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
* @gvieralopez @rolurq @frndmg @alxrcs @nilox94
|