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

dev: Remove Ruff test path ignores and fix errors #281

Merged
merged 4 commits into from
Jul 10, 2024

Conversation

ajay-sentry
Copy link
Contributor

Purpose/Motivation

Part of the lint enhancement epic, this PR brings shared's ruff.toml to parity with codecov-api's here: https://github.com/codecov/codecov-api/blob/d37f5c7b077fa745e07c2b82666f305dae33b631/ruff.toml#L38-L42

The main change with this PR is to just remove the "ignore" path I set previously for all test files. In hindsight, I shouldn't have done this to begin with since we still want all of ruff's formatting and import deletion etc. etc for test files.

In the process I've also gone and fixed a lot of the rules for unused vars, or == None vs. is None, and a couple of list comprehension updates from the PERF rules.

Links to relevant tickets

Closes codecov/engineering-team#2052

What does this PR do?

This PR adds the rules listed above and fixes any errors that stemmed from them.

Legal Boilerplate

Look, I get it. The entity doing business as "Sentry" was incorporated in the State of Delaware in 2015 as Functional Software, Inc. In 2022 this entity acquired Codecov and as result Sentry is going to need some rights from me in order to utilize my contributions in this PR. So here's the deal: I retain all rights, title and interest in and to my contributions, and by keeping this boilerplate intact I confirm that Sentry can use, modify, copy, and redistribute my contributions, under Sentry's choice of terms.

JerrySentry
JerrySentry previously approved these changes Jul 10, 2024
@ajay-sentry ajay-sentry added this pull request to the merge queue Jul 10, 2024
@github-merge-queue github-merge-queue bot removed this pull request from the merge queue due to failed status checks Jul 10, 2024
Copy link

codecov bot commented Jul 10, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 89.25%. Comparing base (de9dc30) to head (465d0eb).

Current head 465d0eb differs from pull request most recent head f7edcf3

Please upload reports for the commit f7edcf3 to get more accurate results.

Additional details and impacted files
@@            Coverage Diff             @@
##             main     #281      +/-   ##
==========================================
- Coverage   89.86%   89.25%   -0.62%     
==========================================
  Files         358      324      -34     
  Lines       11437     9992    -1445     
  Branches     2050     1783     -267     
==========================================
- Hits        10278     8918    -1360     
+ Misses       1074     1004      -70     
+ Partials       85       70      -15     
Flag Coverage Δ
shared-docker-uploader ?

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@ajay-sentry ajay-sentry added this pull request to the merge queue Jul 10, 2024
Merged via the queue into main with commit caf7c85 Jul 10, 2024
6 checks passed
@ajay-sentry ajay-sentry deleted the Ajay/undo-test-ignores-ruff branch July 10, 2024 16:08
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Remove Test Path ignore for Shared
2 participants