fix: apply cargo clippy fixes#4310
Closed
devin-ai-integration[bot] wants to merge 2 commits intomainfrom
Closed
Conversation
Contributor
Author
🤖 Devin AI EngineerI'll be helping with this pull request! Here's what you should know: ✅ I will automatically:
Note: I can only respond to comments from users who have write access to this repository. ⚙️ Control Options:
|
✅ Deploy Preview for hyprnote canceled.
|
❌ Deploy Preview for hyprnote-storybook failed.
|
Auto-fixed by cargo clippy --fix: - Simplify nested if-let chains in tiptap/validate.rs - Remove unnecessary .to_string() in api/main.rs - Collapse nested if blocks in deeplink2/server/mod.rs Manually fixed: - Box large enum variant EnhanceUser in template-app to fix large_enum_variant warning Co-Authored-By: bot_apk <apk@cognition.ai>
c0e2059 to
0de7b5e
Compare
Co-Authored-By: bot_apk <apk@cognition.ai>
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
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
Ran
cargo clippy --fixfollowed bycargo clippyto resolve all remaining warnings. Changes include both auto-applied and manually-applied fixes across 9 files.Auto-fixed by
cargo clippy --fix:.to_string()on an already-&strvalue (posthog.rs)group_by_session_idin two migration files)if/if letblocks intolet-chains (from_ast.rs, two migration files,version/macro.rs,recorder.rs)Manually fixed:
use tauri::Managerimport (desktop/lib.rs)# Safetydoc section to unsafeextern "C"functions generated by macro (notification-macos)Workspace fix:
plugins/cli2from workspace (directory exists but has noCargo.toml, onlynode_modules)Review & Testing Checklist for Human
let-chain syntax (if let ... && let ...) requires Rust 1.87.0+. If any CI job uses an older toolchain, this will break.from_ast.rs:25-31,version/macro.rs:27-31) have unusual indentation. Verify they match project formatting conventions or runcargo fmt.group_by_session_idfunctions had explicit lifetimes removed. Rust's elision rules should handle this correctly, but worth a quick sanity check.tauri::Managerremoval doesn't break macOS builds — The import was removed entirely. Verify it's not needed on macOS (or if it is, that it's re-exported throughext::*orstore::*).Notes
plugins/cli2exclude is a workaround for a directory that hasnode_modulesbut noCargo.toml. If someone adds aCargo.tomlthere later, this exclude should be removed.tools,control-tauri,tcc,notch,am2) from clippy checks since they require macOS-specific dependencies that don't compile on Linux. The fixes applied are for the cross-platform code only.owhisper-client::adapter::elevenlabs::live::tests::test_default_paramsand are not caused by these changes. Thefmtcheck is passing.Link to Devin run: https://app.devin.ai/sessions/8f0aa93729ae44778dad7fbbbe26e4d5
Requested by: bot_apk