Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Delivery: Fix representation entity data #977

Merged
merged 2 commits into from
Oct 29, 2024

Conversation

iLLiCiTiT
Copy link
Member

Changelog Description

Fixed bug caused by ayon api which did not fully convert representation entity data in get_representations_hierarchy.

Additional info

The issue is already fixed in newer version of ayon api 1.0.10 (AYON launcher 1.1.1). But added this fix for those who still use older versions.

Traceback

Traceback (most recent call last):
  File "C:\Users\...\AppData\Local\Ynput\AYON\addons\core_1.0.3\ayon_core\plugins\load\delivery.py", line 210, in deliver
    get_representations_delivery_template_data(
  File "C:\Users\...\AppData\Local\Ynput\AYON\addons\core_1.0.3\ayon_core\pipeline\delivery.py", line 386, in get_representations_delivery_template_data
    template_data.update(copy.deepcopy(general_template_data))
AttributeError: 'str' object has no attribute 'update'

Testing notes:

  1. Use AYON launcher 1.1.0 to run delivery action.
  2. It should not fail with error above.

@iLLiCiTiT iLLiCiTiT self-assigned this Oct 29, 2024
@iLLiCiTiT iLLiCiTiT added the type: bug Something isn't working label Oct 29, 2024
@ynbot ynbot added the size/XS label Oct 29, 2024
Copy link
Collaborator

@BigRoy BigRoy left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Didn't face the issue myself so couldn't confirm it fixes it - but it makes sense.

@@ -383,6 +383,13 @@ def get_representations_delivery_template_data(
continue

template_data = repre_entity["context"]
# Bug in 'ayon_api', 'get_representations_hierarchy' did not fully
# convert representation entity. Fixed in 'ayon_api' 1.0.10 .
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
# convert representation entity. Fixed in 'ayon_api' 1.0.10 .
# convert representation entity. Fixed in 'ayon_api' 1.0.10.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Feels weird to have dot after version with dots.

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Haha, I understand - but as far as I know that's how grammar works. 👼

@iLLiCiTiT iLLiCiTiT merged commit 86e4c42 into develop Oct 29, 2024
1 check passed
@iLLiCiTiT iLLiCiTiT deleted the bugfix/delivery-representation-conversion-fix branch October 29, 2024 10:32
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
size/XS type: bug Something isn't working
Projects
Archived in project
Development

Successfully merging this pull request may close these issues.

3 participants