Laurent Monin
6d9100739d
Add extra tests for prepare_releases_for_versions()
2024-04-03 14:01:34 +02:00
Laurent Monin
fccbef14c2
Merge pull request #2384 from zas/option_class_improv
...
Option class improvement
2024-04-02 19:58:26 +02:00
Laurent Monin
f28dec2469
Move cluster & file comparison weights at module level
...
- it reduces the size of Cluster and File objects
- those are constant
2024-04-02 19:51:02 +02:00
Philipp Wolfer
c333208788
PICARD-2850: Use old filename if naming script evaluates to empty filename
...
This is a variation of previously fixed PICARD-2219, but for the case
where only the basename results in an empty name.
2024-04-02 19:49:30 +02:00
Laurent Monin
c166041531
Move FILE_INFO_TAGS from class File to module picard.util.tags
...
It reduces the size of objects, and it doesn't seem we ever needed to change it.
2024-04-02 18:25:33 +02:00
Laurent Monin
2364f9f979
Add Option.get_default() method and matching tests
2024-04-02 18:03:06 +02:00
Laurent Monin
7902ab9de3
Add more tests for Option
2024-04-02 17:59:13 +02:00
Laurent Monin
8af9db4d94
Remove now unused Version.to_string()
...
- `v.to_string(short=False)` was replaced by `str(v)`
- `v.to_string(short=True)` was replaced by `v.short_str()`
2024-04-01 12:13:11 +02:00
Laurent Monin
e5b28f21a5
Replace Version.to_string(short=True) by Version.short_str()
2024-04-01 12:10:05 +02:00
Laurent Monin
c86c364a37
Version has __str__() method calls to_string(), so make use of it
2024-04-01 12:06:18 +02:00
Laurent Monin
92b09036e9
autodetect_upgrade_hooks(): returns a dict sorted by version and test that
2024-03-31 17:08:41 +02:00
Laurent Monin
5770c2ccc0
Move check for future version upgrade hook to autodetect_upgrade_hooks()
2024-03-31 16:37:36 +02:00
Laurent Monin
de381708d1
autodetect_upgrade_hooks(): throw new UpgradeHooksAutodetectError exception
2024-03-31 16:01:51 +02:00
Laurent Monin
e87333eb03
Handle another tricky case where 2 methods can be defined for same version
...
That's because we support small variations in string version (like a/alpha).
So, check if the loop tries to set the same dict key twice and raises an exception in this case.
2024-03-31 00:33:16 +01:00
Laurent Monin
4202e2ac35
Make Version.from_string() stricter, matching from start of string
2024-03-31 00:07:02 +01:00
Laurent Monin
7e0b89ccd5
Add a tricky case for upgrade hooks autodetection
...
This case is happening because we only match end of string when it comes to version detection
2024-03-31 00:03:47 +01:00
Laurent Monin
9852b8b1cc
Add tests for upgrade hooks autodetection
2024-03-30 23:59:44 +01:00
Laurent Monin
c422bae446
Merge remote-tracking branch 'upstream/master' into simplify_upgrade_config
...
# Conflicts:
# picard/config_upgrade.py
# test/test_config_upgrade.py
2024-03-30 18:35:30 +01:00
Laurent Monin
db05675957
PICARD-2848: Rename option "toolbar_multiselect" to "allow_multi_dirs_selection"
...
- the old name isn't explicit enough, and it isn't related to toolbar anymore at all
2024-03-30 14:18:01 +01:00
Laurent Monin
33027a34a3
Rename upgrade methods, extra underscores aren't needed
...
v1.0.0beta1 -> `upgrade_to_v1_0_0beta1()`
Just replace dots in current version with underscores.
Rename methods in tests
2024-03-29 11:48:11 +01:00
Laurent Monin
8af19d40cd
Merge pull request #2375 from phw/charset-detection-fixes
...
Charset detection fixes
2024-03-28 12:52:10 +01:00
Philipp Wolfer
3cc33b5516
Fix tests for detect_file_encoding without charset-normalizer installed
2024-03-23 17:47:42 +01:00
Philipp Wolfer
06ae9d7de9
Fixed utf-32 detection from BOM
...
- the utf-32-le BOM was in wrong order
- longer BOMs need to be checked first
- added BOM for utf-8-sig
2024-03-23 17:47:42 +01:00
twodoorcoupe
70e0e21450
Avoid writing syncedlyrics to other formats
2024-03-21 22:45:41 +01:00
twodoorcoupe
2f3ffee03c
Improve a2 enhanced lrc support
2024-03-20 15:53:26 +01:00
twodoorcoupe
3ef7e993fa
Add syllable timestamps and preserve language
2024-03-20 15:53:26 +01:00
twodoorcoupe
2c6c0785e6
Add support for SYLT ID3 tag
2024-03-20 15:53:26 +01:00
Serial
63e16040f1
Add test case
...
Signed-off-by: Serial <69764315+Serial-ATA@users.noreply.github.com >
2024-03-14 16:47:09 +01:00
ShubhamBhut
6a3e7b083a
PICARD-2716: Accept encodings other than utf-8 when opening CD extraction logs
2024-03-14 08:44:49 +01:00
Philipp Wolfer
0332f29e79
Fixed tests for file._info changing the test files
...
The test was saving before loading, hence having the side effect of
altering file sizes.
2024-01-17 08:48:59 +01:00
Suryansh Shakya
94250ff086
used file object instead of self.filename
2024-01-17 01:56:35 +05:30
Suryansh Shakya
0c2db251e4
removed os import and filsize from test_wav
2024-01-16 22:33:11 +05:30
Suryansh Shakya
1df7c58e72
modified test cases for 'filesize variable
2024-01-16 16:31:33 +05:30
Suryansh Shakya
939c805c36
added '~filsize' variable
2024-01-10 22:31:46 +05:30
Philipp Wolfer
b096b982cb
PICARD-2814: Fix exception on loading embedded cover with invalid ID3 type
2024-01-08 13:23:07 +01:00
Philipp Wolfer
c5b0ddf05f
PICARD-2584: If AcoustID provides not metadata load the MB recording
...
This resolves problem with AcoustID scan finding no matches or only
standalone-recordings.
2023-12-27 17:22:03 +01:00
Laurent Monin
65d0b10c10
test_length_score(): make results a tuple and reformat
2023-12-22 09:58:17 +01:00
Philipp Wolfer
82821c0992
PICARD-2805: Handle None length in Metadata.length_score
2023-12-22 09:58:17 +01:00
Philipp Wolfer
d21b4f6558
PICARD-2792: Recordings without releases must score lower than with
...
Apply a weighted scoring based on "Other" release type for recordings
without releases. Otherwise "no release" always gives full score, while
matching against a releases usually always gives some deduction to the
matching score.
2023-12-20 00:24:39 +01:00
Philipp Wolfer
762e768388
PICARD-2792: Ignore AcoustID sources for recordings without metadata
...
Avoids AcoustID recordings without linked metadata but high source count
getting a disproportional high score.
2023-12-20 00:24:39 +01:00
Philipp Wolfer
3845de8a64
Merge pull request #2154 from phw/PICARD-2331-pyqt6
...
PICARD-2331: Port to PyQt6
2023-10-30 07:40:04 +01:00
Philipp Wolfer
35f8fd01e1
Additional test for Metadata.compare_to_track
2023-10-28 00:50:19 +02:00
Philipp Wolfer
618c4f2104
PICARD-2780: Fix checking "video" flag in track comparison
...
The MB API can return "null" for the video flag of a recording. This was
not considered False in the check.
2023-10-28 00:50:19 +02:00
Philipp Wolfer
1e33a4c357
PICARD-2781: Fix matching release type score for releases without type
...
No type should use the "Other" type weight instead of leading to zero
match score.
2023-10-28 00:50:19 +02:00
Philipp Wolfer
390c65cfe1
PICARD-2331: Set minimum supported API version to 3.0
...
We need to evaluate and eventually updated all plugins, most notably those using Qt6 directly in some way.
2023-10-13 07:13:26 +02:00
Philipp Wolfer
d450c8181f
PICARD-2331: Fixed picard.config.ListOption
...
QVariantList would now convert strings to lists, leading to unexpected behavior.
2023-10-13 07:13:25 +02:00
Philipp Wolfer
3280370728
PICARD-2331: Remove get_qt_enum
...
As PyQt's enums are now proper Python enums this is no longer needed
2023-10-13 07:13:21 +02:00
Philipp Wolfer
7d55ae5e5d
PICARD-2331: Upgrade to PyQt6
2023-10-13 07:10:06 +02:00
Philipp Wolfer
eb237c1e01
PICARD-2774: Do not fail loading files with invalid ID3 image types
2023-10-10 16:18:53 +02:00
Laurent Monin
dc851395e0
Merge pull request #2333 from zas/get_qt_enum_generator
...
Make `get_qt_enum()` a generator and extend tests
2023-10-02 18:09:47 +02:00