You are trying to add a string 'configplugin' that already exists in this component

You are trying to add a string 'configplugin' that already exists in this component

by Andrei Băutu -
Number of replies: 3
Picture of Plugin developers

Hello,

I got this error today (first time I see it) In developer zone when I updated my plugin (https://moodle.org/plugins/repository_giphy):

Error: AMOS threw exception coding_exception: Coding error detected, it must be fixed by a programmer: You are trying to add a string 'configplugin' that already exists in this component. If this is intentional, use the 'force' parameter

I'm not sure what it means (considering I did not change the language file of my plugin) and I couldn't find any similar error in this forum or on google. Any suggestion?

Cheers,
Andrei

Average of ratings: -
In reply to Andrei Băutu

Re: You are trying to add a string 'configplugin' that already exists in this component

by Céline Perves -
Picture of Core developers Picture of Particularly helpful Moodlers Picture of Plugin developers
Hello,
Just like if in one of langage file there is a duplicate $string['confgiplugin'] entry
Cheers
Céline Pervès
In reply to Céline Perves

Re: You are trying to add a string 'configplugin' that already exists in this component

by Andrei Băutu -
Picture of Plugin developers
Hi,
That's what I thought, too. But this is not the case (the files are here https://github.com/abautu/moodle-repository_giphy/tree/master/lang/ ). "configplugin" shows up only 1 time in the entire plugin directory.
Andrei
In reply to Andrei Băutu

Re: You are trying to add a string 'configplugin' that already exists in this component

by Renaat Debleu -
Picture of Core developers Picture of Particularly helpful Moodlers Picture of Plugin developers
The problem hides in line 25, language files do not need "defined('MOODLE_INTERNAL') || die();"

Perhaps you can use the free Travis service to check your plugin before uploading, there you should be warned of possible errors.
Average of ratings: Useful (1)