From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mp1 ([2001:41d0:2:4a6f::]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) by ms0.migadu.com with LMTPS id cFqoMr2rW2Ad7QAAgWs5BA (envelope-from ) for ; Wed, 24 Mar 2021 22:14:37 +0100 Received: from aspmx1.migadu.com ([2001:41d0:2:4a6f::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by mp1 with LMTPS id GNQ/Lr2rW2DGcQAAbx9fmQ (envelope-from ) for ; Wed, 24 Mar 2021 21:14:37 +0000 Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by aspmx1.migadu.com (Postfix) with ESMTPS id 0D85C13AE3 for ; Wed, 24 Mar 2021 22:14:37 +0100 (CET) Received: from localhost ([::1]:50902 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1lPApo-0008MQ-7j for larch@yhetil.org; Wed, 24 Mar 2021 17:14:36 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:54500) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1lPApe-0008MI-5v for guix-devel@gnu.org; Wed, 24 Mar 2021 17:14:26 -0400 Received: from mail-wm1-x32f.google.com ([2a00:1450:4864:20::32f]:52847) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1lPApc-0006jD-Fc for guix-devel@gnu.org; Wed, 24 Mar 2021 17:14:25 -0400 Received: by mail-wm1-x32f.google.com with SMTP id d191so44744wmd.2 for ; Wed, 24 Mar 2021 14:14:23 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:subject:in-reply-to:references:date:message-id:mime-version :content-transfer-encoding; bh=bhz5cS1OS2qQwRCZedQCrRBsnt4EvrbOYHlPPvtLCtc=; b=mAnByGJlHh203H2+frQSIvI+0OdcXbguzkJ+esaH3s9zud3rHMnL52VpIiDWfvbFO8 qe1ueznFRZm+6+8Ad2rQu3mgUM6dAKIrdMasTH8tvZf0p7g/IqCuhI0qh2zyle/L3nyL CFJYmtScSSU8tRxJMx9LXbFeOszL1u+N1YqnkI+vEYSLLLamTI/9Q33C9GHfnFQRN7Io l5YRoPkvJ0QTCVTZbuaTCIhl/NvCdIMCQ0u0gmnQA9xSXkXTEVIgDcqJGAYA/r5MHdyx EnuCUAnUA0x72fQUze2qpfqZrkWIrdWbMfkxtXwsSopxaZWRDWMWmluJskyFtwlZI+HQ MXIw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:subject:in-reply-to:references:date :message-id:mime-version:content-transfer-encoding; bh=bhz5cS1OS2qQwRCZedQCrRBsnt4EvrbOYHlPPvtLCtc=; b=PEoTGfV5qmYs9J3xLo7tROMuuJ9F2agQ34I6wESzn8OQsivIGHWpsBoJVWkeEN/M97 45ZjIIvd5ZXC/9ITUknItchHoga1MaolmL+lx5gaJ2BNmMkMeSGYeo00TwpgvambCKLk imAjpckgUKdXWnaVT4BdZe51Rqk0ET5ZXySYqz72oXwZVAMrNWwopD22wUay/Sf6ojHU TVx7FKX4V0SCSOISQrQhyj5pvMhCgm+AnBEhb4n1Uc79xJoTYwATdPw1GZ3Q9HRE1y9k dBR1CnEFHCXPgObJuyOqvtAsVAvsb9jPmQg0dxSon3fMI8g3dLQggEbMbBb1jibvb6Q0 hEkQ== X-Gm-Message-State: AOAM5302HpWsdQFECS05+tTEbYoyVMK4opDI+C3e+ncoyqmD2GthQiiY Hz+VXLLyRltrXQWEQzYsMh450R2rGq0= X-Google-Smtp-Source: ABdhPJyR8d0+wdtuV9cysQjvA5qDLA9+IMgvG7yz7nhCcg5N7fSTwxB9+e0OBWNUPjkxhqvJvJdZIg== X-Received: by 2002:a1c:21c3:: with SMTP id h186mr4627622wmh.32.1616620462823; Wed, 24 Mar 2021 14:14:22 -0700 (PDT) Received: from lili ([2a01:e0a:59b:9120:65d2:2476:f637:db1e]) by smtp.gmail.com with ESMTPSA id l6sm4326545wrn.3.2021.03.24.14.14.22 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 24 Mar 2021 14:14:22 -0700 (PDT) From: zimoun To: c4t0 , Guix Devel Subject: Re: guix import hackage fails with errors, and failed tests In-Reply-To: <874kh07317.fsf@riseup.net> References: <87mtut7a6a.fsf@riseup.net> <874kh07317.fsf@riseup.net> Date: Wed, 24 Mar 2021 22:12:38 +0100 Message-ID: <86o8f8b6ih.fsf@gmail.com> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable Received-SPF: pass client-ip=2a00:1450:4864:20::32f; envelope-from=zimon.toutoune@gmail.com; helo=mail-wm1-x32f.google.com X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, FREEMAIL_FROM=0.001, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: guix-devel@gnu.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "Development of GNU Guix and the GNU System distribution." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: guix-devel-bounces+larch=yhetil.org@gnu.org Sender: "Guix-devel" X-Migadu-Flow: FLOW_IN ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=yhetil.org; s=key1; t=1616620477; h=from:from:sender:sender:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:mime-version:mime-version: content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references:list-id:list-help: list-unsubscribe:list-subscribe:list-post:dkim-signature; bh=bhz5cS1OS2qQwRCZedQCrRBsnt4EvrbOYHlPPvtLCtc=; b=kZZ6X6SpxmdprmHHTrXqpaxJdrKShflfBSddp6sPGay3TcYH4DNEEDUjUHeV1KbPtP3NO2 6Y4fwdXIL9lmrXju7yMffDFWUrky2y0Hfacx7Ul30EjQ/sdNnBFfYrBP9viiSMDbStUf71 AV5JihyH4aWRo+lDehDcV2kSSTfzvuvaTAkeEZy7k7J7ECeE63fNAydzx6z9PosPjqU5T2 rdcv0kZCFuf402ZlZwk0y2HGsLOUOYmFw6COkX4sGa8nlCVCqcF5/eSpV/Fo124iLLMhic AFefHe+gNa02bN3SbhByIjm+jcBfXj7NhKKcGWGE+ZUT0MSYNWD7KA+d749wqQ== ARC-Seal: i=1; s=key1; d=yhetil.org; t=1616620477; a=rsa-sha256; cv=none; b=lg1cPi0gWBNE+ExMuOjEy4XpxPsca5HubUSRgGJtGyH2FGO3IX3nWPYo6PAzoxFsDDYJEY 3qd8YYwX/SxhDfGq4VlDk8ewNN3pOf51N7KzuGfncK/IangVfk+AjTpk0Nb9HWIhb0aTkU NGy+uLGXaaVz4Rpry/URjAJOQRU+sRzCgOVXbA3mmFJJGODdaBYo1ww3MqwQLVksEMZu6M P3hp6aKhxjHME/LSaqepL4M7fhnFKWuVeXDTpF36X3nUeB9GvVAk6BSXR/Z3G5O7ESs4qk O0O6zVwobvwFoIV7emQgryEPefpUvuc5zTAJPXw4Ze8jdyLuirqaUDPF0aW2Iw== ARC-Authentication-Results: i=1; aspmx1.migadu.com; dkim=pass header.d=gmail.com header.s=20161025 header.b=mAnByGJl; dmarc=pass (policy=none) header.from=gmail.com; spf=pass (aspmx1.migadu.com: domain of guix-devel-bounces@gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=guix-devel-bounces@gnu.org X-Migadu-Spam-Score: -3.67 Authentication-Results: aspmx1.migadu.com; dkim=pass header.d=gmail.com header.s=20161025 header.b=mAnByGJl; dmarc=pass (policy=none) header.from=gmail.com; spf=pass (aspmx1.migadu.com: domain of guix-devel-bounces@gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=guix-devel-bounces@gnu.org X-Migadu-Queue-Id: 0D85C13AE3 X-Spam-Score: -3.67 X-Migadu-Scanner: scn0.migadu.com X-TUID: sczsEkb1jBlC Hi, On Wed, 24 Mar 2021 at 16:41, c4t0 wrote: > zimoun writes: > yes! I don't know if is really related with > https://debbugs.gnu.org/cgi/bugreport.cgi?bug=3D35743 and is a layout > problem or it doesn't know how to parse 'common'. I have not read carefully the bug report you mention, neither the parser. I guess the parser does not know how to parse =E2=80=99common=E2= =80=99. > running > $cabal format package.cabal You can do that that locally. Well, currently all the importers via =E2=80=9Cguix import=E2=80=9D should be considered as helpers to =E2=80=99i= mport=E2=80=99, not as bullet-proof =E2=80=99converters=E2=80=99. > I think it might be a good idea to run 'cabal format package.cabal' some > how, before parsing. That will give us a consistent format that might > address the #35743 bug also, and remove formatting variance that a > package mantainer may introduce to make things more legible to him. The =C2=ABsomehow=C2=BB cannot be using Guix. Otherwise, it means that Gui= x would depend partly on Haskell ecosystem. That=E2=80=99s why there is a Cabal pa= rser written with Guile. Somehow. :-) > Also is easiest than propagate a set of default options to other > targets, but I think the best argument is the former. > > maybe modify cabal.scm::read-cabal to make a temporary file with the > input port, run 'cabal format tmp-file' and then change the port to use > that temp file? The issue with this is that Guix would somehow depend on Haskell. And it would not happen: GHC is not bootstrappable, is huge, etc. > If it's ok, I'll give it a try, for now touching the parser it's a > little out of my reach. Well, if your aim is to produce the Guix definition of ghc-dec, you can try to run your trick locally. As said, =E2=80=9Cguix import=E2=80=9D are = importers and not converters, which means it helps to produce a Guix package definition from a package definition i.e., it is not a bullet-proof converting all the cases; cases probably without a clean grammar. In other words, to resolve the issue you are pointing, the fix is to improve the Guix parser of cabal, IMHO. I hope that this does not prevent you to contribute by adding ghc-events. :-) Cheers, simon