-
Notifications
You must be signed in to change notification settings - Fork 6
improve CI behavior #11
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
base: master
Are you sure you want to change the base?
Conversation
Code Review: Improve CI BehaviorSummaryThis PR makes sensible improvements to the CI/CD workflow by separating slow integration tests and removing deployment triggers from pull requests. Overall, this is a positive change that should improve CI feedback time and workflow clarity. 🟢 Strengths1. Better CI Performance (.github/workflows/ci.yml:96-102)Separating regular tests from ignored tests is a good practice:
2. Logical Workflow Separation (.github/workflows/deploy.yml:3-5)Removing
🟡 Concerns & Suggestions1. Ignored Tests Being Optional (.github/workflows/ci.yml:99-102)- name: Run ignored tests (optional)
continue-on-error: true
timeout-minutes: 10
run: cargo test --all-features -- --ignoredConcern: The
These are critical integration tests for core functionality (CRUD operations, concurrency). Recommendations:
2. Timeout Value (.github/workflows/ci.yml:101)The 10-minute timeout seems reasonable for integration tests, but verify it's sufficient:
3. Missing Context in PR DescriptionThe PR description is incomplete:
Recommendation: Update the PR description to explain:
🟢 Best Practices Observed
🔒 Security & Performance
📊 Test Coverage ImpactCurrent state:
Risk: Core integration tests could break without immediate visibility. Mitigation: Implement one of the recommendations above to ensure these tests still run and are monitored, even if not on every PR commit. ✅ VerdictApprove with recommendations. The changes are sound and improve CI efficiency. However, I strongly recommend addressing the test coverage visibility concern to ensure critical integration tests don't silently fail. Priority: Consider implementing conditional |
- Fix delta-rs write hang in PGWire context by using block_in_place with Handle::block_on to avoid tokio runtime conflicts - Apply same fix to DML operations (UPDATE/DELETE) in dml.rs - Fix to_json function to properly parse JSON strings into objects instead of double-escaping them - Refactor at_time_zone and to_char UDFs to use flexible type signatures (ScalarUDFImpl with Signature::any) instead of strict type matching that caused runtime failures - Fix at_time_zone return type mismatch (was returning None but promising UTC timezone annotation) - Update sqllogictest expected values for proper JSON output format - Fix custom_functions.slt query column count (query T -> query TT) - Clean up debug eprintln! statements from production code - Add test for sequential SQL inserts matching integration pattern
Code Review: PR #11 - Improve CI BehaviorOverviewThis PR addresses critical runtime issues with PGWire query handling and improves CI workflow efficiency. The changes include fixing tokio runtime conflicts, refactoring UDF implementations for DataFusion compatibility, and reorganizing the CI test execution strategy. Verdict: ✅ Approve with Minor Recommendations 🔍 Detailed Analysis1. Critical Fix: Tokio Runtime Conflicts (src/database.rs, src/dml.rs)The ProblemThe most important change addresses a deadlock/hang issue when handling PGWire queries that involve delta-rs operations. The issue occurs when:
The Solution (src/database.rs:1240-1253)The fix uses Applied consistently:
Assessment: ⭐ Excellent fix - This is a proper solution to a complex concurrency issue. 2. UDF Refactoring (src/functions.rs)Changes SummaryMigrated from deprecated
Improvements:
Potential Issue: Recommendation: Consider using Assessment: ✅ Good modernization, with room for minor improvement. 3. Logging Cleanup (src/database.rs)Removed excessive debug logging:
Why this is good:
New diagnostic logging added (lines 974-976, 1161-1163) Assessment: 4. CI/CD Workflow Changes.github/workflows/ci.ymlPros:
Cons:
Ignored tests include critical functionality:
Recommendation: Make ignored tests required on .github/workflows/deploy.ymlRemoved Assessment: ✅ Correct - PRs shouldn't trigger deployments. 5. Test Coverage (tests/integration_test.rs)Added 3 new comprehensive test scenarios (+91 lines):
Assessment: ⭐ Excellent test coverage - These tests directly validate the fix and prevent regressions. 🔒 Security AnalysisNo security vulnerabilities introduced:
🚀 Performance ConsiderationsPositive impacts:
Potential concerns:
Assessment: ✅ Performance impact is net positive. 🎯 RecommendationsHigh Priority
Medium Priority
Low Priority
✅ SummaryThis PR solves a critical production issue (PGWire query hangs) with a well-understood, correct solution. The test coverage is excellent, and the CI improvements are sensible. The main concern is making ignored tests optional - these cover critical functionality and shouldn't fail silently. Recommendation: Approve and merge after addressing the logging level issue and CI test strategy. Files reviewed:
|
block_in_place requires multi-threaded tokio runtime to work.
Pull Request Review: Improve CI BehaviorSummaryThis PR makes significant changes to address concurrency and runtime issues in the database layer, particularly around Delta Lake operations in PGWire contexts. The changes primarily focus on using Critical Issues1. Potential Deadlock in
|
Closes #
How to test
Checklist