Skip to content

Conversation

@bniladridas
Copy link
Owner

This update trims dependency bloat by narrowing the Tokio feature set to only what the project actually needs—rt-multi-thread and macros. This reduces compile times, lowers transitive dependencies, and keeps the runtime footprint focused.

We also upgraded httpmock to version 0.8, aligning the test stack with its latest API changes and improving long-term compatibility. The update required small adjustments in test setup but keeps the suite stable.

Together, these changes streamline the dependency graph, improve maintainability, and keep the build faster and cleaner without altering any runtime behavior.

@gemini-code-assist
Copy link
Contributor

Summary of Changes

Hello @bniladridas, I'm Gemini Code Assist1! I'm currently reviewing this pull request and will post my feedback shortly. In the meantime, here's a summary to help you and other reviewers quickly get up to speed!

This pull request focuses on optimizing the project's dependency management by trimming unnecessary features from the Tokio runtime and upgrading the httpmock testing framework. The primary goal is to reduce compile times, minimize the runtime footprint, and improve maintainability without introducing any changes to the existing runtime behavior. These changes result in a more efficient and streamlined build environment.

Highlights

  • Tokio Feature Trimming: The Tokio dependency has been optimized by narrowing its feature set from 'full' to only 'rt-multi-thread' and 'macros'. This change significantly reduces the project's compile times and overall runtime footprint.
  • httpmock Upgrade: The httpmock testing library has been upgraded to version 0.8, aligning the test stack with its latest API changes and improving long-term compatibility. This required minor adjustments in test setup.
  • Dependency Bloat Reduction: Numerous unused or transitive dependencies have been removed or updated in Cargo.lock, streamlining the dependency graph and reducing the overall number of packages, contributing to a cleaner and faster build process.
Using Gemini Code Assist

The full guide for Gemini Code Assist can be found on our documentation page, here are some quick tips.

Invoking Gemini

You can request assistance from Gemini at any point by creating a comment using either /gemini <command> or @gemini-code-assist <command>. Below is a summary of the supported commands on the current page.

Feature Command Description
Code Review /gemini review Performs a code review for the current pull request in its current state.
Pull Request Summary /gemini summary Provides a summary of the current pull request in its current state.
Comment @gemini-code-assist Responds in comments when explicitly tagged, both in pull request comments and review comments.
Help /gemini help Displays a list of available commands.

Customization

To customize Gemini Code Assist for GitHub experience, repository maintainers can create a configuration file and/or provide a custom code review style guide (such as PEP-8 for Python) by creating and adding files to a .gemini/ folder in the base of the repository. Detailed instructions can be found here.

Limitations & Feedback

Gemini Code Assist may make mistakes. Please leave feedback on any instances where its feedback is incorrect or counter productive. You can react with 👍 and 👎 on @gemini-code-assist comments. If you're interested in giving your feedback about your experience with Gemini Code Assist for Github and other Google products, sign up here.

You can also get AI-powered code generation, chat, as well as code reviews directly in the IDE at no cost with the Gemini Code Assist IDE Extension.

Footnotes

  1. Review the Privacy Notices, Generative AI Prohibited Use Policy, Terms of Service, and learn how to configure Gemini Code Assist in GitHub here. Gemini can make mistakes, so double check it and use code with caution.

@harperbot
Copy link

harperbot bot commented Dec 11, 2025

HarperBot

HarperBot Analysis

Summary

This pull request significantly refactors the project's asynchronous runtime, migrating away from the async-std ecosystem and consolidating on tokio. It involves removing several async-std related dependencies (async-std, async-process, async-global-executor, async-io, async-signal, async-executor, async-channel) and updating numerous other direct and transitive dependencies to their latest minor versions. The rust-version has also been bumped to 1.75. Additionally, ascii-canvas and term crates have been removed, suggesting a change in console UI handling.

Scores

  • Code Quality: 9/10
  • Maintainability: 9/10
  • Security

Copy link
Contributor

@gemini-code-assist gemini-code-assist bot left a comment

Choose a reason for hiding this comment

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

Code Review

This pull request makes some great dependency optimizations. Trimming the tokio features is an excellent move to reduce bloat and improve compile times. The update to httpmock is also good for keeping dependencies current.

I noticed that httpmock appears to be an unused development dependency. Removing it would further streamline the dependency graph, which aligns perfectly with the goals of this PR. I've added a specific comment about this in Cargo.toml.

With that one change, this PR will be a solid improvement.

Comment on lines 15 to 16
[dev-dependencies]
httpmock = "0.7"
httpmock = "0.8"
Copy link
Contributor

Choose a reason for hiding this comment

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

medium

httpmock is listed as a dev-dependency and is being updated here. However, after reviewing the test files (tests/e2e.rs, tests/integration.rs) and in-file test modules, I couldn't find any usage of it.

If this dependency is indeed unused, removing it would be a great way to further reduce dependency bloat and simplify the dependency tree, which is one of the main goals of this PR. If it's intended for future use, perhaps a basic test case could be added to justify its inclusion.

@harperbot
Copy link

harperbot bot commented Dec 11, 2025

HarperBot

HarperBot Analysis

Summary

This pull request represents a significant refactoring, migrating the ollama crate from the async-std runtime and ecosystem to tokio. This involves updating dependencies, specifically bumping async-object-pool and removing numerous async-std related crates, and replacing all async-std specific APIs (tasks, I/O, synchronization primitives, channels, etc.) with their tokio equivalents.

Scores

  • Code Quality: 9/10
  • Maintainability: 9/10
  • Security: 9/10

Strengths

  • Major Runtime Migration: Successfully migrating from async-std to tokio is a substantial undertaking, indicating a thorough understanding of both runtimes and the codebase

@bniladridas bniladridas merged commit bf3fade into main Dec 11, 2025
10 checks passed
@harper-maintainer harper-maintainer deleted the fix-deps branch December 11, 2025 20:49
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

Status: Done

Development

Successfully merging this pull request may close these issues.

3 participants