Skip to content

AttributeError: runtime_dependencies #2744

Description

@sentry

Sentry Issue: PCKT-002-PACKIT-SERVICE-CPY

AttributeError: 'Munch' object has no attribute 'runtime_dependencies'
  File "__init__.py", line 116, in __getattr__
    return object.__getattribute__(self, k)

KeyError: 'runtime_dependencies'
  File "__init__.py", line 119, in __getattr__
    return self[k]

AttributeError: runtime_dependencies
(2 additional frame(s) were not displayed)
...
  File "packit_service/worker/helpers/build/copr_build.py", line 910, in create_or_update_copr_project
    self.api.copr_helper.create_or_update_copr_project(
  File "backoff/_sync.py", line 105, in retry
    ret = target(*args, **kwargs)
  File "packit/copr_helper.py", line 301, in create_or_update_copr_project
    fields_to_change = self.get_fields_to_change(
  File "packit/copr_helper.py", line 481, in get_fields_to_change
    and copr_proj.runtime_dependencies != runtime_dependencies
  File "__init__.py", line 121, in __getattr__
    raise AttributeError(k)

Result of #2720

Currently set runtime_dependencies needs to be handled in a different way:

  1. Copr exposes runtime_dependencies during creation and editing, but runtime_deps as a getter…
  2. said “getter” converts the delimited string into list (uses set to get rid of duplicates, n.b. Python’s implementation of set() is hash set, i.e., not even the order of the elements is guaranteed, this should be ideally also handled on Copr’s side)

Metadata

Metadata

Assignees

Labels

area/coprRelated to the Copr integrationcomplexity/single-taskRegular task; should be done within daysimpact/highAffects a lot of userskind/bugAn unexpected problem or behavior

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions