How to create a new database for notes?

I’ve set ACTIVATE_NOTES: true and import demo course. And set ENABLE_NOTE:true in Advance Setting. and run databases migrations so it created default Oauth2 Client for me.
The error is:

Sorry, we could not search the store for annotations.
Sorry, we could not create this annotations.

Absolutely, in Notes page ,there’s nothing.

You mentioned that create an additional database and run migrations before notes work. Enable Student Notes not available in Advanced Settings #79
But I don’t know how to access into mysql shell and use which command to create.

Did you activate notes during quickstart (tutor local quickstart) or did you modify the config.yml file manually? In the latter case, you should regenerate the environment and then restart your platform:

tutor config save -y
tutor local stop 
tutor local start -d

Yes, I did. Should I run tutor local databases before activate notes in config.yml?

Yes. Basically, every time you change the config.yml file, you should run tutor config save and then the required platform operations.
The safest way to proceed is to run tutor local quickstart. It will re-configure the platform, re-generate the environment, run all required operations, and then you should be safe. If notes doesn’t work after that, then we have a problem.

Notes service’s up, but error still there. It probably caused by not established a database to store annotations. Access into mysql find database notes is created. :thinking:

@kikoShen thanks for the new information! I found two clues that might help you solve the problem.

  1. First of all, boolean configuration flags were not being correctly saved to the platform configuration. That means that ACTIVATE_NOTES was not being correctly saved whenever we run tutor local quickstart. This will be fixed in v3.3.10, which will be released in a few minutes.

  2. Secondly, the LMS tries to reach the notes server at notes.YOUR_LMS_HOST. In production this is fine, but when doing local development this domain name may not be available. When I tried to access notes on my laptop I managed to reproduce the issue you described. To solve this issue, you should tell your computer that notes.YOUR_LMS_HOST is actually “localhost”. To do so, edit /etc/hosts and add the following line: notes.YOUR_LMS_HOST

In the future, I will add a NOTES_HOST configuration variable that you will be able to set to “notes.localhost”. Also, I will add some documentation on this.

@kikoShen Did the proposed fix work for you?