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

Failures while running tests are reported as branch being out-of-date #35

Open
nwiltsie opened this issue Apr 18, 2024 · 2 comments
Open

Comments

@nwiltsie
Copy link
Member

From https://github.com/uclahs-cds/pipeline-call-mtSNV/pull/165#issuecomment-2065479844.

The Nextflow run died due to a missing file, and the actions/upload-artifact step complained that there were no files to upload.

In the summary step, the command to check if files changed between the merge commit and the branch tip failed - not because there were differences, but because there were no files to be checked:

2024-04-18T23:24:31.6649211Z [command]/usr/bin/git ls-files --modified -- configtest*.json **/configtest*.json
2024-04-18T23:24:31.6802962Z [command]/usr/bin/git diff-tree HEAD cc2bcea5d27ae44814dc88f8f97d8dac104f680b --exit-code --name-status -- 
2024-04-18T23:24:31.6843427Z fatal: empty string is not a valid pathspec. please use . instead if you meant to match all paths
2024-04-18T23:24:32.4297973Z ##[error]Need to merge tests

Weirdly I can't replicate that error locally - there's something odd going on with that.

$ git diff-tree HEAD cc2bcea5d27ae44814dc88f8f97d8dac104f680b --exit-code --name-status -- && echo "No failure"
No failure
@nwiltsie
Copy link
Member Author

Ah, nevermind, the workflow is explicitly passing an empty string - nothing odd going on with that.

$ git diff-tree HEAD cc2bcea5d27ae44814dc88f8f97d8dac104f680b --exit-code --name-status -- ""
fatal: empty string is not a valid pathspec. please use . instead if you meant to match all paths

@nwiltsie
Copy link
Member Author

nwiltsie commented Dec 9, 2024

This came up again with uclahs-cds/pipeline-call-sSV#187 (comment). Here was the chain of events:

gitGraph
    commit id: "  "
    commit id: "   "
    branch mmootor-filter-gridss
    checkout mmootor-filter-gridss
    commit id: "Add required parameter"
    checkout main
    branch nwiltsie-modernize
    commit id: "Tests updated"
    checkout main
    merge nwiltsie-modernize
    checkout mmootor-filter-gridss
    merge main type: REVERSE id: "Tests failed"
Loading

When I merged main into mmootor-filter-gridss, the tests failed due to the addition of a new required parameter, but the workflow reported that main needed to be merged...

I'm not sure if the changes on nwiltsie-modernize were relevant at all - I don't remember the specifics of how the "need to merge main" check is done.

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

No branches or pull requests

1 participant