#3997 host.refuseTask failure
Closed: Fixed by tkopecek. Opened by mikem.

This is due to a typo. Fix forthcoming

  File "/usr/lib/python3.11/site-packages/koji/util.py", line 271, in call_with_argcheck
    return func(*args, **kwargs)
           ^^^^^^^^^^^^^^^^^^^^^
  File "/usr/lib/python3.11/site-packages/kojihub/kojihub.py", line 14765, in refuseTask
    scheduler.set_refusal(host.id, tinfo['id'], soft=soft, msg=msg, by_host=True)
  File "/usr/lib/python3.11/site-packages/kojihub/scheduler.py", line 101, in set_refusal
    upsert.execute()
  File "/usr/lib/python3.11/site-packages/kojihub/db.py", line 444, in execute
    return _dml(str(self), self.data)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/lib/python3.11/site-packages/kojihub/db.py", line 219, in _dml
    c.execute(operation, values, log_errors=log_errors)
  File "/usr/lib/python3.11/site-packages/kojihub/db.py", line 148, in execute
    ret = self.cursor.execute(operation, parameters)
          ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
psycopg2.errors.ForeignKeyViolation: insert or update on table "scheduler_task_refusals" violates foreign key constraint "scheduler_task_refusals_host_id_fkey"
DETAIL:  Key (host_id)=(12216) is not present in table "host".

Metadata Update from @mikem:
- Custom field Size adjusted to small
- Issue priority set to: High (was: Normal)
- Issue set to the milestone: 1.34.1
- Issue tagged with: easyfix

Commit 167ee017 fixes this issue

Commit 2a6e18fa fixes this issue

Metadata Update from @tkopecek:
- Issue tagged with: testing-ready

Metadata Update from @relias-redhat:
- Issue tagged with: testing-done

This issue has been migrated to Fedora Forge:
https://forge.fedoraproject.org/koji/koji/issues/3997

Please continue any further discussion there.

Metadata
Related Pull Requests