-
-
Notifications
You must be signed in to change notification settings - Fork 9.4k
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
Release: Prerelease 8.5.0-alpha.23 #30078
Release: Prerelease 8.5.0-alpha.23 #30078
Conversation
…s-api # Conflicts: # docs/writing-tests/accessibility-testing.mdx
… kasper/remove-warnings-api
…-from-status Addon A11y: Add conditional rendering for a11y violation number in Testing Module
Telemetry: Add metadata distinguishing "apps" from "design systems"
Addon A11y: Show errors of axe properly
Addon A11y: Remove warnings API
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
29 file(s) reviewed, 9 comment(s)
Edit PR Review Bot Settings | Greptile
type ExecaStreamer = typeof Promise & { | ||
stdout: Transform; | ||
kill: () => void; | ||
}; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
logic: ExecaStreamer type extends Promise incorrectly - should use Promise instead of typeof Promise
command: string, | ||
options?: Parameters<typeof execaCommand>[1] | ||
) { | ||
const process = execaCommand(command, { shell: true, buffer: false, ...options }); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
logic: shell: true can be dangerous if command is not properly sanitized
// If the process errors, this will throw | ||
await process; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
style: process errors should be caught and handled gracefully
); | ||
|
||
try { | ||
const command = `git ls-files -- ${globs.join(' ')}`; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
logic: git ls-files command is not escaped properly - paths with spaces could cause issues
} catch { | ||
return undefined; | ||
} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
style: silently returns undefined on any error without logging - could mask real issues
it('returns false if there is a routing package in package.json dependencies', () => { | ||
expect( | ||
getHasRouterPackage({ | ||
dependencies: { | ||
react: '^18', | ||
'react-dom': '^18', | ||
}, | ||
devDependencies: { | ||
'react-router': '^6', | ||
}, | ||
}) | ||
).toBe(false); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
style: The test description should be 'returns false if there is a routing package in devDependencies' to more accurately describe what is being tested
const command = `git grep -l composeStor` + (path ? ` -- ${path}` : ''); | ||
return await execCommandCountLines(command); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
logic: git grep command searches for partial 'composeStor' string which could match unintended files
* NOTE: if the operation returns `undefined` the value will not be cached. Use this to indicate | ||
* that the operation failed. | ||
*/ | ||
export const runTelemetryOperation = async <T>(cacheKey: string, operation: () => Promise<T>) => { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
style: Consider adding error handling for failed cache operations
async function getPackageJsonDetails() { | ||
const packageJsonPath = await findPackagePath(process.cwd()); | ||
if (packageJsonPath) { | ||
return { | ||
packageJsonPath, | ||
packageJson: (await findPackage(packageJsonPath)) || {}, | ||
}; | ||
} | ||
|
||
// If we don't find a `package.json`, we assume it "would have" been in the current working directory | ||
return { | ||
packageJsonPath: process.cwd(), | ||
packageJson: {}, | ||
}; | ||
} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
logic: getPackageJsonDetails returns empty objects for missing package.json which could mask configuration issues. Consider throwing an error or adding a warning.
This is an automated pull request that bumps the version from
8.5.0-alpha.22
to8.5.0-alpha.23
.Once this pull request is merged, it will trigger a new release of version
8.5.0-alpha.23
.If you're not a core maintainer with permissions to release you can ignore this pull request.
To do
Before merging the PR, there are a few QA steps to go through:
And for each change below:
This is a list of all the PRs merged and commits pushed directly to
next
, that will be part of this release:If you've made any changes doing the above QA (change PR titles, revert PRs), manually trigger a re-generation of this PR with this workflow and wait for it to finish. It will wipe your progress in this to do, which is expected.
Feel free to manually commit any changes necessary to this branch after you've done the last re-generation, following the Make Manual Changes section in the docs, especially if you're making changes to the changelog.
When everything above is done:
Generated changelog
8.5.0-alpha.23
Greptile Summary
Based on the provided files and changes, I'll create a concise summary of this pull request:
Storybook 8.5.0-alpha.23 brings several key improvements to accessibility testing and telemetry:
Key bullet points:
The changes represent a significant simplification of the accessibility testing model while adding better telemetry insights into how Storybook is being used.