Simple fix in the rewriter to exclude renaming on software items - #46489
Conversation
There was a problem hiding this comment.
Claude Code Review
This repository is configured for manual code reviews. Comment @claude review to trigger a review and subscribe this PR to future pushes, or @claude review once for a one-time review.
Tip: disable this comment in your organization's Code Review settings.
Codecov Report❌ Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## 44970-fix-get-fleets #46489 +/- ##
=====================================================
Coverage 66.81% 66.81%
=====================================================
Files 2804 2804
Lines 223602 223631 +29
Branches 11400 11400
=====================================================
+ Hits 149393 149413 +20
- Misses 60638 60643 +5
- Partials 13571 13575 +4
Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
|
Doing this in the decoder does seem to be the best of all the options. I wish it was a bit more abstract, because I imagine we'll keep this rewriter forever (even after Fleet 5, we may have other keys we want to deprecate) and having this hard-coded solution in there could bite us later. But maybe the learning there is next time we refactor the rewriter to be path-aware. |
Resolves #44970 (2/2).
The issue is that in
fleetctl applythesetup_experiencefield in software items was being converted tomacos_setup(which we don't want because that rename should only happen in MDM).I tried to make the change as simple as possible and isolated to
software(I checked and it seems there are no renames undersoftwarespec). Supporting some context aware renaming (or prevention of renaming) requires a bigger refactor on the rewriter functionality.changes/,orbit/changes/oree/fleetd-chrome/changes.Testing