13526 Commits

Author SHA1 Message Date
Tom Piccirello
312e914adb WebAPI: Add support for authenticating via API key
PR #23212.
Closes #13201.
2025-10-16 14:50:59 +03:00
Andrew Johnson
bb97817f35 Fix screen reader accessibility in torrent list
PR #23359.
Closes #20393.
2025-10-15 11:10:53 +03:00
Vladimir Golovnev
d41012a285 Fix "Save as .torrent file" button is visible before metadata retrieved
PR #23375.
2025-10-14 13:02:53 +03:00
Vladimir Golovnev
fb71c814ca Don't change the processing order of alerts of different types
PR #23373.
Closes #23319.
2025-10-14 13:00:48 +03:00
Chocobo1
62b5619bc1 Migrate away from deprecated Qt methods
PR #23370.
Closes #23354.
2025-10-13 06:57:58 +08:00
xavier2k6
518fd7cc1b Use appropriate icon for "error" status in search tab
PR #23351.
2025-10-10 16:17:15 +03:00
Vladimir Golovnev
9a68a03f53 Make the Smart filter to reject articles with an unrecognized episode number
PR #23340.
Closes #23313.
2025-10-08 12:51:21 +03:00
tehcneko
d5c173be16 WebUI: Fix path input layout in torrent creator
PR #23345.
2025-10-07 02:35:47 +08:00
Chocobo1
e78b392c7b Avoid spawning another temporary event loop
And redirect stderr messages to console.

PR #23344.
2025-10-07 02:27:19 +08:00
Chocobo1
34ad55bb29 Avoid duplicate lookup
In C++20 `std::views::transform()` followed by `std::views::filter()` has a nasty effect of
invoking transformation function twice.
Note that there will be a `std::views::cache_latest()` in C++26 to
address this issue.

Ref:
https://www.open-std.org/jtc1/sc22/wg21/docs/papers/2023/p2760r1.html#cache_last
https://stackoverflow.com/questions/64199664/why-c-ranges-transform-filter-calls-transform-twice-for-values-that-match

PR #23343.
2025-10-07 02:12:27 +08:00
Chocobo1
d5d690cace Utilize algorithms from std::ranges
The result is shorter code and improves readability.
Note that `asConst()` is still required for non-const containers, otherwise the container will
detach.

PR #23342.
2025-10-07 01:56:08 +08:00
dependabot[bot]
4181a10542 GHA CI: Bump Github Actions versions
PR #23332.

---

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-10-05 18:30:51 +08:00
Samuel Lachance
ee881d4889 Allow to filter RSS by simple string
Adds a search bar for RSS items. It supports plain text search (no regex), applies only to the selected tab, updates results as you type, and shows all items when the field is empty.

PR #23278.
Resolves #14719, resolves #15538, resolves #18444, resolves #18183, resolves #22570.

---------

Co-authored-by: Vladimir Golovnev <glassez@yandex.ru>
Co-authored-by: Chocobo1 <Chocobo1@users.noreply.github.com>
2025-10-04 08:12:26 +08:00
Chocobo1
eed0e56d1a Use proper return type
`count()`, `length()`, `size()`, `indexOf()` and `lastIndexOf()` were
returning `int` in Qt5. In Qt6 they return `qsizetype`.

PR #23317.
2025-09-29 03:08:02 +08:00
Chocobo1
01ac8c012c Improve parsing HTTP request line
Now the parsing is done with Views and the conversion to `QString` is
only done in the last step.

PR #23316.
2025-09-29 02:56:09 +08:00
cocopaw
2d6d9ab792 Add Torrent Creator toolbar button
PR #23305.
Closes #21489.
2025-09-29 02:36:30 +08:00
Tom Piccirello
4fb54d3da0 WebUI: fix adding torrent when using virtual tables
When using virtual tables we can't rely on fetching the values from the DOM. We should always fetch values directly from the file tree.

PR #23263.
Closes #23241.
2025-09-29 02:19:07 +08:00
Vladimir Golovnev
84224c1bbf Don't fail because of existing files when exporting torrent files
PR #23315.
Closes #23017.
2025-09-28 21:08:00 +03:00
nn
42786b2afc Restore default drag behavior in Torrent Content widget
Multi-selection for default LMB action, as before 5.1 update.
Adds option to select grab as the default behavior, for users who don't have the Alt key available.
Holding the Alt key toggles between grab/multi-selection.

PR #23180.
Closes #22686.
2025-09-29 01:58:46 +08:00
Vladimir Golovnev
222d265eec Log a critical error before aborting the app
PR #23303.
2025-09-27 20:22:38 +03:00
Chocobo1
d02b01c733 WebUI: don't send HTTP Referer header to other servers
`same-origin`
> Sends the full URL (stripped of parameters) for same-origin requests. Cross-origin requests will contain no referrer header.

This would be helpful for 3rd party WebUI that were forked from the
official one. The official WebUI is not affect by this change since the
request is blocked by CSP.

PR #23294.
2025-09-27 15:54:49 +08:00
Chocobo1
10b879bdaf Propagate error messages from search engine
This will be useful for development and debugging issues. The messages will be outputted to both console and qbt logger.
Note that having stderr messages does not always mean the operation failed but there might be some (non-fatal) issues.

PR #23293.
Closes #6553. Closes #22381. Closes #23052.
2025-09-27 15:42:51 +08:00
Vladimir Golovnev
3de2a9f486 Don't create lock file in internal data folders
PR #23279.
2025-09-22 20:09:21 +03:00
Tom Piccirello
3b744c3dba WebUI: fix lint errors
PR #23277.
2025-09-22 10:35:21 +08:00
cocopaw
9696c99dbd Block invalid file names when renaming torrent content
Relevant issues: #22426, #21899,#16906,#16834, #16271, #11276, #9085, #11340, #14728, #20412, #20337, #17049, #17752, #17469, #15378, #15227, #14908.
PR #23060.

---------

Co-authored-by: Chocobo1 <Chocobo1@users.noreply.github.com>
2025-09-20 14:42:30 +08:00
Tom Piccirello
753fb80e9b WebAPI: Append port to session cookie name
PR #23228.
Closes #21651.
2025-09-19 08:29:46 +03:00
Chocobo1
c075097acd Allow to run CI checks locally
Now the developer is able to run the checks easily and locally (by
following the instructions in nova3/README.md).

PR #23262.
2025-09-14 22:17:23 +08:00
Chocobo1
b0148ef36c WebUI: enforce coding style
* WebUI: prefer `classList.toggle()` over other pattern
  Addresses: https://github.com/qbittorrent/qBittorrent/pull/23231#discussion_r2328647152
* WebUI: prefer using built-in objects Constructor
* WebUI: combine function calls

PR #23261.
2025-09-14 22:11:23 +08:00
Mark Yu
5edaf2cf10 Use class instead of struct
PR #23255.
2025-09-14 17:18:44 +08:00
Mark Yu
fcaa95101d Allow equals character in the command line value
The CLI options should allow the `=` (equals) char as value so doing `--save-path="/home/test/mydir = somedir"` should parse properly with the `value` method returning `"/home/test/mydir = somedir"`.

Closes #23248.
PR #23251.

---------

Co-authored-by: Vladimir Golovnev <glassez@yandex.ru>
Co-authored-by: Chocobo1 <Chocobo1@users.noreply.github.com>
2025-09-14 16:54:14 +08:00
Mark Yu
8e14541236 Allow to copy content paths of selected torrents
Closes #23227.
PR #23239.

---------

Co-authored-by: Chocobo1 <Chocobo1@users.noreply.github.com>
2025-09-14 16:42:59 +08:00
xavier2k6
919520b4c3 GHA CI: Install NSIS via third party action on Windows
* Install `NSIS` via https://github.com/repolevedavaj/install-nsis
* `NSIS` is no longer installed on GitHub provided Runner Image as of `windows-2025`
* `NSIS: 3.10` was only available on `windows-2019 / windows-2022`
* We can use newer release now eg. `NSIS: 3.11`.

PR #23249.
2025-09-14 16:33:24 +08:00
Thomas (Tom) Piccirello
df9e2bb155 Run all WebUI CI checks regardless of failure
This fixes an annoyance I've hit with the WebUI CI checks. If the linter fails, the GH Action immediately exits before the formatter has run. This can mean fixing the lint error and pushing up a change, only for the GH Action to then fail due to the formatter check.
This PR makes it so that all checks always run, with the job still failing if any of the checks failed. It should allow for a quicker feedback loop. For an example, see #23199
GitHub Action docs: https://docs.github.com/en/actions/reference/workflows-and-actions/contexts#steps-context

PR #23198.
2025-09-13 01:53:10 +08:00
Thomas (Tom) Piccirello
7ddbf58a3b WebAPI: Respond with more detailed info
* WebAPI: return error message when endpoint not found
* WebAPI: send appropriate status code when logging in
* WebAPI: return more info when adding torrents

PR #23202.
Closes #375.
Closes #10688.
Closes #10747.
Closes #11464.
2025-09-12 17:53:48 +03:00
Thomas (Tom) Piccirello
69b2d7a53e WebAPI: Support persisting WebUI client preferences
This provides a mechanism for persisting WebUI client preferences that are distinct from the broader qBittorrent preferences. These preferences apply exclusively to the WebUI.

PR #23088.
2025-09-12 17:47:32 +03:00
Chocobo1
94ef038f3a Improve abstraction of search plugin
To make intentions clear and avoid misuse.
Now it should be possible to inherit `Engine` class and create an usable subclass from it.

PR #23232.
2025-09-07 17:50:39 +08:00
Chocobo1
5c0010ac6c WebUI: prefer for loop over Array.forEach method
These were missed in 6ac0c5a8b8.
Also refactor the code a bit.

PR #23231.
2025-09-07 16:16:31 +08:00
Chocobo1
0a9316382a WebUI: fix invalid method
The FileList type has no `entries()` method. Use the generic function from `Array` instead.
Addresses https://github.com/qbittorrent/qBittorrent/pull/23182#discussion_r2319408410

Closes #23224.
2025-09-07 16:14:40 +08:00
dependabot[bot]
463ac253fd GHA CI: Bump actions version
PR #23208.

---
Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-09-07 16:11:02 +08:00
Thomas (Tom) Piccirello
4ad93bafb2 Update Piccirello's copyright email
PR #23197.
2025-09-07 16:10:07 +08:00
Thomas (Tom) Piccirello
f651a311a4 WebUI: Fix add torrent spinner in Firefox
Firefox seems to have an issue where svgs loaded via background-url are not animated. Loading the svg directly as an img fixes this.

Related: #23074.
PR #23195.
2025-09-07 16:02:32 +08:00
Userdocs
3146a3c2f9 Fix compilation in C++23 mode
This adds c++23 support. In my testing it works for nox and desktop.

PR #23193.
2025-09-07 15:49:50 +08:00
Thomas (Tom) Piccirello
93a72673d4 WebAPI: send names of missing required params
Small quality of life improvement.

PR #23192.
2025-09-05 20:46:47 +08:00
anikey
56277d5e2b WebUI: add I2P peers to peer list
The WebUI part of the changes for #23061. Now qBittorrent will display I2P peers in WebUI peers tab.
Fixes the second part of #19794 ("i2p peer list does not show in GUI").

PR #23185.
2025-09-05 20:40:25 +08:00
Thomas (Tom) Piccirello
ac31fe52e9 WebUI: Continue polling after network error
These `fetch` calls properly handle 4xx and 5xx errors, but don't handle network errors. In all cases, I've used the same logic as the `!response.ok` branch of each individual fetch function. This should ensure consistent behavior.

PR #23164.
2025-09-05 20:32:43 +08:00
Thomas (Tom) Piccirello
4fa433a728 WebUI/WebAPI: Support downloading torrent via search plugin
This adds support for downloading a torrent via a search plugin's `download_torrent` function. This primarily affects torrents that use a private tracker requiring a login.

Closes #18334.
PR #23163.
2025-09-05 20:24:15 +08:00
Chocobo1
becfd19e34 Enable full type checking on search engine
Now it utilize type stub for PySocks library and all search engine python code are properly
type checked.

Note that a `cast` is required because there isn't enough hints in PySocks to let the type
checker understand that the classes are supposed to be compatible.

PR #23183.
2025-08-31 22:10:30 +08:00
Chocobo1
dffd27a879 WebUI: prefer range based for loop
Using `entries()` can also save the work of manually handling the index variable.

PR #23182.
2025-08-31 21:54:48 +08:00
Chocobo1
b851caa6b9 WebUI: use local preference class locally 2025-08-31 21:45:48 +08:00
Chocobo1
07f2afc4ac WebUI: move variable into proper scope 2025-08-31 21:45:48 +08:00