-
Bug
-
Resolution: Fixed
-
Major
-
4.2
-
MOODLE_402_STABLE
-
MOODLE_402_STABLE
-
MDL-77973-master -
- See
MDL-75316for information about how to run the mock server - Run the mock using the command generated from the build process
- In Moodle, create a new OAuth2 issuer for "MoodleNet', using the template button
- Change base URL to moodlenet.test and save (i.e. pointing to the mock host)
- Enable MoodleNet outbound sharing in site admin (enablesharingtomoodlenet)
- Set MoodleNet oauthservice to the service you just created
- Go to a course activity (click it to view it)
- In the more menu, you'll have a "Share to MoodleNet" action link
- Now, via site admin, just delete the OAuth2 issuer
- Go back to the activity view
Expected: This loads fine, albeit without the "Share to MoodleNet" action link
Actual: There's a dml exception thrownCan't find data record in database table oauth2_issuer.Debug info:
SELECT * FROM {oauth2_issuer} WHERE id = ?
[array (
0 => 43,
)]
Error code: invalidrecord
Stack trace: line 1654 of /lib/dml/moodle_database.php: dml_missing_record_exception thrownline 1630 of /lib/dml/moodle_database.php: call to moodle_database->get_record_select()line 461 of /lib/classes/persistent.php: call to moodle_database->get_record()line 57 of /lib/classes/persistent.php: call to core\persistent->read()line 137 of /lib/classes/oauth2/api.php: call to core\persistent->__construct()line 4887 of /lib/navigationlib.php: call to core\oauth2\api::get_issuer()line 4343 of /lib/navigationlib.php: call to settings_navigation->load_module_settings()line 833 of /lib/pagelib.php: call to settings_navigation->initialise()line 962 of /lib/pagelib.php: call to moodle_page->magic_get_settingsnav()line 226 of /lib/classes/navigation/views/secondary.php: call to moodle_page->__get()line 890 of /lib/pagelib.php: call to core\navigation\views\secondary->initialise()line 962 of /lib/pagelib.php: call to moodle_page->magic_get_secondarynav()line 70 of /theme/boost/layout/drawers.php: call to moodle_page->__get()line 1477 of /lib/outputrenderers.php: call to include()line 1403 of /lib/outputrenderers.php: call to core_renderer->render_page_layout()line 171 of /mod/url/locallib.php: call to core_renderer->header()line 259 of /mod/url/locallib.php: call to url_print_header()line 104 of /mod/url/view.php: call to url_print_workaround()
- Discovered while testing
-
MDL-75316 (PARENT) Implement LMS foundation for sharing content to MoodleNet (share activities)
- Closed