# How to deal with MB digital releases with large numbers of individual countries added to release dates?

**URL:** <https://discourse.beets.io/t/how-to-deal-with-mb-digital-releases-with-large-numbers-of-individual-countries-added-to-release-dates/1404>\
**Category:** Help\
**Created:** [July 16, 2020, 4:24am UTC](https://discourse.beets.io/t/how-to-deal-with-mb-digital-releases-with-large-numbers-of-individual-countries-added-to-release-dates/1404 "2020-07-16T04:24:17Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![aptd](https://avatars.discourse-cdn.com/v4/letter/a/74df32/32.png) [@aptd](https://discourse.beets.io/u/aptd)\
**Post date:** [July 16, 2020, 4:24am UTC](https://discourse.beets.io/t/how-to-deal-with-mb-digital-releases-with-large-numbers-of-individual-countries-added-to-release-dates/1404/1 "2020-07-16T04:24:17Z")

</div>

I keep running into these release listings for digital media releases on MusicBrainz where somebody has added an exhaustive (?) list of individual territories the release event occurred in rather than using the XW tag.

[Example 1](https://musicbrainz.org/release/30a2ff50-ed2c-440f-a1ad-bfd1599b5565/details)

 ![grimes](https://canada1.discourse-cdn.com/flex029/uploads/beets/original/1X/6e212c2a187968040619de8e6228c397a51db5de.png)

[Example 2](https://musicbrainz.org/release-group/cbf252c7-bb3f-484f-825e-fc2a42b55849)

 ![perfg](https://canada1.discourse-cdn.com/flex029/uploads/beets/original/1X/fe63749271754430f7237a87bafee270be6836c1.png)

MusicBrainz seems to see these huge lists of countries as acceptable, even if the consensus is split on if they’re not desirable and they’re causing trouble for some Picard users. This looks to be how things will be with MB going forwards.

[1](https://community.metabrainz.org/t/handling-of-multiple-listed-release-countries/464387)  
[2](https://community.metabrainz.org/t/digital-releases-merging-long-country-list-just-worldwide/440381)

What happens with Beets is that it’ll fetch the first on the list. This isn’t satisfactory, even if it isn’t technically correct I think for mine and most libraries the correct country code to list here is XW. Even if the user is from Afghanistan or Algeria, this is not a release specific to those countries, just one listed as having occurred there.

**How best to solve this?**

1. Use rewrite to replace individual country codes likely to be at the top of the list with XR.  
_This seems like a poor solution, prone to being caught out by unexpected countries topping the list_

2. Use …(maybe inline?) to set the country field to XW where a digital media release has more than n countries listed.  
_I don’t know how to implement this myself, additionally it’s unclear to me if MB returns all the countries to be able to count them or if it simply returns the top one, or if this is a reliable solution_

3. Manually change to XW after the fact.  
_This does not seem like a solution befitting of a Beets user_

4. Create a specific plugin to rectify this situation.  
_This is far beyond my capabilities at present_

Any ideas?

---

<div class="post-metadata">

**Author:** ![dorade](https://avatars.discourse-cdn.com/v4/letter/d/b3f665/32.png) [@dorade](https://discourse.beets.io/u/dorade)\
**Post date:** [July 16, 2020, 8:29pm UTC](https://discourse.beets.io/t/how-to-deal-with-mb-digital-releases-with-large-numbers-of-individual-countries-added-to-release-dates/1404/2 "2020-07-16T20:29:42Z")

</div>

Can’t suggest a solution, but I guess I know the cause: the [a-tisket script](https://etc.marlonob.info/atisket/) which allows to import all those multi-country digital releases from music streaming services. Annoying indeed.

---

<div class="post-metadata">

**Author:** ![guilhermehideki](https://avatars.discourse-cdn.com/v4/letter/g/45deac/32.png) [@guilhermehideki](https://discourse.beets.io/u/guilhermehideki)\
**Post date:** [July 24, 2020, 10:35pm UTC](https://discourse.beets.io/t/how-to-deal-with-mb-digital-releases-with-large-numbers-of-individual-countries-added-to-release-dates/1404/3 "2020-07-24T22:35:35Z")

</div>

Another solution is match the order of `match.preferred.countries`  
[https://beets.readthedocs.io/en/stable/reference/config.html#preferred](https://beets.readthedocs.io/en/stable/reference/config.html#preferred)
