Skip to content

Ewoks install for .ows files #32

Closed

Description

@poautran

In GitLab by @woutdenolf on Oct 17, 2024, 18:08 GMT+2:

Original workflow a user would download: test.ows

ewoks convert test.ows conv.ows
ewoks convert test.ows conv.json

conv.json

conv.ows

This does not work because ewoksfluo was an editable install?

pip install ewoks[orange]
ewoks install conv.json
ewoks execute conv.json

ModuleNotFoundError: No module named 'ewoksfluo'
FAILED

OWS files do not retain the requirements

pip install ewoks[orange]
ewoks install conv.ows

This will run f`/users/denolf/.local/wdnbashutils/virtualenvs/pybox_ELoM5Y/bin/python -m pip install `. Do you want to proceed (y/N)?

Assignees: @loichuder

Migrated from GitLab: https://gitlab.esrf.fr/workflow/ewoks/ewoks/-/issues/32

Activity

  1. poautran commented on Oct 30, 2024

    @poautran
    MemberAuthor

    In GitLab by @loichuder on Oct 30, 2024, 14:47 GMT+1:

    Do I read correctly that there are actually two issues here ?

    That this snippet do not work:

    pip install ewoks[orange]
    ewoks install conv.json
    ewoks execute conv.json
    
    ModuleNotFoundError: No module named 'ewoksfluo'
    FAILED
    

    And that ewoks install does not work for ows ?

  2. poautran commented on Oct 30, 2024

    @poautran
    MemberAuthor

    In GitLab by @loichuder on Oct 30, 2024, 14:49 GMT+1:

    For the first, I actually couldn't execute ewoks install for two reasons:

    1. blissdata points to a local folder via subdirectory
    2. Packages require conflicting versions of docutils:
    The conflict is caused by:
        The user requested docutils==0.20.1
        chios 1.0.0 depends on docutils
        nbsphinx 0.9.5 depends on docutils>=0.18.1
        orange-canvas-core 0.2.2 depends on docutils
        pydata-sphinx-theme 0.15.4 depends on docutils!=0.17.0
        readme-renderer 44.0 depends on docutils>=0.21.2
    

    Editable installs do not raise an issue in general since they are translated to a git+ dependency with the commit hash which is quite neat.

  3. poautran commented on Oct 30, 2024

    @poautran
    MemberAuthor

    In GitLab by @woutdenolf on Oct 30, 2024, 16:58 GMT+1:

    To clarify: graph attributes are not stored in .ows which means we need to extract it from the tasks which means we need to convert the orange widgets to the tasks which means we already need to have the package installed.

  4. clarka34 commented on Oct 6, 2026

    @clarka34
    Member

    @loichuder @woutdenolf what is the status of this? I am not sure it's relevant anymore since it was from 2024.

  5. woutdenolf commented on Oct 6, 2026

    @woutdenolf
    Member

    This already fails before I can reproduce the problem:

    pip install --pre ewoksfluo pyqt5 ewoks
    
    ewoks convert map_1det.ows test.ows -o root_module=orangecontrib.ewoksfluo.categories.demo.tutorials
    
    Traceback (most recent call last):
      File "/users/denolf/.local/wdnbashutils/virtualenvs/ewoks/bin/ewoks", line 6, in <module>
        sys.exit(main())
                 ^^^^^^
      File "/home/denolf/dev/ewoks-kit/ewoks/src/ewoks/__main__.py", line 301, in main
        return command_convert(cli_args, shell=shell)
               ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
      File "/home/denolf/dev/ewoks-kit/ewoks/src/ewoks/__main__.py", line 167, in command_convert
        convert_graph(
      File "/home/denolf/dev/ewoks-kit/ewoks/src/ewoks/bindings.py", line 217, in convert_graph
        graph = load_graph(source, inputs=inputs, **load_options)
                ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
      File "/home/denolf/dev/ewoks-kit/ewoks/src/ewoks/graph_cache.py", line 19, in wrapper
        return load_method(*args, **kw)
               ^^^^^^^^^^^^^^^^^^^^^^^^
      File "/home/denolf/dev/ewoks-kit/ewoks/src/ewoks/bindings.py", line 175, in load_graph
        return engine_api.deserialize_graph(
               ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
      File "/home/denolf/dev/ewoks-kit/ewoksorange/src/ewoksorange/engine.py", line 67, in deserialize_graph
        return load_graph(
               ^^^^^^^^^^^
      File "/home/denolf/dev/ewoks-kit/ewoksorange/src/ewoksorange/bindings/__init__.py", line 159, in load_graph
        return owscheme.ows_to_ewoks(
               ^^^^^^^^^^^^^^^^^^^^^^
      File "/home/denolf/dev/ewoks-kit/ewoksorange/src/ewoksorange/gui/workflows/owscheme.py", line 206, in ows_to_ewoks
        ows = read_ows(source)
              ^^^^^^^^^^^^^^^^
      File "/home/denolf/dev/ewoks-kit/ewoksorange/src/ewoksorange/gui/workflows/owscheme.py", line 606, in read_ows
        return _original_parse_ows_stream(source)
               ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
      File "/home/denolf/dev/orange-canvas-core/orangecanvas/scheme/readwrite.py", line 339, in parse_ows_stream
        doc = parse(stream)
              ^^^^^^^^^^^^^
      File "/users/denolf/.local/wdnbashutils/.pyenv/versions/3.12.11/lib/python3.12/xml/etree/ElementTree.py", line 1204, in parse
        tree.parse(source, parser)
      File "/users/denolf/.local/wdnbashutils/.pyenv/versions/3.12.11/lib/python3.12/xml/etree/ElementTree.py", line 558, in parse
        source = open(source, "rb")
                 ^^^^^^^^^^^^^^^^^^
    FileNotFoundError: [Errno 2] No such file or directory: 'map_1det.ows'
    

    Made an issue: #345.

  6. woutdenolf commented on Oct 6, 2026

    @woutdenolf
    Member

    This also fails:

    pip install --pre ewoksfluo pyqt5 ewoks
    
    ewoks-canvas
    
    # Manual actions in the GUI: Select example workflow and execute it
    
    2026-10-06 15:45:42,180:ERROR:orangecanvas.application.examples: Could not load examples from <importlib.metadata.PathDistribution object at 0x7f7e6ccca150>
    Traceback (most recent call last):
      File "/users/denolf/.local/wdnbashutils/virtualenvs/pybox_T1Gpks/lib/python3.12/site-packages/orangecanvas/application/examples.py", line 50, in workflows
        examples = ep.load()
                   ^^^^^^^^^
      File "/users/denolf/.local/wdnbashutils/.pyenv/versions/3.12.11/lib/python3.12/importlib/metadata/__init__.py", line 205, in load
        module = import_module(match.group('module'))
                 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
      File "/users/denolf/.local/wdnbashutils/.pyenv/versions/3.12.11/lib/python3.12/importlib/__init__.py", line 90, in import_module
        return _bootstrap._gcd_import(name[level:], package, level)
               ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
      File "<frozen importlib._bootstrap>", line 1387, in _gcd_import
      File "<frozen importlib._bootstrap>", line 1360, in _find_and_load
      File "<frozen importlib._bootstrap>", line 1331, in _find_and_load_unlocked
      File "<frozen importlib._bootstrap>", line 935, in _load_unlocked
      File "<frozen importlib._bootstrap_external>", line 999, in exec_module
      File "<frozen importlib._bootstrap>", line 488, in _call_with_frames_removed
      File "/users/denolf/.local/wdnbashutils/virtualenvs/pybox_T1Gpks/lib/python3.12/site-packages/orangecontrib/ewoksdemo/tutorials/__init__.py", line 6, in <module>
        raise RuntimeError("ewoksdemo is disabled")
    RuntimeError: ewoksdemo is disabled
    QCssParser::parseColorValue: Specified color without alpha value but alpha given: 'rgb 0, 0, 0, 100'
    -------------------------- AttributeError Exception ---------------------------
    Traceback (most recent call last):
      File "/users/denolf/.local/wdnbashutils/virtualenvs/pybox_T1Gpks/lib/python3.12/site-packages/ewoksfluo/gui/fit_widget.py", line 136, in _task_finished
        if task_future.succeeded():
           ^^^^^^^^^^^^^^^^^^^^^
    AttributeError: 'TaskFuture' object has no attribute 'succeeded'
    -------------------------------------------------------------------------------
    -------------------------- AttributeError Exception ---------------------------
    Traceback (most recent call last):
      File "/users/denolf/.local/wdnbashutils/virtualenvs/pybox_T1Gpks/lib/python3.12/site-packages/orangecontrib/ewoksfluo/categories/regrid/regrid.py", line 101, in _task_finished
        if task_future.succeeded():
           ^^^^^^^^^^^^^^^^^^^^^
    AttributeError: 'TaskFuture' object has no attribute 'succeeded'
    -------------------------------------------------------------------------------
    

    Installing the main branch fixes: AttributeError: 'TaskFuture' object has no attribute 'succeeded'

    The raise RuntimeError("ewoksdemo is disabled") was already reported by @abmajith . Could you take care of that one? Ticket ewoks-kit/ewoksorange#488

  7. woutdenolf commented on Oct 6, 2026

    @woutdenolf
    Member

    So I failed to even arrive at reproducing the issue but I think ewoks-kit/ewoksorange#419 + ewoks-kit/ewoksorange#422 solve the original problem with ewoks install of a .ows file.

    Edit: the problem is partially solved

    ewoks-canvas                       # saving the worklfow from the UI does not save the graph attributes
    ewoks convert test.ows tmp.ows     # this adds the graph attributes
    ewoks install tmp.ows              # this allows installing the .ows file
    

    So I close this ticket (.ows files can be installed) and the rest goes to other tickets:

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

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

No type

Fields

priority

None yet

progress

None yet

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions