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

Missing str/repr for middleware objects

    XMLWordPrintable

Details

    • Architecture
    • No

    Description

      Quite a few middleware-related python objects don't have a useful string representation. I've listed the ones I know about below, with suggestions for how to implement stringification.

      obs_base

      • Instrument
      • FilterDefinitions: repr could duplicate str?

      pipe_base

      • Pipeline: the str could be the instrument and description fields?
      • PipelineTaskConnections
      • QuantumGraph

      daf_butler

      • Butler: at minimum, repr should match str.
      • Registry: repr almost looks more useful to me; str is just a long string with the path.
      • Datastore: str/repr exist, but could be more useful[1].
      • StorageClassFactory: repr could duplicate str?
      • RegistryDefaults

      1)

      >>> str(self.butler.datastore)
      'file:///var/folders/1s/x4hsw5kj4pdbnlvfw75zzkv40000gq/T/tmpccyrt726/'
      >>> repr(self.butler.datastore)
      'FileDatastore@<butlerRoot>'
      

      Attachments

        Activity

          People

            Unassigned Unassigned
            Parejkoj John Parejko
            Jim Bosch, John Parejko, Krzysztof Findeisen, Nate Lust, Tim Jenness
            Votes:
            0 Vote for this issue
            Watchers:
            5 Start watching this issue

            Dates

              Created:
              Updated:

              Jenkins

                No builds found.