Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Plugin System #2407

Open
wants to merge 11 commits into
base: develop
Choose a base branch
from
Open

Plugin System #2407

wants to merge 11 commits into from

Conversation

mh0g
Copy link
Contributor

@mh0g mh0g commented May 22, 2024

Description

This feature adds a plugin system to meshroom.
It also allows to install and run new nodes using containerization tools, such as conda and docker.

Features list

v1

  • Install button in the ui
  • Install from local folder
  • Install from git
  • Camelify code
  • Add support for pipelines
  • New 'build status' for nodes that are building their environment
  • .json to customize plugin install
  • Support multiple env per plugin
  • Documentation to create plugins
  • Node uninstallation
  • Catalog logic
  • PipNode to install pip packages in meshroom's python
  • PythonVirtualEnvNode taking requirements.txt

v2

  • Changing the logic from env class to env attribute
  • Modify process() in node to run normally if no or pip env, or conda, venv, docker, rez via command line meshroom_compute, if specified
  • Added badge and warning to build
  • Access to meshroom within envs

v3

  • support for rez packages
  • autorefresh

Implementation remarks

The logic is in meshroom/core/plugin.py .
It defines a new node classes to run python code in environments/containers using meshroom_compute.
Added bandit file to not test the shell call errors in codefactor.
Uses the CI en var to skip the tests on CI.


Future needed work: ui part to list/uninstall catalog, multiples envs per node, button to delete env

@mh0g mh0g requested a review from fabiencastan May 22, 2024 13:41
@mh0g mh0g marked this pull request as draft May 22, 2024 15:07
@mh0g mh0g requested a review from Just-Kiel May 23, 2024 09:17
@mh0g mh0g marked this pull request as ready for review May 28, 2024 11:50
@mh0g mh0g requested review from cbentejac, elyasbny and almarouk May 28, 2024 11:51
@mh0g mh0g self-assigned this Jun 3, 2024
@fabiencastan fabiencastan added this to the Meshroom 2024.1.0 milestone Jul 15, 2024
@mh0g mh0g force-pushed the dev/plugin_system branch from c6b1898 to 11a7400 Compare July 15, 2024 12:56
@mh0g mh0g removed request for elyasbny and almarouk July 15, 2024 14:34
@mh0g mh0g force-pushed the dev/plugin_system branch from 11a7400 to 4d12b1c Compare July 17, 2024 07:58
meshroom/ui/qml/main.qml Outdated Show resolved Hide resolved
@Just-Kiel

This comment was marked as resolved.

@Just-Kiel

This comment was marked as resolved.

@Just-Kiel

This comment was marked as resolved.

@mh0g mh0g force-pushed the dev/plugin_system branch from 2d166bd to e599269 Compare August 1, 2024 12:03
@mh0g

This comment was marked as resolved.

@Just-Kiel
Copy link
Contributor

Could it be great to have "Delete Environment" button ? Like the "Delete Data"

@mh0g

This comment was marked as resolved.

@mh0g

This comment was marked as resolved.

@mh0g
Copy link
Contributor Author

mh0g commented Aug 6, 2024

Could it be great to have "Delete Environment" button ? Like the "Delete Data"

added in todos for next version. Could be added to the "manage installed plugins" page, alongside the "un-install plugin" button

@mh0g

This comment was marked as resolved.

@Just-Kiel

This comment was marked as resolved.

@mh0g mh0g force-pushed the dev/plugin_system branch 2 times, most recently from 8a21540 to 61d8a15 Compare August 8, 2024 09:56
@mh0g mh0g force-pushed the dev/plugin_system branch 2 times, most recently from ea95d40 to b7f9a2f Compare September 12, 2024 12:36
meshroom/core/desc.py Outdated Show resolved Hide resolved
@mh0g mh0g force-pushed the dev/plugin_system branch from 66e7532 to fab1b8e Compare September 16, 2024 17:10
@mh0g mh0g force-pushed the dev/plugin_system branch from 0e26264 to fa47004 Compare September 30, 2024 13:58
Matthieu Hog added 3 commits October 8, 2024 11:11
added back menu after update

fix for existing symlink
@mh0g mh0g force-pushed the dev/plugin_system branch from f98790b to 24c4585 Compare October 8, 2024 09:11
Matthieu Hog added 3 commits October 10, 2024 13:38
added build badge

changes for uid renaming

added back menu after update

fix for existing symlink
@almarouk
Copy link
Member

Would it be possible to add support for non-default location for conda environments? i.e. using "--prefix PATH" instead of "--name NAME".
In that case, checks for the existence of the environment need to be adapted correspondingly, notably in the following:

cmd = condaBin+" list --name "+envName

would become: cmd = condaBin+" list --prefix "+envName, or alternatively by checking the result of conda env list.

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

Successfully merging this pull request may close these issues.

4 participants