MWPW-204282: Fix broken status filter in M@S Studio - #1165
Conversation
Prevent callers from mutating the shared TERRITORY_MAP by returning a shallow copy of the entry object from resolveTerritoryCountries(). Added test verifying the returned object is independent.
|
Hello, I'm the AEM Code Sync Bot and I will run some actions to deploy your branch.
Commits
|
# Conflicts: # io/www/test/fragment/pipeline.test.js
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## main #1165 +/- ##
==========================================
+ Coverage 90.71% 90.75% +0.03%
==========================================
Files 318 318
Lines 101712 101814 +102
==========================================
+ Hits 92271 92401 +130
+ Misses 9441 9413 -28
... and 7 files with indirect coverage changes Continue to review full report in Codecov by Harness.
🚀 New features to boost your workflow:
|
|
@honstar Added Also added it to the promotions editor ignorable set, so toggling status there does not trigger the discard prompt. 5 new tests in |
|
@Andrei4226 I think this landed on the wrong PR. This one only touches the Studio status filter ( The |
- link Store.filters.status to the hash like locale, tags and personalization - treat status as ignorable in the promotions editor search-sync check - drop the now unused TAG_STATUS_PUBLISHED constant - fix a misleading narrowing test title
Sorry @Axelcureno, you're right, this is the wrong PR. |
| }; | ||
|
|
||
| export const TAG_STATUS_PUBLISHED = 'mas:status/published'; | ||
| export const TAG_STATUS_PUBLISHED_PATH = '/content/cq:tags/mas/status/published'; |
There was a problem hiding this comment.
Nit: this is unused and can be removed as well.

Resolves https://jira.corp.adobe.com/browse/MWPW-204282
The Fragments table Status filter queried the
mas:status/*AEM tag, while the Status column shows the fragment's real publication state. Those had fully diverged: of 300 sandbox fragments, zero carriedmas:status/publishedwhile 50 were genuinely PUBLISHED. Selecting Published returned Draft and Modified cards.A partial bridge existed in
mas-repository.js(translating the published tag intofilter.status), but the in-memory cache-narrowing path bypassed it, so the filter also worked on a cold search and then silently returned stale results once cached.filter.statusAEM.searchFragmenttakes an array; the API accepts multiple values andNEW/MODIFIED/UNPUBLISHEDare all queryableStore.filters.statusis normalized and whitelisted, so an invalid value degrades to no filtermas:status/publishedspecial case deletedMeasured against the live API: no rarity penalty.
NEW(1 in 300 fragments) is as fast as an unfiltered query.Not done: manual browser QA. Reviewer check is to open the Status picker, tick Draft, then also tick New and confirm the result set widens.
Test URLs: