Skip to content

[MNT] Remove __version__.py module and define __version__ in __init__ #1642

Description

@geetu040

Currently, the package defines __version__ inside a __version__.py module and then re-exports it from openml/__init__.py.

This results in two objects named __version__:

  • the module openml.__version__
  • the variable __version__ imported from that module

This kind of name masking between a module and a variable is generally discouraged in Python, as it can lead to confusion and unclear import semantics.

Todo:

  • Remove openml/__version__.py
  • Define __version__ directly inside openml/__init__.py
  • Update any internal imports accordingly

This keeps a single, conventional openml.__version__ attribute while avoiding module/variable name collisions and simplifying the package structure.

Initial Source/Discussion: aiondemand/aiondemand#70

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

    Good First IssueIssues suitable for people new to contributing to openml-python!maintenance & CIContinuous integration & package distribution

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions