Commit graph

26 commits

Author SHA1 Message Date
Andrey Yantsen
a0135f8190 fix flake 2018-09-14 23:26:14 +01:00
Andrey Yantsen
057967a8ae Library section id for all (#292)
* add librarySectionID for each item if MediaContainer had one

* fix getting section for photos which are not in album yet

* another approach
2018-09-14 20:27:24 +02:00
Andrey Yantsen
68fc970d7a Improvements in tests process (#297)
* lets begin

* skip plexpass tests if there is not plexpass on account

* test new myplex attrubutes

* bootstrap: proper photos organisation

* fix rest of photos tests

* fix myplex new attributes test

* fix music bootstrap by setting agent to lastfm

* fix sync tests

* increase bootstrap timeout

* remove timeout from .travis.yml

* do not create playlist-style photoalbums in plex-bootstraptest.py

* allow negative filtering in LibrarySection.search()

* fix sync tests once again

* use sendCrashReports in test_settings

* fix test_settings

* fix test_video

* do not accept eula in bootstrap

* fix PlexServer.isLatest()

* add test against old version of PlexServer

* fix MyPlexAccount.OutOut

* add flag for one-time testing in Travis

* fix test_library onDeck tests

* fix more tests

* use tqdm in plex-bootstraptest for media scanning progress

* create sections one-by-one

* update docs on AlertListener for timeline entries

* fix plex-bootstraptest for server version 1.3.2

* display skip/xpass/xfail reasons

* fix tests on 1.3

* wait for music to be fully processed in plex-bootstraptest

* fix misplaced TEST_ACCOUNT_ONCE

* fix test_myplex_users, not sure if in proper-way

* add pytest-rerunfailures; mark test_myplex_optout as flaky

* fix comment

* Revert "add pytest-rerunfailures; mark test_myplex_optout as flaky"

This reverts commit 580e4c95a7.

* restart plex container on failure

* add conftest.wait_until() and used where some retries are required

* add more wait_until() usage in test_sync

* fix managed user search

* fix updating managed users in myplex

* allow to add new servers to existent users

* add new server to a shared user while bootstrapping

* add some docs on testing process

* perform few attemps when unable to get the claim token

* unlock websocket-client in requirements_dev

* fix docblock in tools/plex-teardowntest

* do not hardcode mediapart size in test_video

* remove cache:pip from travis

* Revert "unlock websocket-client in requirements_dev"

This reverts commit 0d536bd06d.

* remove debug from server.py

* improve webhook tests

* fix type() check to isinstance()

* remove excessive `else` branch due to Hellowlol advice

* add `unknown` as allowed `myPlexMappingState` in test_server
2018-09-14 20:03:23 +02:00
Andrey Yantsen
54b26fdc25 Sync support (#282)
* [sync] initial commit

* fix populating of `state` field in sync.Status

* [connection] add posibliity to return first established connection faster

* [base] add timeout argument to PlexObject.fetchItems()

* [sync] add timeout arg to SyncItem.getMedia()

When you have multiple media within one SyncItem it takes a lot of time
to get all the info for this media (on my machine it takes about a
second for each movie).

* [sync] fix marking media as downloaded

* [sync] pass clientIdentifier to created SyncItem()

* [sync] override __repr__() for sync.Status

* fix after @mikes-nasuni`s review

* fix python2 compatibility

* get rid of sync.init()

* use list comprehension

* remove timeout from PlexObject.fetchItems()

* fix SyncItem under python 2.7

* fix __doc__ in sync module

* revert myplex._connect() back to it`s original state

* improve sync docs

* get rid of PlexObjects where not needed

* add X-Plex-Sync-Version=2 to headers

* add sync() method into Video, LibrarySection and MyPlexAccount

* add SyncItem.delete()

* add sync.Policy.create()

* use self._default_sync_title instead of _prettyfilename as default title

* let the tests begin

* add items for refreshing synclists to PlexServer

* fix sync tests

* sync for everybody!

* add TODO doctring for Audio._defaultSyncTitle()

* SyncItems tag may be presented only once, there is no need for loop

* add more TODO docstrings

* hello docs

* remove relative import

* remove unused variable from tests/test_sync.py
2018-09-08 17:25:16 +02:00
Hellowlol
26bf4ca010 zomg... 2017-10-26 00:01:42 +02:00
Hellowlol
807b6ebc3c add more tests to inc cov. 2017-10-25 21:53:52 +02:00
Hellowlol
f8e594ff3f Add test for a album inside a album 👍 2017-10-25 20:58:20 +02:00
Hellowlol
7682a04c7b remove reload since it interited. 2017-10-25 18:39:32 +02:00
Michael Shepanski
d41bf0fb89 Add support to recursivly navigate photoalbums 2017-02-26 00:17:41 -05:00
Michael Shepanski
de69ace19f Go over documentation a bit more; This will never end. 2017-02-13 23:32:27 -05:00
Michael Shepanski
9b791b95e7 Add TAG constant to PlexObjects; Better method to save and build PLEXOBJECTS; All objects in media.py are now registered and can be looked up; Remove __len__ on Library class (it was causing URL to load twice). 2017-02-12 21:55:55 -05:00
Michael Shepanski
08e61960e7 Move common methods to PlexPartialObject; More documentation 2017-02-09 15:01:23 -05:00
Michael Shepanski
83a8c5733e Rename _root back to _server but keep it private 2017-02-08 23:13:54 -05:00
Michael Shepanski
76c0cb55a1 Rename variable to kwargs 2017-02-08 23:08:25 -05:00
Michael Shepanski
f676d4cbbf Most tests passing; Need to add better filters on fetchItems for watched / unwatched 2017-02-08 02:00:43 -05:00
Michael Shepanski
8212ca9c46 Much more stability from yesterday; Easier to use fetchItem funtions; Common __repr__ for all plexobjects; Fix all uses if listItems 2017-02-07 01:20:49 -05:00
Michael Shepanski
4624512356 A few more updates to get plexattrs.py fully running 2017-02-06 01:28:58 -05:00
Michael Shepanski
6a35f50a43 CHECKPOINT: Lots going on; Added new base class PlexObject that everything inherits from, this ensures all constructors are similar; Lots of work on new tool plexattrs that parses a full Plex library to find differences in attributes plexapi implements and what the Plex XML API offers up; Tests will most definetly be broken at this point, but I wanted to save my work. 2017-02-05 23:52:10 -05:00
Michael Shepanski
fc28f7c1e6 Move Playable and PlexPartialObject to new plexapi.base module 2017-02-04 14:46:51 -05:00
Michael Shepanski
7c766337b6 Remove all references to NA 2017-02-04 12:43:50 -05:00
Michael Shepanski
04251d3805 Finish documenting Photo; Monkey-patch sphinx to not auto-link to unknown types; Remove links to ElementTree (not our code) 2017-01-30 23:44:03 -05:00
Hellowlol
1075f65bb4 Moredocs (#84)
* Docs and speedups.
2017-01-02 22:06:40 +01:00
Michael Shepanski
98671d7e79 Add missing section() function to Photo object; Work on showing photos on client (not working yet) 2016-07-07 22:41:11 -04:00
Michael Shepanski
748fc68406 Cleanup playlist support; Fix UUID on URLs; Better method to store listTypes; Cache section IDs in library 2016-04-11 22:43:21 -04:00
Michael Shepanski
3138ad1087 Added playlist support 2016-04-10 23:49:23 -04:00
Michael Shepanski
09a7ae80db Basic support for photos complete 2016-04-09 23:59:47 -04:00