Skip to content
Snippets Groups Projects

Reoworking the group operations

Merged David Schäfer requested to merge group-operations into develop

There was a ugly inconsistency with respect to the dictionary option to the group parameter. When given the following:

qc.andGroup(field="x", {"y": qc1, "z": qc2})

the group operation was conducted as qc1["y"] & qc2["z"] rendering the field parameter basically useless, but still mandatory... This MR removed the dictionary option and replaces the above by the more streamlined version:

qc.andGroup(field=["y", "z"], target="x", [qc1, qc2])

If there is a need to select more than one variable from any of the SaQC objects, this is achieved by a nested fieldlist. E.g.

qc.andGroup(field=[["a","b"], "c"], target="x", [qc1, qc2])

This basically executes qc1["a"] & qc1["b"] & qc2["c"].

BTW, the docstring for `saqc.func.flagtools._groupOperation was generated by ChatGPT from the function's code. I only made minimal changes.

Merge request reports

Pipeline #188860 passed

Pipeline passed for 7eb41cbd on group-operations

Test coverage 76.00% (0.00%) from 1 job
Approval is optional
Ready to merge by members who can write to the target branch.

Activity

Filter activity
  • Approvals
  • Assignees & reviewers
  • Comments (from bots)
  • Comments (from users)
  • Commits & branches
  • Edits
  • Labels
  • Lock status
  • Mentions
  • Merge request status
  • Tracking
  • Loading
  • Loading
  • Loading
  • Loading
  • Loading
  • Loading
  • Loading
  • Loading
  • Loading
  • Loading
Please register or sign in to reply
Loading