Skip to content

Guidelines on what to import in __init__.py #384

Description

@soininen

Discussed in the developer meeting 2024-04-09.

We import certain functions/classes/etc. in spinedb_api.__init__ so client code can import that stuff more easily, e.g. use from spinedb_api import DatabaseMapping instead of from spinedb_api.db_mapping import DatabaseMapping.

We do not want everything to be available in __init__.py so what should we import there? Some ideas from the developer meeting:

  • Core classes/functions:
    • Things that are specifically mentioned in the API reference
    • Selected functionality from spinedb_api.filters

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions