You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Consolidates an uncommitted cleanup pass into a single reviewed change (51 files, +910/−1968):
Python: split 789-line scripts/utils.py into a utils/ package (async_http, cache, content_clean, fetch, html, http, thread_pool, urls); delete dead provider_decorator.py; slim providers_impl.py by 561 lines; consolidate routing_memory/state/resolve; mirror into .agents/skills/do-web-doc-resolver/scripts/
CLI: init_logging respects config.log_level; config subcommand now prints routing.prewarm, cache.ttl, provider rate limits, min_free_quality_to_skip_paid; add ResolveMetrics unit tests; drop dead config/resolver code
Web: delete dead lib/providers.ts, ToggleChip.tsx, providers.test.ts; thread maxChars through provider functions; consolidate resolvers
Docs/plans: mark plan 11 (cache pre-warming) shipped; update plan 03 progress; DEPLOYMENT.md tweak
Validation
pytest -m "not live": 872 passed, 5 xfailed
cargo test: all binaries green
./scripts/quality_gate.sh: all checks passed (ruff, black, fmt, clippy, eslint, tsc)
We reviewed changes in f088a06...de0fa59 on this pull request. Below is the summary for the review, and you can see the individual issues we found as inline review comments.
Some issues found as part of this review are outside of the diff in this pull request and aren't shown in the inline review comments due to GitHub's API limitations. You can see those issues on the DeepSource dashboard.
AI Review is run only on demand for your team. We're only showing results of static analysis review right now. To trigger AI Review, comment @deepsourcebot review on this thread.
The reason will be displayed to describe this comment to others. Learn more.
`fn apply_env_overrides` has a cyclomatic complexity of 59 with "critical" risk
A function with high cyclomatic complexity can be hard to understand and
maintain. Cyclomatic complexity is a software metric that measures the number of
independent paths through a function. A higher cyclomatic complexity indicates
that the function has more decision points and is more complex.
NEW Get contextual insights on your PRs based on Codacy's metrics, along with PR and Jira context, without leaving GitHub. Enable AI reviewer TIP This summary will be updated as you push new changes.
The reason will be displayed to describe this comment to others. Learn more.
Access to a protected member _url_resolve_async of a client class
Accessing a protected member (a member prefixed with _) of a class from outside that class is not recommended, since the creator of that class did not intend this member to be exposed. If accesing this attribute outside of the class is absolutely needed, refactor it such that it becomes part of the public interface of the class.
The reason will be displayed to describe this comment to others. Learn more.
Access to a protected member _url_resolve_async of a client class
Accessing a protected member (a member prefixed with _) of a class from outside that class is not recommended, since the creator of that class did not intend this member to be exposed. If accesing this attribute outside of the class is absolutely needed, refactor it such that it becomes part of the public interface of the class.
The reason will be displayed to describe this comment to others. Learn more.
Using the global statement
It is recommended not to use global statement unless it is really necessary. Global variables are dangerous because they can be simultaneously accessed from multiple sections of a program. This frequently results in bugs. This also make code difficult to read, because they force you to search through multiple functions or even modules just to understand all the different locations where the global variable is used and modified. Read more about why it should be avoided here.
The reason will be displayed to describe this comment to others. Learn more.
Use lazy % formatting in logging functions
Formatting the message manually before passing it to a logging call does unnecessary work if logging is disabled. Consider using the logging module's built-in formatting features to avoid that.
The reason will be displayed to describe this comment to others. Learn more.
`is_safe_url` has a cyclomatic complexity of 18 with "high" risk
A function with high cyclomatic complexity can be hard to understand and
maintain. Cyclomatic complexity is a software metric that measures the number of
independent paths through a function. A higher cyclomatic complexity indicates
that the function has more decision points and is more complex.
The reason will be displayed to describe this comment to others. Learn more.
Possible binding to all interfaces.
Binding to all network interfaces can potentially open up a service to traffic on unintended interfaces, that may not be properly documented or secured. This can be prevented by changing the code so it explicitly only allows access from localhost.
The reason will be displayed to describe this comment to others. Learn more.
Using the global statement
It is recommended not to use global statement unless it is really necessary. Global variables are dangerous because they can be simultaneously accessed from multiple sections of a program. This frequently results in bugs. This also make code difficult to read, because they force you to search through multiple functions or even modules just to understand all the different locations where the global variable is used and modified. Read more about why it should be avoided here.
The reason will be displayed to describe this comment to others. Learn more.
Access to a protected member _shutdown of a client class
Accessing a protected member (a member prefixed with _) of a class from outside that class is not recommended, since the creator of that class did not intend this member to be exposed. If accesing this attribute outside of the class is absolutely needed, refactor it such that it becomes part of the public interface of the class.
The reason will be displayed to describe this comment to others. Learn more.
Using the global statement
It is recommended not to use global statement unless it is really necessary. Global variables are dangerous because they can be simultaneously accessed from multiple sections of a program. This frequently results in bugs. This also make code difficult to read, because they force you to search through multiple functions or even modules just to understand all the different locations where the global variable is used and modified. Read more about why it should be avoided here.
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
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
Consolidates an uncommitted cleanup pass into a single reviewed change (51 files, +910/−1968):
scripts/utils.pyinto autils/package (async_http,cache,content_clean,fetch,html,http,thread_pool,urls); delete deadprovider_decorator.py; slimproviders_impl.pyby 561 lines; consolidaterouting_memory/state/resolve; mirror into.agents/skills/do-web-doc-resolver/scripts/init_loggingrespectsconfig.log_level;configsubcommand now printsrouting.prewarm,cache.ttl, provider rate limits,min_free_quality_to_skip_paid; addResolveMetricsunit tests; drop dead config/resolver codelib/providers.ts,ToggleChip.tsx,providers.test.ts; threadmaxCharsthrough provider functions; consolidate resolversValidation
pytest -m "not live": 872 passed, 5 xfailedcargo test: all binaries green./scripts/quality_gate.sh: all checks passed (ruff, black, fmt, clippy, eslint, tsc)Test plan