Commit graph

4410 commits

Author SHA1 Message Date
Tobi
e314afbad6 Merge pull request #13256 from pierreeurope/fix/ttml-postprocessing-error-reporting
Fix subtitle post-processing error losing original exception
2026-02-19 00:21:17 -08:00
Tobi
113345ef89 Merge pull request #13203 from dustdfg/video_detail_fragment_click_through
VideoDetailFragment: Forcefully catch click events uncaught by children
2026-02-18 23:45:35 -08:00
vt
e918cd3753 remove existing comment replies screens before adding new one 2026-02-19 12:07:22 +05:30
pierreeurope
c23b258a11 Fix subtitle post-processing error losing original exception
Previously, TtmlConverter.process() caught all exceptions during TTML
to SRT conversion and returned opaque error codes (1 for IOException,
8 for other exceptions). These error codes were then wrapped by
Postprocessing.run() into a generic RuntimeException with the message
'post-processing algorithm returned N', losing the original exception
and its stack trace.

This made it impossible for users and developers to diagnose the root
cause of subtitle download failures, as reported in #13206.

Now, IOExceptions are re-thrown directly, and other exceptions are
wrapped in an IOException with the original exception as the cause.
This allows DownloadMission.doPostprocessing() to properly catch and
report the actual error, including the full stack trace in the crash
report.

Fixes #13206

Signed-off-by: pierreeurope <pierre.europe@pm.me>
2026-02-16 12:46:30 +01:00
Yevhen Babiichuk (DustDFG)
c82bdb5846 ErrorActivity use normal \n instead of \\n in resource strings 2026-02-11 16:54:35 +02:00
Aayush Gupta
389c1b0874 ErrorActivity: Kotlin-fy buildMarkdown method
Signed-off-by: Aayush Gupta <aayushgupta219@gmail.com>
2026-02-11 21:40:02 +08:00
Aayush Gupta
1708e99e75 ErrorActivity: Catch exceptions not throwables
Signed-off-by: Aayush Gupta <aayushgupta219@gmail.com>
2026-02-11 21:40:02 +08:00
Aayush Gupta
4c8c110995 ErrorActivity: Use better variable names and encapsulation
Signed-off-by: Aayush Gupta <aayushgupta219@gmail.com>
2026-02-11 21:39:56 +08:00
Yevhen Babiichuk (DustDFG)
043e3b21c5 ErrorActivity convert to kotlin
Co-authored-by: Aayush Gupta <aayushgupta219@protonmail.com>
2026-02-11 18:31:12 +08:00
Yevhen Babiichuk (DustDFG)
c8b25a9f5a ErrorActivity small refactor 2026-02-11 18:31:12 +08:00
Aayush Gupta
99f26cc7ff Minor improvements
- Use early return in case of nulls
- Use better variable names
- Remove non-required newlines, imports and add missing ones

Signed-off-by: Aayush Gupta <aayushgupta219@gmail.com>
2026-02-10 16:33:43 +08:00
Yevhen Babiichuk (DustDFG)
a379e46eb2 Convert newpipe/settings/export/PreferencesObjectInputStream to kotlin 2026-02-10 10:09:18 +02:00
Yevhen Babiichuk (DustDFG)
698f0ac61b Convert /newpipe/util/StreamTypeUtil to kotlin 2026-02-10 10:09:18 +02:00
Yevhen Babiichuk (DustDFG)
09e17d7540 Covert newpipe/util/DependentPreferenceHelper to kotlin 2026-02-10 10:09:18 +02:00
Yevhen Babiichuk (DustDFG)
2eb86d4f21 Convert newpipe/util/ServiceHelper to kotlin 2026-02-10 10:09:18 +02:00
Yevhen Babiichuk (DustDFG)
e4e3e8d351 Convert newpipe/util/NewPipeTextViewHelper to kotlin 2026-02-10 10:09:18 +02:00
Yevhen Babiichuk (DustDFG)
ba04b63832 Convert newpipe/ExitActivity to kotlin 2026-02-10 10:09:18 +02:00
Yevhen Babiichuk (DustDFG)
80ba2c49fa Convert newpipe/util/PeertubeHelper to kotlin 2026-02-10 09:51:14 +02:00
Yevhen Babiichuk (DustDFG)
3102c65f8a Convert newpipe/util/PlayButtonHelper to kotlin 2026-02-10 09:51:13 +02:00
Yevhen Babiichuk (DustDFG)
12b766f175 Uitilize kotlin elvis operator 2026-02-10 09:23:17 +02:00
Yevhen Babiichuk (DustDFG)
a54c55e7a4 SharedPreferences.edit applies changes automatically 2026-02-10 09:23:17 +02:00
Yevhen Babiichuk (DustDFG)
b6902e2587 Utilize kotlins ifEmpty 2026-02-10 09:23:17 +02:00
Yevhen Babiichuk (DustDFG)
62f224e01c Refactor settings/preferencesearch/PreferenceSearchItem#allRelevantSearchFields
It doesn't need to return mutable list
2026-02-10 09:23:17 +02:00
Yevhen Babiichuk (DustDFG)
25934e01eb Correct inverted check
If performs action when value is true but check when false
Fix for 07e53a2d7a
2026-02-09 14:31:56 +02:00
Aayush Gupta
c7c3520c63 Merge pull request #13137 from dustdfg/info_item_builder_dead
Remove dead code from info_list/InfoItemBuilder
2026-02-08 22:28:19 +08:00
Aayush Gupta
b5edd0a25e Merge pull request #13131 from dustdfg/tabs_json_helper_refactor
TabsJsonHelper refactor
2026-02-08 22:06:25 +08:00
Yevhen Babiichuk (DustDFG)
07e53a2d7a Replace Illegal{State,Argument} exceptions with more idiomatic kotlin code 2026-02-08 21:59:10 +08:00
Yevhen Babiichuk (DustDFG)
ed10aba501 VideoDetailFragment: Forcefully catch click events uncaught by children
Because otherwise they will be caught by underlying view and
"click through" will happen. Workaround for #5600
2026-02-06 19:03:01 +02:00
Tobi
e0892ca9df Merge pull request #13161 from jpds/outdated-subscription-shuffle
FeedLoadManager: Shuffle the order outdated subscriptions are updated in
2026-02-06 02:13:56 -08:00
AbsurdlyLongUsername
b5b6b6bdc4 Fix additional setRecovery from rebase errors 2026-02-05 11:17:30 +00:00
AbsurdlyLongUsername
bd255606d6 Add conditional guard to prevent useVideoAndSubtitles overwriting recovery position that was set in Player.handleIntent for RESUME_PLAYBACK when resuming playback 2026-02-05 05:05:41 +00:00
AbsurdlyLongUsername
b7d69682f7 Update useVideoAndSubtitles rename in comment 2026-02-05 05:05:40 +00:00
AbsurdlyLongUsername
10fc6bf2a3 Small refactor getPlayQueueFromCache 2026-02-05 05:05:40 +00:00
Yevhen Babiichuk (DustDFG)
5d681646e9 Refactor settings/tabs/TabsJsonHelper.java to use java streams 2026-02-02 23:59:01 +02:00
Jonathan Davies
6ccda31305 FeedLoadManager: Shuffle the order outdated subscriptions are updated in 2026-01-31 20:47:48 +00:00
Yevhen Babiichuk (DustDFG)
1905200e4d Remove dead code from info_list/InfoItemBuilder
It no longer really builds any view and used only for stroing click
gesture callbacks. In the same way lik local/LocalItemBuilder does

Last usage of build functions: 93d12e5bf0
2026-01-29 15:01:40 +02:00
Stypox
2c2a595246 Avoid rebuilding BackgroundPlayerUi if already in place 2026-01-28 02:39:56 +01:00
Stypox
3a7abecdcb Address review comments 2026-01-28 02:20:33 +01:00
AudricV
b25240eea9 Disable fetching video and text tracks in background player
This reduces data usage for manifest sources with demuxed audio and
video, such as livestreams, for non-HLS sources only due to an
ExoPlayer bug.
2026-01-28 02:13:14 +01:00
AudricV
503ae74dd1 Allow changing video and text tracks state without stream info
This allows disabling these track types when stream info has been not
loaded while the ExoPlayer instance is.

It is now possible to do so with the background player, in order to
disable fetching video and text tracks for manifest sources,
especially used for livestreams.

Also set the recovery first before reloading play queue manager in the
useVideoAndSubtitles method of the Player class.
2026-01-28 02:13:14 +01:00
AudricV
85bb37368d Rename useVideoSource to useVideoAndSubtitles in Player
As both subtitles and video tracks are disabled in this method, the
goal of this rename is to highlight disabling/enabled subtitles.
2026-01-28 02:13:14 +01:00
AudricV
8edbc1b8d9 Use DASH first instead of HLS and YouTube's DASH parser for lives 2026-01-28 02:13:14 +01:00
AudricV
4b88b9faff Add a YouTube DASH manifest parser to make live DASH manifests usable
This is a hacky solution, a better one should be investigated and used.
2026-01-28 02:13:14 +01:00
Stypox
58e8bc273d Merge pull request #13134 from TeamNewPipe/revert-12781-feat/similar-youtube-client-screen-rotation 2026-01-28 02:12:35 +01:00
Stypox
080b95a6e0 Merge pull request #13129 from AudricV/npe_update 2026-01-28 02:08:26 +01:00
Stypox
e56e4f864d Merge pull request #13133 from Stypox/missing-report-button 2026-01-28 02:05:16 +01:00
Stypox
a0196ea21c Merge pull request #13132 from Stypox/regression-detailfragment-flickers 2026-01-28 02:04:15 +01:00
Stypox
ff0436ecce Revert "Remember and restore orientation on fullscreen exit" 2026-01-28 01:44:39 +01:00
Stypox
403897af39 Allow reporting ContentNotAvailableException 2026-01-28 00:14:21 +01:00
Stypox
c0a007a023 Partial revert: fix VideoDetailFragment flickering
This partially reverts commit c31ae95f1f, which was needed to fix ghost notifications. There I broke the "cycle" causing the useless notifications to popup in 2 different places (see points 3 and 4 of the commit description).
However, breaking the cycle in point 4 ("`PlayerHolder::tryBindIfNeeded()` is now used to passively try to bind, instead of `PlayerHolder::startService()`" was not correct, for the following reason.
I assumed that `ACTION_PLAYER_STARTED` was used for notifying that the player was instantiated anew, while it actually is used to notify that something is now ready for use: it could be the player, but it could also just be that the bottom sheet view was just added and thus the VideoDetailFragment needs to start the player.
Therefore, when handling `ACTION_PLAYER_STARTED` it is correct to start the player service and not just try to bind to it.
The other point in which I broke the cycle (point 3) should still prevent ghost notifications, although I could not test.
2026-01-27 23:44:25 +01:00