Stein Magnus Jodal
6d82cdb611
tests: Cleanup reset_mock() usage
2015-05-06 21:06:30 +02:00
Stein Magnus Jodal
a17c413a70
Merge branch v1.0.x into develop
2015-05-06 20:47:52 +02:00
Thomas Kemmer
636639a201
Fix #1162 : Ignore None results and exceptions from PlaylistsProvider.create().
2015-05-06 14:50:21 +02:00
Thomas Adamcik
4aa984207b
tests: Split up core bad backend tests and unify naming
2015-05-06 01:01:12 +02:00
Thomas Adamcik
e7b241e18b
core: Update playlists to handle bad data from backends and exceptions
2015-05-06 00:28:58 +02:00
Thomas Adamcik
3426633c78
core: Make sure we handle bad mixer data and exceptions.
2015-05-05 23:41:46 +02:00
Thomas Adamcik
dd4a8f3b78
core: Make sure library can handle bad data from backends
...
Note that None values are just ignored, while other bad data logs an error
message and is ignored.
2015-05-05 22:55:53 +02:00
Stein Magnus Jodal
746c3059ba
Merge pull request #1160 from adamcik/feature/model-corner-case-handling
...
Move new models features to new class
2015-05-05 08:08:05 +02:00
Thomas Adamcik
b480311d66
models: Add ValidatedImmutableObject and "revert" ImmutableObject
...
Testing with extension that use custom models it was discovered that the
changes to have type safe models were a bit to invasive to be suitable for a
minor release. This change fixes this by bringing back ImmutableObjects in
their old form, and moving the shinny new features to ValidatedImmutableObject.
A subset of the tests for ImmutableObjects have been resurrected to have some
confidence in this working the way we think it should.
2015-05-04 23:41:11 +02:00
Thomas Adamcik
7f6809aebb
models: Explicitly define which models can be deserialized
2015-05-04 22:36:27 +02:00
Thomas Adamcik
07159f69c2
models: Decouple fields tests from the model metaclass
2015-05-04 21:37:17 +02:00
Thomas Adamcik
bb95dc3b9b
models: Make sure parent fields are used by children.
...
Without this change any sub-class would end up with an empty _fields and none
of the actual fields would be writable even internally.
2015-05-03 22:58:43 +02:00
Stein Magnus Jodal
b4a6a4da7f
Merge branch 'v1.0.x' into develop
2015-04-30 08:44:10 +02:00
Stein Magnus Jodal
2f96dacae8
Bump version to 1.0.4
2015-04-30 08:41:03 +02:00
Thomas Adamcik
94039e06dc
models: Make sure sub-classes can extend models
2015-04-29 21:32:43 +02:00
Thomas Adamcik
9182a7870e
utils: Support opting out of adding auth to proxy
2015-04-29 00:38:06 +02:00
Thomas Adamcik
8cf9da3d55
utils: Fix corner case in format_proxy scheme handling
2015-04-29 00:27:56 +02:00
Thomas Adamcik
5153d9e19f
utils: Add format_user_agent helper
2015-04-28 23:51:19 +02:00
Thomas Adamcik
a48aadaaed
utils: Add basic format proxy helper
2015-04-28 23:50:52 +02:00
Thomas Adamcik
8851fb151c
models: Allow Ref.type to have any value
...
This is to address a potential breakage brought up in #1150 as it turns out
Mopidy-Podcast uses custom models and ref types.
2015-04-28 22:58:15 +02:00
Stein Magnus Jodal
97c336200b
Merge branch 'v1.0.x' into develop
2015-04-28 00:02:26 +02:00
Stein Magnus Jodal
9c2aabb899
Bump version to 1.0.3
2015-04-28 00:00:25 +02:00
Stein Magnus Jodal
b14aee3e04
Merge branch 'v1.0.x' into develop
...
Conflicts:
docs/changelog.rst
2015-04-27 00:18:41 +02:00
Stein Magnus Jodal
21289f8fe5
Bump version to 1.0.2
2015-04-27 00:02:12 +02:00
Thomas Adamcik
651e89357f
tests: Fix IssueGH1120RegressionTest flakiness
2015-04-26 23:23:30 +02:00
Thomas Adamcik
7e59a5aecb
models: Split models into smaller modules
2015-04-25 00:11:41 +02:00
Thomas Adamcik
b3ea425fd0
tests: Fix IssueGH1120RegressionTest flakiness
2015-04-24 19:26:02 +02:00
Stein Magnus Jodal
3dba4f4208
Merge branch 'v1.0.x' into develop
2015-04-23 23:40:04 +02:00
Stein Magnus Jodal
9c793a38ff
Bump version to 1.0.1
2015-04-23 23:35:45 +02:00
Thomas Adamcik
d4c695ac75
mpd: Split browse and playlist name to uri caching
2015-04-23 23:08:25 +02:00
Thomas Adamcik
a62293c316
core: Add play(tlid) support
2015-04-22 20:55:51 +02:00
Thomas Adamcik
fba4069cfd
core: Make index return current index when missing args
2015-04-19 00:22:52 +02:00
Thomas Adamcik
6a7005be1e
core: Add tlid argument to index calls.
...
Should save clients from having to pass tl_track models around.
2015-04-19 00:22:52 +02:00
Stein Magnus Jodal
7752ebe7e4
Merge pull request #1130 from adamcik/feature/more-deprecation-cleanups
...
More deprecations and correspoding cleanups
2015-04-17 00:18:28 +02:00
Thomas Adamcik
09027854c6
validation: Reject iterators as core arguments
...
iter() always never re-wraps an iterator, so 'iter(i) is iter(i)' tests if we
wrapped a container or if we already had an iterator. I also tried
types.GeneratorType and inspect helpers but they did not work for this use
case.
2015-04-17 00:05:46 +02:00
Thomas Adamcik
81fd426caf
tests: Update tests to not used deprecated kwargs
2015-04-17 00:00:58 +02:00
Thomas Adamcik
efad50c253
cleanup: Stop using deprecated copy()
2015-04-17 00:00:58 +02:00
Stein Magnus Jodal
e265f5d673
Merge pull request #1128 from adamcik/feature/validate-core-input
...
Validate core inputs
2015-04-16 07:45:17 +02:00
Thomas Adamcik
98587f5098
review: Fix test name
2015-04-15 23:48:44 +02:00
Thomas Adamcik
97235f9441
core: Don't allow TLIDs in queries, or integers
...
Handle this in tracklist.filter() which is the only API that allows number
and/or TLIDs.
2015-04-14 23:46:20 +02:00
Thomas Adamcik
324bec1f4a
core: Validate core API calls
2015-04-14 23:45:56 +02:00
Thomas Adamcik
8646ba4252
utils: Add validation helpers for verifying core APIs
2015-04-14 23:16:12 +02:00
Stein Magnus Jodal
093c4340cd
Merge branch 'v1.0.x' into develop
...
Conflicts:
mopidy/audio/scan.py
tests/audio/test_scan.py
2015-04-13 08:19:14 +02:00
Thomas Adamcik
94628b5f82
local: Don't use tuple form of TlTracks in tests
2015-04-13 00:50:33 +02:00
Thomas Adamcik
1b10a783d3
mpd: Update tests to use setters and actual booleans
2015-04-13 00:16:09 +02:00
Stein Magnus Jodal
f85ea2a39d
flake8: Fix new import order warnings
...
(cherry picked from commit 71ab9733c7 )
2015-04-12 23:05:53 +02:00
Stein Magnus Jodal
71ab9733c7
flake8: Fix new import order warnings
2015-04-12 23:03:46 +02:00
Thomas Adamcik
20019edf2d
models: Fix review comments
2015-04-12 16:03:51 +02:00
Thomas Adamcik
6327a67874
models: Make sure we really only add __weakref__ once
2015-04-11 00:47:53 +02:00
Thomas Adamcik
9bc4d8b713
audio: Make scanner handle all media types.
...
I don't think this makes anything slower, as before we would still decode
anything we came across in the hopes that we find raw audio.
2015-04-11 00:29:07 +02:00
Stein Magnus Jodal
c367d350f7
Merge pull request #1117 from adamcik/feature/models-memory-reduction
...
Improve models memory usage
2015-04-08 23:29:08 +02:00
Thomas Adamcik
2cc91c0a7f
core: Fix review comments for PR#1111
2015-04-08 23:13:07 +02:00
Thomas Adamcik
e5f59495fc
core: Update refresh test case to fail on multiple calls to same backend
2015-04-08 21:18:18 +02:00
Thomas Adamcik
511cf4e326
core: Catch exceptions when browsing in backends
...
Also splits browse into to method to better distinguish the two possible code
paths.
2015-04-08 21:17:44 +02:00
Thomas Adamcik
682c6b1c6c
Merge branch 'develop' into feature/make-core-more-robust
...
Conflicts:
docs/changelog.rst
2015-04-08 20:28:10 +02:00
Thomas Adamcik
05244f7e60
models: Deprecate copy and add replace method
...
Changed as with the memoization copy was lying, so replace is a better name.
2015-04-08 01:41:50 +02:00
Thomas Adamcik
b7375323e9
models: Memoize identical instances automatically
...
This combined with the previous changes has brought the memory use for a 14k
track test-set down from about 75MB to 17MB or so. Note that this does however,
mean that copy is now lying to us as it does not such thing whenever it can
avoid it.
2015-04-08 01:14:56 +02:00
Thomas Adamcik
86481b1d50
models: Shortcut case where copy didn't change anything
...
We no longer copy in this case and will just give you the same instance back.
2015-04-08 00:34:02 +02:00
Thomas Adamcik
0fee1b4b11
models: Switch to slots to reduce memory usage per instance
2015-04-08 00:30:53 +02:00
Thomas Adamcik
08fd99ffdb
models: Add Identifer type which interns values.
...
This gives some moderate memory saving since the values are used in multiple
places.
2015-04-08 00:11:23 +02:00
Stein Magnus Jodal
7bda4f835f
xdg: Add XDG dir utils
2015-04-07 23:50:59 +02:00
Thomas Adamcik
9b442e1563
review: Address review comments
2015-04-06 23:27:46 +02:00
Thomas Adamcik
50f68064be
core: Update PlaylistsController to catch backend exceptions
2015-04-06 02:13:51 +02:00
Thomas Adamcik
66771dec68
core: Update LibraryController to catch backend exceptions
2015-04-06 02:12:56 +02:00
Thomas Adamcik
11c9aa4ad0
Merge branch 'develop' into feature/implement-gapless
...
Conflicts:
mopidy/backend.py
mopidy/commands.py
mopidy/core/actor.py
mopidy/core/playback.py
tests/audio/test_actor.py
tests/core/test_playback.py
tests/local/test_playback.py
2015-04-05 19:24:56 +02:00
Thomas Adamcik
2d03cd7290
models: Make fields handle unsetting defaults in __dict__
2015-04-05 13:09:19 +02:00
Thomas Adamcik
73415ce60f
models: Make sure del on attributes does not work
2015-04-05 13:08:15 +02:00
Thomas Adamcik
07912e1091
models: Add fields for supporting validation of models
...
Feature makes use of python descriptors to hook in type checking and other
validation when fields get set.
2015-04-05 13:08:15 +02:00
Thomas Adamcik
5c0430ef4a
tests: Move models tests into a directory
2015-04-05 13:08:15 +02:00
Thomas Adamcik
8f96bf0f39
tests: Fix some model use oddities
2015-04-05 13:08:15 +02:00
Stein Magnus Jodal
c4940cbea2
autopep8: Add space after class signature/docstring
2015-04-03 00:05:26 +02:00
Thomas Adamcik
83c3d0013f
Merge pull request #1096 from jodal/feature/faster-travis-build
...
travis: Use new faster build infrastructure
2015-04-02 21:41:43 +02:00
Stein Magnus Jodal
2bc63ec027
audio: Skip MP3 tests if missing plugin
2015-04-02 20:53:29 +02:00
Thomas Adamcik
9ede14f4a1
tests: Convert to using deprecation helpers across the board.
2015-03-30 23:50:54 +02:00
Thomas Adamcik
f4c93619d1
core: Make core tracklist.add(tracks=...) deprecation safe
2015-03-29 23:11:00 +02:00
Thomas Adamcik
dc673d554c
tests: Ignore deprecated tracklist.add(tracks=...) in local tests
...
Note, this is mostly because these tests are just core tests in disguise and
need a lot more love than I can give them right now.
2015-03-29 23:11:00 +02:00
Thomas Adamcik
c85689edad
mpd: Make mpd warnings safe with respect to tracklist.add(tracks=...)
2015-03-29 23:11:00 +02:00
Thomas Adamcik
f7399c1849
tests: Stop using playlist filters in mpd music_db tests
2015-03-29 23:11:00 +02:00
Thomas Adamcik
79b0584887
tests: Stop using tracklist add tracks in mpd status test
2015-03-29 23:11:00 +02:00
Thomas Adamcik
7d42d028c6
tests: Stop using tracklist tracks in mpd playback tests
2015-03-29 23:11:00 +02:00
Thomas Adamcik
faf8174ef7
tests: Update mpd.test_status to not use tracklist.add(tracks=...)
2015-03-29 23:11:00 +02:00
Thomas Adamcik
a8860faa35
tests: Cleanup mpd.protocol.current_playlist tests
...
- Split into smaller test cases more or less per command
- Created a BasePopulatedTracklistTestCase with a sensible setUp
- Modified test cases to work with the common tracklist state
- Replaced all calls to tracklist.add(tracks=...) with uris=...
- Test tracklist ordering in more compact way that also gives better error
messages
2015-03-29 23:11:00 +02:00
Thomas Adamcik
d3b275e1a4
core: Mark tracklist.add by URI as deprecated
2015-03-29 23:11:00 +02:00
Thomas Adamcik
49fc9941a1
core: Mark searching via keyword argument based query deprecated
2015-03-29 23:11:00 +02:00
Thomas Adamcik
0ab52a73fa
core: Mark library.lookup by uri deprecated
...
Updates core, mpd and tests to not use deprecated calls or safely catch them
when running with -W error.
2015-03-29 23:11:00 +02:00
Thomas Adamcik
f5f9899db9
tests: Make bases test classes in core
2015-03-29 23:10:58 +02:00
Thomas Adamcik
a54551d985
core: Mark get_playlists and filter as deprecated
2015-03-29 23:10:19 +02:00
Thomas Adamcik
5a3fb64250
core: Emit deprecation warning for library.find_exact
2015-03-29 23:08:03 +02:00
Thomas Adamcik
b31f0c421f
tests: Make tests warning safe
2015-03-26 21:58:44 +01:00
Stein Magnus Jodal
2c11344434
dummy: Make it obvious that method is test-only
2015-03-25 13:16:27 +01:00
Stein Magnus Jodal
c9f60170f8
Merge pull request #1084 from tkem/feature/m3u_replace_invalid_chars
...
m3u: Replace slashes in playlist names with pipes.
2015-03-25 09:48:39 +01:00
Stein Magnus Jodal
36fba3d67d
flake8: Fix unussed import
2015-03-25 09:48:24 +01:00
Thomas Kemmer
a9393c3850
m3u: Replace slashes in playlist names with pipes.
2015-03-25 05:36:03 +01:00
Stein Magnus Jodal
d768a3b4f7
Merge pull request #1082 from adamcik/feature/only-support-new-style-search-in-backends
...
core/backend: Stop supporting old search signatures
2015-03-25 00:09:06 +01:00
Stein Magnus Jodal
f2a56edbf0
dummy: Replace playlists property with test-only helper
2015-03-25 00:03:56 +01:00
Thomas Adamcik
ead725e995
core/backend: Stop supporting old search signatures
...
All backends are expected to support the exact argument. A friendly log message
will be printed to prompt users to upgrade backends that fail due to this.
2015-03-24 23:54:49 +01:00
Stein Magnus Jodal
a8e6cd26dc
core: Warn if backend does not implement as_list()
...
Fixes #1080
2015-03-24 23:40:50 +01:00
Thomas Adamcik
141c14ad45
core: Add exact to search() and deprecate find_exact()
...
Backends that still implement find_exact will be called without exact as an
argument to search, and we will continue to use find_exact. Please remove
find_exact from such backends and switch to the new search API.
2015-03-24 09:31:03 +01:00
Stein Magnus Jodal
23e2295c46
dummy: Fix playlists.get_items() bug
2015-03-24 01:54:07 +01:00
Thomas Adamcik
24fe242d56
core/backend: Remove find_exact from backends
...
Functionality has been replaced with an `exact` param in the search method.
Backends that still implement find_exact will continue being called via
the old method for now.
2015-03-23 23:55:03 +01:00
Stein Magnus Jodal
07cf962434
Merge branch 'develop' into feature/new-playlists-api
...
Conflicts:
docs/changelog.rst
2015-03-23 21:45:32 +01:00
Stein Magnus Jodal
dbe4165a0f
m3u: Only test through core actor
2015-03-23 13:31:25 +01:00
Thomas Adamcik
6d22c4fd59
core: Remove set_current_tl_track
2015-03-23 00:50:05 +01:00
Thomas Adamcik
07f0453c6e
core: Make event triggers internal
2015-03-23 00:50:05 +01:00
Stein Magnus Jodal
d37bd62bb1
backend: Remove playlists.playlists property
2015-03-23 00:44:39 +01:00
Stein Magnus Jodal
e3f2e368c7
m3u: Add playlists.get_items()
2015-03-23 00:44:39 +01:00
Stein Magnus Jodal
4bae9c874c
m3u: Add playlists.as_list()
2015-03-23 00:44:39 +01:00
Stein Magnus Jodal
5693b454ee
m3u: Use lookup() instead of playlists prop in tests
2015-03-23 00:44:39 +01:00
Stein Magnus Jodal
bd2e4f7af0
core: Reimplement get_playlists() using new backend API
2015-03-23 00:44:39 +01:00
Stein Magnus Jodal
4f3a0839b3
core: Add playlists.as_list() and playlists.get_items(uri)
2015-03-23 00:44:39 +01:00
Stein Magnus Jodal
55b1eb7383
backend: Add playlists.as_list() and playlists.get_items(uri)
2015-03-23 00:44:39 +01:00
Stein Magnus Jodal
9462071e0c
Merge pull request #1074 from adamcik/fix/1069-handle-broken-backends
...
core: Protect against old clients that implement backend.play
2015-03-23 00:05:05 +01:00
Thomas Adamcik
a74bc24bdc
core: Protect against old clients that implement backend.play
2015-03-22 23:54:37 +01:00
Thomas Adamcik
7ec2342921
core: Normalize search queries
...
This is needed as otherwise each and every backend needs to handle the fact
that some "bad" clients might send {'field': 'value'} instead of
{'field': ['value']} Though the real problem isn't the clients but our
organically grown query API.
2015-03-22 23:33:49 +01:00
Thomas Adamcik
28f8a99090
review: Fixed mock use and docstring
2015-03-22 23:14:29 +01:00
Thomas Adamcik
efe9430c7a
core: Update playback code to take change track into account.
...
This change has us checking the return value of change_track when deciding if
the play call was a success or if the track is unplayable. Which ensures that
the following can no longer happen: 1) play stream 2) play stream that fails
change_track 3) stream 1) continues playing. Correct behavior being the next
stream playing instead.
2015-03-22 22:12:51 +01:00
Thomas Kemmer
67d4dac862
m3u: Store by URI internally
...
Based upon tkem's PR #1053
2015-03-22 21:54:29 +01:00
Stein Magnus Jodal
12649265b1
Bump version to 1.0.0
...
So that the development version of extensions can start depending on
1.0.0 and test that they work with the changed APIs.
2015-03-22 09:25:04 +01:00
Stein Magnus Jodal
56dca0e931
Merge pull request #1064 from adamcik/fix/1052-break-backend-play
...
backend: Change playback API (breaking change!)
2015-03-22 09:19:39 +01:00
Stein Magnus Jodal
b2f60bc338
m3u: Extract new M3U backend from local
...
Fixes #1054
2015-03-21 08:13:45 +01:00
Thomas Adamcik
31d12c7e1d
Merge pull request #1065 from jodal/fix/1060-tracklist-add-uris
...
core: Add uris kwarg to tracklist.add()
2015-03-21 00:42:22 +01:00
Stein Magnus Jodal
2bc3db0d0e
core: Add uris kwarg to tracklist.core()
...
Fixes #1060
2015-03-21 00:16:24 +01:00
Stein Magnus Jodal
f67e55618c
core: Make lookup(uris=...) return dict with all uris
...
All uris given to lookup should be in the result even if there is no
backend to handle the uri, and the lookup result thus is an empty list.
As a side effect, future.get() is now called in the order of the URIs
in the `uris` list, making it easier to mock out
backend.library.lookup() in core layer tests.
2015-03-21 00:11:15 +01:00
Thomas Adamcik
bbf52eede9
backend: Change playback API (breaking change!)
...
While trying to remove traces of stop calls in core to get gapless working I
found we had no way to switch to switch tracks without triggering a play. This
change fixes this by changing the backends playback provider API.
- play() now _only_ starts playback and does not take any arguments.
- prepare_change() has been added, this could have been avoided with a kwarg to
change_track(track), but that would break more backends.
- core has been updated to call prepare_change+change_track+play as needed.
- tests have been updated to handle this change.
Longer term I hope to completely rework the playback API in backends, as 99% of
our backends only use change_track(track) to translate URIs. So we should make
simple case simple, and handle mopidy-spotify / appsrc in some other way.
Cherry picked from the WIP gapless branch.
2015-03-21 00:05:00 +01:00
Stein Magnus Jodal
861f60e6f1
core: Make history.add() private
...
Instead of changing the signature to add(uri, name) I opted for
renaming it to _add_track(track).
Since it's internal we may change it whenever we like to. Since you need
different logic for extracting an interesting name from a track and from
a ref or a stream title, it makes sense to add another method for adding
refs/stream titles to the history when that time comes.
Fixes #1056
2015-03-20 22:41:56 +01:00
Stein Magnus Jodal
dc982cd880
Merge pull request #1047 from adamcik/fix/1008-add-uris-to-lookup
...
core: Add uris argument to library.lookup (Fixes #1008 )
2015-03-18 23:24:29 +01:00
Stein Magnus Jodal
65c5242b14
backend: Remove default impl of PlaylistProvider.playlists
...
The default was insane. For one, because overriding e.g. just the
getter would make the property have a pair of working getter and
setter that are entirely disconnected.
2015-03-18 00:25:26 +01:00
Thomas Adamcik
fdc84c3905
core: Add uris argument to library.lookup ( Fixes #1008 )
...
For now this doesn't add any corresponding APIs to backends, or for that matter
tracklist.add(uris). This is just to get the API in for clients in 0.20.
2015-03-17 23:49:21 +01:00
Thomas Adamcik
65f87e89f1
core: Update pending track handling and fix consume / gapless issue
...
- Pending track should only be triggered by stream_changed if there is one.
- Tracklist changed was incorrectly calling stop breaking tests and gapless
- Tests have been updated to capture and replay audio events. This should avoid
test deadlocks while still using the audio fakes.
2015-03-16 23:50:08 +01:00
Stein Magnus Jodal
5240b50f8b
Merge pull request #1040 from adamcik/fix/only-update-stream-title-for-streams
...
core: Only emit stream title changed for streams
2015-03-15 21:27:50 +01:00
Stein Magnus Jodal
0f21e7425e
Merge pull request #1039 from adamcik/bug/923/duration-as-int-or-none
...
core: Correctly handle missing duration in seek.
2015-03-15 21:26:16 +01:00
Thomas Adamcik
28d047e1d2
core: Only emit stream title changed for streams
...
This is done by checking for the presence of the organization tag typically set
by web streams. This might be a bit to strict and a bad heuristic, but it's
currently better than wrongly emitting stream titles for non streams IMO.
2015-03-15 11:42:01 +01:00
Thomas Adamcik
6adeea6009
core: Correctly handle missing duration in seek.
...
Seeks will now fail when the duration is None, this is an approximation to if
the track is seekable or not. This check is need as otherwise seeking a radio
stream will trigger the next track.
If the track truly isn't seekable despite having a duration we should still
fail as GStreamer will reject the seek.
2015-03-15 11:29:07 +01:00
Stein Magnus Jodal
aed91008a3
deps: Add executable path to 'mopidy deps' output
2015-03-14 23:07:59 +01:00
Stein Magnus Jodal
336ef4534a
tests: Use assertEqual instead of assertEquals
2015-03-14 23:01:49 +01:00
Thomas Kemmer
29b4a2075a
local: Fix get_images() for local libraries returning single track from lookup().
2015-03-14 16:12:46 +01:00
Thomas Adamcik
6260ba00be
core: Test stream_title_changed listener
2015-03-14 00:30:46 +01:00
Thomas Adamcik
67f9bd73bf
Merge branch 'develop' into feature/stream-reference
...
Conflicts:
docs/changelog.rst
2015-03-14 00:28:51 +01:00
Thomas Adamcik
ea97047607
flake8: Fix bad import
2015-03-14 00:10:21 +01:00
Thomas Adamcik
4db4b4d63b
core: Reduce stream metadata to just the title
...
The API I really want for this to support regular tracks, stream updates and
dynamic playlists is still unclear to me. As such I'm taking the KISS approach
and reducing this to just the stream title and nothing else.
If all goes as planed this will be replaced by playback_track_changed(tlid, ref)
style events and other improvements in a later version.
2015-03-13 23:56:51 +01:00
Thomas Adamcik
980e04537b
Merge pull request #1035 from jodal/feature/none-mixer-adjustments
...
core/mpd: None-mixer adjustments
2015-03-13 23:31:20 +01:00
Stein Magnus Jodal
30badf60b9
Merge pull request #1033 from adamcik/feature/scanner-with-typefind
...
Add typefinding / MIME guess to scan code.
2015-03-13 23:22:12 +01:00
Stein Magnus Jodal
b29f9e10c4
core: get_mute() with no mixer returns None
...
...and not False, because the mute state is unknown (None) and not
unmuted (False) when there is no mixer.
Note that this change does not affect the MPD responses.
2015-03-13 21:19:56 +01:00
Thomas Adamcik
083ec130f9
Merge pull request #1015 from ZenithDK/feature/mixer_none
...
core/mpd: Allow empty or 'none' as audio.mixer value
2015-03-13 17:57:51 +01:00
Thomas Adamcik
cee73b5501
audio: Add support for checking seekable state in scanner
...
Return type of scanner changed to a named tuple with (uri, tags, duration,
seekable). This should help with #872 and the related "live" issues.
Tests, local scan and stream metadata lookup have been updated to account for
the changes.
2015-03-12 22:11:50 +01:00
Thomas Kemmer
e655d39384
Fix #1031 : Add get_images() to local library.
2015-03-12 11:43:27 +01:00
Thomas Adamcik
6fcd43891e
core: Switch to reference based stream info.
...
- Adds tests for new behaviors in core.
- Adds stream name to MPD format (fixes #944 )
- Adds 'stream_changed' core event (needs a new name/event)
- Adds 'get_stream_reference' (which I'm also unsure about)
The bits I'm unsure about are mostly with respect to #270 , but I'm going ahead
with this commit so we can discuss the details in PR with this code as an
example.
2015-03-10 21:55:51 +01:00
Lasse Bigum
cb19b2c48c
Allow 'none' as audio.mixer value
...
To disable mixing altogether, you can now set the configuration value
audio/mixer to 'none'.
2015-03-10 00:26:22 +01:00
Thomas Adamcik
e639b2b18b
tests: Add method for emitting fake tags changed in tests
2015-03-09 21:55:23 +01:00
Thomas Adamcik
29b00cabf9
Merge pull request #1028 from tkem/fix/1026
...
Fix #1026 : Sort local playlists by name.
2015-03-08 23:53:04 +01:00
Lasse Bigum
cf0b666a0a
Add tests for PlaybackController get_current_(tl_)track
...
Add some more test cases for PlaybackController
2015-03-08 04:10:02 +01:00
Thomas Kemmer
94c418d5e6
Fix #1026 : Sort local playlists by name.
2015-03-07 22:42:22 +01:00
Thomas Kemmer
9150c34053
Fix #1023 : Remove support for local album images from coverartarchive.org
2015-03-06 10:02:08 +01:00
Stein Magnus Jodal
2280a533c0
Use py.test as test runner
2015-03-05 00:35:20 +01:00
Thomas Adamcik
319c1fc1e3
local: Readd support for search without limit for get_distinct support
2015-03-02 23:39:06 +01:00
Thomas Adamcik
7c2c4c1c45
Merge branch 'fix/local-json-limit-offset' of https://github.com/ali/mopidy into develop
2015-03-02 23:18:39 +01:00
Thomas Adamcik
8cc9c9bbc0
core: Rename list_distinct to get_distinct
2015-03-02 22:41:09 +01:00
Thomas Adamcik
5fd2afa7ca
mpd: Switch list command to using list_distinct
2015-03-02 00:26:51 +01:00
Stein Magnus Jodal
0634de6e28
Merge pull request #1020 from adamcik/feature/fix-ws-disconnect-race
...
Fix WS disconnect race
2015-03-02 00:16:09 +01:00
Thomas Adamcik
0fb6c620df
docs: Add changelog entry for broadcast race
2015-03-02 00:05:58 +01:00
Thomas Adamcik
4ee7dd73bd
http: Make WS broadcast more robust against disconnect race
...
Adds some WebSocketHandler tests that actually connect using a WS client and
plugs a potential race condition.
Any call to write_message could fail, either due to WebSocketClosedError like
in the log below, or simply due to socket errors. To play it safe we catch all
errors and debug log that a broadcast failed.
2015-02-26 21:24:02,266 ERROR [HttpServer] /home/adamcik/dev/mopidy/mopidy/http/handlers.py:116
mopidy.http.handlers WebSocket request error: deque index out of range
2015-02-26 21:24:10,098 ERROR [HttpFrontend-11] build/bdist.linux-x86_64/egg/pykka/actor.py:268
pykka Unhandled exception in HttpFrontend (urn:uuid:e376bd95-c32e-4e17-ad20-7d0b3c0cf2b2):
Traceback (most recent call last):
File "build/bdist.linux-x86_64/egg/pykka/actor.py", line 200, in _actor_loop
response = self._handle_receive(message)
File "build/bdist.linux-x86_64/egg/pykka/actor.py", line 294, in _handle_receive
return callee(*message['args'], **message['kwargs'])
File ".../dev/mopidy/mopidy/http/actor.py", line 77, in on_event
on_event(name, **data)
File ".../dev/mopidy/mopidy/http/actor.py", line 84, in on_event
handlers.WebSocketHandler.broadcast(message)
File ".../dev/mopidy/mopidy/http/handlers.py", line 78, in broadcast
client.write_message(msg)
File ".../dev/mopidy-virtualenv/local/lib/python2.7/site-packages/tornado/websocket.py", line 183, in write_message
raise WebSocketClosedError()
WebSocketClosedError
2015-03-02 00:05:21 +01:00
Lasse Bigum
fbd534efbf
Don't change to playing state when seeking in paused state
...
Do not switch state from paused to playing when seeking
2015-03-01 15:50:17 +01:00
Thomas Adamcik
47911f24ea
Merge pull request #1013 from tkem/fix/get_images
...
backend: Improve default get_images() implementation with album/artist URIs.
2015-02-28 12:35:16 +01:00
Thomas Kemmer
301f732047
Improve default get_images() implementation with album/artist URIs.
2015-02-27 22:22:28 +01:00
Stein Magnus Jodal
5536c79be5
Merge pull request #1005 from adamcik/fix/808
...
Add per logger colors
2015-02-25 23:18:08 +01:00
Thomas Adamcik
b11d89d72f
config: Convert the loglevel schema to a generic map schema
2015-02-25 21:36:59 +01:00
Thomas Adamcik
0829f34a90
Merge pull request #999 from tkem/fix/998
...
Fix #998 : Remove event already sent by PlaylistsController.
2015-02-25 21:05:53 +01:00
Thomas Kemmer
dd54fdb086
Fix #937 : Local playlists refactoring.
2015-02-25 18:50:29 +01:00
Thomas Kemmer
96a3cb6ef5
Remove obsolete unit test.
2015-02-25 17:48:41 +01:00
Stein Magnus Jodal
255d92f21f
Merge pull request #992 from adamcik/feature/default-get-images-fallback
...
backend: Add a default get_images impl.
2015-02-18 22:13:10 +01:00
Thomas Adamcik
2ff2a3719e
backend: Add test for get_images fallback
2015-02-18 21:55:39 +01:00
Thomas Adamcik
e4ba4b3e5f
mpd: Support blacklisting MPD commands in the server.
...
Default blacklist set to listall and listallinfo.
This change has been done to avoid clients being able to call "bad" MPD
commands which are often misused to try and keep a client db. Note that
this change will break some MPD clients, but the blacklist can be controlled
via config to allow opting out for now.
2015-02-18 00:13:24 +01:00
Ali Ukani
ead147f482
Fix flake8 errors, prepare for Python 3 port
...
Fixes flake8 warnings
Reword docstring for find_exact
Use range instead of xrange in preparation for porting to Python 3
2015-02-16 02:24:40 -05:00
Ali Ukani
fc21d466f0
local: use limit and offset when searching json library
...
Fixes the json local library's search behavior. Uses limit and offset
arguments when returning search results.
2015-02-16 02:24:40 -05:00
Stein Magnus Jodal
5270aa65e2
audio: Move DummyAudio into tests package
2015-02-13 10:40:21 +01:00
Stein Magnus Jodal
b554a64aad
mixer: Move DummyMixer into tests package
2015-02-13 01:37:07 +01:00
Stein Magnus Jodal
df95a988b7
backend: Move DummyBackend into tests package
2015-02-13 01:37:07 +01:00
Stein Magnus Jodal
160afbcd26
mpd: Use DummyMixer in tests
2015-02-13 01:22:46 +01:00
Stein Magnus Jodal
886c2b92d8
core: Use a mixer mock in tests
2015-02-13 01:15:25 +01:00
Stein Magnus Jodal
333bc69777
jsonrpc: Don't use mixer in tests
2015-02-13 01:15:15 +01:00
Stein Magnus Jodal
7aede98fda
Merge pull request #982 from adamcik/feature/use-proxy-in-stream-scanner
...
Use proxy in stream scanner
2015-02-13 01:04:09 +01:00
Thomas Adamcik
0e4e872d6b
stream: Hook stream scanner up to proxy settings
2015-02-13 00:52:20 +01:00
Stein Magnus Jodal
638740541b
Merge pull request #981 from adamcik/feature/core-get-images
...
Add library.get_images()
2015-02-13 00:33:29 +01:00
Thomas Adamcik
ddd872cdea
core: Always return an answer for all URIs in get_images
...
Also make sure that results are tuples instead of lists so we don't
accidentally give out mutable state.
2015-02-13 00:10:14 +01:00
Thomas Adamcik
3cb9eb52f0
Merge pull request #975 from jodal/feature/core-mixer
...
Add core.mixer replacing playback mixer methods.
2015-02-12 23:50:04 +01:00
Thomas Adamcik
533948f8f8
core: Make sure we return list of images in get_images tests
2015-02-12 23:10:20 +01:00
Thomas Adamcik
b1b6fb7808
tests: Re-add incorrectly removed test case
2015-02-12 23:08:27 +01:00
Thomas Adamcik
c0b0e3657a
core: Add core.library.get_images
2015-02-12 22:38:42 +01:00
Stein Magnus Jodal
e938fb0a7f
Merge pull request #965 from ZenithDK/fix/flake-lambda
...
flake8: fix PEP8 warnings about lambda
2015-02-12 22:22:53 +01:00
Lasse Bigum
34ada2784a
flake8: fix PEP8 warnings about lambda
...
Fix the 'lambda to def' warnings
2015-02-12 22:10:36 +01:00
Thomas Adamcik
05b66ba4a3
models: Add basic image model
2015-02-12 22:02:59 +01:00
Stein Magnus Jodal
df67d708db
config: Add support for 'all' loglevel
...
Equal to logging.NOTSET or 0 in the logging module.
2015-02-12 18:12:33 +01:00
Stein Magnus Jodal
e1fa76a48e
mpd: Use core.mixer for volume/mute
2015-02-12 10:31:16 +01:00
Stein Magnus Jodal
91bcdddf56
tests: Use core.mixer for volume/mute
2015-02-12 10:31:16 +01:00
Stein Magnus Jodal
42115c56f7
core: Add mixer controller ( fixes : #962 )
...
Deprecate volume and mute methods on playback controller.
2015-02-12 10:31:16 +01:00
kingosticks
0de13994c2
Moved MPDUriMapper to own file and updated changelog
2015-02-09 12:07:17 +00:00
kingosticks
317d02de3e
Pass MPDUrimapper into mpd test setup
2015-02-08 23:43:22 +00:00
Lasse Bigum
4bf7a568d1
Check that config is readable
...
Implement a check on file permissions for the config files that are loaded
and print debug if mopidy fails to load it due to missing file file permissions
2015-02-07 17:47:20 +01:00
Stein Magnus Jodal
a693993905
flake8: Fix new warnings after flake8 upgrade
2015-02-07 17:11:36 +01:00
Thomas Adamcik
41d48dc0ec
audio: Stop mocking in audio event tests
2015-01-24 00:49:02 +01:00
Thomas Adamcik
b0aebaf993
core: Make sure current_tl_track changes on stream change
...
- Adds stream changed handler to core
- Moves playback started trigger to stream changed
- Made about to finish store next track in _pending_tl_track
- Set the pending track as current in stream changed
- Adds tests for all of this and fixes existing tests
2015-01-23 00:14:30 +01:00
Thomas Adamcik
49f16704d8
core: Remove on_end_of_track from playback
...
This has been replaced by on_about_to_finish and on_end_of_stream.
Tests have been updated to reflect these changes.
2015-01-22 23:16:51 +01:00
Thomas Adamcik
82bf1c0eb9
core: Move core.playback.on_end_of_track off change_track helper
...
Only handles the playing case, unlike the previous and next changes. It should
also be noted that this is just a temporary state on the road to making this
method handle gapless.
2015-01-21 23:15:42 +01:00
Thomas Adamcik
4a39671ee7
core: Move core.playback.previous off change_track helper
...
Same fix as for core.playback.next and mostly the same caveats.
2015-01-21 23:07:47 +01:00
Thomas Adamcik
bbb3301a98
core: Move core.playback.next off change_track helper
...
Note that since this doesn't use play via change_track we have to copy over the
tracking code and make sure it is only run for the playing case
2015-01-21 23:02:06 +01:00
Thomas Adamcik
9fc319055c
backend: Change playback API (breaking change)
...
While trying to remove traces of stop calls in core to get gapless working I
found we had no way to switch to switch tracks without triggering a play. This
change fixes this by changing the backends playback provider API.
- play() now _only_ starts playback and does not take any arguments.
- prepare_change() has been added, this could have been avoided with a kwarg to
change_track(track), but that would break more backends.
- core has been updated to call prepare_change+change_track+play as needed.
- tests have been updated to handle this change.
Longer term I hope to completely rework the playback API in backends, as 99% of
our backends only use change_track(track) to translate URIs. So we should make
simple case simple, and handle mopidy-spotify / appsrc in some other way.
2015-01-21 22:13:41 +01:00
Ali Ukani
dac5f9e406
Add test for exact search with album query
2015-01-05 23:24:52 -05:00
kingosticks
1e7a4247c6
Add non-ascii utf-8 chars to test playlists
2015-01-04 20:21:10 +00:00
Thomas Adamcik
ab49d75a45
tests: Fix outstanding flake8 errors in tests
2014-12-30 00:23:08 +01:00
Thomas Adamcik
627b856578
tests: Fix MPD tests helper names
2014-12-30 00:23:08 +01:00
Thomas Adamcik
fa8547c397
tests: Add noqa markers for setUp/tearDown
2014-12-30 00:23:01 +01:00
Thomas Adamcik
a50ba6e3a7
tests: Add noqa markers to custom assert helpers
2014-12-29 23:58:36 +01:00
Thomas Adamcik
9f6e0cc5fa
tests: Fix versions test pep8 naming errors
2014-12-29 23:48:59 +01:00
Thomas Adamcik
656f7e976f
Merge branch 'develop' into feature/taglist-converter
...
Conflicts:
docs/changelog.rst
2014-12-25 22:46:44 +01:00
Stein Magnus Jodal
890ed53ee6
Merge branch 'release/v0.19.x' into develop
...
Conflicts:
docs/changelog.rst
2014-12-24 00:41:10 +01:00
Stein Magnus Jodal
6af624a369
Bump version to 0.19.5
2014-12-24 00:37:33 +01:00
Stein Magnus Jodal
dbbb86e6c0
Merge branch 'release/v0.19.x' into develop
...
Conflicts:
mopidy/core/playback.py
2014-12-24 00:24:19 +01:00
Stein Magnus Jodal
c6ff9eee86
playback: Remove skipped track on next in consume mode
...
Also adds core level tests of consume behavior on next/prev/eot.
Fixes #902
2014-12-24 00:04:41 +01:00
Stein Magnus Jodal
6ec35b2d02
Merge branch 'release/v0.19.x' into develop
2014-12-23 22:23:32 +01:00
Stein Magnus Jodal
aa3b8ab5f8
path: Support unicode content when creating file
2014-12-23 22:21:10 +01:00
Thomas Adamcik
935a038405
audio: Only add albums that have a name
...
Fixes case where we could have an empty album. We could alternatively be more
conservative and only limit to fully empty albums. But I think we only want
ones with names anyway.
2014-12-22 22:45:31 +01:00
Thomas Adamcik
819680e074
audio: Move utils test to tests folder
2014-12-22 22:34:11 +01:00
Thomas Adamcik
9b9cdc3ade
stream: Fix track conversion bug and add tests
...
This adds basic checks for the library provider lookup:
- Check that uri schemes are respected
- Check that blacklisting and globbing works
- Check uri successfully gets converted to a track
2014-12-22 22:29:36 +01:00
Thomas Adamcik
9be788b129
audio: Move tags to track conversion to audio utils
2014-12-18 23:36:56 +01:00
Thomas Adamcik
983148a9a4
audio: Start storing the tags we find in audio
...
Adds a new get_currents_tags method for fetching the full set of current tags.
There are still some untested cases for this, and I also suspect we still want
some API refinements one core starts using this.
2014-12-18 23:28:19 +01:00
Thomas Adamcik
6c62252919
audio: Add tags changed event to audio.
...
Current version simply emits the keys of the changed tags to the audio
listener. Following change will add support for storing the actual data.
2014-12-18 23:28:19 +01:00
Thomas Adamcik
de6bd63481
audio: Remove min duration code from scanner.
...
The local scanner now handles this itself by looking at the duration.
2014-12-18 23:28:19 +01:00
Thomas Adamcik
4f8244c499
audio: Convert audio_data_to_track to tags_to_track
...
The new function only uses tags as input. In other words we now need to set
length, uri and mtime ourselves. Users of scan APIs have been updated.
2014-12-18 23:28:19 +01:00
Thomas Adamcik
4948dee4b9
audio: Make scanner return duration in milliseconds
...
Also ensures that we normalize unknown duration to None instead of -1.
2014-12-18 23:28:19 +01:00
Thomas Adamcik
d9d501cd98
audio: Update scanner to just return tags+duration
...
The caller should know what URI we are talking about. Additionally finding the
mtime is never belonged in this class and has been moved out.
2014-12-18 23:28:19 +01:00
Thomas Adamcik
dcaa0f6732
local: Move musicbrainz cover art helper to translator
2014-12-18 23:28:14 +01:00
Thomas Adamcik
b365d2494b
mpd: Remove "Comment" tag type from translator output.
...
Newer versions of the protocol have removed this tag, so we should as well.
This also works around the issue of #881 which was breaking things with
newlines in comment fields.
The readcomments command seems to replace this, but it seems to only care about
specific extra tagtypes, not the general comment tag we normally collect when
scanning things.
(cherry picked from commit 08a8d5c43b )
2014-12-16 23:30:38 +01:00
Stein Magnus Jodal
6e55435aa9
mpd: Enable browsing of empty dirs
...
This was disabled together with a bunch of other changes without any
explanation in commit f24ca36e5a . I'm
guessing that this wasn't intentional, and no test covered the case.
(cherry picked from commit 4e508cd017 )
2014-12-16 23:25:31 +01:00
Thomas Adamcik
90fdd46109
local: Cleanup translator tests
2014-12-14 23:14:11 +01:00
Thomas Adamcik
671ee5ee6a
audio: Switch to using converted taglists instead of raw data.
2014-12-14 22:25:52 +01:00
Thomas Adamcik
08a8d5c43b
mpd: Remove "Comment" tag type from translator output.
...
Newer versions of the protocol have removed this tag, so we should as well.
This also works around the issue of #881 which was breaking things with
newlines in comment fields.
The readcomments command seems to replace this, but it seems to only care about
specific extra tagtypes, not the general comment tag we normally collect when
scanning things.
2014-12-14 14:16:37 +01:00
Thomas Adamcik
2c3217685b
utils: Switch to exceptions.FindError for errors.
2014-12-14 14:08:45 +01:00
Stein Magnus Jodal
4e508cd017
mpd: Enable browsing of empty dirs
...
This was disabled together with a bunch of other changes without any
explanation in commit f24ca36e5a . I'm
guessing that this wasn't intentional, and no test covered the case.
2014-12-13 01:27:14 +01:00
Stein Magnus Jodal
4f428b8601
py3: Move compat module out of utils
2014-12-07 21:36:15 +01:00
Stein Magnus Jodal
7a1bb224f7
py3: Avoid indexing exception objects
...
It doesn't work on Python 3.
2014-12-07 20:26:09 +01:00
Stein Magnus Jodal
58527406c1
py3: Use compat.text_type instead of unicode
2014-12-07 20:17:10 +01:00
Stein Magnus Jodal
496142c201
py3: Use absolute imports by default
2014-12-07 20:17:10 +01:00
Stein Magnus Jodal
680dbffc0c
models: Make all fields default to None or empty collection
...
(cherry picked from commit abed15b9e4 )
2014-11-04 21:27:29 +01:00
Stein Magnus Jodal
a4b17a9aa8
models: Fix equality for fields set to the default
...
Fixes #837
(cherry picked from commit bdd1fb983b )
2014-11-04 20:17:20 +01:00
Stein Magnus Jodal
88d64044de
models: Hide empty lists from repr()
...
(cherry picked from commit 305a76486d )
Conflicts:
docs/changelog.rst
2014-11-04 20:17:13 +01:00
Thomas Kemmer
63277c4db3
Add unit tests for artist browsing
2014-11-04 19:22:45 +01:00
Thomas Adamcik
063c757570
utils/path: Add support for handling sym/hardlink loops
2014-10-15 23:46:08 +02:00
Thomas Adamcik
54a89038d3
utils/path: Don't skip hidden files and folders in generic find code
...
Updates the local scan code to do this instead.
2014-10-15 23:45:49 +02:00
Thomas Adamcik
9b1d20677d
tests: Cleanup find tests to use tempfile all over.
...
This should make it more clear what structure we expect.
2014-10-15 23:45:27 +02:00
Thomas Adamcik
69fa6f4674
tests: Test symlink that points to it's own parent.
2014-10-15 23:45:22 +02:00
Thomas Adamcik
93c0d6cc44
tests: Update no permission test to use tempfile.
2014-10-15 23:45:12 +02:00
Thomas Adamcik
b2419f9814
tests: Add test case for a symlink pointing at itself
2014-10-15 23:45:03 +02:00
Thomas Adamcik
ebb62885cd
util/path: Add basic support for following symlinks
2014-10-15 23:44:48 +02:00
Thomas Adamcik
682af27348
tests: Add test case for file without permissions.
2014-10-15 23:44:41 +02:00
Thomas Adamcik
d219bab0b2
tests: Add test for directory without permission behaviour
2014-10-15 23:44:01 +02:00
Thomas Adamcik
de5fe5ebab
tests: Add test for current find symlink handling
2014-10-15 23:43:13 +02:00
Thomas Adamcik
a8017dfef1
tests: Start adding checks for find errors
2014-10-15 23:42:36 +02:00
Thomas Adamcik
de4bdbec03
tests: Minor cleanup of the existing find tests
2014-10-15 23:42:15 +02:00
Thomas Adamcik
2447e2fa40
util/path: Expose errors to callers of find helper
2014-10-15 23:42:12 +02:00
Stein Magnus Jodal
7856c14b26
tests: Use with stmt for assertRaises
2014-09-25 23:03:35 +02:00
Stein Magnus Jodal
07d088fc18
models: Use with stmts in exception tests
2014-09-24 18:26:25 +02:00
Stein Magnus Jodal
5317834baf
history: Change size property to get_length() method
...
For consistency with tracklist.get_length() and our goal of aligning Python
and JS APIs by using less properties in the core API.
2014-09-23 18:47:54 +02:00
Stein Magnus Jodal
5a67339855
history: Cleanup history entry test
2014-09-23 18:47:39 +02:00
Stein Magnus Jodal
d30cf68efd
history: Raise TypeError if non-Tracks are added
2014-09-23 18:42:41 +02:00
Stein Magnus Jodal
718405421d
history: Rename class to HistoryController
...
For consistency with other core controllers.
2014-09-23 18:32:37 +02:00
Arjun Naik
c38b9f378f
Use assertIn instead of assertTrue to test membership.
2014-09-23 18:09:12 +02:00
Arjun Naik
9006968f75
TrackHistory stores Ref instances. Timestamp as epoch in milliseconds also stored.
2014-09-23 18:09:12 +02:00
Arjun Naik
ed87ab8dd1
Added a playback history object to the core.
2014-09-23 18:09:11 +02:00
Stein Magnus Jodal
1fcc75ba1e
Merge pull request #840 from tkem/feature/local-library-lookup-multiple
...
local: Return multiple tracks from lookup()
2014-09-23 14:14:22 +02:00
Stein Magnus Jodal
abed15b9e4
models: Make all fields default to None or empty collection
2014-09-22 22:25:42 +02:00
Stein Magnus Jodal
bdd1fb983b
models: Fix equality for fields set to the default
...
Fixes #837
2014-09-22 22:01:50 +02:00
Stein Magnus Jodal
305a76486d
models: Hide empty lists from repr()
2014-09-22 21:42:57 +02:00
Stein Magnus Jodal
f58fe9a192
py3: Replace xrange() with range()
2014-09-17 20:28:07 +02:00
Thomas Adamcik
d049b07fa9
Merge branch 'develop' into feature/audio-message-handler
2014-09-07 21:38:19 +02:00
Thomas Kemmer
806174916d
Change JsonLibrary.lookup to return a list
2014-09-05 05:35:18 +02:00
Stein Magnus Jodal
d41deb1844
Merge branch 'release/v0.19.x' into develop
...
Conflicts:
docs/changelog.rst
2014-09-01 23:17:00 +02:00
Stein Magnus Jodal
e1ab70e1e9
Bump version to 0.19.4
2014-09-01 23:08:59 +02:00
Thomas Kemmer
f90671fe96
Fixed flake8: I201 Missing newline between sections or imports
2014-08-30 14:10:39 +02:00
Thomas Kemmer
380223bb96
local: Return multiple tracks from lookup()
2014-08-30 14:02:43 +02:00
Stein Magnus Jodal
c50641230d
Merge branch 'release/v0.19.x' into develop
2014-08-29 14:03:11 +02:00
Stein Magnus Jodal
a244761abc
mpd: Replace / with | instead of whitespace in playlist names
2014-08-17 23:25:09 +02:00
Trygve Aaberge
15597b3c60
tests: Test call order in test_recv_callback_gets_no_data
2014-08-14 12:43:42 +02:00
Trygve Aaberge
265951bf00
network: disable_recv before telling actor to close connection
...
As of d62ad96 , when the connection can't receive more data from the
client, it tells the actor to stop the connection and calls
disable_recv(). The actor operates in it's own thread and when it stops
the connection, disable_recv is being called again from a different
thread. Since the actor is told to stop the connection before
disable_recv is called, the two calls to disable_recv may happen
simultaneously.
This causes a race condition issue where both threads can reach past the
check that recv_id is not None before either of them set it to None. If
one of them set it to None before the other one tries to use it, an
error is raised.
This commit calls disable_recv before telling the actor to stop the
connection. Since disable_recv is a blocking call, this ensures that
recv_id is being set to None before the actor thread begins to stop the
connection.
Fixes #781
2014-08-14 01:58:48 +02:00
Stein Magnus Jodal
ae3a932ed3
Merge branch 'release/v0.19.x' into develop
...
Conflicts:
mopidy/config/__init__.py
2014-08-12 23:54:14 +02:00
Thomas Adamcik
ac5bf9af17
audio: Move most of event handling out of audio.
...
Some of the signal handling still needs to be moved.
2014-08-11 22:33:49 +02:00
Thomas Adamcik
101b2a9817
audio: Make stream-changed correctly handle tee setup
...
For the purposes of this event we consider the outputs sink the final element.
If we don't do this we would get one event per branch, and we don't want to
track when each of them actually switches any way. So just tracking when the
tee/outputs bin gets the event is good enough for us.
As part of this I've also added 'testoutput' as a special cased output value.
This is now needed as outputs are always synced to the clock, making testing
a lot less practical.
2014-08-11 22:33:49 +02:00
Trygve Aaberge
584484379a
config: Only load .conf-files when loading directories
2014-08-11 16:21:34 +02:00
Trygve Aaberge
9e41eff187
config: Support passing directories to mopidy --config
2014-08-11 14:48:04 +02:00
Trygve Aaberge
c798257f00
mpd: Test that "list album foo" responds correctly
...
Previously, test_list_album_with_artist_name would only test that the
command didn't fail. Now it also checks that the response is correct.
That is, that the response contains albums.
This makes the test detect the error reported in #817 .
(cherry picked from commit 9771eda230 )
2014-08-05 23:52:40 +02:00
Trygve Aaberge
9771eda230
mpd: Test that "list album foo" responds correctly
...
Previously, test_list_album_with_artist_name would only test that the
command didn't fail. Now it also checks that the response is correct.
That is, that the response contains albums.
This makes the test detect the error reported in #817 .
2014-08-05 18:34:08 +02:00
Thomas Adamcik
d650c0ba14
audio: Split out ouput handling from audio actor
...
This also lays some basic ground work for handling multiple outputs.
2014-08-03 23:57:22 +02:00
Stein Magnus Jodal
e9822117e5
Merge branch 'master' into develop
...
Conflicts:
docs/changelog.rst
2014-08-03 23:40:18 +02:00
Stein Magnus Jodal
dc80f17296
Bump version to 0.19.3
2014-08-03 23:34:25 +02:00
Stein Magnus Jodal
9260ae23a7
Merge branch 'release/v0.19.x' into develop
2014-08-03 23:13:40 +02:00
Stein Magnus Jodal
837fb00fb7
Fail early if extension doesn't implement setup()
...
Fixes #813
2014-08-03 23:13:14 +02:00
Thomas Adamcik
5d1dd1a355
review-fixes: Mostly typos etc.
2014-08-02 20:45:55 +02:00
Thomas Adamcik
bf752859da
flake8: Fix duplicate import and import order in audio actor test
2014-07-29 23:12:53 +02:00
Thomas Adamcik
e73159dc6c
Merge branch 'develop' into feature/audio-prep-work-for-gapless
2014-07-29 23:07:08 +02:00
Ignasi Fosch
e9289ca554
Checks for musicbrainz album ID and sets images to a list containing the corresponding URL
2014-07-27 16:34:28 +02:00
Stein Magnus Jodal
3bc82f82ac
Bump version to 0.19.2
2014-07-26 14:18:50 +02:00
Stein Magnus Jodal
93bf3ea918
mpd: Fix crash on wrong number of command args
...
Fixes #789
2014-07-26 13:56:26 +02:00
Ignasi Fosch
9d493792bf
version help test fixed
2014-07-26 12:31:53 +02:00
Stein Magnus Jodal
19dae10575
Bump version to 0.19.1
2014-07-23 18:14:00 +02:00
Thomas Adamcik
2aeb87e003
Merge branch 'develop' into feature/audio-prep-work-for-gapless
...
Conflict files fixed up to a state where tests pass again before commit.
Conflicts:
mopidy/audio/actor.py
mopidy/audio/listener.py
tests/audio/test_actor.py
tests/audio/test_listener.py
2014-07-23 00:06:29 +02:00
Stein Magnus Jodal
0bf7302005
Merge remote-tracking branch 'adamcik/fix/gh-734-cleanup-audio-buffering' into develop
...
Conflicts:
mopidy/audio/actor.py
2014-07-20 12:29:49 +02:00
Stein Magnus Jodal
1ebe1151fc
http: Make event emitting testable
2014-07-17 01:14:06 +02:00
Stein Magnus Jodal
3fac0cb8de
http: Split socket and server creation
2014-07-17 01:13:48 +02:00
Stein Magnus Jodal
7e6d3de81a
Merge branch 'develop' into feature/mixers
...
Conflicts:
mopidy/backend/__init__.py
2014-07-16 22:12:07 +02:00
Stein Magnus Jodal
44664f2796
exc: Add {Backend,Frontend,Mixer}Error exceptions
...
(cherry picked from commit bf8307f329 )
2014-07-16 10:32:18 +02:00
Stein Magnus Jodal
7e489ccb0b
exc: Test ScannerError
...
(cherry picked from commit 8f59dd69ad )
2014-07-16 10:32:15 +02:00
Stein Magnus Jodal
dda06dd8de
config: Add optional support to Boolean type
2014-07-15 00:33:30 +02:00
Thomas Adamcik
d8c41de2f7
audio: Add tests for state changes while buffering
2014-07-14 23:15:40 +02:00
Stein Magnus Jodal
d15d66f070
Use 'mute' instead of 'muted', to avoid changing old APIs
2014-07-12 03:14:19 +02:00
Stein Magnus Jodal
249114b051
audio: Update tests broken by 5f091c10
2014-07-12 03:12:21 +02:00
Stein Magnus Jodal
a3dc763b29
core: Forward {volume,mute}_changed events, don't trigger them ourselves
2014-07-10 01:15:44 +02:00
Stein Magnus Jodal
b8de7fa75c
mixer: Add MixerListener
2014-07-10 01:00:35 +02:00
Stein Magnus Jodal
bf8307f329
exc: Add {Backend,Frontend,Mixer}Error exceptions
2014-07-09 22:17:46 +02:00
Stein Magnus Jodal
8f59dd69ad
exc: Test ScannerError
2014-07-09 22:15:45 +02:00
Stein Magnus Jodal
9da716935c
audio: Only expose GStreamer's software mixer
2014-07-08 01:34:33 +02:00
Stein Magnus Jodal
6d6bc4b808
core: Use new mixer API
2014-07-08 01:11:25 +02:00
Stein Magnus Jodal
9ced0f740f
Merge 'dz0ny/bug/fix-708-duplicate' into develop
2014-07-01 23:25:49 +02:00
dz0ny
d871ca9128
Remove duplicates from library root.
...
Closes #708
2014-06-26 16:27:22 +02:00
Trygve Aaberge
c062dd21c4
mpd: Create unique names for all items in browse
...
Replace the playlist uri/name mapping with a mapping for all the items
in browse. Check the mapping when browsing a path.
This has the added benefit of serving as a cache for browse, so we don't
need to traverse the path parts and lookup each of them for each call to
browse.
2014-06-24 00:45:49 +02:00
Thomas Adamcik
e4d4652c68
Merge pull request #759 from jodal/feature/web-client-selector
...
Add web client selector
2014-06-23 22:47:14 +02:00
Stein Magnus Jodal
25f41664d7
Bump version number to 0.19
2014-06-23 22:32:43 +02:00
Stein Magnus Jodal
aed8670797
http: Fix flake8 warnings
2014-06-22 09:53:03 +02:00
Stein Magnus Jodal
9b9791ab5b
Merge pull request #755 from trygveaa/feature/lsinfo-change-order
...
mpd: List browse results before playlists in lsinfo
2014-06-22 09:49:00 +02:00
Trygve Aaberge
1ac470c58c
mpd: Test that whitespace query parts are ignored
2014-06-22 02:13:14 +02:00
Stein Magnus Jodal
9f925570d2
http: Redirect from root to /mopidy/ if no static_dir app
2014-06-22 01:24:57 +02:00
Stein Magnus Jodal
6596871918
http: Test serving og legacy static_dir apps
2014-06-22 01:22:22 +02:00
Stein Magnus Jodal
5861071bb1
http: List installed web clients at /mopidy/
2014-06-22 00:39:54 +02:00
Stein Magnus Jodal
59760bb36c
web: Remove WebSocket demo page
2014-06-21 23:27:35 +02:00
Trygve Aaberge
0c3e5bd71e
mpd: Test that empty query parts are ignored
2014-06-21 17:29:41 +02:00
Thomas Adamcik
7975815cde
audio: Expand audio state changed with target state
2014-06-21 17:28:25 +02:00
Stein Magnus Jodal
fbcc73004d
http: Redirect from /app to /app/
2014-06-21 16:36:16 +02:00
Stein Magnus Jodal
6c6600c37b
http: Group HTTP server tests
2014-06-21 16:21:39 +02:00
dz0ny
7c428ce8d2
Fix http router so it can handle /{ext_name} same as /{ext_name}/
2014-06-21 15:05:13 +02:00
Trygve Aaberge
81898cb709
mpd: Test order of result from lsinfo
2014-06-21 14:42:35 +02:00
Thomas Adamcik
2e1ca08fef
audio: Use on buffering internal in buferring tests
2014-06-21 14:20:56 +02:00
Thomas Adamcik
58976ef52d
config: Lists need to handle missing values
2014-06-21 14:11:24 +02:00
Trygve Aaberge
0b7243dce1
mpd: Test albums in listall(info)
2014-06-21 01:52:44 +02:00
Stein Magnus Jodal
4cd545e147
Merge branch 'trygveaa/feature/mpd-browse-playlists' into develop
2014-06-20 22:19:48 +02:00
Trygve Aaberge
496b3f5552
mpd: Test playlists in listall(info)
2014-06-20 22:16:27 +02:00
Thomas Adamcik
c87684aa6b
audio: Handle all caps ASX tags.
...
Also add support for simple asx format.
2014-06-20 21:31:03 +02:00
Stein Magnus Jodal
720a403439
http: Remove unused Router class
2014-06-04 21:32:54 +02:00
Stein Magnus Jodal
33228f2528
http: Simplify app registration
2014-06-04 21:32:19 +02:00
Stein Magnus Jodal
b6ab29eed4
http: Remove unused code
2014-06-04 21:02:33 +02:00
Stein Magnus Jodal
d13194dfa4
http: Remove static file serving from the Router
2014-06-04 20:55:28 +02:00
Stein Magnus Jodal
eea6138b3d
http: Simplify static files serving
2014-06-04 20:47:49 +02:00
Stein Magnus Jodal
684a64405d
http: Move MopidyHttpRouter into handlers module
2014-05-22 21:03:42 +02:00