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

Fix detector component filepath custom overrides #1306

Merged
merged 2 commits into from
Nov 18, 2024

Conversation

grvillic
Copy link
Contributor

@grvillic grvillic commented Nov 16, 2024

Context

A detector does not need to specify location where a component was found. Nevertheless, custom wrapper plugins can report additional locations if desired and that shouldn't be blocked.

In PR #648 a regression occurred while trying to address an experiments framework bug. We don't want to unsuspectingly record locations for experimental detectors before producing the final graph. We added a check to prevent experiments from overriding the graph, but this was partially incomplete, because we are clearing the file paths at the top of the method.

Solution

Use the same flag to verify if the component file paths should be updated and only clear the list when generating final graph.

@grvillic grvillic requested a review from a team as a code owner November 16, 2024 03:03
Copy link

codecov bot commented Nov 16, 2024

Codecov Report

Attention: Patch coverage is 98.14815% with 1 line in your changes missing coverage. Please review.

Project coverage is 89.6%. Comparing base (9408a0e) to head (16cf57a).
Report is 1 commits behind head on main.

Files with missing lines Patch % Lines
...GraphTranslation/DefaultGraphTranslationService.cs 80.0% 0 Missing and 1 partial ⚠️
Additional details and impacted files
@@          Coverage Diff          @@
##            main   #1306   +/-   ##
=====================================
  Coverage   89.6%   89.6%           
=====================================
  Files        378     378           
  Lines      29907   29960   +53     
  Branches    1837    1840    +3     
=====================================
+ Hits       26808   26861   +53     
  Misses      2707    2707           
  Partials     392     392           

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


🚨 Try these New Features:

@grvillic grvillic enabled auto-merge (squash) November 18, 2024 18:01
@grvillic grvillic merged commit 7721f99 into main Nov 18, 2024
22 of 25 checks passed
@grvillic grvillic deleted the users/grvillic/FixCustomPathOverrides branch November 18, 2024 18:25
Copy link

👋 Hi! It looks like you modified some files in the Detectors folder.
You may need to bump the detector versions if any of the following scenarios apply:

  • The detector detects more or fewer components than before
  • The detector generates different parent/child graph relationships than before
  • The detector generates different devDependencies values than before

If none of the above scenarios apply, feel free to ignore this comment 🙂

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.

2 participants