Skip to content

Make the stripping of annotation properties optional#1206

Merged
gouttegd merged 2 commits intomasterfrom
fix-strip-annotation-properties
Apr 1, 2025
Merged

Make the stripping of annotation properties optional#1206
gouttegd merged 2 commits intomasterfrom
fix-strip-annotation-properties

Conversation

@gouttegd
Copy link
Contributor

This PR adds a new option to the ImportGroup section, strip_annotation_properties. It allows to disable the stripping of annotation properties from the import modules (introduced in ODK 1.5). The option is enabled by default, preserving the ODK 1.5 behaviour.

It also makes sure that, when annotation stripping is enabled, it is performed on individual SLME modules as well, instead of only on the merged module and individual “filter” and ”“minimal” modules.

Lastly, it adds OMO:0002000 (the property used to define macros expanded by ROBOT’s expand command) to the list of properties preserved by default.

closes #1093

We add a new configuration option in the ImportGroup,
`strip_annotation_properties`. Setting it to False disables the default
behaviour (introduced in ODK 1.5) of stripping most annotation
properties from the import modules.

When enabled, the stripping of annotation properties is now also
performed on individual SLME modules (previously it was only done on the
merged import module and on individual "mirror" and "filter" modules).

closes #1093
Add OMO:0002000 to the list of annotation properties to be preserved,
even when annotation properties are being stripped from imports.

That property has a logical meaning (it defines how an annotation is to
be expanded using ROBOT's `expand` command), so it should be preserved.
@gouttegd gouttegd self-assigned this Mar 30, 2025
@gouttegd gouttegd requested a review from matentzn March 30, 2025 19:27
Copy link
Contributor

@matentzn matentzn left a comment

Choose a reason for hiding this comment

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

Looks great, thank you!

@gouttegd gouttegd merged commit 3e5aa45 into master Apr 1, 2025
1 check passed
@gouttegd gouttegd deleted the fix-strip-annotation-properties branch April 1, 2025 17:50
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.

Revise stripping of annotation properties in imports

2 participants