-
Notifications
You must be signed in to change notification settings - Fork 13
Backport the recent changes from Launchable CLI to Smart Tests CLI #1112
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
Merged
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This commit adds comprehensive auto-collection functionality for PTS v2: - Add --get-tests-from-guess option to collect tests from git ls-files - Implement _collect_potential_test_files method with test file detection - Add SubsetResult class for handling subset responses - Enhanced workspace state management with PTS v2 support - Convert Click patterns to Typer equivalents - Preserve smart-tests package naming and Typer-based CLI Co-authored-by: Claude <noreply@anthropic.com>
We expect the file transfer could be sizable, so occasionally update the user with what's going on.
Added validate_session_format() function to ensure session strings follow the expected format: builds/<build-name>/test_sessions/<test-session-id> Updated subset command help text to clarify expected session format. 🤖 Generated with [Claude Code](https://claude.ai/code) Co-Authored-By: Claude <noreply@anthropic.com>
- Updated package name from 'launchable' to 'smart-tests-cli' in version.py - Removed deprecated types-pkg_resources dependency from pyproject.toml - smart-tests already uses built-in importlib.metadata (Python 3.8+) 🤖 Generated with [Claude Code](https://claude.ai/code) Co-Authored-By: Claude <noreply@anthropic.com>
The caller side was not removed. Oof.
When percentage parameter is missing '%' on Windows, provide helpful error message explaining that '%' needs to be escaped as '%%' in batch files. This prevents confusing error messages when Windows users forget to escape percentage characters in command line arguments. 🤖 Generated with [Claude Code](https://claude.ai/code) Co-Authored-By: Claude <noreply@anthropic.com>
Add base_url() method to LaunchableClient and display the server endpoint in verify command output when it differs from the default. This helps users understand which API endpoint they are connecting to, which is especially useful when using custom endpoints. 🤖 Generated with [Claude Code](https://claude.ai/code) Co-Authored-By: Claude <noreply@anthropic.com>
- Fixed subset command architecture with nested test runner commands - Added missing base_url() method to LaunchableClient - Fixed subset stdin handling for test environments - Updated file test runner to properly handle auto-collection - Modified dynamic command builder to properly run test runners - Fixed linting issues with unused imports 🤖 Generated with [Claude Code](https://claude.ai/code) Co-Authored-By: Claude <noreply@anthropic.com>
- Fixed pytest JSON report parser to handle longrepr as dict, list, or string - Updated subset test to expect correct warning message format (WARNING vs Warning) - Updated record build tests to use decode_request_body helper method These fixes resolve pytest test runner compatibility issues and improve test reliability across different pytest output formats. 🤖 Generated with [Claude Code](https://claude.ai/code) Co-Authored-By: Claude <noreply@anthropic.com>
- Added workspace state endpoint mocks for fail-fast mode checks - Added builds endpoint mocks for record build operations - Updated request indices to account for additional state API calls - Fixed all record build tests to work with new fail-fast mode logic This resolves test failures where record build commands were not making HTTP requests due to missing endpoint mocks, which were required after the fail-fast mode functionality was added. 🤖 Generated with [Claude Code](https://claude.ai/code) Co-Authored-By: Claude <noreply@anthropic.com>
- Added workspace state endpoint mocks to 4 subset tests (goalspec, ignore_flaky_tests_above, prioritize_tests_failed_within_hours, targetless) - Updated API request indices to account for additional state API calls - Fixed API error test tracking counts to expect 2 calls instead of 1 (due to added fail-fast mode state checking) This resolves all remaining test failures, bringing the test suite to 100% passing status with only 1 skipped test (auto-collection format). 🤖 Generated with [Claude Code](https://claude.ai/code) Co-Authored-By: Claude <noreply@anthropic.com>
git was installed only build stage
- Update check_java_version to return -1 on CalledProcessError - Add proper exception handling for java -version command failures - Update tests to expect -1 return value on error conditions
- Display warning when total test duration is 0 - Convert Click syntax to Typer syntax for consistency - Add yellow warning message about checking test duration in report files
Error reporting problem
Replace Github repo URLs
🤖 Generated with [Claude Code](https://claude.ai/code) Co-Authored-By: Claude <noreply@anthropic.com>
…uild-provenance-2.x Update actions/attest-build-provenance action to v2.4.0
This backport includes the following changes: 1. **Docker**: Updated to use OpenJDK 21 instead of 17 2. **Java Core Changes**: - Enhanced commit graph collection with server-side filtering - Added TreeReceiver interface for optimized file transfer - Improved FlushableConsumer interface for batch processing - Updated CommitGraphCollector to support repository naming 3. **CLI Features**: - Added new 'compare subsets' command to analyze test order changes - Enhanced record commit command with repository name parameter - Updated record build to pass repository names to commit collection 4. **Infrastructure**: - Updated JAR file with latest Java changes - Added comprehensive test coverage for new features All tests passing. Ready for production use. 🤖 Generated with [Claude Code](https://claude.ai/code) Co-Authored-By: Claude <noreply@anthropic.com>
ninjinkun
added a commit
that referenced
this pull request
Aug 20, 2025
Revert "Merge pull request #1112 from cloudbees-oss/smart-tests-backport"
ninjinkun
added a commit
that referenced
this pull request
Aug 21, 2025
…rt-2 Revert backport from Launchable CLI to Smart Tests CLI on #1112
This was referenced Sep 16, 2025
Closed
Closed
Closed
Closed
Merged
Merged
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Summary
This PR backports critical bug fixes, enhancements, and stability improvements from the main branch to the smart-tests branch. The changes include major Java component updates, new features like fail-fast mode and subset comparison, and comprehensive test fixes across multiple test runners.
Key Changes
✨ New Features
🔧 Core Functionality Improvements
🏗️ Java Component Overhaul
🐛 Bug Fixes & Stability
📦 Build & Infrastructure
Files Changed
Notable Commits
Test Plan
Breaking Changes
No breaking changes in this backport. All changes are backward compatible additions and bug fixes.
Impact
This backport brings the smart-tests branch up to date with critical improvements from main, including:
---🤖 Generated with https://claude.ai/code