Skip to content

Debugging

Marco Donadoni edited this page Apr 11, 2024 · 9 revisions

Contents

  1. Using wdb

Using wdb

This page provides example how to debug REANA cluster component internally, e.g. see the incoming API requests coming through micro services, thanks to wdb.

1. The REANA cluster should be created in the debugging mode, which allows for live code mounting and live code reloads:

$ reana-dev cluster-create --mode=debug

2. The REANA cluster components that you would like to debug should be build also in debugging mode. It could be one component only, or the full cluster:

$ reana-dev docker-build -b DEBUG=1 -c reana-server
$ reana-dev kind-load-docker-image -c reana-server

3. Deploy the cluster:

$ reana-dev cluster-deploy --admin-email [email protected] --admin-password mysecretpassword --mode debug

4. Add a breakpoint (using wdb) for example in the list workflows endpoint:

    """
+   import wdb; wdb.set_trace()
    try:

5. Call reana-client list from the command line:

$ reana-client list

6. Open the debugging session in your web browser:

$ firefox http://localhost:31984

Debugging