Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[CodeHealth][rust] bump tracing-subscriber 0.2 -> 0.3 #27740

Closed
wants to merge 2 commits into from

Conversation

bridiver
Copy link
Collaborator

@bridiver bridiver commented Feb 20, 2025

Resolves brave/brave-browser#44129

Submitter Checklist:

  • I confirm that no security/privacy review is needed and no other type of reviews are needed, or that I have requested them
  • There is a ticket for my issue
  • Used Github auto-closing keywords in the PR description above
  • Wrote a good PR/commit description
  • Squashed any review feedback or "fixup" commits before merge, so that history is a record of what happened in the repo, not your PR
  • Added appropriate labels (QA/Yes or QA/No; release-notes/include or release-notes/exclude; OS/...) to the associated issue
  • Checked the PR locally:
    • npm run test -- brave_browser_tests, npm run test -- brave_unit_tests wiki
    • npm run presubmit wiki, npm run gn_check, npm run tslint
  • Ran git rebase master (if needed)

Reviewer Checklist:

  • A security review is not needed, or a link to one is included in the PR description
  • New files have MPL-2.0 license header
  • Adequate test coverage exists to prevent regressions
  • Major classes, functions and non-trivial code blocks are well-commented
  • Changes in component dependencies are properly reflected in gn
  • Code follows the style guide
  • Test plan is specified in PR before merging

After-merge Checklist:

Test Plan:

@bridiver bridiver requested review from a team as code owners February 20, 2025 13:32
@bridiver bridiver requested a review from bsclifton February 20, 2025 13:32
@github-actions github-actions bot added the CI/run-audit-deps Check for known npm/cargo vulnerabilities (audit_deps) label Feb 20, 2025
@bridiver bridiver force-pushed the remove-tracing-pretty branch from c516301 to e398f85 Compare February 20, 2025 15:11
@bridiver bridiver added the CI/skip-teamcity Do not run builds in TeamCity label Feb 20, 2025
@bridiver bridiver changed the title [CodeHealth][rust] remove unsupported ansi crate [CodeHealth][rust] bump tracing-subscriber 0.2 -> 0.3 Feb 20, 2025
Base automatically changed from remove-unused-chrono-features to master February 20, 2025 19:43
@bridiver bridiver force-pushed the remove-tracing-pretty branch from e398f85 to e6d9fa5 Compare February 20, 2025 19:46
Copy link
Contributor

[puLL-Merge] - brave/brave-core@27740

Here's my analysis of this pull request:

Description

This PR downloads and reverts the tracing-subscriber dependency from v0.3 to v0.2 in the Brave browser's SKUS component. The change includes downgrading several related dependencies and adding new ones to support the older version.

Possible Issues

  • Downgrading to an older version of tracing-subscriber may miss out on bug fixes and improvements from v0.3
  • Additional dependencies being added increase the overall package size

Security Hotspots

  1. The PR notes a security vulnerability (RUSTSEC-2021-0139) related to the ansi_term crate being unmaintained, which is added as a new dependency. This should be monitored for potential security issues.
Changes

Changes

By filename:

  • components/skus/browser/rs/cxx/BUILD.gn: Updates tracing-subscriber dependency from v0.3 to v0.2
  • components/skus/browser/rs/cxx/Cargo.toml:
    • Downgrades tracing-subscriber to v0.2.0
    • Adds additional features requirements
  • components/skus/browser/rs/cxx/src/log.rs: Updates formatting code to work with older API
  • components/skus/browser/rs/lib/Cargo.toml: Adds tracing-subscriber v0.2 as dev dependency with note about security vulnerability
  • Added multiple new dependency files for:
    • ansi_term v0.12
    • valuable v0.1
    • winapi v0.3
sequenceDiagram
    participant Build as Build System
    participant SKUs as SKUS Component
    participant Tracing as Tracing Subscriber
    participant Format as Log Formatter

    Build->>SKUs: Initialize
    SKUs->>Tracing: Initialize v0.2 subscriber
    Tracing->>Format: Configure formatter
    Format->>Format: Apply ANSI settings
    Format->>SKUs: Return formatted log
    SKUs->>Build: Complete initialization
Loading

@bridiver
Copy link
Collaborator Author

This PR downloads and reverts the tracing-subscriber dependency from v0.3 to v0.2 in the Brave browser's SKUS component

That's backwards

@bridiver
Copy link
Collaborator Author

Moved the whole thing into #27745

@bridiver bridiver closed this Feb 20, 2025
@bsclifton bsclifton deleted the remove-tracing-pretty branch February 21, 2025 00:02
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
CI/run-audit-deps Check for known npm/cargo vulnerabilities (audit_deps) CI/skip-teamcity Do not run builds in TeamCity puLL-Merge
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Bump tracing-subscriber and removed unsupported/unused ansi dep
2 participants