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

Need better error message when a CommandLineTool is submitted #582

Open
mexanick opened this issue Nov 15, 2023 · 3 comments · May be fixed by #587
Open

Need better error message when a CommandLineTool is submitted #582

mexanick opened this issue Nov 15, 2023 · 3 comments · May be fixed by #587

Comments

@mexanick
Copy link

Description

CWL Viewer cannot find a workflow in gitlab (self-hosted) repository.

Expected Behavior

CWL Viewer shall find and parse the workflow correctly

Actual Behavior

Error: The workflow could not be found within the repository

Possible Fix

Must be related to #424

Steps to Reproduce

  1. Go to the https://view.commonwl.org/ and paste the address of the repository https://gitlab.cta-observatory.org/cta-computing/dpps/dpps-workflows.git as URL to workflow.
  2. Paste this commit hash: 76f7c25c0472da23b7e0bfe9f2c18ab6bc369c9d to the "Branch Name/Commit ID" field
  3. Now, the workflow that has been previously registered (long time ago) works: /workflows/calibpipe/uc-cp-001.cwl
  4. However, the other workflow (that has not been registered before) doesn't: /workflows/datapipe/uc-dp-XXX.cwl

Context

I can't render my workflows

Your Environment

  • Version used:
  • Environment name and version (e.g. Chrome 39, Java 17):
@mr-c
Copy link
Member

mr-c commented Nov 15, 2023

Error reported in the webapp

Error: The workflow could not be found within the repository

From the logs

2023-11-15 14:59:15,556 INFO  [http-nio-8080-exec-6] org.commonwl.view.workflow.WorkflowService: Time has expired for caching, checking commits for workflow 7af8dede-2258-4b57-aaa7-f83f63f88342
2023-11-15 14:59:15,895 INFO  [http-nio-8080-exec-6] org.commonwl.view.workflow.WorkflowService: Current: 9495f778ed203c82c554144f9ae2dc7e3b66378b, HEAD: 9495f778ed203c82c554144f9ae2dc7e3b66378b for workflow 7af8dede-2258-4b57-aaa7-f83f63f88342
2023-11-15 14:59:28,484 ERROR [task-1776] org.commonwl.view.cwl.CWLToolRunner: Jena query exception for workflow c37d89d2-44cd-4971-a21d-5844d8540dff
org.apache.jena.sparql.engine.http.QueryExceptionHTTP: HTTP 503 error making the query: Service Unavailable

I restarted the service and now I get

cwl-docker-spring-1    | 2023-11-15 15:07:20,061 WARN  [http-nio-8080-exec-10] org.commonwl.view.workflow.WorkflowController: git.notFound WorkflowForm [url=https://gitlab.cta-observatory.org/cta-computing/dpps/dpps-workflows.git, branch=main, path=/workflows/datapipe/uc-dp-XXX.cwl]
cwl-docker-spring-1    | org.commonwl.view.workflow.WorkflowNotFoundException: null
cwl-docker-spring-1    | 	at org.commonwl.view.cwl.CWLService.parseWorkflowNative(CWLService.java:212)
cwl-docker-spring-1    | 	at org.commonwl.view.cwl.CWLService.parseWorkflowNative(CWLService.java:256)

Looking at the code

// Packed ID specified but was not found
if (!cwlService.isPacked(workflowFile.toFile())) {
throw new WorkflowNotFoundException();

But https://gitlab.cta-observatory.org/cta-computing/dpps/dpps-workflows/-/blob/main/workflows/datapipe/uc-dp-XXX.cwl?ref_type=heads is not a packed workflow. In fact, it isn't a workflow, it is a CommandLineTool.

@mexanick Thank you for your report. This service is for visualizing CWL Workflows, not CommandLineTools. We should have given a better error message in this instance.

@mexanick
Copy link
Author

Ah, I see! This explains things! Right, can you please improve the error message? :)

@kinow
Copy link
Member

kinow commented Nov 15, 2023

We should have given a better error message in this instance.

+1

@mr-c mr-c changed the title Impossible to add workflows to render Need better error message when a CommandLineTool is submitted Nov 16, 2023
@mr-c mr-c linked a pull request Nov 16, 2023 that will close this issue
7 tasks
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants