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

Zen mode does not work for anonymous users, throws JSON error #9331

Closed
2 tasks done
emmapeel2 opened this issue May 30, 2023 · 3 comments
Closed
2 tasks done

Zen mode does not work for anonymous users, throws JSON error #9331

emmapeel2 opened this issue May 30, 2023 · 3 comments
Assignees
Labels
bug Something is broken.
Milestone

Comments

@emmapeel2
Copy link
Contributor

Describe the issue

When users without login try to make changes in Zen mode, they get a JSON error.

I already tried

  • I've read and searched the documentation.
  • I've searched for similar issues in this repository.

Steps to reproduce the behavior

There is a red message from weblate:

SyntaxError: JSON.parse: unexpected character at line 7 column 1 of the JSON data

And the changes are not saved.

Expected behavior

The changes should be saved, even if as suggestions.

Screenshots

error-zen cleaned

Exception traceback

No response

How do you run Weblate?

weblate.org service

Weblate versions

No response

Weblate deploy checks

No response

Additional context

No response

@nijel nijel self-assigned this May 31, 2023
@nijel nijel added the bug Something is broken. label May 31, 2023
@nijel nijel added this to the 4.18 milestone May 31, 2023
@nijel nijel closed this as completed in c74f0eb May 31, 2023
@github-actions
Copy link

Thank you for your report; the issue you have reported has just been fixed.

  • In case you see a problem with the fix, please comment on this issue.
  • In case you see a similar problem, please open a separate issue.
  • If you are happy with the outcome, don’t hesitate to support Weblate by making a donation.

@emmapeel2
Copy link
Contributor Author

emmapeel2 commented May 31, 2023

Nice!

It is better now with the message 'Forbidden', but it would be even better if the contributions of non-logged users in Zen, become suggestions. Is that not possible?

I would like that feature because I want to have an ' Improve translation' button on our website, and send the people that clicks this button to a Zen interface with the strings of that page in particular (using the string location value to search). But I am afraid people will submit translations that are going to be lost.

Anonymous users can suggest on the normal view, is it not possible to allow them to suggest in Zen view?

@nijel
Copy link
Member

nijel commented Jun 1, 2023

I don't think it's a good idea. When automatically making suggestions here, it would behave different for authenticated and unauthenticated users. So, when user doesn't notice he got signed out, he would be suddenly making suggestions without really noticing.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something is broken.
Projects
None yet
Development

No branches or pull requests

2 participants