-
Notifications
You must be signed in to change notification settings - Fork 52
SDK Version Check #1967
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
SDK Version Check #1967
Conversation
Co-authored-by: Copilot <[email protected]>
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.
Pull Request Overview
This PR adds SDK version checking functionality to the Percy core package. The feature checks if a newer version of the SDK is available by comparing the current version against the latest GitHub release.
- Adds a utility function to check SDK versions against GitHub releases
- Integrates version checking into the Percy snapshot workflow
- Maps package names to their corresponding GitHub repositories
Reviewed Changes
Copilot reviewed 2 out of 2 changed files in this pull request and generated 3 comments.
File | Description |
---|---|
packages/core/src/utils.js | Adds package-to-repo mapping and checkSDKVersion function |
packages/core/src/percy.js | Integrates SDK version checking into the snapshot process |
Tip: Customize your code reviews with copilot-instructions.md. Create the file or learn how to get started.
'@percy/selenium-webdriver': 'percy-selenium-js', | ||
'@percy/playwright': 'percy-playwright', | ||
'@percy/appium-app': 'percy-appium-js', | ||
'@percy/storybook': 'percy-storybook', | ||
'@percy/ember': 'percy-ember', | ||
'@percy/cypress': 'percy-cypress', | ||
'@percy/puppeteer': 'percy-puppeteer', | ||
'@percy/testcafe': 'percy-testcafe', | ||
'@percy/nightwatch': 'percy-nightwatch', | ||
'percy-java-selenium': 'percy-selenium-java', | ||
'percy-playwright-java': 'percy-playwright-java', | ||
'percy-appium-dotnet': 'percy-appium-dotnet', | ||
'percy-selenium-dotnet': 'percy-selenium-dotnet', | ||
'percy-playwright-dotnet': 'percy-playwright-dotnet', | ||
'percy-playwright-python': 'percy-playwright-python', | ||
'percy-selenium-python': 'percy-selenium-python', | ||
'percy-selenium-ruby': 'percy-selenium-ruby', | ||
'percy-capybara': 'percy-capybara' |
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.
i don't think this is all appium java, appium ruby etc are missing.
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.
I added the most used ones over the last 7 days. For the rest the user agent string is ambiguous for example
we get percy-appium-app for java appium, python appium and ruby appium except those I have added the most used ones.
// Get GitHub repo name from mapping | ||
const repoName = PACKAGE_TO_REPO[packageName]; | ||
if (!repoName) { | ||
log.debug(`No repo mapping found for package: ${packageName}`); |
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.
Is this log required? When we add newer sdk's it will have issues
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.
@prklm10 I kept it for debugging purpose sometimes the user-agent can come as something unexpected or there might be a new newer sdk as you mentioned. Will it be a issue if it is shown only in debug mode logs? Normally the customer won't see it
Ticket - https://browserstack.atlassian.net/browse/PPLT-4314
