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

Fetch job by ref instead of commit #14

Closed
tarajdactyl opened this issue May 27, 2020 · 0 comments · Fixed by #15
Closed

Fetch job by ref instead of commit #14

tarajdactyl opened this issue May 27, 2020 · 0 comments · Fixed by #15

Comments

@tarajdactyl
Copy link
Contributor

Currently art resolves ref to its commit hash and then queries jobs using the sha field.

This can result in incorrect results. In particular, consider a policy of only retaining artifacts for tags and latest:

job id commit hash ref artifacts
2 abcdefdeadbeef master (deleted)
1 abcdefdeadbeef v1.0.0 artifacts.zip

in this case, fetching aritfacts for ref: v1.0.0 results in resolving v1.0.0 to abcdefdeadbeef and then getting the last successful job, (2), whose artifacts have been deleted.

If, on the other hand, the job was queried by ref, it would have returned 1.

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.

1 participant