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

Fix mypy complains in pipe_base

    XMLWordPrintable

    Details

    • Story Points:
      0.25
    • Sprint:
      DB_S22_12
    • Team:
      Data Access and Database
    • Urgent?:
      No

      Description

      Tim Jenness's comments from Slack:

      Looks like the new (yesterday) mypy 0.950 is breaking pipe_base (at least). It’s not on conda-forge yet so I haven’t tried it on daf_butler but I will make one of my PRs re-run to check.

      The failure:
      python/lsst/pipe/base/graph/_loadHelpers.py:254: error: Argument 1 to "UUID" has incompatible type "UUID"; expected "Optional[str]"

      python/lsst/pipe/base/graph/_loadHelpers.py:254: error: Subclass of "UUID" and "str" cannot exist: would have incompatible method signatures

      The nodes variable is declared as Optional[Iterable[UUID]] so nodes =

      Unknown macro: {UUID(n) if isinstance(n, str) else n for n in nodes}

      doesn’t seem like it can ever contain str.

        Attachments

          Issue Links

            Activity

            Hide
            price Paul Price added a comment -

            I've just pushed a fix to the ticket branch for DM-34590. Do you want to cherry-pick this to a new ticket branch, or leave it there?

            Show
            price Paul Price added a comment - I've just pushed a fix to the ticket branch for DM-34590 . Do you want to cherry-pick this to a new ticket branch, or leave it there?
            Hide
            salnikov Andy Salnikov added a comment -

            I'm fine with doing it on your ticket, I'll just close one, thanks for the fix!

            Show
            salnikov Andy Salnikov added a comment - I'm fine with doing it on your ticket, I'll just close one, thanks for the fix!
            Hide
            salnikov Andy Salnikov added a comment -

            It is being fixed on DM-34590.

            Show
            salnikov Andy Salnikov added a comment - It is being fixed on DM-34590 .

              People

              Assignee:
              salnikov Andy Salnikov
              Reporter:
              salnikov Andy Salnikov
              Watchers:
              Andy Salnikov, Paul Price, Tim Jenness
              Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

                Dates

                Created:
                Updated:
                Resolved:

                  Jenkins

                  No builds found.