openc3-cosmos-script-engine-cstol 1.1.1 → 1.2.0

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 (6) hide show
  1. checksums.yaml +4 -4
  2. data/README.md +100 -8
  3. data/lib/cstol_script_engine.py +573 -399
  4. data/pyproject.toml +83 -0
  5. data/uv.lock +1396 -0
  6. metadata +4 -2
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 6ef43bd11a38493eccfc313dccee63034ead05937930eaed62e5c164bd4b68a4
4
- data.tar.gz: e63152c3a168bf6da0b6d70b3e3aa9f05cb2c974c631cbd4e1ac5f36908618a6
3
+ metadata.gz: '09b27bfb1b01bd2a21ff41078e7d25e2112d9024d9dfb2ab4663a2bd1b419780'
4
+ data.tar.gz: 8fd1660731f16948ea44cd2539408b100f34018534d8e7df47bb045d18ff2984
5
5
  SHA512:
6
- metadata.gz: eab9091c50b1867c2d4ac4b2794f72abb67bd48352ccbd01cfa14fb442be43314c1766e73ba418cef8445d6f596d7855b54306c6b5a58cddfcca900698450107
7
- data.tar.gz: d23e20164925cafe6a9efee37d6348b2277a1996a53fe8d05f0b31dd6fa4612635a0e34c1ffdcf893af8a5c297b175ece81a747250459ce747a97e298a3e6ece
6
+ metadata.gz: ee0cf899dd95e9c5aa305a9e228bef5cbaad1d41d357cc76a7eba36b51cdaf16777bf43ac7f7fbea875853319b9b34bedd73c798779a8746056079c047e6e844
7
+ data.tar.gz: 4d3600530bec3d984aeb07529ba87d67314254a4233c6bb7bec010a78ac6fce08d5e5c49193af70a50f182e8b95c23b3a5928eeb2e7f44698b0bab34c3f19336
data/README.md CHANGED
@@ -165,20 +165,112 @@ The following CSTOL keywords are not supported and will simply print a warning:
165
165
 
166
166
  1. At the Administrator Console - Plugins, upload the openc3-cosmos-script-engine-cstol.gem file
167
167
 
168
- ## Testing
168
+ ## Development
169
169
 
170
- ### Run tests with coverage
170
+ This project uses:
171
171
 
172
- source test_env/bin/activate
173
- python -m pytest
172
+ - **uv** for dependency management and locking
173
+ - **pytest** for testing
174
+ - **ruff** for linting and formatting
175
+ - **ty** for static type checking
176
+ - **just** for task automation
174
177
 
175
- ### Generate detailed terminal report
178
+ All Python tooling is configured in `pyproject.toml`, and dependency versions are
179
+ pinned in `uv.lock`. Install the development environment with:
176
180
 
177
- python -m pytest --cov=lib --cov-report=term-missing
181
+ ```bash
182
+ uv sync --group dev
183
+ ```
178
184
 
179
- ### Generate HTML report
185
+ Note that `openc3` is a development-only dependency. At runtime COSMOS provides it,
186
+ so the plugin declares no runtime dependencies of its own.
180
187
 
181
- python -m pytest --cov=lib --cov-report=html
188
+ ### Quick Start with Just
189
+
190
+ This project uses [just](https://github.com/casey/just) as a command runner. To see
191
+ all available commands:
192
+
193
+ ```bash
194
+ just --list
195
+ ```
196
+
197
+ Common commands:
198
+
199
+ ```bash
200
+ # Run all checks (lint, format check, type check, tests)
201
+ just check
202
+
203
+ # Run tests
204
+ just test
205
+
206
+ # Run tests with coverage
207
+ just test-cov
208
+
209
+ # Generate an HTML coverage report in htmlcov/
210
+ just coverage-html
211
+
212
+ # Lint, and auto-fix what can be fixed
213
+ just lint
214
+ just lint-fix
215
+
216
+ # Format, or check formatting without writing
217
+ just format
218
+ just format-check
219
+
220
+ # Type check with ty
221
+ just typecheck
222
+
223
+ # Remove build, cache, and coverage artifacts
224
+ just clean
225
+ ```
226
+
227
+ ### Manual Commands
228
+
229
+ If you prefer to invoke the tools directly with uv:
230
+
231
+ ```bash
232
+ uv run --group dev pytest # tests + coverage
233
+ uv run --group dev pytest test/ -v --cov=lib --cov-report=term-missing # detailed report
234
+ uv run --group dev pytest test/ --cov=lib --cov-report=html # HTML report
235
+ uv run --group dev ruff check . # lint
236
+ uv run --group dev ruff format . # format
237
+ uv run --group dev ty check --exit-zero-on-warning lib/ test/ # type check
238
+ ```
239
+
240
+ Coverage settings, including the 80% minimum, live in `pyproject.toml` and apply to
241
+ every one of these invocations.
242
+
243
+ ## Versioning and Building the Gem
244
+
245
+ The plugin version is defined in one place, the `version` field of `pyproject.toml`:
246
+
247
+ ```toml
248
+ [project]
249
+ name = "openc3-cosmos-script-engine-cstol-python"
250
+ version = "1.2.0"
251
+ ```
252
+
253
+ The gemspec does not hardcode a version. It reads the `VERSION` environment variable,
254
+ and `just build-gem` supplies that value by reading it out of `pyproject.toml`. So
255
+ bumping the version in `pyproject.toml` is what changes the version of the built gem:
256
+
257
+ ```bash
258
+ # Builds openc3-cosmos-script-engine-cstol-<pyproject version>.gem
259
+ just build-gem
260
+ ```
261
+
262
+ To override the version for a one-off build, pass it explicitly:
263
+
264
+ ```bash
265
+ just build-gem 1.3.0
266
+ ```
267
+
268
+ For a throwaway build, `just build-gem-dev` appends a `-dev.<timestamp>` suffix to the
269
+ `pyproject.toml` version, which keeps prerelease gems from colliding. RubyGems
270
+ normalizes that into a prerelease version, so `1.2.0` builds as
271
+ `openc3-cosmos-script-engine-cstol-1.2.0.pre.dev.<timestamp>.gem`.
272
+
273
+ Both `pyproject.toml` and `uv.lock` are packaged into the gem.
182
274
 
183
275
  ## Contributing
184
276