Skip to content

feat: add strict parameter map in python - #274

Merged
domire8 merged 2 commits into
mainfrom
feat/py-param-copy
May 1, 2026
Merged

feat: add strict parameter map in python#274
domire8 merged 2 commits into
mainfrom
feat/py-param-copy

Conversation

@domire8

@domire8 domire8 commented Apr 28, 2026

Copy link
Copy Markdown
Member

Description

We overlooked two things in #265:

  1. Bind the new StrictParameterMap in python
  2. Implement copy_parameter_value in python

This PR fixes that

Review guidelines

Estimated Time of Review: 5 minutes

Checklist before merging:

  • Confirm that the relevant changelog(s) are up-to-date in case of any user-facing changes

Co-authored-by: Copilot <copilot@github.com>
@domire8
domire8 requested review from SprGrf and yrh012 April 28, 2026 05:56
@domire8
domire8 requested a review from eeberhard as a code owner April 28, 2026 05:56
py::class_<ParameterMap, std::shared_ptr<ParameterMap>, PyParameterMap> c(m, "ParameterMap");

c.def(py::init(), "Empty constructor");
c.def(

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Here just fixing docstrings

this->set_attractor(parameter->get_parameter_value<JointState>());
} else if (parameter->get_parameter_state_type() == StateType::JOINT_POSITIONS) {
this->set_attractor(parameter->get_parameter_value<JointPositions>());
} else {

@domire8 domire8 Apr 28, 2026

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I made this addition to PointAttractor<CartesianState> in the other PR but not in the PointAttractor<JointState>

SprGrf
SprGrf previously approved these changes Apr 28, 2026

@SprGrf SprGrf left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good, pending a changelog update

@domire8

domire8 commented Apr 28, 2026

Copy link
Copy Markdown
Member Author

I omitted the changelog on purpose because it's already captured with

- feat!: rename set_parameter_value to set_parameter and add strict parameter map (#259)

@yrh012 yrh012 left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good to me!

@domire8
domire8 merged commit 24f21f6 into main May 1, 2026
4 of 5 checks passed
@domire8
domire8 deleted the feat/py-param-copy branch May 1, 2026 05:30
@github-actions github-actions Bot locked and limited conversation to collaborators May 1, 2026
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants