You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I understand that AWX is open source software provided for free and that I might not receive a timely response.
I am NOT reporting a (potential) security vulnerability. (These should be emailed to [email protected] instead.)
Bug Summary
After upgrading to 24.3.1, api/v2/workflow_job_templates//access_list/ started returning 500. The error message from the web component is:
2024-05-24 08:20:55,223 ERROR [c35f22e3c31d410fbb10d98bbaea2b27] django.request Internal Server Error: /api/v2/workflow_job_templates/3125/access_list/
Traceback (most recent call last):
File "/var/lib/awx/venv/awx/lib64/python3.11/site-packages/django/core/handlers/exception.py", line 55, in inner
response = get_response(request)
^^^^^^^^^^^^^^^^^^^^^
File "/var/lib/awx/venv/awx/lib64/python3.11/site-packages/django/core/handlers/base.py", line 197, in _get_response
response = wrapped_callback(request, *callback_args, **callback_kwargs)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/lib64/python3.11/contextlib.py", line 81, in inner
return func(*args, **kwds)
^^^^^^^^^^^^^^^^^^^
File "/var/lib/awx/venv/awx/lib64/python3.11/site-packages/django/views/decorators/csrf.py", line 56, in wrapper_view
return view_func(*args, **kwargs)
^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/var/lib/awx/venv/awx/lib64/python3.11/site-packages/django/views/generic/base.py", line 104, in view
return self.dispatch(request, *args, **kwargs)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/var/lib/awx/venv/awx/lib64/python3.11/site-packages/awx/api/generics.py", line 339, in dispatch
return super(APIView, self).dispatch(request, *args, **kwargs)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/var/lib/awx/venv/awx/lib64/python3.11/site-packages/rest_framework/views.py", line 509, in dispatch
response = self.handle_exception(exc)
^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/var/lib/awx/venv/awx/lib64/python3.11/site-packages/rest_framework/views.py", line 469, in handle_exception
self.raise_uncaught_exception(exc)
File "/var/lib/awx/venv/awx/lib64/python3.11/site-packages/rest_framework/views.py", line 480, in raise_uncaught_exception
raise exc
File "/var/lib/awx/venv/awx/lib64/python3.11/site-packages/rest_framework/views.py", line 506, in dispatch
response = handler(request, *args, **kwargs)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/var/lib/awx/venv/awx/lib64/python3.11/site-packages/rest_framework/generics.py", line 203, in get
return self.list(request, *args, **kwargs)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/var/lib/awx/venv/awx/lib64/python3.11/site-packages/rest_framework/mixins.py", line 43, in list
return self.get_paginated_response(serializer.data)
^^^^^^^^^^^^^^^
File "/var/lib/awx/venv/awx/lib64/python3.11/site-packages/rest_framework/serializers.py", line 795, in data
ret = super().data
^^^^^^^^^^^^
File "/var/lib/awx/venv/awx/lib64/python3.11/site-packages/rest_framework/serializers.py", line 249, in data
self._data = self.to_representation(self.instance)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/var/lib/awx/venv/awx/lib64/python3.11/site-packages/rest_framework/serializers.py", line 713, in to_representation
return [
^
File "/var/lib/awx/venv/awx/lib64/python3.11/site-packages/rest_framework/serializers.py", line 714, in <listcomp>
self.child.to_representation(item) for item in iterable
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/var/lib/awx/venv/awx/lib64/python3.11/site-packages/awx/api/serializers.py", line 2884, in to_representation
old_role = get_role_from_object_role(new_role)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/var/lib/awx/venv/awx/lib64/python3.11/site-packages/awx/main/models/rbac.py", line 605, in get_role_from_object_role
return getattr(object_role.content_object, role_name)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
AttributeError: 'WorkflowJobTemplate' object has no attribute 'approve_role'
AWX version
24.3.1
Select the relevant components
UI
UI (tech preview)
API
Docs
Collection
CLI
Other
Installation method
kubernetes
Modifications
no
Ansible version
No response
Operating system
No response
Web browser
No response
Steps to reproduce
Find or create a workflow template to assign approval permission to some teams.
Hit api/v2/workflow_job_templates//access_list/ API for the same workload response should have status 500
Expected results
api/v2/workflow_job_templates//access_list/ API should return all teams/users that has permissions
Actual results
The request fails due to an internal error.
Additional information
A similar API(teams//roles) that returns permissions from a team perspective works fine, it looks like authorization works OK as well. Users can still take action on the workflows for which they have permission.
The text was updated successfully, but these errors were encountered:
Please confirm the following
[email protected]
instead.)Bug Summary
After upgrading to 24.3.1, api/v2/workflow_job_templates//access_list/ started returning 500. The error message from the web component is:
AWX version
24.3.1
Select the relevant components
Installation method
kubernetes
Modifications
no
Ansible version
No response
Operating system
No response
Web browser
No response
Steps to reproduce
Expected results
api/v2/workflow_job_templates//access_list/ API should return all teams/users that has permissions
Actual results
The request fails due to an internal error.
Additional information
A similar API(teams//roles) that returns permissions from a team perspective works fine, it looks like authorization works OK as well. Users can still take action on the workflows for which they have permission.
The text was updated successfully, but these errors were encountered: