Skip to content
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

error_could_not_get_api_version / api_exception on v4.3 (2023101500) #71

Open
ksteitz opened this issue Oct 20, 2023 · 5 comments
Open

Comments

@ksteitz
Copy link

ksteitz commented Oct 20, 2023

Updating from v4.2-r5 (2023-07-27) to v4.3 (2023101500) from Oct 16 (8b4112f) we got that errors and etherpad stop working:
[20-Oct-2023 14:13:39 Europe/Berlin] Default exception handler: Fehler: Class "mod_etherpadlite\api\api_exception" not found Debug:
Error code: generalexceptionmessage

  • line 235 of /mod/etherpadlite/classes/api/client.php: Error thrown
  • line 247 of /mod/etherpadlite/classes/api/client.php: call to mod_etherpadlite\api\client->get_version()
  • line 116 of /mod/etherpadlite/classes/api/client.php: call to mod_etherpadlite\api\client->check_version()
  • line 771 of /mod/etherpadlite/classes/api/client.php: call to mod_etherpadlite\api\client->__construct()
  • line 45 of /mod/etherpadlite/classes/output/component/urlsettingsnote.php: call to mod_etherpadlite\api\client::get_instance()
  • line 32 of /mod/etherpadlite/settings.php: call to mod_etherpadlite\output\component\urlsettingsnote->__construct()
  • line 158 of /lib/classes/plugininfo/mod.php: call to include()
  • line 47 of /admin/settings/plugins.php: call to core\plugininfo\mod->load_settings()
  • line 8758 of /lib/adminlib.php: call to require()
  • line 8639 of /lib/adminlib.php: call to admin_get_root()
  • line 19 of /admin/upgradesettings.php: call to admin_externalpage_setup()

[20-Oct-2023 14:15:15 Europe/Berlin] Default exception handler: The Moodle server could not get the api version! Your Moodle server may not be able to connect to the Etherpad server. Please check your configuration! Debug:
Error code: error_could_not_get_api_version

  • line 235 of /mod/etherpadlite/classes/api/client.php: mod_etherpadlite\api\api_exception thrown
  • line 247 of /mod/etherpadlite/classes/api/client.php: call to mod_etherpadlite\api\client->get_version()
  • line 116 of /mod/etherpadlite/classes/api/client.php: call to mod_etherpadlite\api\client->check_version()
  • line 771 of /mod/etherpadlite/classes/api/client.php: call to mod_etherpadlite\api\client->__construct()
  • line 59 of /mod/etherpadlite/view.php: call to mod_etherpadlite\api\client::get_instance()

Moodle 4.2.3
pg13
PHP 8.0

@grabs
Copy link
Collaborator

grabs commented Oct 20, 2023

Hi, thank you for reporting this!
Could you be a bit more specific. When do you get this error? Did you have a look into the settings. What is it showing? Maybe there was a change in your environment.

Best regards
Andreas

@ksteitz
Copy link
Author

ksteitz commented Oct 20, 2023

Hi Andreas,

thanks for your quick answer!

The first one directly during update / at the end of the update (just updated etherpad-plugin, no other changes in parallel); the second one entering the settings.
In the meantime i rolled back to the previous, working, etherpad-version. But i remember red font in the plugins-settings saying "our Moodle server may not be able to connect to the Etherpad server. Please check your configuration!"

There was NO change in our environment. Using v4.2-r5 everything works fine, so also after rollback to that version setting "2023072700" in the DB for mod_etherpadlite in mdl_config_plugins table.

Best regards and nice weekend!
Klaus

@MalteHellwig
Copy link

Hello,
we got the same issue with updating Etherpad. We updated to Moodle 4.1.6 and the Etherpad.
There were no changes made in the configuration.

This is the error: The Moodle server could not get the api version! Your Moodle server may not be able to connect to the Etherpad server. Please check your configuration!

Greetings,
Malte

@MalteHellwig
Copy link

Update:
We changed the Etherpad URL in the configuration. We just removed the last "/" in the end of the URL and it is working now.
Maybe its something similar for you... the URL we used for the earlier Version had the / at the end and worked..

Best regards!
Malte

@grabs
Copy link
Collaborator

grabs commented Oct 27, 2023

Hi at all, I really can not reproduce this problem :(.
I tried with PHP 8.0 and PHP 8.1 and Moodle 4.1, 4.2 and 4.3.
I tried with and without "/" at the end of the server url.
All test were successful.
So I really don't know, what else I can do.
Maybe someone posts his plugin configuration (without the apikey of course).

Thank you!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants