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

Inconsistent service errors when working on non-existing projects #2787

Closed
lorenzo-cavazzi opened this issue Mar 28, 2022 · 0 comments · Fixed by #2789
Closed

Inconsistent service errors when working on non-existing projects #2787

lorenzo-cavazzi opened this issue Mar 28, 2022 · 0 comments · Fixed by #2789
Assignees

Comments

@lorenzo-cavazzi
Copy link
Member

Describe the bug
When working with service APIs requiring a project URL, and the provided URL doesn't refer to an existing project, the first time we get a reasonable error (e.g. UserRepoUrlInvalidError), but the following invocations return different errors (e.g. UserNonRenkuProjectError or even IntermittentTimeoutError).

To Reproduce
Try with any API, like GET /config.show providing a non-existing git_url as parameter.

Expected behavior
The error should always be the same, probably UserRepoUrlInvalidError or another invalid repository error.

Additional context
It seems that the cached folder of the project isn't cleaned up properly. The second time the API is invoked, the same folder is checked and the error changes for that reason. The folder is usually empty, usually with a <project_name>.lock file and occasionally also a <something>semapthore.00.lock file.

Probably, cache.project_clone should remove the folder if cloning fails because of a non-existing repo/URL.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
1 participant