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

Internal server error when creating new page translations #1678

Closed
timobrembeck opened this issue Sep 13, 2022 · 0 comments · Fixed by #1679
Closed

Internal server error when creating new page translations #1678

timobrembeck opened this issue Sep 13, 2022 · 0 comments · Fixed by #1679
Assignees
Labels
🐛 bug Something isn't working ☺️ effort: low Should be doable in <4h 🆘 prio: urgent Needs to be resolved now(?)
Milestone

Comments

@timobrembeck
Copy link
Member

Describe the Bug

The page form throws an internal server error when the translation does not yet exist

Steps to Reproduce

  1. Go to a page form where the translation does not yet exist
  2. See error

Expected Behavior

A new translation form should be opened

Actual Behavior

An internal server error occurs

Additional Information

Traceback
Sep 13 08:33:31 ERROR   django.request - Internal Server Error: /lahndillkreis/pages/fr/5665/edit/
Traceback (most recent call last):
File "/opt/integreat-cms/.venv/lib/python3.9/site-packages/django/core/handlers/exception.py", line 47, in inner
  response = get_response(request)
File "/opt/integreat-cms/.venv/lib/python3.9/site-packages/django/core/handlers/base.py", line 181, in _get_response
  response = wrapped_callback(request, *callback_args, **callback_kwargs)
File "/opt/integreat-cms/.venv/lib/python3.9/site-packages/django/views/generic/base.py", line 70, in view
  return self.dispatch(request, *args, **kwargs)
File "/opt/integreat-cms/.venv/lib/python3.9/site-packages/django/utils/decorators.py", line 43, in _wrapper
  return bound_method(*args, **kwargs)
File "/opt/integreat-cms/.venv/lib/python3.9/site-packages/django/contrib/auth/decorators.py", line 21, in _wrapped_view
  return view_func(request, *args, **kwargs)
File "/opt/integreat-cms/.venv/lib/python3.9/site-packages/django/views/generic/base.py", line 98, in dispatch
  return handler(request, *args, **kwargs)
File "/opt/integreat-cms/.venv/lib/python3.9/site-packages/integreat_cms/cms/views/pages/page_form_view.py", line 92, in get
  if page_translation.status != status.PUBLIC:
AttributeError: 'NoneType' object has no attribute 'status'
@timobrembeck timobrembeck added 🐛 bug Something isn't working ☺️ effort: low Should be doable in <4h 🆘 prio: urgent Needs to be resolved now(?) labels Sep 13, 2022
@timobrembeck timobrembeck added this to the 22Q3 milestone Sep 13, 2022
@timobrembeck timobrembeck self-assigned this Sep 13, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
🐛 bug Something isn't working ☺️ effort: low Should be doable in <4h 🆘 prio: urgent Needs to be resolved now(?)
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant