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

Preflight Script environment variables no parse storage read #6407

Closed
jasonkuhrt opened this issue Jan 22, 2025 · 0 comments
Closed

Preflight Script environment variables no parse storage read #6407

jasonkuhrt opened this issue Jan 22, 2025 · 0 comments
Labels
bug Something isn't working chrome enhancement New feature or request that adds new things or value to Hive laboratory

Comments

@jasonkuhrt
Copy link
Member

jasonkuhrt commented Jan 22, 2025

User can crash app by having invalid localStorage state for key hive:laboratory:environment. It would be better that app can gracefully recover.

Here is a repro example. We set the value to {}. Once the page loads at path /:org/:project/development/laboratory, click icon for "Show Preflight Script".

Image

Uncaught TypeError: $.create is not a function
    at O (textModel.ts:74:17)
    at new H (textModel.ts:281:38)
    at o._createInstance (instantiationService.ts:162:18)
    at o.createInstance (instantiationService.ts:128:18)
    at u._createModelData (modelService.ts:313:55)
    at u.createModel (modelService.ts:372:21)
    at H (standaloneCodeEditor.ts:598:22)
    at q (standaloneCodeEditor.ts:591:9)
    at Object.U [as createModel] (standaloneEditor.ts:227:9)

Because this issue is currently only known to happen via user error, I suggest the category of enhancement instead of bug.

@jasonkuhrt jasonkuhrt added the enhancement New feature or request that adds new things or value to Hive label Jan 22, 2025
@dotansimha dotansimha removed the enhancement New feature or request that adds new things or value to Hive label Jan 29, 2025
@dotansimha dotansimha added enhancement New feature or request that adds new things or value to Hive improvement labels Jan 29, 2025 — with Linear
@linear linear bot added the chrome label Jan 30, 2025
@jasonkuhrt jasonkuhrt added the laboratory label Jan 30, 2025 — with Linear
@jasonkuhrt jasonkuhrt changed the title Make Laboratory Preflight Script Editor resilient to invalid state Preflight Script environment variables double parse Jan 30, 2025
@jasonkuhrt jasonkuhrt added the bug Something isn't working label Jan 30, 2025 — with Linear
@jasonkuhrt jasonkuhrt changed the title Preflight Script environment variables double parse Preflight Script environment variables no parse storage read Jan 30, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working chrome enhancement New feature or request that adds new things or value to Hive laboratory
Development

No branches or pull requests

2 participants