Upgrading existing question types, what is the procedure

Upgrading existing question types, what is the procedure

by Melissa . -
Number of replies: 17

Hi,

I have just updated 30 of the Question Types to version 3.3.  What is the procedure to get code updated on GIT?  Do I just update the code myself, or is there a procedure that I am supposed to follow?  I do not want to invade somebody's territory by creating new branches in GIT for plugins that I did not start.

These are all existing plugins that have not been upgraded to the current version of Moodle yet.  I did not do any code changes to the plugins, except to get them to work with the current version.

I also only generally tested these (making sure they installed and adding a simple question), so it would be best if somebody else helped to fully test these questions.

Thanks,

Melissa



Average of ratings: Useful (1)
In reply to Melissa .

Re: Upgrading existing question types, what is the procedure

by Marcus Green -
Picture of Core developers Picture of Particularly helpful Moodlers Picture of Plugin developers Picture of Testers
I understand your concern about treading on other peoples toes smile

One way is to fork the original to your own repository, make the changes and then create a pull request so the original creator can bring your changes back into the main repo. If the current maintainer has put them up for adoption and will let you take over maintenance then it is a case of creating/updating an automatic testing code (phpunit/behat) and poking up to the plugins database

I think all question types should come with a samplequestions.xml file, both for end user convenience  and for testing. I put mine in the root, but I think it should probably be in a folder and perhaps even in language file, e.g. plugqtype/examples/en/examplequestions.xml. And then see if you can pursuade some of the awesome translators to do their magic. (what should it be examplequestions.xml or samplequestions.xml?)

Average of ratings: Useful (1)
In reply to Marcus Green

Re: Upgrading existing question types, what is the procedure

by Melissa . -

I agree with you about the sample questions, but this needs some thought.  Right now the plugin pages do not even link to the Wiki Documentation Pages for the specific plugins.

I found one plugin that does have sample data:  Formulas

This formulas plugin also has a documentation page, but the file is called "sample-formulas-questions.xml", which I personally do not like.

I think that the sample files should be unique and contain the plugin name.

samples -> qtype_sample_formulas.xml

samples -> qtype_sample_[plugin_name].xml

That way if a person has a bunch of sample files contained within one directory, there will not be a name conflict.  A school will not want the plugin source code available to teachers, but they may want sample xml files available to teachers.  This also means that there needs to be a clear / clean way to make sure that the sample files are contained in the documentation.

There also needs to be improvement in the documentation for all of the plugins, but that is another issue.

Also, what is a pull request?

Thanks,

Melissa


In reply to Melissa .

Re: Upgrading existing question types, what is the procedure

by Germán Valero -
Picture of Documentation writers Picture of Particularly helpful Moodlers Picture of Plugin developers Picture of Testers Picture of Translators

@Melissa,

Yes

"There also needs to be improvement in the documentation for all of the plugins, but that is another issue."

I agree 100%, but could you please list the first 5 plugin types that should have their documentation pages upgraded?

Are you thinking about standard question types or are they third party plugin types ?

Should we improve the Moodle Docs pages by adding some examples as image screens or  .xml files, or real life examples ?

In the past, some of us have copied text and images from (mostly) the authors' GitHub sites to Moodle Docs, so that Moodlers can have the documentation easily translated into other languages (e g, Spanish in my case).

If you provide a link to your GitHub repository, I (and many other Moodlers) could download and  beta-test your new versions and perhaps provide some feedback or possible suggestions.

I think that it would be extremely useful if the examples inside the plugin's downloadable ZIP file could have their English language strings available for translation in AMOS.

Perhaps Marcus Green  smile would be so kind as to include one such example file in one of his excellent plugins currently available in the Moodle plugins database, as a proof-of-concept, and update the Moodle plugins database, so that we can use AMOS and have a celebration of this very friendly improvement; and we could later perhaps suggest in the tracker that all Moodle core standard question types might adopt this trend as a suggested practice. I would dare to suggest that we could contact David Mudrak (Moodle plugins' guardian) and ask him for his opinion on this matter. This has a potential to be a very (unexpensive and quck)  user-friendly improvement for many Moodle questions.

I (a Moodle translator) think that there are far many more Moodle translators actively translating English language strings in AMOS on a regular base, than there are translating Moodle Doc pages.

In reply to Germán Valero

Re: Upgrading existing question types, what is the procedure

by Melissa . -
1. Every question type should have an example xml import file. (all

question plugins), although most plugins do not even have the function

included for import and export to xml coded in the plugin.

2. Every question should have one valid example, with screenshots, of both

the input screens and what the student taking the test sees.  (some have

this and some do not)

3. There should be a direct link from the plugin download page to the

corresponding docs page for a given plugin. (all plugins)

4. If questions that started as third party are now included as standard

plugins, this should be indicated on the plugin download page.



Better navigation in general for the plugins:



Main Page -> "More for teachers" -> "questions" -> "third party question

types"



Compare that to Mediawiki where on their main page they have a direct link

to "third party extensions".



I just randomly selected a plugin:



1. All or nothing multiple choice question type - stub



2. Freehand drawing.  I made an attempt to update this plugin, but I am not

exactly sure what the original intention of the author was.  What was he

expecting a question to look like, and how did he expect a student to

answer the question?



3. spreadsheet question - again, I tried to update this, but I have no idea

exactly how the original author intended the plugin to work.



4. All of the music questions.  I was going to try to update these, but I

am not a musician and I don't know what the original intention of the

original author was.





All or nothing multiple choice question type



On Wed, Aug 9, 2017 at 6:53 PM, Germán Valero (via Moodle.org) <
In reply to Melissa .

Re: Upgrading existing question types, what is the procedure

by Mary Cooch -
Picture of Documentation writers Picture of Moodle HQ Picture of Particularly helpful Moodlers Picture of Testers Picture of Translators

Looking at that page Third-party question types I see references to versions of Moodle available- for example the freehand drawing type says Moodle 2.5 only. If that's the case and until such question types are updated to the latest versions, I think they should be removed from the page as they are misleading. 

Just a reminder to those unaware: each version of Moodle has its own documentation, so question types only available for certain versions  of Moodle should only appear in those versions of the documentation. Anyone of course can contribute to the documentation but we tend to add and improve to the current version (3.3 at the moment). the version before the current version (3.2 at the moment) and any Long Term Releases - at the moment that is 3.1. For questions that become core question types (such as the UK Open university drag and drop types which became core in 3.0) I agree, the documentation should be - and was - improved. For third party question types, we do very much depend on  community volunteers who have used the question types recently and are willing to update the documentation. German is a great example!wink

I also agree that those who contribute question types should write good documentation with examples for their pluginssmile

In reply to Mary Cooch

Re: Upgrading existing question types, what is the procedure

by Germán Valero -
Picture of Documentation writers Picture of Particularly helpful Moodlers Picture of Plugin developers Picture of Testers Picture of Translators
While I usually tend to agree with Mary Cooch on all things related to Moodle Docs, I stubbornly  think that for now we should keep the Moodle 3.3 Docs page for the third party question types as it currently is; with references to outdated plugins that are only available for some older Moodle branches, with the hope that (as of now) someone could be motivated to update these plugins and improve Moodle for many of us.

I think that most plugin authors have already helped Moodle a lot by writing those plugins. And other people (such as myself) might/can/should help them by providing/expanding the Moodle Documentation pages with examples and images.

 Sometimes, while testing one plugin in my translated (non-English) language, I have come across issues that needed additional changes, and most plugin authors have been very accommodating.

Convincing a third party plugin author to provide a link to Moodle Docs in the Moodle plugins database page for the 'More documentation for this plugin' link is another story. We can not force the Moodle plugins database to include a compulsory Moodle Docs link for all third party plugins (I know, I tried).

I usually try to explain to the plugin authors that while they may/can/usually provide a magnificent, fully updated, well designed, efficient documentation page for their plugin in their institutional, GitHub, or personal web page (e g, The Open University), many users would like/prefer/need to see that documentation in other languages. The  Academic Moodle Cooperation has some very good documentation for their great Moodle plugins in German language in their web site, and while some of it is also available in English, none of it is available there in Spanish sad According to the Moodle statistics page, three of the 10 countries with the most registered Moodle sites are Spanish-speaking countries smile .
Average of ratings: Useful (2)
In reply to Mary Cooch

Re: Upgrading existing question types, what is the procedure

by Germán Valero -
Picture of Documentation writers Picture of Particularly helpful Moodlers Picture of Plugin developers Picture of Testers Picture of Translators

@Mary Cooch,

Can you ask David Mudrak if he could/would put all the 16 outdated plugins currently listed in the third party question types Moodle 3.3 Doc page  into the Seeking new maintainer set in the Moodle plugins database, so that they can be properly updated now and maintained later ?

Perhaps David could first try to contact the listed plugin maintainers and kindly ask them whether they are willing/able to update the plugins ?

Thanks in advance

In reply to Germán Valero

Re: Upgrading existing question types, what is the procedure

by David Mudrák -
Picture of Core developers Picture of Documentation writers Picture of Moodle HQ Picture of Particularly helpful Moodlers Picture of Peer reviewers Picture of Plugin developers Picture of Plugins guardians Picture of Testers Picture of Translators

Better than doing it manually, there should be an automatic job in the Plugins directory that contacts maintainers of all outdated plugins, not just question types, and send them a notification. Unfortunately I don't think I would find time to implement such a feature soon. But as always, I will appreciate a feature request in the tracker so that we do not forget.

Thanks in advance.

Average of ratings: Useful (1)
In reply to David Mudrák

Re: Upgrading existing question types, what is the procedure

by Germán Valero -
Picture of Documentation writers Picture of Particularly helpful Moodlers Picture of Plugin developers Picture of Testers Picture of Translators

As suggested by David, I just created MDLSITE-5198  .

Please feel free to add/change/comment/vote as needed.

In reply to Melissa .

Re: Upgrading existing question types, what is the procedure

by Germán Valero -
Picture of Documentation writers Picture of Particularly helpful Moodlers Picture of Plugin developers Picture of Testers Picture of Translators

The [https://moodle.org/plugins/view.php?plugin=qtype_multichoiceset All or nothing multiple choice question type] is currently [https://moodle.org/plugins/browse.php?list=set&id=61 seeking new maintainer].

Please see the [https://moodle.org/mod/forum/discuss.php?d=260354 Plugins adoption programme]. I think it would be very quick and easy for you to become the happy new maintainer for this plugin smile .


The [https://docs.moodle.org/33/en/All_or_nothing_multiple_choice_question_type documentation page] for this plugin is a [https://docs.moodle.org/33/en/MoodleDocs:Stub stub] and anybody can help improve Moodle Docs by editing any of the stub articles and adding some content. 

I will happily try to update this documentation page for this plugin, so that it shall have one valid example, with screenshots, of both the input screens and what the student taking the test sees. I should have it done by the end of the coming weekend smile


I know that the organization where the author of the spreadsheet question was (The National Mexican Autonomous University, my University), actually instructed a junior programmer to update this plugin in the Moodle plugins database, but the wheels at this (my) University sometimes turn extremelly slow sad . Last time I heard about this plugin (more than six month ago), I was told that they were working on it.


The Moodle Docs Main page has a link to Test students with a quiz, that leads to the page for the Quiz activity.  The Quiz activity Docs page has a See also section that has a link to Questions, where all the standard question types are listed and there is also a link to third party question types

The Moodle Docs Main page also has a link to Install plugins. There, I just expanded the information about the 16 standard and 49 third party question types smile

In reply to Germán Valero

Re: Upgrading existing question types, what is the procedure

by Melissa . -

I should probably explain myself and my intentions.  I am a professional software engineer by trade.  I worked in the industry for 10 years, and then left the industry for 15 years to raise and homeschool my children.  Due to personal circumstances, I am trying to get back into industry -- begin a professional software engineer.

Most employers look at my resume, and are treating me as a person who just got out of college with no experience.  I need to "volunteer" for a project, so I have something recent to put on my resume.

Since I have been involved in education (homeschooling) for the last 15 years and I care about the success of Moodle, I thought that volunteering to update Moodle plugins to the current version would be a good volunteer project.  I do not work for any organization.  I am an individual (aka Homeschooling teacher / parent for K-12).  My "Moodle classes" only have a few students, and as of yet, I have only used them for my own planning.  I have never had a student access and use moodle.  My experience as a moodle user is limited, especially in the areas that are intended for 30 student classes and large schools and the university level (high level chemistry, etc).

The plugin groups that I thought that I would tackle first were:

1. Question Types

2. Course Formats

3. Import / export of question types

4. Import / export of courses.

5. Blocks

As for linking to the docs, why isn't the link autogenerated from the version.php file?

Also, there is a problem with the version.php file.  The file contains a field for the lowest version of moodle that a plugin can work on, but it does not contain a field for the highest version that the plugin was tested on.  Also, there is no standard that I can see the for the plugin release number.  I have been using "3.3.0 (Build <build number>).  The first two numbers represent the highest version of Moodle the plugin works with, and the 3rd number is the plugin version for that specific Moodle version.  Is that the current standard or should the plugin release number be something else?

One more thing, my "professional identity" is proactiveprogramming.  Although I have had that company name for 25 years, I only just recently setup a login under that name.  So if you start seeing stuff under the name "Proactive Programming" that is me.

Melissa




Average of ratings: Useful (1)
In reply to Melissa .

Re: Upgrading existing question types, what is the procedure

by Marcus Green -
Picture of Core developers Picture of Particularly helpful Moodlers Picture of Plugin developers Picture of Testers

I just wanted to say this is one of the most inspiring threads in many years. Melissa, look out for any posts from Tim Hunt, he is the main architect of the Quiz engine and works for the UK Open University one of the largest distance learning organisations anywhere.

In reply to Melissa .

Re: Upgrading existing question types, what is the procedure

by Mary Cooch -
Picture of Documentation writers Picture of Moodle HQ Picture of Particularly helpful Moodlers Picture of Testers Picture of Translators

Melissa, feel free to change your name from GamerHeadman if you wish smile

In reply to Mary Cooch

Re: Upgrading existing question types, what is the procedure

by Germán Valero -
Picture of Documentation writers Picture of Particularly helpful Moodlers Picture of Plugin developers Picture of Testers Picture of Translators

I am happy to announce that the Moodle Docs page for the All or nothing question type now has one example with images of what the teacher needs to do and what the student sees smile

Please feel free to check it and add/remove/change as needed.

The plugin page in the Moodle plugins database will need to be updated for:

  • Maintained by: no longer Jean-Michel Védrine sad
  • Moodle branches supported: it does work in Moodle 3.3 with the Boost theme  smile
  • More documentation for this plugin: the current link is for Moodle 2.6 Docs

The code checker plugin reports 4 errors and 3 warnings for this plugin under Moodle 3.3.1+ (Build: 20170727). Upgrading it should be easy for a programmer.


In reply to Germán Valero

Re: Upgrading existing question types, what is the procedure

by Jean-Michel Védrine -

Hello German,

Thanks a lot for this excellent documentation on the multichoiceset (all or nothing) plugin

I first updated the plugin page in the plugin database to change Moodle versions supported and link to your documentation.

I corrected some of the errors reported by the code checker plugin and will do more work now that my Travis jobs are running (This new feature is wonderful for Moodle developers a big thanks you to all the people involved)

I will also add compatibility with Moodle mobile 2 contributed by Philipp Steingrebe. Unfortunately not having a "real" Moodle site running (only a local version for development) I am unable to test this but multichoiceset is so similar to multichoice and comparing these files with the one for mobile 2 support of multichoice questions I am confident that they will oork.

In reply to Melissa .

Re: Upgrading existing question types, what is the procedure

by Marcus Green -
Picture of Core developers Picture of Particularly helpful Moodlers Picture of Plugin developers Picture of Testers

A pull request is where you ask the maintainer of a repo to pull and incorporate your changes. There is a button somewhere on Github to do it. I find it a confusing term in that it sounds like you are requesting to pull something, whereas it is the other way around.....

In reply to Melissa .

Re: Upgrading existing question types, what is the procedure

by Jean-Michel Védrine -

Hello Melissa,

It seems that you have a lot of good ideas about upgrading Moodle plugins in general and qtype plugins in particular.

I was the author or maintainer of some of thems including formulas and multichoiceset (all or nothing).

I stopped my Moodle work back in 2016 when I retired as a teacher.

But I am now inclined to do some work to upgrade some of my contributions so they can be used with Moodle recent versions.

I tried to contact you but was unsuccessful.

Could you contact me and tell me what you think should be done for at least formulas and multichoiceset plugins ?