Skip to content

fix(mobile): respect Matplotlib aliases in plot style overrides - #991

Open
tandede wants to merge 1 commit into
petercorke:mainfrom
tandede:fix/mobile-plot-style-aliases
Open

tandede wants to merge 1 commit into
petercorke:mainfrom
tandede:fix/mobile-plot-style-aliases

Conversation

@tandede

@tandede tandede commented Nov 26, 2026

Copy link
Copy Markdown
Contributor

Summary

Passing goal_style={"ms": 8} to a planner used to pass both ms and the default markersize to Matplotlib and raise a TypeError. Normalise the defaults and the caller's options separately using the destination artist's aliases, then merge them. This also lets options passed to vehicle drawing override the spelling used at construction.

This changes public plotting behaviour for alias overrides. It does not change planning, control or estimation results. OpenAI Codex helped write and test the change.

Related issue

Fixes #990

Testing

Eight mobile plotting and planner test files passed on macOS with the Agg backend: 310 tests passed, 6 skipped and 11 subtests passed. Compared Ruff output for the changed files against the base commit and ran git diff --check. The full suite, documentation build and cross-platform CI were not run locally.

AI assistance: OpenAI Codex (GPT-6).

@codacy-production

Copy link
Copy Markdown

Up to standards ✅

🟢 Issues 0 issues

Results:
0 new issues

View in Codacy

🟢 Metrics -8 complexity · 0 duplication

Metric Results
Complexity -8
Duplication 0

View in Codacy

NEW Get contextual insights on your PRs based on Codacy's metrics, along with PR and Jira context, without leaving GitHub. Enable AI reviewer
TIP This summary will be updated as you push new changes.

This branch has not been deployed

No deployments
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

mobile: a style dict with short option names (ms=, lw=) clashes with the defaults

1 participant