Problems after upgrading to Moodle 3.4

Problems after upgrading to Moodle 3.4

by T K -
Number of replies: 28

We have just upgraded our moodle from 2.7 to 3.0, and then to 3.4


After version 3.4, we noticed the below discrepancies:


1) Calendar is loading, and layout is distorted, and on the left, below 'CALENDAR', there is the loading ring

calendar


2) Upon selecting the calendar, the dates appear twice:


calendar


3) Titles/topics, appear twice:

topic


4) And there is the phrase 'hidden from students' appearing out of nowhere:


hideen


Can someone provide me with some info as to why and how to solve this?

Average of ratings: -
In reply to T K

Re: Problems after upgrading to Moodle 3.4

by Emma Richardson -
Picture of Documentation writers Picture of Particularly helpful Moodlers Picture of Plugin developers

Switch your theme - I am presuming that you are using a theme that is not compatible.  Switch to Boost.

In reply to Emma Richardson

Re: Problems after upgrading to Moodle 3.4

by T K -

boost is a theme? this means I will lose all theme settings?

In reply to T K

Re: Problems after upgrading to Moodle 3.4

by Rick Jerz -
Picture of Particularly helpful Moodlers Picture of Testers

I think that your current theme settings will be retained if you switch back to it.

In reply to T K

Re: Problems after upgrading to Moodle 3.4

by Emma Richardson -
Picture of Documentation writers Picture of Particularly helpful Moodlers Picture of Plugin developers

Yes, but if your theme is not working, it might be time for a change... or is there a newer version?  What theme are you using?  Your other option would be to use css to fix the various issues but you are missing a lot by not using a boost based theme...

In reply to T K

Re: Problems after upgrading to Moodle 3.4

by Howard Miller -
Picture of Core developers Picture of Documentation writers Picture of Particularly helpful Moodlers Picture of Peer reviewers Picture of Plugin developers

Regardless... you need to eliminate the theme as the issue. If your theme is broken then you'll need to do *something*

In reply to Howard Miller

Re: Problems after upgrading to Moodle 3.4

by T K -

OK so I am looking to customise the boost theme for our use, but I am so bad with css stuff. Can someone advice, given the below files in my existing theme, which are the css and layout files, how/which ones do I put into the custom scss for boost?

Just wondering, is there any way to seamlessly import theme settings from moodle 2.5 to moodle 3.4?


[root@Moodle2001 style]# ls -lrt

total 40

-rwxr-xr-x. 1 apache apache 5559 Jul  4 09:39 pagelayout.css

-rwxr-xr-x. 1 apache apache  146 Jul  4 09:39 editor.css

-rwxr-xr-x. 1 apache apache   62 Jul  4 09:39 settings.css

-rwxr-xr-x. 1 apache apache 2759 Jul  4 09:39 admin.css

-rwxr-xr-x. 1 apache apache 7805 Jul  4 09:39 core.css

-rwxr-xr-x. 1 apache apache  684 Jul  4 09:39 menu.css

-rwxr-xr-x. 1 apache apache 4502 Jul  4 09:39 report.css

[root@Moodle2001 style]# cd ../layout

[root@Moodle2001 layout]# ls -lrt

total 36

-rwxr-xr-x. 1 apache apache 4379 Jul  4 09:39 frontpage.php

-rwxr-xr-x. 1 apache apache 4994 Jul  4 09:39 report.php

-rwxr-xr-x. 1 apache apache 1802 Jul  4 09:39 scorm.php

-rwxr-xr-x. 1 root   root   6509 Jul  5 15:50 general.php_5Jul2018

-rwxr-xr-x. 1 apache apache 6510 Jul  5 15:51 general.php

In reply to T K

Re: Problems after upgrading to Moodle 3.4

by Howard Miller -
Picture of Core developers Picture of Documentation writers Picture of Particularly helpful Moodlers Picture of Peer reviewers Picture of Plugin developers

Read this - https://docs.moodle.org/dev/Themes

Then if (when?) you have specific questions please post them in the Themes forum... you will get lots of great help over there big grin

In reply to Howard Miller

Re: Problems after upgrading to Moodle 3.4

by T K -

ok will do, thx!

In reply to T K

Re: Problems after upgrading to Moodle 3.4

by T K -

I've got another problem here since the upgrade - this is pertaining to educator site experience.


We enter a course and try to list the participants and get this error:

get_related_contexts_string() is removed, please use $context->get_parent_context_ids(true) instead


I checked the lib/accesslib.php is using the correct get_parent_context_ids(true):

$contexts = $context->get_parent_context_ids(true);


I realised that user/index.php was still calling the old get_related_context_string at line 365, so I changed it to:

$contextlist = get_parent_context_ids(true);


However I am still getting some error:

$contextlist = get_parent_context_ids(true);


Is the parameter 'true' correct or should be something else?

I tried turning the debugging on, this is what I get:

Exception - Call to undefined function get_parent_context_ids()

More information about this error

Debug info: 
Error code: generalexceptionmessage
Stack trace:

Exception - Call to undefined function get_parent_context_ids()

More information about this error

Debug info: 
Error code: generalexceptionmessage
Stack trace:
  • line 365 of /user/index.php: Error thrown

In reply to T K

Re: Problems after upgrading to Moodle 3.4

by Emma Richardson -
Picture of Documentation writers Picture of Particularly helpful Moodlers Picture of Plugin developers

This sounds like either a cache problem or an incorrect upgrade procedure...how exactly was the upgrade done?  I suspect the new code was copied over the old code instead of replacing it entirely.  If that is the case, then you need to redownload the code, and follow the upgrade instructions to upgrade correctly.

In reply to Emma Richardson

Re: Problems after upgrading to Moodle 3.4

by T K -

I've cleared the cache a few times, so we can rule that out. Unless it is user related?


We did the upgrade by replacing the moodle folder entirely, and then we copied the needed files over for the settings.


In reply to T K

Re: Problems after upgrading to Moodle 3.4

by Howard Miller -
Picture of Core developers Picture of Documentation writers Picture of Particularly helpful Moodlers Picture of Peer reviewers Picture of Plugin developers

"....and then we copied the needed files over for the settings"

What *exactly* does that mean?

In reply to Howard Miller

Re: Problems after upgrading to Moodle 3.4

by T K -

i mean we copied our themes, plugin, etc files into the moodle 3.4

In reply to T K

Re: Problems after upgrading to Moodle 3.4

by Howard Miller -
Picture of Core developers Picture of Documentation writers Picture of Particularly helpful Moodlers Picture of Peer reviewers Picture of Plugin developers

Ok.... as long as you're very confident that you didn't overwrite any core code. 

In reply to Emma Richardson

Re: Problems after upgrading to Moodle 3.4

by T K -

 I've cleared the cache a few times, so we can rule that out. Unless it is user related?


We did the upgrade by replacing the moodle folder entirely, and then we copied the needed files over for the settings.


Is the line 365 in user/index.php correct?


$contextlist = get_parent_context_ids(true);

In reply to T K

Re: Problems after upgrading to Moodle 3.4

by Emma Richardson -
Picture of Documentation writers Picture of Particularly helpful Moodlers Picture of Plugin developers

user/index.php in moodle3.4 only has 358 lines...

I suggest redoing the install...or do you have some plugins that involve the user/index file?

In reply to Emma Richardson

Re: Problems after upgrading to Moodle 3.4

by T K -

You were right indeed Emma, we did not use the latest user/index.php in the upgrade. 

I fixed this to use the latest user/index.php, now we no longer get the function error, but I see the layout of the list of participants is a bit weird, the alphabets are appearing vertical instead of horizontal, how can I fix this?


participants

In reply to T K

Re: Problems after upgrading to Moodle 3.4

by Emma Richardson -
Picture of Documentation writers Picture of Particularly helpful Moodlers Picture of Plugin developers

I cannot really help you if you have been picking and choosing which files to upgrade - how are we meant to know which files are old and which are new?  The entire moodle code needs to be replaced with the latest version.  Then, if you have issues, come back and we can help.

In reply to Emma Richardson

Re: Problems after upgrading to Moodle 3.4

by Cleo Prakash -
Hi Emma,


I am new to a role where an upgrade to Moodle 3.4 had taken place prior to my start (six months ago) and I have the same issue of the listing in vertical format when I need them in Horizontal format. Any help in this regards is much appreciated. 

Thank you

Kind regards

Cleo Prakash

In reply to Cleo Prakash

Re: Problems after upgrading to Moodle 3.4

by Cleo Prakash -

The upgrade was performed as per instructions. I changed the theme to More but no changes and still it's vertical. Please help.


Thank you


Kind regards

Cleo Prakash

In reply to T K

Re: Problems after upgrading to Moodle 3.4

by Howard Miller -
Picture of Core developers Picture of Documentation writers Picture of Particularly helpful Moodlers Picture of Peer reviewers Picture of Plugin developers

I'm guessing that you have made changes to core Moodle code and have now found out why it's a really bad idea. 

What you can't do is to copy the old versions into the new code and hope it works. There are various things you can do but, basically, you need to re-make the changes in the new version. 

However, again, don't do that. It's very bad practice and leads to this sort of thing. 

In reply to Howard Miller

Re: Problems after upgrading to Moodle 3.4

by T K -

@emma @howard agree its not ideal, this is the legacy moodle  learning system that we have got from our client.

Thanks for all your inputs!

In reply to Howard Miller

Re: Problems after upgrading to Moodle 3.4

by T K -

Can someone help me with the codes at user/index.php, moodle 3.4, how can I edit to make the below alphabets appear in horizontal instead of this vertical?


user list

In reply to T K

Re: Problems after upgrading to Moodle 3.4

by T K -

we added the below lines in custom css for our theme to remove the vertical alphabets, it works for us (my pc and my colleague, both on different networks) but at the client side they still view the alphabets. Is there something else at work here? firewall?


form#participantsform div.initialbar.firstinitial,

form#participantsform div.initialbar.lastinitial,

In reply to T K

Re: Problems after upgrading to Moodle 3.4

by T K -

ok so the above problem, was that when we login as admin (which is us) it shows correctly, other logins does not show the css changes. How to override this?

In reply to T K

Re: Problems after upgrading to Moodle 3.4

by Cleo Prakash -

Hi Karishma,


Did the issue raised got fixed? I see the same vertical listing under assessments as well as participants. How did you overcome by changing to horizontal please.


Any help is much appreciated.


Thank you


Kind regards

Cleo Prakash

In reply to Howard Miller

Re: Problems after upgrading to Moodle 3.4

by T K -
Sir, are you an Admin? I need your help to remove this post. Thank you!
In reply to T K

Re: Problems after upgrading to Moodle 3.4

by Gail Jackson -

Its look like your theme is not supporting this install other theme and try again