Skip to content

CLI: selection rule creation fails #251

@katharinabassler

Description

@katharinabassler

When attempting to create a selection rule with the CLI, the following error occurs:

prosEO (S1C)> productclass rule create S2_SLC__1X
Checking for missing mandatory attributes ...
Selection rule in Rule Language (empty field cancels, ^D terminates): 
FOR AUX_PRE SELECT LatestValCover(0 D, 6 M) OPTIONAL
(E6225) Selection rule data invalid (cause: (E5044) Selection rule missing in selection rule string de.dlr.proseo.prodclmgr.rest.model.SelectionRuleString@819a613[id=<null>,version=<null>,selectionRule=<null>,mode=<null>,configuredProcessors=[]])

For reference, the product class manager log:

2025-08-20 12:56:34.773 TRACE 1 --- [http-nio-8080-exec-7] d.d.p.p.rest.ProductClassControllerImpl  : >>> createSelectionRuleString(SelectionRuleString[1])
2025-08-20 12:56:34.774 TRACE 1 --- [http-nio-8080-exec-7] d.d.p.p.rest.ProductClassManager         : >>> createSelectionRuleString(SelectionRuleString[1])
2025-08-20 12:56:34.777 ERROR 1 --- [http-nio-8080-exec-7] d.d.p.p.rest.ProductClassManager         : (E5044) Selection rule missing in selection rule string de.dlr.proseo.prodclmgr.rest.model.SelectionRuleString@819a613[id=<null>,version=<null>,selectionRule=<null>,mode=<null>,configuredProcessors=[]]

A workaround using the format and file options is possible:

productclass rule create --format=PLAIN --file=s1c-config/S1C_S2_SLC__1X_product_rule.txt S2_SLC__1X

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't workingimplementedIssue has been implemented and is ready for test

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions