[PATCH] gnu: peek: Add missing input.

  • Done
  • quality assurance status badge
Details
6 participants
  • 宋文武
  • jgart
  • Christopher Baines
  • Tobias Geerinckx-Rice
  • (
  • zimoun
Owner
unassigned
Submitted by
jgart
Severity
normal

Debbugs page

J
(address . guix-patches@gnu.org)(name . jgart)(address . jgart@dismail.de)
20221119012744.30470-1-jgart@dismail.de
* gnu/packages/video.scm (peek): Add missing input.
[inputs]: Add ffmpeg so that Peek will not fail to run on a foreign
distro.

hi, peek fails to run on a foreign distro without ffmpeg as an input.

this patch fixes that.

all best,

jgart
---
gnu/packages/video.scm | 2 ++
1 file changed, 2 insertions(+)

Toggle diff (15 lines)
diff --git a/gnu/packages/video.scm b/gnu/packages/video.scm
index c394c65442..4f38d4432c 100644
--- a/gnu/packages/video.scm
+++ b/gnu/packages/video.scm
@@ -5369,6 +5369,8 @@ (define-public peek
(arguments '(#:glib-or-gtk? #t))
(inputs
`(("gtk+" ,gtk+)
+ ;; Peek fails to run on a foreign distro without ffmpeg.
+ ("ffmpeg" ,ffmpeg)
("python" ,python-wrapper)))
(native-inputs
`(("desktop-file-utils" ,desktop-file-utils) ; for update-desktop-database
--
2.38.1
T
T
Tobias Geerinckx-Rice wrote on 18 Nov 2022 18:50
(name . jgart)(address . jgart@dismail.de)
87sfifabuy.fsf@nckx
Hi jgart,

jgart via Guix-patches via 写道:
Toggle quote (5 lines)
> hi, peek fails to run on a foreign distro without ffmpeg as an
> input.
>
> this patch fixes that.

Thanks!

As far as I can tell, this change doesn't affect the peek
package's output at all. Am I mistaken? What should the
observable difference be, beyond ‘working’?

How are you invoking both peeks, and testing the difference? Are
they both running in the exact same environment, back-to-back?

Kind regards,

T G-R
-----BEGIN PGP SIGNATURE-----

iIMEARYKACsWIQT12iAyS4c9C3o4dnINsP+IT1VteQUCY3hGdg0cbWVAdG9iaWFz
LmdyAAoJEA2w/4hPVW15OaUA/3VWEbXSYSgU/LEJvon3SP2c1d9I/sohmxpp+MEQ
suvoAQCOQ1/5HGCeVE/MjfOJdIkfM6RbU/YkKR0OD5UrW7uNDg==
=yKTm
-----END PGP SIGNATURE-----

J
(name . Tobias Geerinckx-Rice)(address . me@tobias.gr)
20221118220730.GB6211@dismail.de
On Sat, 19 Nov 2022 03:50:05 +0100 Tobias Geerinckx-Rice <me@tobias.gr> wrote:
Toggle quote (4 lines)
> As far as I can tell, this change doesn't affect the peek
> package's output at all. Am I mistaken? What should the
> observable difference be, beyond ‘working’?

It was complaining on Ubuntu when I started it that either ffmpeg needs
to be installed or a gnome-shell needs to be running. I didn't log the
exact error message but that was more or less it.

Toggle quote (2 lines)
> How are you invoking both peeks, and testing the difference?

When I add ffmpeg it worked without the warning and actually started
recording my screen as expected. After pressing the record button of
course ;()

I tested once without ffmpeg and once with ffmpeg.

The former failed to record.

Toggle quote (2 lines)
> Are they both running in the exact same environment, back-to-back?

Yup I tested both in Ubuntu.

Let me know if you'd like any more info or if I wasn't precise enough
in my description.

all best,

jgart
(
COG5NUH2AL8O.ZEQDQS240I2H@guix-framework
Heya,

On Sat Nov 19, 2022 at 1:27 AM GMT, jgart via Guix-patches via wrote:
Toggle quote (18 lines)
> * gnu/packages/video.scm (peek): Add missing input.
> [inputs]: Add ffmpeg so that Peek will not fail to run on a foreign
> distro.

> diff --git a/gnu/packages/video.scm b/gnu/packages/video.scm
> index c394c65442..4f38d4432c 100644
> --- a/gnu/packages/video.scm
> +++ b/gnu/packages/video.scm
> @@ -5369,6 +5369,8 @@ (define-public peek
> (arguments '(#:glib-or-gtk? #t))
> (inputs
> `(("gtk+" ,gtk+)
> + ;; Peek fails to run on a foreign distro without ffmpeg.
> + ("ffmpeg" ,ffmpeg)
> ("python" ,python-wrapper)))
> (native-inputs
> `(("desktop-file-utils" ,desktop-file-utils) ; for update-desktop-database

I don't think this will be enough; does the program call the ``ffmpeg''
executable? If so, you'll need to patch the call to ``ffmpeg'' to point to
/gnu/store/.../bin/ffmpeg directly.

Could you also update the inputs/arguments style to gexp form?

-- (
T
T
Tobias Geerinckx-Rice wrote on 19 Nov 2022 01:38
(name . jgart)(address . jgart@dismail.de)
87o7t39sql.fsf@nckx
jgart 写道:
Toggle quote (6 lines)
> It was complaining on Ubuntu when I started it that either
> ffmpeg needs
> to be installed or a gnome-shell needs to be running. I didn't
> log the
> exact error message but that was more or less it.

And how does this patch provide ffmpeg? It adds it to the build
environment, but what happens then?

We know it doesn't add a reference to the final ‘peek’ output (you
can verify this yourself, assuming peek builds reproducibly). It
doesn't change any code in the peek binary.

So what's the mechanism by which it would work? It will need to
be documented.

Toggle quote (8 lines)
>> How are you invoking both peeks, and testing the difference?
>
> When I add ffmpeg it worked without the warning and actually
> started
> recording my screen as expected. After pressing the record
> button of
> course ;()

But how exactly? Please provide exact steps and commands.

( 写道:
Toggle quote (2 lines)
> Could you also update the inputs/arguments style to gexp form?

…but in a separate patch, please.)

Kind regards,

T G-R
-----BEGIN PGP SIGNATURE-----

iIMEARYKACsWIQT12iAyS4c9C3o4dnINsP+IT1VteQUCY3inQg0cbWVAdG9iaWFz
LmdyAAoJEA2w/4hPVW15KJwA/iGHamjzaV80qY5dJyWxcPnpkH+gPmhUh3VQLjZY
PubCAQDvuMbWAP9PHqIIDU8Fk0Ji5aTiSmtHL+YpZCxLwXmzAA==
=vnc1
-----END PGP SIGNATURE-----

C
C
Christopher Baines wrote on 21 Nov 2022 05:11
tag 59372 moreinfo
(address . control@debbugs.gnu.org)
87cz9giha4.fsf@cbaines.net
tags 59372 + moreinfo
quit
J
Re: [bug#59372] [PATCH] gnu: peek: Add missing input.
(name . Tobias Geerinckx-Rice)(address . me@tobias.gr)
20221121082715.GE10046@dismail.de
On Sat, 19 Nov 2022 10:38:26 +0100 Tobias Geerinckx-Rice <me@tobias.gr> wrote:
Toggle quote (3 lines)
> So what's the mechanism by which it would work? It will need to
> be documented.

Hi Tobias,

peek, needs either ffmpeg or gnome shell to be present.

See here for the exact reference:


How should I handle that in Guix?

Should I patch ffmpeg? What if a user wants to use gnome-shell instead of ffmpeg?

Is there a switch I can provide in Guile code?

all best,

jgart
Z
Z
zimoun wrote on 21 Nov 2022 09:13
(address . 59372@debbugs.gnu.org)
87mt8kut6x.fsf@gmail.com
Hi,

Thanks for resuming #51202. :-)

On Sat, 19 Nov 2022 at 03:50, Tobias Geerinckx-Rice via Guix-patches via <guix-patches@gnu.org> wrote:

Toggle quote (4 lines)
> As far as I can tell, this change doesn't affect the peek
> package's output at all. Am I mistaken? What should the
> observable difference be, beyond ‘working’?

Peek needs to be propagated. An issue is open,

IIRC, peek needs to be patched to avoid the propagation and personally,
I am using something along,

guix shell peek \
gtk+ gsettings-desktop-schemas ffmpeg \
-- peek


Cheers,
simon
J
(name . zimoun)(address . zimon.toutoune@gmail.com)
20221121133804.GB16771@dismail.de
On Mon, 21 Nov 2022 18:13:26 +0100 zimoun <zimon.toutoune@gmail.com> wrote:
Toggle quote (12 lines)
> Hi,
>
> Thanks for resuming #51202. :-)
>
> On Sat, 19 Nov 2022 at 03:50, Tobias Geerinckx-Rice via Guix-patches via <guix-patches@gnu.org> wrote:
>
> > As far as I can tell, this change doesn't affect the peek
> > package's output at all. Am I mistaken? What should the
> > observable difference be, beyond ‘working’?
>
> Peek needs to be propagated. An issue is open,

I read through the open issue. Should I send a patch implementing lilyp's suggestion?

That's what I was also thinking of doing but I also had the question
regarding choosing between ffmpeg or gnome-shell. Should we prefer
ffmpeg? Would be cool if we could support choosing between ffmpeg or
gnome-shell.

Is there currently a way to do that?
T
T
Tobias Geerinckx-Rice wrote on 21 Nov 2022 07:14
(name . jgart)(address . jgart@dismail.de)(address . 59372@debbugs.gnu.org)
877czojcs1.fsf@nckx
Hi jgart,

The patch you sent does nothing and didn't fix your foreign
distro. The questions you won't answer were supposed to find out
what might have, but let's move on.

So, please test ('s suggestion. It's the right fix! Propagation
isn't.

You can offer two variants of peek (peek-ffmpeg and
peek-gnome-shell, say) if you like. I don't think that's
necessary, though, unless ffmpeg support is incomplete?

Thanks,

T G-R
-----BEGIN PGP SIGNATURE-----

iIMEARYKACsWIQT12iAyS4c9C3o4dnINsP+IT1VteQUCY3vZjg0cbWVAdG9iaWFz
LmdyAAoJEA2w/4hPVW154qsBAIhRkHVvYUbRl51ogMCQvCDQkJ4j8nBxYIzNRkt9
o6bUAQCZcIsbKj1HUucfwb4/oYB+r3Bw3mjyXOiKQGIixh1iBA==
=xk/Y
-----END PGP SIGNATURE-----

T
T
Tobias Geerinckx-Rice wrote on 21 Nov 2022 12:18
(name . jgart)(address . jgart@dismail.de)
8735acjbu4.fsf@nckx
jgart 写道:
Toggle quote (3 lines)
> peek, needs either ffmpeg or gnome shell to be present.
> How should I handle that in Guix?

Ideally: let peek pop up the window asking the user to install
ffmpeg.

Then the user installs ffmpeg only if it's actually needed, and
isn't ‘forced’ to pay the cost if it's not.

Does it not show that window on a foreign distribution?

Kind regards,

T G-R
-----BEGIN PGP SIGNATURE-----

iIMEARYKACsWIQT12iAyS4c9C3o4dnINsP+IT1VteQUCY3veUw0cbWVAdG9iaWFz
LmdyAAoJEA2w/4hPVW159U0BALrZiUAYPbrjgitVimx3y2KZeJd52GBFc6knCJrC
+HMCAP4tLHUIK24uDkg3uCmLVQEaUr1FGr5roQyQPhQ1TBi9DQ==
=IcNQ
-----END PGP SIGNATURE-----

J
(name . Tobias Geerinckx-Rice)(address . me@tobias.gr)
20221121145805.GB18341@dismail.de
On Mon, 21 Nov 2022 21:18:32 +0100 Tobias Geerinckx-Rice <me@tobias.gr> wrote:
Toggle quote (2 lines)
> Does it not show that window on a foreign distribution?

Yup, it does show that window on a foreign distro.

So, we should just have the user install ffmpeg along with peek in their profile?

Should this ticket be closed then? https://issues.guix.gnu.org/issue/51202#3
Z
Z
zimoun wrote on 22 Nov 2022 06:39
(name . jgart)(address . jgart@dismail.de)
86bkozdpek.fsf@gmail.com
Hi,

On Mon, 21 Nov 2022 at 13:38, jgart via Guix-patches via <guix-patches@gnu.org> wrote:

Toggle quote (5 lines)
> That's what I was also thinking of doing but I also had the question
> regarding choosing between ffmpeg or gnome-shell. Should we prefer
> ffmpeg? Would be cool if we could support choosing between ffmpeg or
> gnome-shell.

Well, from my point of view, let start to use ffmeg without the
propagation. Then, incremental improvements. :-)

Cheers,
simon
J
(name . zimoun)(address . zimon.toutoune@gmail.com)
20221122122934.GB25646@dismail.de
On Tue, 22 Nov 2022 15:39:31 +0100 zimoun <zimon.toutoune@gmail.com> wrote:
Toggle quote (3 lines)
> Well, from my point of view, let start to use ffmeg without the
> propagation. Then, incremental improvements. :-)

Ok, should I send a new patch patching the ffmpeg executable from the
inputs of peek?
宋
宋文武 wrote on 28 Jan 2023 22:02
Re: bug#59372: [PATCH] gnu: peek: Add missing input.
(name . jgart)(address . jgart@dismail.de)
87o7qhj2u3.fsf_-_@envs.net
jgart <jgart@dismail.de> writes:

Toggle quote (9 lines)
> On Mon, 21 Nov 2022 21:18:32 +0100 Tobias Geerinckx-Rice <me@tobias.gr> wrote:
>> Does it not show that window on a foreign distribution?
>
> Yup, it does show that window on a foreign distro.
>
> So, we should just have the user install ffmpeg along with peek in their profile?
>
> Should this ticket be closed then? https://issues.guix.gnu.org/issue/51202#3

Yes, I think it's expected to install ffmpeg yourself for peek when not
in gnome shell. Close now.
Closed
?
Your comment

This issue is archived.

To comment on this conversation send an email to 59372@patchwise.org

To respond to this issue using the mumi CLI, first switch to it
mumi current 59372
Then, you may apply the latest patchset in this issue (with sign off)
mumi am -- -s
Or, compose a reply to this issue
mumi compose
Or, send patches to this issue
mumi send-email *.patch