Uploaded image for project: 'Data Management'
  1. Data Management
  2. DM-20955

Refactor commandline parsing to allow reuse

    Details

    • Type: Story
    • Status: Won't Fix
    • Resolution: Done
    • Fix Version/s: None
    • Component/s: cp_pipe, pipe_base
    • Labels:
      None
    • Team:
      Data Access and Database

      Description

      In pipe.base.IdValueAction has code to parse id strings from the command line, but it's mixed in with argparse deeply enough that people who need to write custom TaskRunners can't use it.

      I pulled this code out into cp_pipe/utils.py as parseCmdlineNumberString() but this is somewhat duplicative, and should therefore be removed, with this functionality neatly factored out in pipe_base so that it, and cp_pipe can use it.

        Attachments

          Activity

          Hide
          swinbank John Swinbank added a comment -

          Is this still relevant for PipelineTask / command-line activators?

          Show
          swinbank John Swinbank added a comment - Is this still relevant for PipelineTask / command-line activators?
          Hide
          swinbank John Swinbank added a comment -

          Task framework -> team DAX.

          Show
          swinbank John Swinbank added a comment - Task framework -> team DAX.
          Hide
          mfisherlevine Merlin Fisher-Levine added a comment -

          That's an interesting question, but not really one I can answer. I'd hope so, at least for the calibration products stuff where you really do care about the exact inputs (though obviously the syntax might change, in which case it would indeed not be relevant after all). Could you tag someone appropriate to answer this? Maybe Jim Bosch?

          Show
          mfisherlevine Merlin Fisher-Levine added a comment - That's an interesting question, but not really one I can answer. I'd hope so, at least for the calibration products stuff where you really do care about the exact inputs (though obviously the syntax might change, in which case it would indeed not be relevant after all). Could you tag someone appropriate to answer this? Maybe Jim Bosch ?
          Hide
          jbosch Jim Bosch added a comment - - edited

          Gen3 has it's own (more expansive) version of this ticket: DM-15257.  We definitely need to refactor the command-line parsing to make it more modular, but while I expect Gen2 and Gen3 to have configuration parsing in common, I don't think the Gen2 and Gen3 data ID parsing will overlap at all.

          Show
          jbosch Jim Bosch added a comment - - edited Gen3 has it's own (more expansive) version of this ticket: DM-15257 .  We definitely need to refactor the command-line parsing to make it more modular, but while I expect Gen2 and Gen3 to have configuration parsing in common, I don't think the Gen2 and Gen3 data ID parsing will overlap at all.
          Hide
          swinbank John Swinbank added a comment -

          Given that, I think we can close this as “won't fix” — we should migrate to the new system, rather than fix the old one.

          Show
          swinbank John Swinbank added a comment - Given that, I think we can close this as “won't fix” — we should migrate to the new system, rather than fix the old one.

            People

            • Assignee:
              Unassigned
              Reporter:
              mfisherlevine Merlin Fisher-Levine
              Watchers:
              Jim Bosch, John Swinbank, Merlin Fisher-Levine, Robert Lupton
            • Votes:
              0 Vote for this issue
              Watchers:
              4 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved:

                Summary Panel