-
-
Notifications
You must be signed in to change notification settings - Fork 638
Fix yalc publish #2054
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
Fix yalc publish #2054
Conversation
WalkthroughThe build script in Changes
Sequence Diagram(s)sequenceDiagram
autonumber
participant Dev as Developer/CI
participant Script as package-scripts.yml
participant FS as File System
Dev->>Script: start build
Script->>FS: test -f lib/ReactOnRails.full.js
alt file exists
FS-->>Script: file found
Script->>Dev: skip build (prebuilt artifact detected)
else file missing
FS-->>Script: file not found
Script->>Dev: run npm build or mark failure
end
note right of Script `#DDDDFF`: Two conditional checks updated to use the shorter path
Estimated code review effort🎯 2 (Simple) | ⏱️ ~8 minutes
Poem
Pre-merge checks and finishing touches✅ Passed checks (3 passed)
✨ Finishing touches🧪 Generate unit tests (beta)
📜 Recent review detailsConfiguration used: CodeRabbit UI Review profile: CHILL Plan: Pro 📒 Files selected for processing (1)
🚧 Files skipped from review as they are similar to previous changes (1)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
Code Review - PR #2054: Fix yalc publishSummaryThis PR fixes a critical bug in the ✅ Approved - Excellent FixWhat This PR DoesThe PR corrects the file path in Why This Fix Is CorrectRoot Cause Analysis:
Verification from package.json:
Code Quality: ✅ Excellent
Testing:
|
Code Review - PR #2054: Fix yalc publishSummaryThis PR fixes the yalc publish functionality that has been broken since September 29th by correcting the path to build artifacts in the prepack script. Changes AnalysisFile:
✅ Positive Findings
🔍 Verification Needed
💡 SuggestionsConsider adding a comment to clarify the path context: # Note: This script runs from packages/react-on-rails/ context during prepack
script: >
[ -f lib/ReactOnRails.full.js ] ||
(npm run build >/dev/null 2>&1 || true) &&
[ -f lib/ReactOnRails.full.js ] ||
{ echo 'Building react-on-rails seems to have failed\!'; }🎯 Overall AssessmentApproval Status: ✅ LGTM (Looks Good To Me) The fix is correct and addresses the immediate issue. The change makes sense given that npm lifecycle scripts run in the package directory context, not the workspace root. Recommendation:
Questions
|
Updated Code Review - PR #2054: Fix yalc publishI need to provide a clarification on my previous review after re-examining the workspace execution context. Correction: This Fix Is Actually CORRECT ✅After reviewing the documentation (CONTRIBUTING.md:111-113), I can confirm that yalc commands are run from within the workspace directory ( Key Evidence:
Why The Original Path Was WrongBefore (broken): [ -f packages/react-on-rails/lib/ReactOnRails.full.js ]When running from After (correct): [ -f lib/ReactOnRails.full.js ]When running from Final Recommendation: ✅ APPROVE & MERGEThis fix correctly restores the yalc publish functionality by using workspace-relative paths that match the execution context. Apologies for the confusion in my initial review - I misunderstood the execution context. This PR is correct and should be merged. |
6236ae3 to
278adde
Compare
…se-otp-timing * origin/master: (27 commits) Fix doctor command false version mismatch for beta/prerelease versions (#2064) Fix beta/RC version handling in generator (#2066) Document Rails Engine development nuances and add tests for automatic rake task loading (#2067) Add /run-skipped-tests as alias for /run-skipped-ci (#XXXX) (#2068) Fix: Add Rails 5.2-6.0 compatibility for compact_blank (#2058) Break CI circular dependency with non-docs change (#2065) Fix CI safety check to evaluate latest workflow attempt (#2062) Fix yalc publish (#2054) Add Shakapacker 9.0+ private_output_path integration for server bundles (#2028) Consolidate all beta versions into v16.2.0.beta.10 (#2057) Improve reliability of CI debugging scripts (#2056) Clarify monorepo changelog structure in documentation (#2055) Bump version to 16.2.0.beta.10 Bump version to 16.2.0.beta.9 Fix duplicate rake task execution by removing explicit task loading (#2052) Simplify precompile hook and restore Pro dummy app to async loading (#2053) Add Shakapacker precompile hook with ReScript support to Pro dummy app (#1977) Guard master docs-only pushes and ensure full CI runs (#2042) Refactor: Extract JS dependency management into shared module (#2051) Add workflow to detect invalid CI command attempts (#2037) ... # Conflicts: # rakelib/release.rake
Yalc Publish has been failing since Sep 29th.
Here's the fix.
Summary by CodeRabbit