Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Advertise support for qBittorrent v4.5.2 #150

Merged
merged 1 commit into from
Feb 28, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Advertise support for qBittorrent v4.5.2
  • Loading branch information
rmartin16 committed Feb 28, 2023
commit 3761cb2c70a81e786f4403f735c7a18cf845cd7d
2 changes: 1 addition & 1 deletion .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ concurrency:

env:
LATEST_PYTHON_VER: "3.11"
LATEST_QBT_VER: "v4.5.1"
LATEST_QBT_VER: "v4.5.2"
SUBMIT_COVERAGE_VERSIONS: '[ "3.11" ]'
QBITTORRENTAPI_HOST: "localhost:8080"
QBITTORRENTAPI_USERNAME: "admin"
Expand Down
3 changes: 3 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,8 @@
Change log
==========
### v2023.2.43 (27 feb 2023)
- Advertise support for qBittorrent v4.5.2

### v2023.2.42 (13 feb 2023)
- Advertise support for qBittorrent v4.5.1

Expand Down
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ Python client implementation for qBittorrent Web API

</div>

Currently supports qBittorrent [v4.5.1](https://github.com/qbittorrent/qBittorrent/releases/tag/release-4.5.1) (Web API v2.8.19) released on Feb 11, 2023.
Currently supports qBittorrent [v4.5.2](https://github.com/qbittorrent/qBittorrent/releases/tag/release-4.5.2) (Web API v2.8.19) released on Feb 27, 2023.

User Guide and API Reference available on [Read the Docs](https://qbittorrent-api.readthedocs.io/).

Expand Down
2 changes: 1 addition & 1 deletion docs/source/introduction.rst
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ Introduction

Python client implementation for qBittorrent Web API.

Currently supports qBittorrent `v4.5.1 <https://github.com/qbittorrent/qBittorrent/releases/tag/release-4.5.1>`_ (Web API v2.8.19) released on Feb 11, 2023.
Currently supports qBittorrent `v4.5.2 <https://github.com/qbittorrent/qBittorrent/releases/tag/release-4.5.2>`_ (Web API v2.8.19) released on Feb 27, 2023.

Features
------------
Expand Down
3 changes: 2 additions & 1 deletion qbittorrentapi/_version_support.py
Original file line number Diff line number Diff line change
Expand Up @@ -45,9 +45,10 @@
"v4.5.0beta1": "2.8.14",
"v4.5.0": "2.8.18",
"v4.5.1": "2.8.19",
"v4.5.2": "2.8.19",
}

MOST_RECENT_SUPPORTED_APP_VERSION = "v4.5.1"
MOST_RECENT_SUPPORTED_APP_VERSION = "v4.5.2"
MOST_RECENT_SUPPORTED_API_VERSION = "2.8.19"


Expand Down
3 changes: 2 additions & 1 deletion qbittorrentapi/torrents.py
Original file line number Diff line number Diff line change
Expand Up @@ -1953,7 +1953,8 @@ def torrents_set_location(self, location=None, torrent_hashes=None, **kwargs):
"""
Set location for torrents' files.

:raises Forbidden403Error: if the user doesn't have permissions to write to the location
:raises Forbidden403Error: if the user doesn't have permissions to write to the
location (only before v4.5.2 - write check was removed.)
:raises Conflict409Error: if the directory cannot be created at the location

:param torrent_hashes: single torrent hash or list of torrent hashes. Or ``all`` for all torrents.
Expand Down
2 changes: 1 addition & 1 deletion setup.cfg
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[metadata]
name = qbittorrent-api
version = 2023.2.42
version = 2023.2.43
author = Russell Martin
author_email = rmartin16@gmail.com
maintainer = Russell Martin
Expand Down
12 changes: 7 additions & 5 deletions tests/test_torrents.py
Original file line number Diff line number Diff line change
Expand Up @@ -787,12 +787,14 @@ def test_set_share_limits(client, api_version, client_func, orig_torrent):
"torrents.setLocation",
),
)
def test_set_location(client, api_version, client_func, new_torrent):
def test_set_location(client, api_version, app_version, client_func, new_torrent):
if v(api_version) >= v("2.0.2"):
with pytest.raises(Forbidden403Error):
get_func(client, client_func)(
location="/etc/", torrent_hashes=new_torrent.hash
)
# stopped erroring when the write check was removed for API
if v(app_version) < v("v4.5.2"):
with pytest.raises(Forbidden403Error):
get_func(client, client_func)(
location="/etc/", torrent_hashes=new_torrent.hash
)

loc = mkpath("/tmp", "1")
get_func(client, client_func)(location=loc, torrent_hashes=new_torrent.hash)
Expand Down