BiologicalRecordsCentre / PoMS

repository for Pollinator Monitoring Scheme website
0 stars 0 forks source link

Move site from Drupal 8 to Drupal 9 #131

Closed andrewvanbreda closed 5 months ago

andrewvanbreda commented 3 years ago

Hi @BirenRathod @CCarvell @kitenetter

Thought I would open an issue for the move so that details can be stored here rather than lost in emails.

So far I have done a check of the code to make sure it should work in Drupal 9. No alterations to the existing code were identified. However the new checking/verification pages will need some alteration. These are not deployed yet so this isn't a problem.

I did do some limited practical tests on the Drupal 9 test site. The site past inspection apart from 3 observations

  1. Lots of translations were not working on the pages. Biren has said this isn't a genuine problem, but because that Drupal 9 site hasn't been attached to the UKPoMS name yet, so the final version will be unaffected.

  2. The recent grid width CSS alteration was missing on the Drupal 9 test site. I think Biren has corrected this one already.

  3. A slight oddity was detected during registration (I think Biren may have already looked at fixing this). After using the one-time login and setting password and saving, it confusingly tells you to change your password. This is the message... "You have just used your one-time login link. It is no longer necessary to use this link to log in. Please change your password. The changes have been saved." So it continues to tell the user to change their password even after save.

The Drupal 8 version doesn't have this problem, it just says "The changes have been saved." after the password save.

Maybe Biren will be able to confirm.

Note to all: The Drupal 9 test site is at this address. https://test-ceh-ukpoms.pantheonsite.io

BirenRathod commented 3 years ago

Thanks, @andrewvanbreda. As you already mentioned my comments, we are good to go for Drupal 9 Migration. this is only site left for me to migrate. @kitenetter Have you sorted out the downtime regarding this? please do so. I believe October & November will get more busy, so better to do next week.

CCarvell commented 3 years ago

@BirenRathod - @kitenetter is on leave and back Monday 20th. Since Andy noted that Drupal 8 is coming to end of life 2nd November I was wondering if we could wait until PoMS surveys have finished at the end of September, as Biren noted the migration takes 1 hour to 12 hours max.

BUT if it has to be next week, then perhaps we could say Wednesday? That way Martin can confirm on Monday and has time to maybe put a note out on the PoMS Twitter account that the website and data forms will be down for a few hours on Weds?

BirenRathod commented 3 years ago

@CCarvell Yes, Wednesday will be perfect once @kitenetter confirmed that.

kitenetter commented 3 years ago

Okay, I will put out a message for Wednesday.

BirenRathod commented 3 years ago

@kitenetter yes, please. thanks. I assume you are going to put message on website too. I will put down website after 12:00 pm.

kitenetter commented 3 years ago

@BirenRathod do you mean it will be down from mid-day on Wednesday 22 September?

BirenRathod commented 3 years ago

@kitenetter Yes.

BirenRathod commented 3 years ago

@andrewvanbreda Just see above for your info.

andrewvanbreda commented 3 years ago

@BirenRathod Yes that is fine, won't really affect me as I just won't work on the site that day.

andrewvanbreda commented 3 years ago

Just for the record, I noticed the Species Grid translations were not appearing (actually the rows were completely empty).

This was fixed by Using this line in dynamic.php $html .= call_user_func(array(self::$called_class, $method), $auth, $args, $tabalias, array_merge(['extraParams'=>$auth['read']], $options));

instead of this $html .= call_user_func(array(self::$called_class, $method), $auth, $args, $tabalias, array_merge($defAttrOptions, $options));

This was already present on the Drupal 8 site

andrewvanbreda commented 3 years ago

@BirenRathod @kitenetter I have added translation for the help text and labels on the Welsh Fit Count data entry form for the Drupal 9 site. The termlists translation won't work unless the User Interface Translation problem is fixed. Note there is some old code (that is no longer needed because of a bug fix) that could be adapted that used to force translation of the species grid, am sure that could be changed for the whole page, but would need some extra budget....maybe a few hours work.

andrewvanbreda commented 3 years ago

@BirenRathod It is probably a good idea to leave the Drupal 8 test running for now as it maybe useful for fixing the translation issue.

BirenRathod commented 3 years ago

@andrewvanbreda My recommendation is you don't need to use drupal 8 test env. instead you can use live env of Drupal 8. It will will be available soon one propagation process finished completely. Here is the URL of that -> http://live-ceh-poms.pantheonsite.io/ Although test & live env of Drupal 8 will be available till End of Oct. After that I have to decommission them.

CCarvell commented 3 years ago

@andrewvanbreda if there is a clear (near-guaranteed) fix to this Welsh translation issue that you have identified, then I think we should sort it out asap. I have already alerted our Welsh Gov funder (she's also a PoMS volunteer) and she is keen that we meet our objectives of treating the English and Welsh equally, but is OK with the site having gone back to live as it is.

Could you please send a short 'quote' for the few hours you anticipate needing for this work, with your rate and cost. I am tempted to ask WG if they would consider funding it separately as we have already soaked up considerable extra cost for translation work than originally budgeted, plus we are effectively providing @BirenRathod s time on the website for free on this project. It's worth asking, but if not then I am sure we can fund the work needed somehow.

BirenRathod commented 3 years ago

@BirenRathod @kitenetter I have added translation for the help text and labels on the Welsh Fit Count data entry form for the Drupal 9 site. The termlists translation won't work unless the User Interface Translation problem is fixed. Note there is some old code (that is no longer needed because of a bug fix) that could be adapted that used to force translation of the species grid, am sure that could be changed for the whole page, but would need some extra budget....maybe a few hours work.

When you say "The termlists translation won't work unless the User Interface Translation problem is fixed." . This is not something we should do as this feature been introduced by one of Drupal contributed module.

Also, about extra budget for fixing species grid bit is something I could not comment on. It is definitely to consider for @CCarvell to decide.

andrewvanbreda commented 3 years ago

@BirenRathod That is fine. I wasn't intending to actively work on it. But it is worth leaving until the language is fixed.

@CCarvell No it isn't a near-guarantee. I will have to do a test, then I can send a quote. I would hope it works.

However what I will do is see if John has seen this happen before first as really we could do with the translation module working.

I have also had to soak up overrun on the project that I hadn't originally anticipated. I think that a lot of the trouble was that I hadn't realised some of the forms wouldn't have a translation (and I wouldn't of known that was going to cause difficulty anyway). But actually that mixture made the translation very difficult.

andrewvanbreda commented 3 years ago

@BirenRathod I have spoken to John, and he remind me of an option to check that I had forgotten about. I think this line is missing from the helper_config (actually I think the helper_config file isn't present)

public static $delegate_translation_to_hostsite = TRUE;

I think this will fix it. I dunno if you just want to copy over the old helper_config from the Drupal 8 site, or whether you want me to commit it into Pantheon. Anyway, let me know, but am almost certain that is the issue.

BirenRathod commented 3 years ago

@andrewvanbreda Yes, that has not been added as I copied drupal 8 version of git on to ceh-ukpoms repository not from ceh-poms repository. Please commit onto pantheon of ceh-ukpoms, so If I update iform module in future, I will check first and copy that.

andrewvanbreda commented 3 years ago

@kitenetter @CCarvell @BirenRathod Language problem fixed. Not the new configuration version of that configuration file for the website has an extra option "upload_max_filesize = '4M'" I didn't remove it, as it might be required for the later version of the code the site is now running. However it could theoretically impact the size of images people can upload, we can increase if needed.

Please close this issue once you are happy with the way the new Drupal 9 site is running.

BirenRathod commented 3 years ago

Fantastic @andrewvanbreda. Upload file size is fine.

kitenetter commented 3 years ago

Many thanks @andrewvanbreda - I will do final checks and close the issue tomorrow.

andrewvanbreda commented 3 years ago

@kitenetter @BirenRathod Hi, When I was looking at your question from this morning just now, I just noticed the Create Account link s now very small, it wasn't even obvious to me at first. That is a theme issue, so am just raising it, you'll need to ask Biren or Steve to have a look.