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

peertube: 6.0.4 -> 6.3.3 #358194

Merged
merged 1 commit into from
Dec 3, 2024
Merged

Conversation

liberodark
Copy link
Contributor

Things done

  • Built on platform(s)
    • x86_64-linux
    • aarch64-linux
    • x86_64-darwin
    • aarch64-darwin
  • For non-Linux: Is sandboxing enabled in nix.conf? (See Nix manual)
    • sandbox = relaxed
    • sandbox = true
  • Tested, as applicable:
  • Tested compilation of all packages that depend on this change using nix-shell -p nixpkgs-review --run "nixpkgs-review rev HEAD". Note: all changes have to be committed, also see nixpkgs-review usage
  • Tested basic functionality of all binary files (usually in ./result/bin/)
  • 25.05 Release Notes (or backporting 24.11 and 25.05 Release notes)
    • (Package updates) Added a release notes entry if the change is major or breaking
    • (Module updates) Added a release notes entry if the change is significant
    • (Module addition) Added a release notes entry if adding a new NixOS module
  • Fits CONTRIBUTING.md.

Add a 👍 reaction to pull requests you find important.

@github-actions github-actions bot added 6.topic: nixos Issues or PRs affecting NixOS modules, or package usability issues specific to NixOS 8.has: module (update) This PR changes an existing module in `nixos/` labels Nov 22, 2024
@liberodark
Copy link
Contributor Author

liberodark commented Nov 22, 2024

Cleanup PR without formating
Fix : #357286

@liberodark liberodark mentioned this pull request Nov 22, 2024
13 tasks
@wegank wegank added 12.approvals: 1 This PR was reviewed and approved by one reputable person 12.approved-by: package-maintainer This PR was reviewed and approved by a maintainer listed in the package labels Nov 23, 2024
@ofborg ofborg bot requested review from Izorkin and immae November 23, 2024 12:01
@synq
Copy link

synq commented Nov 24, 2024

It looks like this PR will only build if this PR from the Peertube project has been fixed: Chocobozzz/PeerTube#6548

I have put a remark about this in that PR.

@donovanglover donovanglover added the 2.status: wait-for-upstream Waiting for upstream fix (or their other action). label Nov 24, 2024
@synq
Copy link

synq commented Nov 25, 2024

So the problem is that the test fails on this:

server # [  235.543401] peertube[877]: node:internal/errors:496
server # [  235.563965] peertube[877]:     ErrorCaptureStackTrace(err);
server # [  235.567887] peertube[877]:     ^
server # [  235.574601] peertube[877]: Error [ERR_MODULE_NOT_FOUND]: Cannot find package '@peertube/peer>
server # [  235.579849] peertube[877]:     at new NodeError (node:internal/errors:405:5)
server # [  235.584877] peertube[877]:     at packageResolve (node:internal/modules/esm/resolve:916:9)
server # [  235.590518] peertube[877]:     at moduleResolve (node:internal/modules/esm/resolve:973:20)
server # [  235.594392] peertube[877]:     at defaultResolve (node:internal/modules/esm/resolve:1206:11)
server # [  235.598478] peertube[877]:     at ModuleLoader.defaultResolve (node:internal/modules/esm/loa>
server # [  235.601779] peertube[877]:     at ModuleLoader.resolve (node:internal/modules/esm/loader:373>
server # [  235.604889] peertube[877]:     at ModuleLoader.getModuleJob (node:internal/modules/esm/loade>
server # [  235.609638] peertube[877]:     at ModuleWrap.<anonymous> (node:internal/modules/esm/module_j>
server # [  235.612933] peertube[877]:     at link (node:internal/modules/esm/module_job:75:36) {
server # [  235.615966] peertube[877]:   code: 'ERR_MODULE_NOT_FOUND'
server # [  235.621379] peertube[877]: }
server # [  235.625732] peertube[877]: Node.js v18.20.5

@liberodark
Copy link
Contributor Author

liberodark commented Nov 25, 2024

Hi, @synq

Sorry but have zero build issue on peertube 6.3.3
https://paste.yunohost.org/itupimivuj.rust
Ps : Probably you speak about internal test of nixos ?

Best Regards

@roberth
Copy link
Member

roberth commented Nov 26, 2024

It does look like the NixOS test is failing.
You're right that the package is buildable, producing outputs and all, but those outputs seem to contain a peertube that's broken when you run it.
The NixOS test and NixOS module don't seem to do anything outlandish, and they don't seem to configure anything related to transcription. It's the test that protects users from a broken package, and while tests are technically internal, that does not diminish their importance.
Did you perhaps run peertube in a different way? Then it would be good to look at any differences between your configuration and that which is provided by the NixOS peertube module and the test.

@OPNA2608
Copy link
Contributor

OPNA2608 commented Nov 26, 2024

It looks like this PR will only build if this PR from the Peertube project has been fixed: Chocobozzz/PeerTube#6548

Not really relevant, as that is about managing external plugins. Your log is cut off on the side, but it's complaining about peertube/peertube-transcription, which is a new in-tree package that needs to be installed together with the rest:

diff --git a/pkgs/servers/peertube/default.nix b/pkgs/servers/peertube/default.nix
index 35750c0eeebb..58f9a74b8f0b 100644
--- a/pkgs/servers/peertube/default.nix
+++ b/pkgs/servers/peertube/default.nix
@@ -134,6 +134,7 @@ stdenv.mkDerivation rec {
       ~/packages/models/dist/ \
       ~/packages/node-utils/dist/ \
       ~/packages/server-commands/dist/ \
+      ~/packages/transcription/dist/ \
       ~/packages/typescript-utils/dist/ \
       \( -name '*.d.ts' -o -name '*.d.ts.map' \) -type f -delete
   '';
@@ -144,12 +145,13 @@ stdenv.mkDerivation rec {
     mv ~/node_modules $out/node_modules
     mkdir $out/client
     mv ~/client/{dist,node_modules,package.json,yarn.lock} $out/client
-    mkdir -p $out/packages/{core-utils,ffmpeg,models,node-utils,server-commands,typescript-utils}
+    mkdir -p $out/packages/{core-utils,ffmpeg,models,node-utils,server-commands,transcription,typescript-utils}
     mv ~/packages/core-utils/{dist,package.json} $out/packages/core-utils
     mv ~/packages/ffmpeg/{dist,package.json} $out/packages/ffmpeg
     mv ~/packages/models/{dist,package.json} $out/packages/models
     mv ~/packages/node-utils/{dist,package.json} $out/packages/node-utils
     mv ~/packages/server-commands/{dist,package.json} $out/packages/server-commands
+    mv ~/packages/transcription/{dist,package.json} $out/packages/transcription
     mv ~/packages/typescript-utils/{dist,package.json} $out/packages/typescript-utils
     mv ~/{config,support,CREDITS.md,FAQ.md,LICENSE,README.md,package.json,yarn.lock} $out
 

And a new storage location was added storage.original_video_files, which needs to be added to the module. I've re-ordered the storage entries here to match the order from upstream's code, for an easier overview.

diff --git a/nixos/modules/services/web-apps/peertube.nix b/nixos/modules/services/web-apps/peertube.nix
index d85c601f316f..bffc74e10610 100644
--- a/nixos/modules/services/web-apps/peertube.nix
+++ b/nixos/modules/services/web-apps/peertube.nix
@@ -355,19 +355,20 @@ in {
           tmp_persistent = lib.mkDefault "/var/lib/peertube/storage/tmp_persistent/";
           bin = lib.mkDefault "/var/lib/peertube/storage/bin/";
           avatars = lib.mkDefault "/var/lib/peertube/storage/avatars/";
+          logs = lib.mkDefault "/var/lib/peertube/storage/logs/";
           web_videos = lib.mkDefault "/var/lib/peertube/storage/web-videos/";
           streaming_playlists = lib.mkDefault "/var/lib/peertube/storage/streaming-playlists/";
+          original_video_files = lib.mkDefault "/var/lib/peertube/storage/original-video-files/";
           redundancy = lib.mkDefault "/var/lib/peertube/storage/redundancy/";
-          logs = lib.mkDefault "/var/lib/peertube/storage/logs/";
-          previews = lib.mkDefault "/var/lib/peertube/storage/previews/";
           thumbnails = lib.mkDefault "/var/lib/peertube/storage/thumbnails/";
           storyboards = lib.mkDefault "/var/lib/peertube/storage/storyboards/";
-          torrents = lib.mkDefault "/var/lib/peertube/storage/torrents/";
+          previews = lib.mkDefault "/var/lib/peertube/storage/previews/";
           captions = lib.mkDefault "/var/lib/peertube/storage/captions/";
+          torrents = lib.mkDefault "/var/lib/peertube/storage/torrents/";
           cache = lib.mkDefault "/var/lib/peertube/storage/cache/";
           plugins = lib.mkDefault "/var/lib/peertube/storage/plugins/";
-          well_known = lib.mkDefault "/var/lib/peertube/storage/well_known/";
           client_overrides = lib.mkDefault "/var/lib/peertube/storage/client-overrides/";
+          well_known = lib.mkDefault "/var/lib/peertube/storage/well_known/";
         };
         import = {
           videos = {

With that, the VM test passes.

@Izorkin
Copy link
Contributor

Izorkin commented Nov 27, 2024

And a new storage location was added storage.original_video_files, which needs to be added to the module. I've re-ordered the storage entries here to match the order from upstream's code, for an easier overview.

Maybe keep the current sort order? At the very least, can see the history of file changes in upstream.

@wegank wegank removed 12.approvals: 1 This PR was reviewed and approved by one reputable person 12.approved-by: package-maintainer This PR was reviewed and approved by a maintainer listed in the package labels Nov 27, 2024
@ofborg ofborg bot requested a review from Izorkin November 28, 2024 09:04
@fricklerhandwerk
Copy link
Contributor

x86_64-darwin builds are failing and aarch64-darwin is stuck, but not sure this is a blocker for merging. Hard to imagine anyone would host peertube on macOS. If someone is, please open PRs with fixes.

@fricklerhandwerk fricklerhandwerk merged commit 0c053df into NixOS:master Dec 3, 2024
34 of 35 checks passed
RedEtherbloom pushed a commit to RedEtherbloom/nixpkgs that referenced this pull request Dec 4, 2024
mkg20001 pushed a commit to mkg20001/nixpkgs that referenced this pull request Dec 5, 2024
@natsukagami
Copy link
Contributor

Will this be backported to 24.11?

@fricklerhandwerk
Copy link
Contributor

fricklerhandwerk commented Dec 9, 2024

I'd have nothing against it personally, but it wouldn't conform to the general policy of only backporting security fixes. @wegank @RossComputerGuy how firm is that rule?

@natsukagami
Copy link
Contributor

One point to argue for backporting is that 6.1 (which we don't have yet) fixes two important security bugs: https://joinpeertube.org/news/release-6.1

@fricklerhandwerk fricklerhandwerk added the backport release-24.11 Backport PR automatically label Dec 9, 2024
nix-backports bot pushed a commit that referenced this pull request Dec 9, 2024
(cherry picked from commit 0c053df)
@nix-backports
Copy link

nix-backports bot commented Dec 9, 2024

Successfully created backport PR for release-24.11:

fricklerhandwerk pushed a commit that referenced this pull request Dec 10, 2024
peertube: 6.0.4 -> 6.3.3 (#358194)

(cherry picked from commit 0c053df)

Co-authored-by: liberodark <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
2.status: wait-for-upstream Waiting for upstream fix (or their other action). 6.topic: nixos Issues or PRs affecting NixOS modules, or package usability issues specific to NixOS 8.has: module (update) This PR changes an existing module in `nixos/` 10.rebuild-darwin: 1-10 10.rebuild-darwin: 1 10.rebuild-linux: 1-10 backport release-24.11 Backport PR automatically
Projects
None yet
Development

Successfully merging this pull request may close these issues.

9 participants