1.0.0 • Published 6 days ago

dotdata_widgets v1.0.0

Weekly downloads
-
License
UNLICENSED
Repository
github
Last release
6 days ago

Dotdata Widgets

Dotdata widgets consist of a NodeJS library and a python module.

Building the nodejs part

In order to build the nodejs part of dotdata widgets - follow the make targets defined in the Makefile in this directory.

make build_js

There is an alias for this command in the root-level Makefile:

make -C ../../ build_widgets_js_for_iff

NOTE: this command might not work if on platforms other than linux. The docker container in which the commands are executed is based on node:18.15 container, which assumes that the working user has UID=1000. Calling it on MacOS may produce artifacts with invalid ownership.

In order to build the nodejs package without the docker, make sure you've provisioned your local environment as described in the docker/npm/Dockerfile. Especially make sure that you have:

  • node in version >=18
  • yarn (npm install yarn -g)
  • python >=3.8
  • jupyterlab

Then you may call:

make -C ../../ build_js_without_docker

Publishing the js part of Dotdata Widgets

DO NOT publish the nodejs package unless you're sure what you're doing!

Dotdata Widgets are published in a public npm repository. You can browse the published packages at https://www.npmjs.com/package/dotdata_widgets

Dotdata widgets are published together with the dotdata wheel by the jenkins job, which calls make publish_iff from the root-level Makefile. This command refers to the npm publish command, which utilises credentials to npm registry defined in .npmrc

Interactive development and testing

WARNING: THERE ARE NO AUTOMATED TESTS OF DOTDATA WIDGETS (neither JS nor python part).

Dotdata widgets can be tested manually in a jupyter notebook.

In order to do so do the following:

  • Prune local virtual env:
    make -C ../../ prune_iff_test_env
    This command cleans the venv directory and deletes pre-existing artifacts.
  • Install dotdata in dev mode in the local virtual env:
    make -C ../../ prepare_iff_interactive_dev_env
    This command installs jupyterlab, installs dotdata in --editable mode, and calls jupyter labextension develop --overwrite ${PATH_TO_DOTDAT_WIDGETS}. Although it make take up to 20 minutes, it has to be called only once.
  • Launch widgets compilation server:
    make -C ../../ _run_yarn_watch_compilation_of_dotdata_widgets
    • NOTE: this command requires node and yarn to be installed in your environment.
    • Also, it fails if prepare_iff_interactive_dev_env wasn't called before.
    • This command spawns a server that watches for changes in the ts files and recompiles them on the fly.
    • Run it in separate terminal.
    • A single recompilation may take up to a minute, so be patient.
  • Launch jupyter lab:
    make -C ../../ _start_jupyterlab
    • This command spawns a jupyter-lab server. Run it in separate terminal.
    • It also opens a browser window with a jupyter lab workspace.
  • Open a notebook (e.g. examples/introduction.ipynb) and work with your widgets.

When developing widgets in interactive mode, keep in mind that:

  • you have to reload browser caches in order to force it to load re-compiled *.js files.
  • you have to restart notebook's kernel in order to load modified python modules.
1.2.0-b3.dev119

6 days ago

1.2.0-b3.dev115

7 days ago

1.2.0-b2.post3

6 days ago

1.2.0-b3.dev112

10 days ago

1.2.0-b3.dev109

11 days ago

1.2.0-b3.dev108

12 days ago

1.2.0-b3.dev104

13 days ago

1.2.0-b3.post1

12 days ago

1.2.0-b2.post2

13 days ago

1.2.0-b3.dev100

14 days ago

1.2.0-b3.dev93

15 days ago

1.2.0-b3.dev92

16 days ago

1.2.0-b3.dev90

18 days ago

1.2.0-b3.dev86

19 days ago

1.2.0-b3

19 days ago

1.2.0-b3.dev80

20 days ago

1.2.0-b3.dev72

21 days ago

1.2.0-b3.dev64

22 days ago

1.2.0-b3.dev63

24 days ago

1.2.0-b3.dev59

25 days ago

1.2.0-b3.dev50

26 days ago

1.2.0-b3.dev44

27 days ago

1.2.0-b3.dev41

28 days ago

1.2.0-b3.dev39

1 month ago

1.2.0-b3.dev35

1 month ago

1.2.0-b2.post1

1 month ago

1.2.0-b2

1 month ago

12.2.0-b1

1 month ago

0.0.0-a1

1 month ago

1.1.0

2 months ago

1.2.0-b1

2 months ago

1.1.0-b10.post1

2 months ago

1.1.0-b10

3 months ago

0.0.0-dev.0.mk5

4 months ago

0.0.0-dev.0.mk3

4 months ago

1.1.0-b9.post2

4 months ago

0.0.0-dev.0.mk2

4 months ago

0.0.0-dev.0.mk-1

4 months ago

0.0.0-dev.0.mk1

4 months ago

1.1.0-b9.post1

4 months ago

1.1.0-b9

4 months ago

1.1.0-b8.post2

5 months ago

1.1.0-b8.post1

5 months ago

1.1.0-b8

5 months ago

1.1.0-b6

6 months ago

1.1.0-b5

7 months ago

1.1.0-b4

8 months ago

1.1.0-b3

8 months ago

1.1.0-b7

5 months ago

0.5.0

9 months ago

1.1.0-a1

8 months ago

0.3.4

10 months ago

0.4.1

10 months ago

1.0.0

9 months ago

0.4.0

10 months ago

0.3.3

11 months ago

0.0.129

12 months ago

0.0.123

12 months ago

0.0.121

12 months ago

0.3.0

12 months ago

0.3.2

11 months ago

0.3.1

12 months ago

0.0.130

12 months ago

0.0.28

1 year ago

0.0.29

1 year ago

0.2.1

1 year ago

0.2.0

1 year ago

0.2.3

1 year ago

0.2.2

1 year ago

0.1.20

1 year ago

0.1.10

1 year ago

0.0.0

1 year ago

0.1.8

1 year ago

0.1.7

1 year ago

0.1.9

1 year ago

0.1.6

1 year ago

0.1.4

1 year ago

0.1.5

1 year ago

0.1.3

1 year ago

0.1.2

1 year ago

0.1.1

1 year ago

0.1.0

1 year ago