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

fx: exclude fields typo #69

Merged
merged 14 commits into from
Oct 1, 2024
9 changes: 8 additions & 1 deletion CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,10 @@
- CI: Use `poetry` in the build workflow.
- CI: Use `pull_request_target` trigger to make sure secrets are passed to runs in forks.

### Fixed

- `exclude_extra_fields`: A typo that prevented exclude configurations from being applied correctly
whatphilipcodes marked this conversation as resolved.
Show resolved Hide resolved

## [0.19.2] 2024-08-04

### Fixed
Expand Down Expand Up @@ -47,18 +51,21 @@
### Updated

- `album`:

- handle some edge cases when string **EP** or **LP** is followed with data relevant to
the album
- do not remove artist or label when it is preceded by **` x `** or followed by characters
- do not remove artist or label when it is preceded by **`x`** or followed by characters
**`'`**, **`_`** and **`&`**, or words **EP**, **LP** and **deluxe**
- handle apostrophes more reliably
- Do not remove **VA** or **V/A** from the beginning when followed by a word or a number

- `album` / `title`:

- Remove **`Various -`** from album and track names
- Handle this [album sent to us by the devil himself]

- `catalognum`:

- allow catalogue numbers like **Dystopian LP01**
- parse a _range_ of catalogue numbers when it is present, for example
**TFT013SR - TFT-016SR**
Expand Down
2 changes: 1 addition & 1 deletion beetsplug/bandcamp/metaguru.py
Original file line number Diff line number Diff line change
Expand Up @@ -77,7 +77,7 @@ def from_html(cls, html: str, config: Optional[JSONDict] = None) -> "Metaguru":

@cached_property
def excluded_fields(self) -> Set[str]:
return set(self.config.get("excluded_fields") or [])
return set(self.config.get("exclude_extra_fields") or [])
snejus marked this conversation as resolved.
Show resolved Hide resolved

@property
def comments(self) -> Optional[str]:
Expand Down
101 changes: 100 additions & 1 deletion poetry.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -27,8 +27,8 @@ Changelog = "https://github.com/snejus/beetcamp/blob/master/CHANGELOG.md"
[tool.poetry.dependencies]
python = ">=3.8, <4"

beets = { version = ">=1.5,<=1.6", extras = ["fetchart"] }
pycountry = ">=20.7.3"
beets = ">=1.4,<=2"
httpx = ">=0.27.0"
ordered-set = ">=4.0"
packaging = ">=24.0"
Expand Down
2 changes: 1 addition & 1 deletion tests/conftest.py
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,7 @@ def console():

@pytest.fixture
def beets_config():
return deepcopy({**DEFAULT_CONFIG, "exclude_extra_fields": ["comments"]})
return deepcopy(DEFAULT_CONFIG)


@pytest.fixture
Expand Down