-
Notifications
You must be signed in to change notification settings - Fork 11
Description
Background
When working on the Block to Text editor, it was noticed images weren't loading which prevented progress through the steps.
Problems
Problem 1 - editor not loading on block to text branch
PROBLEM SOLVED - Scott identified env var and rebuilt
As a precursor to all of this, it was noted the editor doesn't load on the block-to-text-integration preview branch
This is due to a CORS error, it seems that the API images route won't allow the domain. Yesterday, I (Conor) updated the ALLOWED_ORIGINS env var to include this domain and rebuilt on staging, but the error persists
Problem 2 - images not loading on production
PROBLEM IDENTIFIED - CSV issue
Scott found these two URLs where images aren't loading
- https://editor.raspberrypi.org/en/projects/world-happiness-measures
- https://projects.raspberrypi.org/en/projects/mapping-data
Problem 3 - images referenced by local name
LIKELY SOLVED - linked to problem 1
Locally, when everything is set up and running, and run Step 7 on block to text (local url), I noticed that the editor was asking for dog.webp which resolved to a localhost URL, instead of requesting this image from editor-api, which would return a rails active storage URL. There is a new environment variable (ASSETS_URL='https://staging-editor-api.raspberrypi.org/') but this didn't seem to do the trick.
For some reason this requests the image name instead of the image URL
Problem 4 - editor can constantly reload
Magda has an issue locally where the editor constantly reloads. @magdalenajadach mind filling this bit in on any symptoms?