Skip to content
Snippets Groups Projects

Fix setting job platforms when props are empty

Merged Cal Pratt requested to merge cpratt34/fix-empty-platform-prop-setting into master

There is a bug here when the platform_requirements dict is empty. The line

select(PlatformEntry.key, PlatformEntry.value).where(or_(*conditions))

Becomes:

select(PlatformEntry.key, PlatformEntry.value).where(or_(*[]))

Which is the same as

select(PlatformEntry.key, PlatformEntry.value)

This leads to a job with no platform properties being assigned them all...

Quick fix is to short circuit on empty values.

Merge request reports

Loading
Loading

Activity

Filter activity
  • Approvals
  • Assignees & reviewers
  • Comments (from bots)
  • Comments (from users)
  • Commits & branches
  • Edits
  • Labels
  • Lock status
  • Mentions
  • Merge request status
  • Tracking
Please register or sign in to reply
Loading