warn about potentially missing patches in --new-pr#3759
warn about potentially missing patches in --new-pr#3759akesandgren merged 5 commits intoeasybuilders:developfrom
Conversation
cbcbe1e to
78ecc14
Compare
|
What about --new-pr on easyconfig that uses patch files that already exist in the repo? |
c2b9109 to
6a543d7
Compare
6a543d7 to
799c3b4
Compare
right, addressed in 799c3b4 |
| for ec, ec_path in zip(file_info['ecs'], file_info['paths_in_repo']): | ||
| for patch in ec.asdict()['patches']: | ||
| if patch not in paths['patch_files'] and not os.path.isfile(os.path.join(os.path.dirname(ec_path), patch)): | ||
| print_warning("new patch %s, referenced by %s, is not included in this PR" % (patch, ec.filename())) |
There was a problem hiding this comment.
perhaps "new patch file"?? but do as you please.
|
All in all, this looks good and it's something I could have benefited from multiple times... ooohh so many times... |
|
oops hit the wrong button |
|
Change to non-draft? |
|
@akesandgren wait, the tests requiring github token are failing |
|
I have one more question, is the file_info['ecs'] and file_info['paths_in_repo'] guaranteed to match in number of elements? |
|
that's a good point - I'd say yes ( easybuild-framework/easybuild/framework/easyconfig/easyconfig.py Lines 2402 to 2442 in 23071bd copy_easyconfigs itself (
), but this could probably be made clearer and/or more robust...
|
|
Have you run the framework test suite after this commit? |
I ran the (50) tests that require the github token locally, yes, they all pass now |
|
Going in, thanks @migueldiascosta! |
requested in #1674, at least
not sure if it always makes sense to automatically add patches, but we can at least warn about potentially missing ones...