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

Download json schema catalog at build-time instead of run-time #14065

Merged
merged 3 commits into from
Aug 26, 2024

Conversation

tsmaeder
Copy link
Contributor

What it does

This fixes the problem where we run into timeout at front-end start time because downloading the json schema catalog takes longer than expected. We now download the catalog as part of the core package build and just require() the json file at run time.

Fixes #11881

Contributed on behalf of STMicroelectronics

How to test

Build Theia from source and make sure that there are no errors at startup. Also check that json files that are on the schemastore.org catalog have proper code assist according to their schema.

Follow-ups

Review checklist

Reminder for reviewers

Fixes eclipse-theia#11881

Contributed on behalf of STMicroelectronics

Signed-off-by: Thomas Mäder <t.s.maeder@gmail.com>
@tsmaeder tsmaeder requested a review from msujew August 22, 2024 14:20
@tsmaeder
Copy link
Contributor Author

@msujew I seem to have a "works on my machine" problem here. Maybe hold off on the review until I have fixed it.

Our CI build never invokes "build" on the core package.

Signed-off-by: Thomas Mäder <t.s.maeder@gmail.com>
@tsmaeder
Copy link
Contributor Author

@msujew turns out our CI build script does not actually invoke build on the individual packages 🤷. Should be fine now.

Copy link
Member

@msujew msujew left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good to me and I can confirm that the feature still works as expected 👍

Signed-off-by: Thomas Mäder <t.s.maeder@gmail.com>
@tsmaeder
Copy link
Contributor Author

@msujew I added a flag that overwrites the file if you already have a catalog.json downloaded. If you think this is bogus, we can always revert the PR.

@tsmaeder tsmaeder merged commit acaa3df into eclipse-theia:master Aug 26, 2024
11 checks passed
@jfaltermeier jfaltermeier added this to the 1.53.0 milestone Aug 29, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
Archived in project
Development

Successfully merging this pull request may close these issues.

[core] Consider getting the schemastore.azurewebsites.net/api/json/catalog.json at build time
3 participants