all messages for Guix-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
From: david larsson <david.larsson@selfhosted.xyz>
To: zimoun <zimon.toutoune@gmail.com>
Cc: 58247@debbugs.gnu.org
Subject: bug#58247: Using guix time-machine results in unsupported manifest format error
Date: Thu, 20 Oct 2022 20:44:23 +0200	[thread overview]
Message-ID: <e2594aa19c0c0bda6aec06406b9dd51e@selfhosted.xyz> (raw)
In-Reply-To: <87v8p1x4fj.fsf@gmail.com>

On 2022-10-03 00:10, zimoun wrote:

[..]

> 
> Let try the converse,
> 
> --8<---------------cut here---------------start------------->8---
> $ guix time-machine --commit=729ce5f -- package -i hello -p /tmp/old
> 
> $ cat /tmp/old/manifest | grep -A 1 '(manifest'
> (manifest
>   (version 4)
> 
> $ guix package --list-generations -p /tmp/old
> Generation 1	oct. 02 2022 18:53:10
>   hello	2.10	out	/gnu/store/xg67cpxq2p6q7wn4y2z194pndwdymhpf-hello-2.10
> 
> Generation 2	oct. 02 2022 21:25:11	(current)
>  + 
> hello	2.12.1	out	/gnu/store/s5pd3rnzymliafb4la5sca63j86xs0y0-hello-2.12.1
>  - hello	2.10  
> 	out	/gnu/store/xg67cpxq2p6q7wn4y2z194pndwdymhpf-hello-2.10
> --8<---------------cut here---------------end--------------->8---
> 
> This profile /tmp/old is thus converted from version 3 to version 4, 
> and
> then, reusing old version of Guix fails,
> 
> --8<---------------cut here---------------start------------->8---
> $ guix time-machine --commit=7e8e070 -- package -i hello -p /tmp/old
> guix package: error: unsupported manifest format
> --8<---------------cut here---------------end--------------->8---
> 
> 
> Well, I do not know if a fix is possible.  The issue is a
> backward compatibility issue.
> 

Hi,
Thanks for the clarification.

I imagine it would be possible to give it a dirty fix, approximately as 
you just showed with /tmp/old, if you also just readd the default 
profile's currently installed packages to it at the end. So, if using 
~/.guix-profile, it would be something like:

1. Say your ~/.guix-profile is at commit=XYZ
2. build a NEW profile with the old package ONLY, from commit=ABC (as in 
/tmp/old)
3. guix pull /tmp/old "back" to commit=XYZ
4. install remaining packages that was in your ~/.guix-profile to 
/tmp/old.
5. mv the ~/.guix-profile symlink to /tmp/old.

( /tmp/old should just be in /var/guix/profiles/per-user/$USER as normal 
)

Building a new package generation like this would not be the same as 
usual, cuz the currently installed packages may come from different guix 
revisions. That might be a dealbreaker for fixing it. I do think it's 
very sad though, that the time-machine is kind of broken whenever the 
manifest gets a new version, with no hint even to the user how to find a 
solution.

Best regards,
David






      parent reply	other threads:[~2022-10-20 18:48 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-10-02 11:17 bug#58247: Using guix time-machine results in unsupported manifest format error david larsson
2022-10-02 17:02 ` zimoun
2022-10-02 18:57   ` david larsson
2022-10-02 22:10     ` zimoun
2022-10-19 10:51       ` zimoun
2022-12-04 17:01         ` Ludovic Courtès
2022-10-20 18:44       ` david larsson [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=e2594aa19c0c0bda6aec06406b9dd51e@selfhosted.xyz \
    --to=david.larsson@selfhosted.xyz \
    --cc=58247@debbugs.gnu.org \
    --cc=zimon.toutoune@gmail.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this external index

	https://git.savannah.gnu.org/cgit/guix.git

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.