spine-tools / Spine-Database-API

Database interface to Spine generic data model
https://www.tools-for-energy-system-modelling.org/
GNU Lesser General Public License v3.0
6 stars 5 forks source link

Guidelines on what to import in __init__.py #384

Open soininen opened 2 months ago

soininen commented 2 months ago

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: