packit-service icon indicating copy to clipboard operation
packit-service copied to clipboard

Tests triggered even if labels are absent

Open majamassarini opened this issue 1 year ago • 1 comments

@lsm5 reported two PRs first and second where packit triggered tests even though labels were absent (and the other way around in the first link).

Looking at the logs (for the second link) seems like we selected a job config even though the release label was present in the PR and the config required it absent:

[2024-12-10 12:59:08,265: INFO/MainProcess] task.steve_jobs.process_message[e46e6af3-8c4d-4ded-8bba-a4a979c4e4b7] About to check whether PR labels in PR 24747 match to the labels configuration (label.present: [], label.absent: ['release'])
[2024-12-10 12:59:08,376: INFO/MainProcess] task.steve_jobs.process_message[f24cd144-3404-4bfa-97fa-2b4c4402ff6a] About to check whether PR labels in PR 24747 match to the labels configuration (label.present: [], label.absent: ['release'])
[2024-12-10 12:59:08,537: INFO/MainProcess] task.steve_jobs.process_message[e46e6af3-8c4d-4ded-8bba-a4a979c4e4b7] Labels on PR: ['approved', 'do-not-merge/work-in-progress', 'release-note-none', 'release']
[2024-12-10 12:59:08,545: INFO/MainProcess] task.steve_jobs.process_message[e46e6af3-8c4d-4ded-8bba-a4a979c4e4b7] About to check whether PR labels in PR 24747 match to the labels configuration (label.present: ['release'], label.absent: [])
[2024-12-10 12:59:08,608: INFO/MainProcess] task.steve_jobs.process_message[f24cd144-3404-4bfa-97fa-2b4c4402ff6a] Labels on PR: ['approved', 'do-not-merge/work-in-progress', 'release-note-none', 'release']
[2024-12-10 12:59:08,619: INFO/MainProcess] task.steve_jobs.process_message[f24cd144-3404-4bfa-97fa-2b4c4402ff6a] About to check whether PR labels in PR 24747 match to the labels configuration (label.present: ['release'], label.absent: [])
[2024-12-10 12:59:08,732: INFO/MainProcess] task.steve_jobs.process_message[e46e6af3-8c4d-4ded-8bba-a4a979c4e4b7] Labels on PR: ['approved', 'do-not-merge/work-in-progress', 'release-note-none', 'release']
[2024-12-10 12:59:08,744: DEBUG/MainProcess] task.steve_jobs.process_message[e46e6af3-8c4d-4ded-8bba-a4a979c4e4b7] Matching handlers: {<class 'packit_service.worker.handlers.copr.CoprBuildStartHandler'>}


[2024-12-10 12:59:08,764: INFO/MainProcess] task.steve_jobs.process_message[e46e6af3-8c4d-4ded-8bba-a4a979c4e4b7] About to check whether PR labels in PR 24747 match to the labels configuration (label.present: [], label.absent: ['release'])
[2024-12-10 12:59:08,816: INFO/MainProcess] task.steve_jobs.process_message[f24cd144-3404-4bfa-97fa-2b4c4402ff6a] Labels on PR: ['approved', 'do-not-merge/work-in-progress', 'release-note-none', 'release']
[2024-12-10 12:59:08,829: DEBUG/MainProcess] task.steve_jobs.process_message[f24cd144-3404-4bfa-97fa-2b4c4402ff6a] Matching handlers: {<class 'packit_service.worker.handlers.copr.CoprBuildStartHandler'>}


[2024-12-10 12:59:08,852: INFO/MainProcess] task.steve_jobs.process_message[f24cd144-3404-4bfa-97fa-2b4c4402ff6a] About to check whether PR labels in PR 24747 match to the labels configuration (label.present: [], label.absent: ['release'])
[2024-12-10 12:59:08,950: INFO/MainProcess] task.steve_jobs.process_message[e46e6af3-8c4d-4ded-8bba-a4a979c4e4b7] Labels on PR: ['approved', 'do-not-merge/work-in-progress', 'release-note-none', 'release']
[2024-12-10 12:59:08,960: INFO/MainProcess] task.steve_jobs.process_message[e46e6af3-8c4d-4ded-8bba-a4a979c4e4b7] About to check whether PR labels in PR 24747 match to the labels configuration (label.present: ['release'], label.absent: [])
[2024-12-10 12:59:09,085: INFO/MainProcess] task.steve_jobs.process_message[f24cd144-3404-4bfa-97fa-2b4c4402ff6a] Labels on PR: ['approved', 'do-not-merge/work-in-progress', 'release-note-none', 'release']
[2024-12-10 12:59:09,094: INFO/MainProcess] task.steve_jobs.process_message[f24cd144-3404-4bfa-97fa-2b4c4402ff6a] About to check whether PR labels in PR 24747 match to the labels configuration (label.present: ['release'], label.absent: [])
[2024-12-10 12:59:09,194: INFO/MainProcess] task.steve_jobs.process_message[e46e6af3-8c4d-4ded-8bba-a4a979c4e4b7] Labels on PR: ['approved', 'do-not-merge/work-in-progress', 'release-note-none', 'release']
[2024-12-10 12:59:09,220: DEBUG/MainProcess] task.steve_jobs.process_message[e46e6af3-8c4d-4ded-8bba-a4a979c4e4b7]

But it could also be related with #2669 because it is the copr_build_start_handler to set the testing-farm check

[2024-12-10 12:59:37,272: DEBUG/MainProcess] task.run_copr_build_start_handler[db535663-3c37-470f-88d1-c57b275452c5] Setting Github status check 'in_progress' for check 'testing-farm:fedora-rawhide-aarch64:dev': RPM build is in progress...

majamassarini avatar Dec 10 '24 14:12 majamassarini

@lsm5 reported two PRs first and second where packit triggered tests even though labels were absent (and the other way around in the first link).

In the latest run of https://github.com/containers/podman/pull/24369 I see now that the tests not meant to run are not run as intended, but simply listed. I guess it'd be great if we could hide the untriggered ones from the list entirely.

lsm5 avatar Dec 11 '24 15:12 lsm5