GeezerVisonThe World Wide Web, restored to 800 pixels of glory. | ||||||||||||||||||||||||||||||||||||
| Home|About|Gaming cabinet|Archives|How it works|Starter sites | ||||||||||||||||||||||||||||||||||||
GeezerVison is showing github.com — Cache feature flags on disk by aeisenberg · Pull Request #1384 · github/codeql-action Conversation
|
| fs.writeFileSync( | ||
| cachedFeatureFlags, | ||
| JSON.stringify(actualFeatureEnablement) | ||
| ); |
Code scanning / CodeQL
Potential file system race condition
There was a problem hiding this comment.
The reason will be displayed to describe this comment to others. Learn more.
Huh.. should we be checking files we write to?
Sorry, something went wrong.
There was an error while loading. Please reload this page.
There was a problem hiding this comment.
The reason will be displayed to describe this comment to others. Learn more.
This does feel like an FP. I will contact the team.
Sorry, something went wrong.
There was an error while loading. Please reload this page.
There was a problem hiding this comment.
The reason will be displayed to describe this comment to others. Learn more.
Thanks!! Makes sense, just a couple of naming thoughts
Sorry, something went wrong.
There was an error while loading. Please reload this page.
| fs.writeFileSync( | ||
| cachedFeatureFlags, | ||
| JSON.stringify(actualFeatureEnablement) | ||
| ); |
There was a problem hiding this comment.
The reason will be displayed to describe this comment to others. Learn more.
Huh.. should we be checking files we write to?
Sorry, something went wrong.
There was an error while loading. Please reload this page.
There was an error while loading. Please reload this page.
| */ | ||
| type GitHubFeatureFlagsApiResponse = Partial<Record<Feature, boolean>>; | ||
|
|
||
| export const FEATURE_FLAGS_FILE_NAME = "feature-flags.json"; |
There was a problem hiding this comment.
The reason will be displayed to describe this comment to others. Learn more.
Wondering if this could be renamed to include local or cache somehow so it's easier to remember the difference between this file and the remote server-side flags 🤔
Sorry, something went wrong.
There was an error while loading. Please reload this page.
There was a problem hiding this comment.
The reason will be displayed to describe this comment to others. Learn more.
Thanks! Extra test looks 👍
Sorry, something went wrong.
There was an error while loading. Please reload this page.
There was an error while loading. Please reload this page.
Successfully merging this pull request may close these issues.
There was an error while loading. Please reload this page.