Skip to content

[Request] Loosen CLI package dependencies for 50MB #583

@m-roberts

Description

@m-roberts

Problem or Possibility

The CLI package currently requires a significant installation size, as it requires all subpackages that it works with in order to work at all. This means installing PMA stuff, etc.

pi@pi-top:~ $ sudo apt install python3-pitop-cli --no-install-recommends
Reading package lists... Done
Building dependency tree... Done
Reading state information... Done
The following additional packages will be installed:
  fonts-roboto fonts-roboto-unhinted liblbfgsb0 python3-decorator python3-pitop-display python3-pitop-miniscreen python3-pitop-pma
  python3-pyinotify python3-scipy
Suggested packages:
  python-pyinotify-doc python-scipy-doc
The following NEW packages will be installed:
  fonts-roboto fonts-roboto-unhinted liblbfgsb0 python3-decorator python3-pitop-cli python3-pitop-display python3-pitop-miniscreen
  python3-pitop-pma python3-pyinotify python3-scipy
0 upgraded, 10 newly installed, 0 to remove and 0 not upgraded.
Need to get 13.7 MB of archives.
After this operation, 53.1 MB of additional disk space will be used.
Do you want to continue? [Y/n]

Where this functionality is not required, it adds additional install size.

Proposed Solution

Can plotting IMU calibration graphs be moved somewhere else (PMA?) with a soft dependency that is handled with a try/catch statement?

Perhaps the CLI package is configured to scan for available subpackages and only imports them if they exist? That would make it a lot more flexible.

Note: pdm has a plugin architecture that would likely serve as a useful reference

Alternative Solutions

Additional Context

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions