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

Authority additions from localised sites generate erroneous change requests / notifications #509

Open
mdeuk opened this issue Sep 30, 2018 · 3 comments
Labels
bug stale Issues with no activity in over a year

Comments

@mdeuk
Copy link
Collaborator

mdeuk commented Sep 30, 2018

When submitting a request to add a new authority in using the Cymraeg version of WDTK an error appears to occur which causes the change request to attempt to update the English version of WDTK rather than the Cymraeg (Welsh).

Example:

I have submitted a request to add a new authority 'Trafnidiaeth Cymru' (Transport for Wales) from the /cy website, which generates a support request:
image

As you can see, the request is fully localised, however, when attempting to action the change request, the localised fields, e.g. body name and request email address populate in the default language fields (English), leaving the Cymraeg fields empty
image

This has the additional side effect of generating notifications back to the user in the wrong language, with no option to correct this, other than to manually change the message.
image

Steps to reproduce

  1. Navigate to https://www.whatdotheyknow.com/cy/change_request/new and add an authority - note that, for the most part, the form is localised.
  2. Submit, note the following message "Mae'ch cais i ychwanegu awdurdod wedi ei anfon. Diolch am gysylltu. Byddwn mewn cysylltiad â chi'n fuan." (aka "Your request to add an authority has been sent. Thanks for contacting. We will be in touch with you soon")
  3. Open support mailbox and click the relevant change request link (or access via Admin console). Note: The alert in the support mailbox will be shown in the correct language (e.g. welsh in this instance)
  4. Note that the 'Cymraeg' tab is not populated and that the email to user template is in the wrong language

I am able to reproduce this issue consistently.

@mdeuk
Copy link
Collaborator Author

mdeuk commented Sep 30, 2018

Note, change request in question is 3287 (Trafnidiaeth Cymru). I have not added this authority yet, to allow for developers to investigate what might be going wrong. Test authority 'cwango' (3291) has been added to confirm that the bug is reproducible.

[fun fact - BydTermCymru does confirm the translation is correct - quango becomes 'cwango' 🙂]

@garethrees
Copy link
Member

Note: The alert in the support mailbox will be shown in the correct language (e.g. welsh in this instance)

FWIW I think this is incorrect – Admins should receive mail in the default language.

@garethrees
Copy link
Member

I think the gist of the problem here is that we're assuming that any "change request" adds the details for the default language of the site. This isn't a huge problem for WDTK specifically (I expect 98% of people use EN) but would be a bigger problem for international reusers supporting multiple locales.

@mdeuk Thanks for the really nice reproduction steps. Feel free to add the authority now, as we'll be able to recreate this in our development environments with the info you've given.

You'll want to move the Welsh translations over to the "Cymraeg" tab, and manually fill in the English with the English translation.

@HelenWDTK HelenWDTK added the stale Issues with no activity in over a year label Nov 17, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug stale Issues with no activity in over a year
Projects
None yet
Development

No branches or pull requests

3 participants