Skip to content

build: upgrade dependencies and bump to v0.2.4#36

Merged
SuaveIV merged 6 commits intomainfrom
112_update
Apr 13, 2026
Merged

build: upgrade dependencies and bump to v0.2.4#36
SuaveIV merged 6 commits intomainfrom
112_update

Conversation

@SuaveIV
Copy link
Copy Markdown
Owner

@SuaveIV SuaveIV commented Apr 13, 2026

This PR upgrades dependencies and fixes code quality issues in build.nu.

What changed

We updated Nushell plugin dependencies from 0.111.0 to 0.112.0, along with system libraries like libc, nix, linux-raw-sys, and lscolors. The build script was refactored to use named flags instead of positional parameters, making it clearer and easier to maintain.

Fixes

  • Removed vague 'any' type annotation from http-get-with-retry
  • Added proper null checks for optional typed flags
  • Fixed ZIP extraction to avoid unnecessary tar attempts
  • Fixed conditional chain for flag combinations to handle all cases

Dependencies

Incorporated the lofty 0.24 update from dependabot, which fixes FLAC metadata corruption and improves APE tag handling for multi-value items.

Testing

Build script tested on the current branch and handles all extraction formats correctly.

Summary by CodeRabbit

Release Notes

  • Chores

    • Released version 0.2.4 with dependency updates.
    • Updated Nushell plugin framework and protocol libraries for compatibility.
    • Updated audio decoding library to the latest version.
  • Bug Fixes

    • Improved error handling and validation in the build and installation process.
    • Enhanced platform detection with clearer error messages for unsupported systems.

SuaveIV added 2 commits April 13, 2026 16:36
Upgrade Nushell plugin dependencies from v0.111.0 to v0.112.0 and other system libraries including libc, nix, linux-raw-sys, and lscolors. Refactor the http-get-with-retry function in build.nu to use named flags instead of positional parameters and improve documentation with inline comments.
Updated lofty dependency from 0.23.3 to 0.24.0 in Cargo.lock.

Simplified zip extraction logic in build.nu by removing unnecessary try-catch block and directly checking OS type for Windows-specific expansion.

Enhanced check_and_download_prebuilt function to handle all combinations of optional parameters (filename, install-root, checksum-url) instead of only specific combinations, improving flexibility and coverage.
@coderabbitai
Copy link
Copy Markdown

coderabbitai Bot commented Apr 13, 2026

Warning

Rate limit exceeded

@SuaveIV has exceeded the limit for the number of commits that can be reviewed per hour. Please wait 41 minutes and 55 seconds before requesting another review.

Your organization is not enrolled in usage-based pricing. Contact your admin to enable usage-based pricing to continue reviews beyond the rate limit, or try again in 41 minutes and 55 seconds.

⌛ How to resolve this issue?

After the wait time has elapsed, a review can be triggered using the @coderabbitai review command as a PR comment. Alternatively, push new commits to this PR.

We recommend that you space out your commits to avoid hitting the rate limit.

🚦 How do rate limits work?

CodeRabbit enforces hourly rate limits for each developer per organization.

Our paid plans have higher rate limits than the trial, open-source and free plans. In all cases, we re-allow further reviews after a brief timeout.

Please see our FAQ for further information.

ℹ️ Review info
⚙️ Run configuration

Configuration used: Organization UI

Review profile: ASSERTIVE

Plan: Pro

Run ID: 36b1974a-d95b-4c36-bf3e-c6178afd4cbb

📥 Commits

Reviewing files that changed from the base of the PR and between 624b958 and 448f878.

⛔ Files ignored due to path filters (1)
  • Cargo.lock is excluded by !**/*.lock
📒 Files selected for processing (1)
  • build.nu
📝 Walkthrough

Walkthrough

This PR updates Nushell plugin dependencies (nu-plugin, nu-protocol to 0.112.0) and lofty decoder library (0.23 to 0.24) in Cargo.toml, increments the crate version to 0.2.4, and refactors build.nu to replace positional parameters with typed flags, improve error handling and validation paths, and update the package manifest version accordingly.

Changes

Cohort / File(s) Summary
Dependency & Version Updates
Cargo.toml, nupm.nuon
Bumped nu_plugin_audio version from 0.2.3 to 0.2.4, updated nu-plugin and nu-protocol dependencies from 0.111.0 to 0.112.0, and upgraded lofty from 0.23 to 0.24.
Build Script Refactoring
build.nu
Converted function parameters from positional to typed flags (--max-retries, --timeout, --filename, --install-root, --checksum-url, --expected-checksum, --signature-path). Enhanced error handling with explicit cleanup on failures, improved extraction logic using complete() and tar --extract --xz, and refactored main to use direct cargo install instead of shell-string invocation.

Estimated code review effort

🎯 4 (Complex) | ⏱️ ~45 minutes

Possibly related PRs

  • PR #6: Modifies package and manifest versions in Cargo.toml and nupm.nuon with similar versioning patterns.
  • PR #23: Updates audio-related dependencies in Cargo.toml, including adjustments to the lofty decoder library.
  • PR #12: Evolves build.nu utilities and Nushell CI/dependency bumping patterns used in this PR.

Poem

🐰 hops excitedly
Flags replace old positional ways,
Errors caught with careful paws,
Dependencies dance to newer beats—
The plugin builds more cleanly now! ✨

🚥 Pre-merge checks | ✅ 3
✅ Passed checks (3 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The PR title directly and accurately summarizes the main changes: dependency upgrades (Nushell plugins from 0.111.0 to 0.112.0, lofty from 0.23 to 0.24) and version bump to 0.2.4, matching the primary modifications across Cargo.toml, nupm.nuon, and build.nu.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.

✏️ Tip: You can configure your own custom pre-merge checks in the settings.

✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch 112_update

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.

❤️ Share

Comment @coderabbitai help to get the list of available commands and usage tips.

Update multiple dependencies to their latest versions including cc, coreaudio-rs, doctest-file, pkg-config, rand, rand_core, rustc-hash, and semver. Remove older versions of anstream (0.6.21) and anstyle-parse (0.2.7) that are no longer needed, and consolidate dependency version specifications by removing explicit version pins where they're redundant.
Copy link
Copy Markdown

@coderabbitai coderabbitai Bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 2

🤖 Prompt for all review comments with AI agents
Verify each finding against the current code and only fix it if needed.

Inline comments:
In `@build.nu`:
- Around line 93-123: The code silently skips checksum verification when
fetching the checksum sidecar fails; change the branch that handles
$checksum_url so a failed HTTP fetch is treated as an error (fail-closed)
instead of returning null: in the computation of let expected (the
$expected_checksum / $checksum_url logic) replace the catch that returns null
with a catch that logs a warning (including the URL), cleans up the temporary
directory ($tmp_dir) and returns false (or otherwise aborts the install_prebuilt
flow), so that missing/failed checksum fetches do not cause an unverified binary
to be installed; keep the rest of the checksum comparison logic (is_md5,
actual/expected extraction) unchanged.
- Around line 279-282: The feature picker builds a comma-separated feature_list
from selected_features and passes it verbatim to cargo install
(--features=($feature_list)), but the picker options include invalid feature
names (e.g., flac, minimp3) that don't exist in Cargo.toml (which only defines
default, lite, all-decoders), causing cargo install to fail; fix by constraining
or mapping selections to the actual manifest features: update the selection
options used to populate selected_features (or add a validation/mapping step
after selected_features and before feature_list) so only "default", "lite", and
"all-decoders" are passed to cargo install, and ensure the log line (log info)
and cargo install invocation use the validated/mapped feature_list variable.
🪄 Autofix (Beta)

Fix all unresolved CodeRabbit comments on this PR:

  • Push a commit to this branch (recommended)
  • Create a new PR with the fixes

ℹ️ Review info
⚙️ Run configuration

Configuration used: Organization UI

Review profile: ASSERTIVE

Plan: Pro

Run ID: 7e82282c-3779-4744-bfe5-9a94dba24cd7

📥 Commits

Reviewing files that changed from the base of the PR and between 187da08 and 624b958.

⛔ Files ignored due to path filters (1)
  • Cargo.lock is excluded by !**/*.lock
📒 Files selected for processing (3)
  • Cargo.toml
  • build.nu
  • nupm.nuon

Comment thread build.nu
Comment thread build.nu
SuaveIV and others added 3 commits April 13, 2026 16:54
Replace individual decoder feature flags with simplified generic options (default, lite, all-decoders) for cleaner dependency management. Add detailed error logging and cleanup when checksum download fails, improving robustness of the download_and_install function by handling network failures gracefully.
@SuaveIV SuaveIV merged commit bd49a2e into main Apr 13, 2026
2 checks passed
@SuaveIV SuaveIV deleted the 112_update branch April 13, 2026 20:58
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant