Skip to content

Widget calls requiring browser context hang during testing #99

Open

Description

@alex-remedios

Describe the bug
The ITKWidgets project cannot test a notebooks that calls a widget which is only initialised when a browser is present

To Reproduce
See InsightSoftwareConsortium/itkwidgets#587

Expected behavior
Can call the initialised widget API successfully

Additional context
This issue occurs because nbclient is an alternative to running a full jupyter web app + server (architecture diagram) and doesn't run a browser context.

Problem cell example

image = itk.image_from_array(array)
print('Dimension', image.GetImageDimension())
print('Components', image.GetNumberOfComponentsPerPixel())

from ipynb.

Activity

  1. changed the title [-]Widgets calls requiring browser context hang during testing[/-] [+]Widget calls requiring browser context hang during testing[/+] on Feb 16, 2023
  2. alex-remedios commented on Mar 10, 2023

    @alex-remedios
    MemberAuthor

    This repo has a pretty advanced setup using Selenium's python APIs @thewtex you can see that they actually test the widget's functionality (not just load it).

  3. thewtex commented on Apr 20, 2023

    @thewtex

    @alex-treebeard here is a high level architecture that aims to:

    1. Provide the needed JavaScript, WebGL context
    2. Be simple, requiring relatively little code
    3. Work with the existing nbmake code

    References:

  4. added
    bug
    enhancement
    on Apr 26, 2023
  5. alex-remedios commented on Oct 5, 2023

    @alex-remedios
    MemberAuthor
  6. thewtex commented on Oct 20, 2023

    @thewtex

    Interesting! It does not look like they are running the notebooks in an actual browser, though, from what I can tell.

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

    bugenhancement

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions