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

AttributeError: 'UUID' object has no attribute 'encode' #3921

Closed
sentry-io bot opened this issue Jan 25, 2023 · 2 comments
Closed

AttributeError: 'UUID' object has no attribute 'encode' #3921

sentry-io bot opened this issue Jan 25, 2023 · 2 comments
Assignees
Labels
P0 - critical Priority: Release blocker or regression

Comments

@sentry-io
Copy link

sentry-io bot commented Jan 25, 2023

Sentry Issue: STUDIO-FYJ

AttributeError: 'UUID' object has no attribute 'encode'
(5 additional frame(s) were not displayed)
...
  File "django_celery_results/managers.py", line 43, in _inner
    return fun(*args, **kwargs)
  File "django_celery_results/managers.py", line 173, in store_result
    obj.save(using=using)
  File "contentcuration/models.py", line 2481, in save
    self.set_signature()
  File "contentcuration/models.py", line 2475, in set_signature
    self.signature = generate_task_signature(self.task_name, task_kwargs=self.task_kwargs, channel_id=self.channel_id)
  File "contentcuration/utils/celery/tasks.py", line 88, in generate_task_signature
    md5.update((channel_id or '').encode('utf-8'))

Pool callback raised exception: "AttributeError(\"'UUID' object has no attribute 'encode'\")"
@bjester bjester self-assigned this Jan 25, 2023
@bjester bjester added P0 - critical Priority: Release blocker or regression labels Jan 25, 2023
marsian83 added a commit to marsian83/studio that referenced this issue Jan 25, 2023
@bjester
Copy link
Member

bjester commented Jan 25, 2023

I was hoping that there wasn't a need for set_signature on the TaskResult model. This perhaps came about from an enqueued task right before deploy that didn't have a signature to begin with. Good news is that the presence of this bug gives us insight into how often it occurs, if at all, and if not we can remove the model handling

@rtibbles
Copy link
Member

rtibbles commented Feb 2, 2023

Fixed in #3934

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
P0 - critical Priority: Release blocker or regression
Projects
None yet
Development

No branches or pull requests

2 participants