-
Notifications
You must be signed in to change notification settings - Fork 19
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
Groupid in forums is not cleared #13
Comments
If you disable the plugin in the course, does it work as expected? What version of Moodle/plugin? I don't really think this plugin would affect that... |
Disabling the plugin does not help. Neither does deleting and recreating the groups. The groupid for the forums is not cleared in the database. It could be unrelated to the autogroup plugin, in which case I apologize for the false alarm. Just thought it was worth mentioning here, since the problem seemed to arise after the user profile field was changed. |
This may also be helpful: Just tried to update and came across this error: Notice: Undefined variable: dbman in /var/www/moodle/local/autogroup/db/upgrade.php on line 34 |
I continue to experience this issue on our Moodle site. My latest thinking is that this problem happens because Autogroup messes up the GROUPS IDs in forums (and possibly other activities) when the user These steps should reproduce the problem. Please don't try this on a production server. Create (or go) to a test course that has the following features:
Now to reproduce the problem:
It's also possible that this could be a Moodle bug (not Autogroup) or possibly a conflict with another plugin. More testing is needed. Thanks. |
Sorry, I am checking to see if I can find someone to help work on this plugin - if by chance, you have found a fix, please put in a pull request. |
Ok. I will see if I can find a developer to take a look. |
It looks like same problem (with forums) occurs if the profile field (which is used by autogroups) is changed after the student has posted to forums. For example, if the city profile field is used to create groups and the city of a user is changed after she posts to a forum, the group will not not get updated in the forum. It will just disappear. |
This scenarios described above will replicated the problem, but the actual cause is as follows: Moodle handles course groups and forum groups separately. If a group doesn’t have any members, Autogroup will delete the course group but it does not delete/update the groups associated with forum posts. As a result, forum posts associated with the old groups will point to groups that no longer exist. A fix for this problem can be found here: ned-code#1 (thanks Sergei Porfenovich). This code has not been tested. Looking for testers to verify. |
I will test but it might not be right away. I am buried with the start of the year. If others can test and report back, that would be awesome.
Emma
Emma Richardson
Distance Learning Coordinator
Direct: 719-650-3037
…On Aug 5, 2019, 9:51 AM -0600, NED eLearning Services ***@***.***>, wrote:
This scenarios described above will replicated the problem, but the actual cause is as follows:
Moodle handles course groups and forum groups separately. If a group doesn’t have any members, Autogroup will delete the course group but it does not delete/update the groups associated with forum posts. As a result, forum posts associated with the old groups will point to groups that no longer exist.
A fix for this problem can be found here: ned-code#1 (thanks Sergei Porfenovich). This code has not been tested. Looking for testers to verify.
—
You are receiving this because you commented.
Reply to this email directly, view it on GitHub, or mute the thread.
|
Not tested yet but PR seems ok. |
Thanks Arnaud - if you find it to be ok, I am happy to merge it. Just let me know when you get a chance to review. I will try and find some testing time too but won’t hold it up if you find it acceptable.
Emma
Emma Richardson
Distance Learning Coordinator
Direct: 719-650-3037
…On Aug 5, 2019, 4:44 PM -0600, Arnaud Trouvé ***@***.***>, wrote:
Not tested yet but PR seems ok.
I just asked sergei to open PR on this repo. Once done I’ll do a proper code review.
—
You are receiving this because you commented.
Reply to this email directly, view it on GitHub, or mute the thread.
|
The PR can be found here #17 |
Our site is experiencing a problem with forum groups and I suspect it's related to the autogroup plugin.
In some courses (not all), groups are not applied to forums even though the course has forced-groups enabled. I tried to fix the problem by removing all groups from the course and allowing autogroup to rebuild them, but it looks like this process does not reset the forum groupid in the database, as shown here: https://www.screencast.com/t/KImDQKdh
This info might help diagnose to issue:
The autogroup plugin is using the Institution field to generate groups. Last week, we changed the name of the institution for about 40 user profiles. I suspect this may have something to do with the problem, but I could be wrong.
We changed "Institution" to "Campus" in the Moodle language string, but I doubt this has any impact on the way autogroup manages groups.
All the event triggers are enabled, as shown here: https://www.screencast.com/t/IBtucat7HsD9
Thanks!
The text was updated successfully, but these errors were encountered: