Commit graph

91 commits

Author SHA1 Message Date
Andrey Yantsen
7a67417615 fix docs for Raises clauses 2018-10-03 11:09:43 +01:00
Andrey Yantsen
12a318a8e2 Add a method to request a claim token (#287)
* add MyPlexAccount.claimToken()

* improve docstring for MyPlexAccount.claimToken()
2018-09-14 20:52:26 +02:00
Andrey Yantsen
93ec86d746 add enable_fast_connect configuration parameter (#288) 2018-09-14 20:28:35 +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
afd4e24420 fix myplexaccount initialization (#296) 2018-09-08 19:59:10 +02:00
Andrey Yantsen
9e04a4f999 Populate subscription related fields in MyPlexAccount (#289)
* populate subscription related fields in MyPlexAccount

* improve reading with .iter()
2018-09-08 17:28:26 +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
6238fa5fd2 fix bug so device returns a object as it should. 2018-04-03 23:08:17 +02:00
Hellowlol
b111e2490e add more missing stuff from /resources. 2018-03-02 19:11:43 +01:00
Hellowlol
3af2a5af59 Add support for relay 2018-03-02 19:02:22 +01:00
ninthwalker
c091c39c3c
update plexurl
It appears plex is doing away with the plexapp.com url.
It no longer has a valid SAN cert for that domain as it redirects to plex.tv now.
Update myplex.py to reflect new signin URL.
2018-01-11 13:48:23 -08:00
Hellowlol
0f16ea9cb7 fix invite and add editfriend. 2017-10-28 22:58:47 +02:00
Hellowlol
807b6ebc3c add more tests to inc cov. 2017-10-25 21:53:52 +02:00
Hellowlol
0e4d53a74c fix python 2, bug, dunno why the last didnt work. 2017-10-25 18:22:10 +02:00
Hellowlol
419437e58b Merge branch 'shareinfo' 2017-10-24 21:41:40 +02:00
Hellowlol
63d76f3d03 fix section.
see https://github.com/pkkid/python-plexapi/pull/220 for more info.
2017-10-24 21:41:07 +02:00
Hellowlol
68d8eeebac Lets see if this is enoght. 2017-10-23 00:45:56 +02:00
Michael Shepanski
ae3e90e58d Update myplex.py 2017-10-11 23:30:58 -04:00
Hellowlol
e48462cd9f rename to outOut, handle http 204 2017-10-11 23:31:05 +02:00
Hellowlol
a4443db64f add opt out. untested so dont merge. 2017-10-03 21:23:47 +02:00
Michael Shepanski
fd015439c4 Fix flake8 warnings 2017-09-29 19:49:13 -04:00
Hellowlol
25cf962470 Merge branch 'pr/184' 2017-09-24 00:21:29 +02:00
Hellowlol
9765f381e6 remove a unused method. 2017-09-24 00:14:47 +02:00
Hellowlol
e87fb484e4 More explisit 2017-09-23 23:11:34 +02:00
blacktwin
375907744a is True 2017-09-14 16:53:11 -04:00
blacktwin
f9f4b80b2b camelCase formating
removeSections instead of remove_sections. update the doc string.
2017-09-11 22:43:52 -04:00
blacktwin
4ed895d5b6 Update myplex.py
254:28: E712 comparison to True should be 'if cond is True:' or 'if cond:'
2017-09-11 11:08:07 -04:00
Michael Shepanski
8e11fe4b95 Unable to remove/invite managed/home users #157 2017-09-08 18:49:55 -04:00
blacktwin
423f11d3c2 update to allow adding shares if none exist 2017-09-08 14:17:39 -04:00
blacktwin
0650aaad67 Home user and remove sections
def updateFriend() update to allow for removing sections if `remove_sections=True`. 

def user() update to find Home user names.
2017-09-08 10:39:58 -04:00
Michael Shepanski
2104ec0d64 One-liner it 2017-07-30 00:54:13 -04:00
Michael Shepanski
9d7fee2527 Merge pull request #162 from pkkid/random
make connect build the correct type.
2017-07-30 00:50:32 -04:00
Michael Shepanski
48bc16b01c Cleanup doc strings 2017-07-30 00:35:52 -04:00
Hellowlol
a0f030e353 Add a test for share playlist. 2017-07-28 22:29:14 +02:00
Hellowlol
fa2bbeabb8 make connect build the correct type. 2017-07-27 01:28:14 +02:00
Hellowlol
97b8c5e64a init 2017-07-17 02:59:53 +02:00
Nolan Buchanan
720d7f94e4 Fixed bug preventing unowned server connections.
Also fixed issue where self.connections was being used in place of
connections variable.
2017-06-05 18:10:46 -04:00
Michael Shepanski
215bf833fa Bug #144 Fix docs for private vars 2017-06-04 22:01:07 -04:00
Michael Shepanski
b9312f1eb8 Make flake8 happy 2017-05-26 22:53:06 -04:00
Michael Shepanski
a0833516fd Remove commented URL 2017-05-26 22:42:05 -04:00
Michael Shepanski
624afd7082 Move share into MyPlexAccount.inviteFriend; Add abilities inviteFriend, updateFriend, RemoveFriend 2017-05-26 22:35:33 -04:00
Michael Shepanski
a79bc44b7a Ability to get a MyPlexAccount object from the plexServer object A(using same token). Review code to lookup port if not available on the client listing (fixed a few bugs in it). 2017-05-18 23:04:57 -04:00
Michael Shepanski
19039e1fed Cleanup client settings in pytest 2017-04-25 23:09:37 -04:00
Michael Shepanski
be2142f7ed Better logging when connecting to resources; Ability to specify timeout when connecting to resources; Update connect_to_resource test to be a bit more generic 2017-04-23 22:59:22 -04:00
Michael Shepanski
1dcbf85a9f Changes to myplex.py from code review; Update test_documentation to check for warnings and errors 2017-02-27 23:43:31 -05:00
Michael Shepanski
cbb999a0f5 Make flake8 happy 2017-02-25 10:50:54 -05:00
Michael Shepanski
4c83961cb4 Ability to delete device 2017-02-25 02:37:30 -05:00
Michael Shepanski
32a69db63e Support webhooks 2017-02-25 01:56:12 -05:00
Michael Shepanski
cd1a05d770 Make flake8 happy 2017-02-20 00:37:00 -05:00
Michael Shepanski
4b1a564409 All config options can be set with environment variables; Update all os.environ calls to use CONFIG.get; Finish documenting configuration options. 2017-02-19 22:18:23 -05:00