Skip to content

Conversation

@Rudxain
Copy link
Member

@Rudxain Rudxain commented Aug 10, 2025

  • comment-out non-deterministic tests. This is still a mystery 👀
  • un-deprecate adb_shell_command and warn in doc-comment instead
  • fix many lints
  • remove some lints (see commit message)
  • promote rustc warnings to errors, without promoting all Clippy warnings

@Rudxain Rudxain added refactor Rework of code — behaviour doesn't change ci Continuous Integration labels Aug 10, 2025
@Rudxain Rudxain force-pushed the ci/fix-lints-tests branch 5 times, most recently from da0bdbb to 9f56c02 Compare August 13, 2025 23:32
@AnonymousWP

This comment was marked as resolved.

@Rudxain

This comment was marked as resolved.

@Rudxain Rudxain force-pushed the ci/fix-lints-tests branch from 9f56c02 to 09fec11 Compare October 31, 2025 21:40
@Rudxain Rudxain force-pushed the ci/fix-lints-tests branch 2 times, most recently from 0366feb to 0ee9bbf Compare October 31, 2025 22:12
@Rudxain Rudxain changed the title ci: fix lints, disable test ci: fix lints, disable non-determ tests Oct 31, 2025
@Rudxain

This comment was marked as resolved.

@Rudxain Rudxain requested a review from Copilot October 31, 2025 22:40
Copy link

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull Request Overview

This PR refactors code to improve type safety and remove unused code. The main changes focus on adding explicit lifetime parameters to Element return types, cleaning up deprecated code, and removing unused clippy lints.

Key changes:

  • Added explicit lifetime parameters ('_) to Element return types across view methods
  • Removed unused delay_hide_copy_confirmation function and inlined delay logic
  • Removed unused PickList enum and commented out unused UserInfo fields
  • Updated CI workflow to add a dedicated cargo check step with warnings as errors

Reviewed Changes

Copilot reviewed 11 out of 11 changed files in this pull request and generated 3 comments.

Show a summary per file
File Description
src/gui/widgets/package_row.rs Added explicit lifetime to Element return type
src/gui/views/settings.rs Added explicit lifetime to Element return type
src/gui/views/list.rs Added explicit lifetimes, inlined delay logic, removed unused function
src/gui/views/about.rs Added explicit lifetime to Element return type
src/gui/style.rs Removed unused PickList enum
src/gui/mod.rs Added explicit lifetime to Element return type
src/core/sync.rs Replaced deprecated attribute with warning comment, changed to_string() to clone()
src/core/config.rs Commented out non-deterministic tests
src/core/adb.rs Commented out unused UserInfo fields and methods
Cargo.toml Removed unused clippy lints and fixed indentation
.github/workflows/ci.yml Added cargo check step and updated clippy configuration

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment on lines +379 to +383
Command::perform(
// intentional delay
async { std::thread::sleep(std::time::Duration::from_secs(1)) },
|()| Message::HideCopyConfirmation,
),
Copy link

Copilot AI Oct 31, 2025

Choose a reason for hiding this comment

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

Using std::thread::sleep inside an async block is problematic because it blocks the executor thread, preventing other async tasks from running. Replace with tokio::time::sleep or the appropriate async sleep function for your runtime to avoid blocking the async executor.

Copilot uses AI. Check for mistakes.
Copy link
Member Author

@Rudxain Rudxain Oct 31, 2025

Choose a reason for hiding this comment

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

This seems valid, but it's off-topic/out-of-scope for this PR.

BTW, that line was introduced in #1033, but I inlined it: 956d64a

@Rudxain Rudxain force-pushed the ci/fix-lints-tests branch from 0ee9bbf to a3cc388 Compare October 31, 2025 22:42
@Rudxain Rudxain force-pushed the ci/fix-lints-tests branch from a3cc388 to f9e4344 Compare October 31, 2025 22:46
@Rudxain Rudxain force-pushed the ci/fix-lints-tests branch from f9e4344 to 15fcd10 Compare October 31, 2025 23:12
this fixes `unused-doc-comments` lint warn
@Rudxain Rudxain marked this pull request as ready for review October 31, 2025 23:25
@Rudxain Rudxain requested a review from a team October 31, 2025 23:26
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

ci Continuous Integration refactor Rework of code — behaviour doesn't change

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants