Commit graph

1498 commits

Author SHA1 Message Date
meisnate12
abc3464de3
Raise Exceptions on bad Download Responses (#1109)
* expose showstatus to downloadDatabases and downloadLogs

* throw errors for bad download responses
2023-05-24 11:37:37 -07:00
Elan Ruusamäe
981f1624ac
Add support Discover isPlayed/markPlayed/markUnplayed (#1090)
* Add isPlayed, markPlayed, markUnplayed to MyPlexAccount

* Add documentation for item

* Clarify that the methods change on Discover
2023-05-24 11:37:13 -07:00
JonnyWong16
405d21b6bc
Release 4.13.4 2023-03-09 18:31:55 -08:00
JonnyWong16
b5b70d81e2
Fix missing marker attribute for Movie (#1123) 2023-03-09 18:27:13 -08:00
JonnyWong16
74c0b933b4
Release 4.13.3 2023-03-09 17:57:28 -08:00
JonnyWong16
e7571ce311
Fix updateProgress docs (#1122) 2023-03-09 17:56:40 -08:00
JonnyWong16
0080cc8964
Add blendColor parameter to transcodeImage() (#1121)
* Add `blendColor` to `transcodeImage()`

* Update `transcodeImage()` tests
2023-03-09 16:18:27 -08:00
JonnyWong16
3a4c246ff5
Update getStreamURL() for dash protocol (#1120)
* Update `getStreamURL()`

* Update `getStreamURL()` test
2023-03-09 15:48:51 -08:00
JonnyWong16
0962cace85
Add advanced settings for show/season preferred audio/subtitle settings (#1114)
* Add advanced settings for Show/Season audio/subtitle settings

* Add tests for Show/Season audio/subtitle setting attributes
2023-03-09 15:34:49 -08:00
JonnyWong16
3c64bdb11c
Add support for editing addedAt field (#1107)
* Add AddedAtMixin

* Add tests for AddedAtMixin
2023-03-09 15:22:56 -08:00
Elan Ruusamäe
a00f1e2766
Cleanup duplicate header.platform reading (#1080)
It was originally a typo fallback for header.platorm before 3917b335c.

See also f26db5de
2023-03-09 14:50:46 -08:00
JonnyWong16
0e958f6136
Fix unable to remove tags with special characters (#1102)
* Ensure removed tags are URL encoded

* Add special characters to test mixin tag
2023-03-09 14:49:52 -08:00
JonnyWong16
63fe34c2f4
Speed up searchType and tagType lookups (#1097) 2023-03-09 14:21:45 -08:00
JonnyWong16
a22830dc94
Add convenience method to set default audio and subtitle streams (#1085)
* Reload when accessing audioStreams or subtitleStreams

* Add setDefault method to AudioStream and SubtitleStream

* Update subtitle test

* Add `videoStreams()` convenience method

* Add test for `videoStreams()` method
2023-03-09 14:21:20 -08:00
JonnyWong16
1e220eb311
Add support for credit markers (#1094)
* Add credit markers

* Disable credit detection in bootstrap test server

* Add `first` property for credits markers

* Add credits detection setting attribute

* Update tests for credits detection setting
2023-03-09 13:32:17 -08:00
JonnyWong16
6350e85ff9
Add seasonCount attribute to Show (#1108)
* Add `seasonCount` attribute to `Show`

* Add test for show seasonCount

* Fix season year test

* Fix show studio test

* Fix season year test

Season year metadata is flakey
2023-03-09 13:18:59 -08:00
JonnyWong16
8b3235445f
Release 4.13.2 2022-12-21 14:00:56 -08:00
JonnyWong16
a314caf861
Add pin parameter to switchHomeUser (#1076) 2022-12-21 13:57:23 -08:00
JonnyWong16
9b8c7d522d
Properly close file object in mixin uploads (#1074)
* Properly close file object in mixin uploads

* Also support a file-like object as the upload `filepath` parameter

* Update image upload tests for file-like object
2022-12-21 13:56:02 -08:00
Elan Ruusamäe
e1e9a6995e
Fix: Remove bogus space from limit parameter (#1073) 2022-12-21 13:10:48 -08:00
Elan Ruusamäe
668fdbbe56
Allow overriding includeUserState for _toOnlineMetadata (#1071)
* Allow overriding includeUserState for _toOnlineMetadata

* Pass kwargs from watchlist to _toOnlineMetadata

Co-authored-by: JonnyWong16 <9099342+JonnyWong16@users.noreply.github.com>
2022-12-21 13:10:09 -08:00
Elan Ruusamäe
c3d2a56a80
Use totalSize attribute for watchlist walking (#1070) 2022-12-21 13:02:02 -08:00
Elan Ruusamäe
b056e9d60b
Fix: Inherit session when creating internal PlexServer objects (#1069)
* Make myPlexAccount inherit session

* Pass session to _toOnlineMetadata PlexServer
2022-12-21 13:01:37 -08:00
JonnyWong16
f330d87d51
Fix getGuid doc string (#1068) 2022-12-21 11:52:29 -08:00
Elan Ruusamäe
7580fc84a9
Use cached_property decorator (#1065)
* Use @cached_property in PlexSession.user

* Use @cached_property in PlexServer.library

* Use @cached_property in PlexServer.settings

* Tests: Update clearing plex.settings cache

* Use @cached_property in LibrarySection.totalSize

* Add backports.cached-property==1.0.2; python_version<="3.7" dependency

* Import cached_property from dist or backports

* Add backports.cached-property to requirements_dev.txt

* Remove version pin for backports.cached-property in requirements.txt

Co-authored-by: JonnyWong16 <9099342+JonnyWong16@users.noreply.github.com>

Co-authored-by: JonnyWong16 <9099342+JonnyWong16@users.noreply.github.com>
2022-12-21 11:51:45 -08:00
JonnyWong16
ac41fbf4fb
Add 2FA code parameter for MyPlexAccount (#1063) 2022-12-21 11:44:34 -08:00
JonnyWong16
955c697549
Add Rating media tag (#1059)
* Add tagKey for Role

* Simplify Guid tag

* Sort tag attributes and update doc strings

* Add media Rating tag

* Add tests for Rating tag
2022-12-21 11:43:52 -08:00
JonnyWong16
be42435ed3
Factor out playQueue() method to PlexPartialObject (#1058)
* Factor out `playQueue` to `PlexPartialObject`

* Update `PlayQueue.create()`

* Fix playqueue tests
2022-12-21 11:43:26 -08:00
JonnyWong16
e5d3ebe273
Fix parsing settings enum (#1057)
* Assume key and value are equal when missing `key:value` pair
2022-12-21 11:34:50 -08:00
JonnyWong16
9dbb2e5169
Create music playlist from m3u file (#1055)
* Create music playlists from m3u files

* Add test for playlist m3u import

* Add createCollection examples
2022-12-21 11:32:43 -08:00
ReenigneArcher
b5110722fd
Add timeout parameter to uploadTheme (#1039)
Since themes may take a while to upload, it may be beneficial to have a separate `timeout` option for uploading themes, instead of using the default `config.TIMEOUT`.
2022-12-21 11:32:07 -08:00
JonnyWong16
3d3f9da501
Release 4.13.1 2022-11-08 18:02:59 -08:00
Michael Cramer
1d5eb8a883
"repeat" should not be a boolean: 0, 1 or 2 (#1046)
* "repeat" should not be a boolean: 0, 1 or 2

* cast to int
2022-11-08 16:36:56 -08:00
JonnyWong16
3216acfb41
Add methods to change Plex Home PIN (#1044)
* Add methods to change Plex Home PIN

* Add tests for changing Plex Home PIN
2022-11-08 15:57:54 -08:00
Sebastian Noel Lübke
f97b1c48c8
fix typo (#1041) 2022-11-08 15:57:30 -08:00
JonnyWong16
01c8ff269d
Fix initializing metadata.provider.plex.tv multiple times (#1027) 2022-11-08 15:57:16 -08:00
JonnyWong16
9b0c8e5fd3
More f-string changes (#1025) 2022-11-08 13:40:18 -08:00
Rick Getz
52b3abfe69
Add container size to seasons request to allow more than 20 to be pulled (#1019)
* Add container size to seasons request to allow more than 20 to be pulled

* Add child count as container_size argument as requested.

* Spacing typo
2022-11-08 13:39:53 -08:00
JonnyWong16
2f52b300f1
Fix library guid search (#1024)
* Fix library guid search

* PMS 1.28.2.6151-914ddd2b3 no longer allows `guid!=` search

* Update library search operators doc string for guid
2022-09-08 14:58:04 -07:00
JonnyWong16
356ce8bf7e
Release 4.13.0 2022-08-27 23:09:16 -07:00
JonnyWong16
020a32f2b8
Update PlexAPI to f-strings (#1000)
* Update plexapi to f-strings

* Update tests to f-strings
2022-08-27 22:56:01 -07:00
Joshua Peek
fbc124aa57
Fix searchDiscover handling invalid results (#1013)
* Filter out bad discover search results

An stub object is sometimes returned from the API that is marked as
`'external'` but has has no `'SearchResults'` key.

    {'id': 'external', 'title': 'More Ways To Watch', 'size': 0}

* Wrap line to fit 127c

* Ensure empty array for SearchResult
2022-08-27 06:24:10 -07:00
JonnyWong16
4d9e1d4f14
Add edition support for movies (#1010)
* Add editionTitle to Movie attributes

* Add EditionTitleMixin to Movie

* Add tests for movie editionTitle

* Add `editions()` method to Movie

* Add test for movie editions method
2022-08-27 06:17:33 -07:00
JonnyWong16
02e3ddf3c1
Add maxresults parameter to MyPlexAccount.watchlist() (#1009)
* Add `maxresults` parameter to watchlist

* Test watchlist maxresults
2022-08-27 00:20:11 -07:00
JonnyWong16
e640f57319
Add utils.toJson(obj) function to convert an object to a JSON string (#998)
* Add `utils.toJson(obj)` function to convert an object to a JSON string

* Add test for utils.toJson()
2022-08-27 00:13:41 -07:00
JonnyWong16
ef12e64a6f
Add support for using MediaTag objects when editing tags (#994)
* Support using MediaTag objects when editing tags

* Update tests for editing tags with MediaTag objects
2022-08-26 22:52:50 -07:00
JonnyWong16
d1211722c8
Use pagination for /all endpoints (#990) 2022-08-26 22:45:15 -07:00
JonnyWong16
c8854c64c9
Add return self to various methods to support chaining (#986)
* Add return self to various methods to support chaining

* Fix runButlerTask test
2022-08-26 14:44:50 -07:00
JonnyWong16
f0ed19c2fe
Add PlayedUnplayedMixin (#984)
* Add PlayedUnplayedMixin

* Deprecate Video isPlayed, markWatched, and markUnwatched

* Rename all deprecated methods

* Return self to enable method chaining

* Update tests for audio markPlayed / markUnplayed using history

* Remove duplicate video history tests
2022-08-26 12:14:24 -07:00
JonnyWong16
716d8edb52
Add ability to toggle account view state syncing (#983)
* Add method to enable/disable view state syncing

* Add tests for view state sync
2022-08-26 12:00:46 -07:00