Skip to content

Packagination#301

Merged
alhom merged 23 commits intofmihpc:devfrom
alhom:packagination
Feb 4, 2025
Merged

Packagination#301
alhom merged 23 commits intofmihpc:devfrom
alhom:packagination

Conversation

@alhom
Copy link
Copy Markdown
Member

@alhom alhom commented Dec 20, 2024

Draft PR for making Analysator a package with a build system. What is in here:

  • import analysator as pt imports the (installed) package
  • import pytools as pt imports the analysator package transparently for backward compatibility
    • this works through two aliases, one module alias at analysator root and one alias package, both to be eventually deprecated. Probably should add analysator as a root module for import analysator to enable import analysator without pip install.
  • pip install <path to analysator> (or, with the --editable flag if preferred; that links to the cloned repo instead of installing to site-packages) to install analysator with all dependencies automatically via pip to user's environment/virtual environment
  • moving files around to a standard src-layout - didn't yet figure out how to get the hatchling build grab the analysator root folder; numpy manages this with meson build
    • pro: more separation between analysator proper and application scripts
    • con: unnecessarily deep folder structure to my taste (and existing workflows)

Discussion is open.

@alhom
Copy link
Copy Markdown
Member Author

alhom commented Jan 8, 2025

Todo: figure out sub-packages and get rid of the system path hacks.

@alhom alhom changed the base branch from master to dev February 4, 2025 09:02
@alhom alhom marked this pull request as ready for review February 4, 2025 11:08
@alhom alhom merged commit aef9f88 into fmihpc:dev Feb 4, 2025
2 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant