Johnny Robeson
aa0a0a0f22
use util.py3_path for confit and env paths in tests
2016-06-30 22:24:17 -04:00
Johnny Robeson
dd729f0ce8
mark more paths as bytestrings in tests
2016-06-30 22:21:56 -04:00
Adrian Sampson
f65cf62c80
Use py3_path for plugin search paths (from #2096 )
2016-06-30 15:49:42 -07:00
Adrian Sampson
ec08272a06
Replace map with list comprehension
2016-06-30 15:47:39 -07:00
Adrian Sampson
d04fe42cee
Use py3_path for sqlite3.connect (part of #2096 )
2016-06-30 14:54:38 -07:00
Johnny Robeson
e25a95b2d3
add py3_path() for methods the only accept strings on py3
...
It returns bytes on py2, and native strings on py3.
This function was created by @sampsyo.
2016-06-30 14:50:55 -07:00
Adrian Sampson
61805b9994
Marginally more readable bytes/memoryview switch
2016-06-30 14:48:07 -07:00
Adrian Sampson
a6830ae7d1
Remove dead path normalization
...
The `self.path` field was immediately overwritten in the __init__ from dbcore,
so this was doing nothing.
2016-06-30 14:29:50 -07:00
Adrian Sampson
c532860613
Apply simple type consistency changes from #2096
...
These are the changes from that PR that just enforce the path type invariants
we already want---they're a good idea regardless of Python 3.
2016-06-30 14:22:16 -07:00
Johnny Robeson
75c226bd37
remove pathlib tests that just test pathlib itself
2016-06-30 02:09:52 -04:00
Adrian Sampson
cec632f359
Python 3 compatible formatting in unique_path
2016-06-29 22:53:51 -07:00
Adrian Sampson
386f582364
Invent a new utility to deal with native strings
2016-06-29 22:25:03 -07:00
Johnny Robeson
ecfda77f5a
bytestringify a few more paths in tests
2016-06-30 00:08:38 -04:00
Johnny Robeson
a2a4926598
replace .decode('utf-8') with as_string() from #2094
...
They are strings in py3, so they need to stay that way
2016-06-29 23:42:14 -04:00
Adrian Sampson
3d9b43fd06
Update codecov.yml for new configuration format?
...
Their web interface confusingly just says that the file is missing, but
perhaps that means the formatting is invalid? I *really* wish this stuff were
more transparent. 😢
2016-06-29 11:38:58 -07:00
Johannes Baiter
4c324fae2a
beatport: Use track numbers from API ( #2091 )
...
* beatport: Use trackNumber from API instead of enumerating the tracks
* beatport: Set medium_index to track number
* Update changelog with fixes to beatport plugin
2016-06-29 20:34:05 +02:00
Adrian Sampson
ce59658aec
Merge branch 'master' of github.com:sampsyo/beets
2016-06-29 10:55:42 -07:00
Adrian Sampson
44ca6938ff
Add FIXMEs to functemplate about py3
2016-06-29 10:51:56 -07:00
Adrian Sampson
f3df7b5dd3
Merge pull request #2095 from beetbox/pipeline_invalidation_workaround
...
Workaround for a race condition on queue invalidation
2016-06-29 10:48:48 -07:00
Adrian Sampson
89c7b78994
Disable PyPy on Travis for now
...
Travis has a very old version of PyPy which seems to be running into a
Unicode-related bug in our tests.
2016-06-29 10:43:51 -07:00
Adrian Sampson
a6098928f5
Merge branch 'master' of github.com:sampsyo/beets
2016-06-29 10:33:00 -07:00
Adrian Sampson
d5205915cc
Avoid dangerous string conversions ( #2094 )
...
This rolls back the places in #2094 where `six.text_type(s)` was used where
`s` might be a bytestring. We almost never want that conversion, because it
uses the default encoding (almost always ASCII). The need for it indicates a
problem somewhere else, where bytes were produced when we were expecting
unicode strings.
2016-06-29 10:30:26 -07:00
wordofglass
e2c6547635
fetchart: Clarify the deprecation of remote_priority in docs and
...
warning, closes #2092
2016-06-29 19:18:06 +02:00
Adrian Sampson
4ae7448c25
Simplify print_ changes ( #2094 )
2016-06-29 10:12:38 -07:00
Adrian Sampson
dc0fff0ca0
Merge pull request #2094 from jrobeson/ui-print_-args-must-be-unicode
...
make sure ui.print_() only accepts unicode strings
2016-06-29 10:08:26 -07:00
wordofglass
ebf44fd6cd
Workaround for a race condition on queue invalidation, Issue #2078
2016-06-29 18:22:44 +02:00
Johnny Robeson
6b3cc6ff37
adapt print_() callers to send unicode strings
2016-06-29 03:17:02 -04:00
Johnny Robeson
2f1cd59e1b
make sure ui.print_() only accepts unicode strings
2016-06-29 03:16:42 -04:00
Adrian Sampson
10a47e98d0
Merge branch 'master' of github.com:beetbox/beets
2016-06-28 20:41:14 -07:00
Adrian Sampson
aea692a112
Fix applying track index in per_disc_numbering
...
Fixes #2085 . This is the second half, which deals with actually applying the
track number. The previous condition didn't acknowledge that `Item` coerced
`None` to 0 to enforce its field types.
2016-06-28 20:38:41 -07:00
Adrian Sampson
f46bfdf219
Fix index display with per_disc_numbering
...
If `medium_index` is missing, as it is from the Beatport source, the display
would show "None" instead of the global index (a fallback). This is half of
the problem in #2085 .
2016-06-28 20:34:04 -07:00
Johnny Robeson
bdbed1f6d9
only decode input_ results on python 2
2016-06-28 23:33:39 -04:00
Johnny Robeson
159e24a14b
only decode decarg results on python 2
2016-06-28 23:32:46 -04:00
Johnny Robeson
5d4e3396d2
wrap a path in displayable_path in commands
2016-06-28 23:28:58 -04:00
Adrian Sampson
44e0e44108
Enforce type of ID3 desc fields
2016-06-28 20:22:58 -07:00
Adrian Sampson
0da1ba9299
Enforce string types for mutagen.Image
2016-06-28 20:19:20 -07:00
Adrian Sampson
4955933670
Update Mutagen dependency ( #2088 )
...
This lets us remove a few more workarounds that Mutagen itself has addressed
already.
2016-06-28 10:58:08 -07:00
Adrian Sampson
192dd321f1
permissions: Add debug logging
2016-06-28 10:53:23 -07:00
Adrian Sampson
890b9e81e3
Fix #2089 : correct permissions configuration
...
This reverts the change in 44380db6e8 , where we
lost the ability to "reinterpret" decimals in the YAML configuration file as
octal permissions values.
2016-06-28 10:51:13 -07:00
Adrian Sampson
84bfbe95b9
permissions: More helpful logging ( #2089 )
2016-06-28 10:39:35 -07:00
Adrian Sampson
b099503a6c
permissions: Use correct path conversions
...
It looks like the original author mistook `bytestring_path` for `syspath`.
2016-06-28 10:31:57 -07:00
Adrian Sampson
e33c19a3e9
permissions: Use proper logging ( #2089 )
...
Refactored so we can use the proper logging infrastructure instead of `print`.
2016-06-28 10:29:26 -07:00
Adrian Sampson
3a700eb2a4
Merge pull request #2088 from lazka/mutagen-cleanup
...
Mutagen cleanup
2016-06-28 10:17:16 -07:00
Adrian Sampson
7827d86917
Note about six in changelog
2016-06-28 10:12:18 -07:00
Adrian Sampson
e39b6bd3fe
Fix in-package version number ( fix #2086 )
2016-06-28 10:10:03 -07:00
Christoph Reiter
629241efd3
mediafile: Cleanup mutagen error handling
...
Instead of the individial mutagen format exceptions use the
mutagen.MutagenError exception introduced in 1.25.
Since 1.33 mutagen will only raise MutagenError for load/save/delete
and no longer raise IOError. Translate both errors to UnreadableFileError
to support older and newer mutagen versions. Unify error handling
in __init__(), save() and delete().
Since it's no longer possible to get an IOError from MediaFile, adjust
all callers and tests accordingly.
This was tested with mutagen 1.27 and current mutagen master.
2016-06-28 16:43:34 +02:00
Christoph Reiter
45404bce85
mediafile: Add note about MPEGInfo.channels being available in newer mutagen versions
2016-06-28 16:43:34 +02:00
Christoph Reiter
9f16cfd078
mediafile: Remove alac detection workaround
...
No longer needed since we depend on mutagen 1.27
2016-06-28 16:43:34 +02:00
Christoph Reiter
3984febf6c
mediafile: Add note to ASF.delete that it's fixed in newer mutagen
2016-06-28 16:43:34 +02:00
Adrian Sampson
2515f98dfc
Merge pull request #2087 from lazka/fix-setup-py-test
...
tests: Fix setup.py test
2016-06-27 23:04:20 -07:00