From unknown Wed Jun 18 00:28:21 2025 Content-Disposition: inline Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 X-Mailer: MIME-tools 5.509 (Entity 5.509) Content-Type: text/plain; charset=utf-8 From: bug#35594 <35594@debbugs.gnu.org> To: bug#35594 <35594@debbugs.gnu.org> Subject: Status: GNOME: Application icons are not displayed immediately after installation Reply-To: bug#35594 <35594@debbugs.gnu.org> Date: Wed, 18 Jun 2025 07:28:21 +0000 retitle 35594 GNOME: Application icons are not displayed immediately after = installation reassign 35594 guix submitter 35594 sirgazil severity 35594 important thanks From debbugs-submit-bounces@debbugs.gnu.org Sun May 05 19:19:49 2019 Received: (at submit) by debbugs.gnu.org; 5 May 2019 23:19:49 +0000 Received: from localhost ([127.0.0.1]:55196 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1hNQQ8-0001Hh-Js for submit@debbugs.gnu.org; Sun, 05 May 2019 19:19:48 -0400 Received: from eggs.gnu.org ([209.51.188.92]:34057) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1hNQQ5-0001HR-Bi for submit@debbugs.gnu.org; Sun, 05 May 2019 19:19:47 -0400 Received: from lists.gnu.org ([209.51.188.17]:58441) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_256_CBC_SHA1:32) (Exim 4.71) (envelope-from ) id 1hNQQ0-0007mB-8p for submit@debbugs.gnu.org; Sun, 05 May 2019 19:19:40 -0400 Received: from eggs.gnu.org ([209.51.188.92]:48434) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1hNQPz-00066q-5o for bug-guix@gnu.org; Sun, 05 May 2019 19:19:40 -0400 X-Spam-Checker-Version: SpamAssassin 3.3.2 (2011-06-06) on eggs.gnu.org X-Spam-Level: X-Spam-Status: No, score=0.8 required=5.0 tests=BAYES_50,FREEMAIL_FROM, RCVD_IN_DNSWL_NONE,URIBL_BLOCKED autolearn=disabled version=3.3.2 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1hNQPy-0007kz-7D for bug-guix@gnu.org; Sun, 05 May 2019 19:19:39 -0400 Received: from sender4-pp-o95.zoho.com ([136.143.188.95]:25558) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_256_CBC_SHA1:32) (Exim 4.71) (envelope-from ) id 1hNQPx-0007kU-Ts for bug-guix@gnu.org; Sun, 05 May 2019 19:19:38 -0400 ARC-Seal: i=1; a=rsa-sha256; t=1557098356; cv=none; d=zoho.com; s=zohoarc; b=htYjj/dzfNpjASq/NE5ZGbwwclmJNMu3a71j2P/i+cn21A5NIBHTCdWwPR+d8kLT5S09zd4gZqa0rYD4KHbLRWM8O0ws1PN7PfhnU1RW72YA0DZnuOU2/G3LwsM3kdup9GpF3FfxMMzQyP/QAZWe4DPPAD16kfM/lBW8aS13z6s= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zoho.com; s=zohoarc; t=1557098356; h=Content-Type:Content-Transfer-Encoding:Date:From:MIME-Version:Message-ID:Subject:To:ARC-Authentication-Results; bh=+v+vg/YjfIixn2Cb0+sDOM07ajGIMQZA5qK3NXthy38=; b=G1ZeCAFXsDpky+xCJTI+hItpyc1zk5cE8u57upCsnWIoEhLnINDgiTmRShGyOMVsnpsfs1nyGSyxk958V1wjR3yF1Sh+IHFJlT1x1u1EZoDSH5Uk2Vqqys75Pm4gfFr45tzUl3REQS/UTdx1oiWMMIIjXtLnJC6BFG5CdLUcdxY= ARC-Authentication-Results: i=1; mx.zoho.com; dkim=pass header.i=zoho.com; spf=pass smtp.mailfrom=sirgazil@zoho.com; dmarc=pass header.from= header.from= DomainKey-Signature: a=rsa-sha1; q=dns; c=nofws; s=zapps768; d=zoho.com; h=date:from:to:message-id:in-reply-to:subject:mime-version:content-type:user-agent; b=e6GbASvEdss2pie2Zu4FwA7RI/VfJlnLtXxNu0knvzLfzN2ArW8OlThpUhZU2Ls7hxmqlQj0jwaf JcSDn4jUI5NcdTBVxZmq8EwKJ696IzNnJ3k06aoP5z7ocRwBegDl DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; t=1557098356; s=default; d=zoho.com; i=sirgazil@zoho.com; h=Date:From:To:Message-ID:In-Reply-To:Subject:MIME-Version:Content-Type:Content-Transfer-Encoding; l=757; bh=+v+vg/YjfIixn2Cb0+sDOM07ajGIMQZA5qK3NXthy38=; b=cMZd5sFl88Du0V2YHHWWI52DZs8p2/gTzkILsrmjdIq2/rkcbgksj2ooHFwuLFDU xD5hkWHGVjK7VD6hoVt/aH86IUoJhqIlYxLFznok27VxVmkde144X7KP5naRQ3OtxZq knOUysN3HTtYRHCDrofQ718dt19HvlICdpkBMcdQ= Received: from mail.zoho.com by mx.zohomail.com with SMTP id 1557098351625534.8276645117022; Sun, 5 May 2019 16:19:11 -0700 (PDT) Received: from [181.130.25.222] by mail.zoho.com with HTTP;Sun, 5 May 2019 16:19:11 -0700 (PDT) Date: Sun, 05 May 2019 18:19:11 -0500 From: sirgazil To: "bug-guix" Message-ID: <16a8a4b4c07.ad1f7a9a40480.985002149086753257@zoho.com> In-Reply-To: Subject: GNOME: Application icons are not displayed immediately after installation MIME-Version: 1.0 Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: 7bit X-Priority: Medium User-Agent: Zoho Mail X-Mailer: Zoho Mail X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-Received-From: 136.143.188.95 X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6.x X-Spam-Score: -1.4 (-) X-Debbugs-Envelope-To: submit X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -2.4 (--) Hi, I installed the GNU system in a real machine using Guix 1.0 ISO installer (https://ftp.gnu.org/gnu/guix/guix-system-install-1.0.0.x86_64-linux.iso.xz). Whenever I install a desktop application, the application icon does not show up immediately in the list of available applications. I have to log out and log in again to be able to see it. ## Steps to reproduce 1. Install a desktop application (I tried GIMP, Scribus, Inkscape, Audacity) 2. Click on "Activities". 3. Click on "Show Applications" (the button with nine dots). ## Unexpected result The icon of the installed application is not in the list. ## Expected result. The icon of the installed application is in the list. --- https://sirgazil.bitbucket.io/ From debbugs-submit-bounces@debbugs.gnu.org Sun May 05 22:23:56 2019 Received: (at 35594) by debbugs.gnu.org; 6 May 2019 02:23:56 +0000 Received: from localhost ([127.0.0.1]:55365 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1hNTIK-0003v5-8O for submit@debbugs.gnu.org; Sun, 05 May 2019 22:23:56 -0400 Received: from world.peace.net ([64.112.178.59]:34150) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1hNTII-0003ut-HM for 35594@debbugs.gnu.org; Sun, 05 May 2019 22:23:54 -0400 Received: from mhw by world.peace.net with esmtpsa (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.89) (envelope-from ) id 1hNTIC-0005Gl-Rv; Sun, 05 May 2019 22:23:49 -0400 From: Mark H Weaver To: sirgazil Subject: Re: bug#35594: GNOME: Application icons are not displayed immediately after installation References: <16a8a4b4c07.ad1f7a9a40480.985002149086753257@zoho.com> Date: Sun, 05 May 2019 22:21:59 -0400 In-Reply-To: <16a8a4b4c07.ad1f7a9a40480.985002149086753257@zoho.com> (sirgazil@zoho.com's message of "Sun, 05 May 2019 18:19:11 -0500") Message-ID: <87pnowqq3h.fsf@netris.org> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/26.2 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain X-Spam-Score: 0.0 (/) X-Debbugs-Envelope-To: 35594 Cc: 35594@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.0 (-) Hi, sirgazil writes: > I installed the GNU system in a real machine using Guix 1.0 ISO > installer > (https://ftp.gnu.org/gnu/guix/guix-system-install-1.0.0.x86_64-linux.iso.xz). > > Whenever I install a desktop application, the application icon does > not show up immediately in the list of available applications. I have > to log out and log in again to be able to see it. Indeed, this has always been the case on Guix, and I agree it would be good to fix it. FWIW, another way to refresh the list of available applications from GNOME Shell is to type: Alt-F2, and then enter the single letter "r" as the command. That should restart GNOME Shell without affecting your other applications. (Unfortunately for me, this only works under Xorg, not Wayland.) A related issue is that if you upgrade a program in Guix, and then launch it using GNOME Shell, it will launch the old one. That's because our installed desktop files are specifically rewritten to launch the program via an absolute path name /gnu/store/xxxxx/bin/* instead of simply looking in PATH, and GNOME Shell continues to use the old desktop files until it's restarted. This was implemented back in 2016, here: https://git.savannah.gnu.org/cgit/guix.git/commit/?id=d31860b9de07810e114490db5cc160a8b078c58d I remember thinking it was a bad idea at the time, but I didn't have enough energy to speak up about it. Mark From debbugs-submit-bounces@debbugs.gnu.org Mon May 06 07:35:09 2019 Received: (at 35594) by debbugs.gnu.org; 6 May 2019 11:35:09 +0000 Received: from localhost ([127.0.0.1]:55810 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1hNbtl-0003Ry-3B for submit@debbugs.gnu.org; Mon, 06 May 2019 07:35:09 -0400 Received: from sender-pp-092.zoho.com ([135.84.80.237]:25482) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1hNbti-0003Rf-MY for 35594@debbugs.gnu.org; Mon, 06 May 2019 07:35:07 -0400 ARC-Seal: i=1; a=rsa-sha256; t=1557142486; cv=none; d=zoho.com; s=zohoarc; b=ZTA4VAMLJYIlyDhwFU2hRCPch9hHrNeKWRZqCOGi9HShqYjlgPn55yea0Foyo/z5UyVeAiZpQtmFXseBAi5rw9p1gf1iexEok5xFXxlFDiIMpdDDDFTyZTiyH4ZOgkA/TVPfXXMCgshi46zo8xeA8uVFLu7ZzFtGTk2aB4VItMw= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zoho.com; s=zohoarc; t=1557142486; h=Content-Type:Content-Transfer-Encoding:Cc:Date:From:In-Reply-To:MIME-Version:Message-ID:References:Subject:To:ARC-Authentication-Results; bh=D8YZMRZ1Rkijw2PyRyurcp/W+4dgSZoUM2RiggVcwFU=; b=UN+IKUMfFohiYF5g55Z97RRh9s/zseT8KnMeAhUrlD0KYZCL1M0tE6mvAwKsX9Hm8zH+CmALr2mP3wSfdDHpQuA67JmM5SnkyEhw30lASpg0W5QFZj3PqlKf6a8JHqHIA6ZNxt7Dhljae1rUw17MHB2JP2VhMFQ/kMot1cC1wmM= ARC-Authentication-Results: i=1; mx.zoho.com; dkim=pass header.i=zoho.com; spf=pass smtp.mailfrom=sirgazil@zoho.com; dmarc=pass header.from= header.from= DomainKey-Signature: a=rsa-sha1; q=dns; c=nofws; s=zapps768; d=zoho.com; h=date:from:to:cc:message-id:in-reply-to:references:subject:mime-version:content-type:user-agent; b=CcPvDknptYVY6mjJ9s+YqVNH3AtZgt3luwlTWww7YMXW+r/vqkx3eTV7qfYi5sL2cSdzAieu3yJn yABrZfe4ohL7izjD+uwmqPblkTN7xaZWoyaSg/eMXlfpwUMGch0L DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; t=1557142486; s=default; d=zoho.com; i=sirgazil@zoho.com; h=Date:From:To:Cc:Message-ID:In-Reply-To:References:Subject:MIME-Version:Content-Type:Content-Transfer-Encoding; l=1647; bh=D8YZMRZ1Rkijw2PyRyurcp/W+4dgSZoUM2RiggVcwFU=; b=fLwMOSDdkzzzosxtnGNN7sl2IYwzad8wAOyd2991muLfqY13IFhRRrHc4exJqJkx +XPzqSA9FdNDpwTPOdqcvrFVGSisa+fDir3evX7g5akCKkcPNsYF9P1d48nAJsmEFBI FX4CFPJrIhOVZFePJirildUeqDKbmUR4VWz8hNTA= Received: from mail.zoho.com by mx.zohomail.com with SMTP id 1557142480078890.2440313889506; Mon, 6 May 2019 04:34:40 -0700 (PDT) Received: from [181.130.25.222] by mail.zoho.com with HTTP;Mon, 6 May 2019 04:34:40 -0700 (PDT) Date: Mon, 06 May 2019 06:34:40 -0500 From: sirgazil To: "Mark H Weaver" Message-ID: <16a8ceca4cb.feaa0c4945447.2719212968817627071@zoho.com> In-Reply-To: <87pnowqq3h.fsf@netris.org> References: <16a8a4b4c07.ad1f7a9a40480.985002149086753257@zoho.com> <87pnowqq3h.fsf@netris.org> Subject: Re: bug#35594: GNOME: Application icons are not displayed immediately after installation MIME-Version: 1.0 Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: 7bit X-Priority: Medium User-Agent: Zoho Mail X-Mailer: Zoho Mail X-Spam-Score: 0.0 (/) X-Debbugs-Envelope-To: 35594 Cc: 35594 <35594@debbugs.gnu.org> X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.0 (-) ---- On Sun, 05 May 2019 21:21:59 -0500 Mark H Weaver wrote ---- > Hi, > > sirgazil writes: > > > I installed the GNU system in a real machine using Guix 1.0 ISO > > installer > > (https://ftp.gnu.org/gnu/guix/guix-system-install-1.0.0.x86_64-linux.iso.xz). > > > > Whenever I install a desktop application, the application icon does > > not show up immediately in the list of available applications. I have > > to log out and log in again to be able to see it. > > Indeed, this has always been the case on Guix, and I agree it would be > good to fix it. FWIW, another way to refresh the list of available > applications from GNOME Shell is to type: Alt-F2, and then enter the > single letter "r" as the command. That should restart GNOME Shell > without affecting your other applications. (Unfortunately for me, this > only works under Xorg, not Wayland.) > > A related issue is that if you upgrade a program in Guix, and then > launch it using GNOME Shell, it will launch the old one. That's because > our installed desktop files are specifically rewritten to launch the > program via an absolute path name /gnu/store/xxxxx/bin/* instead of > simply looking in PATH, and GNOME Shell continues to use the old desktop > files until it's restarted. This was implemented back in 2016, here: > > https://git.savannah.gnu.org/cgit/guix.git/commit/?id=d31860b9de07810e114490db5cc160a8b078c58d > > I remember thinking it was a bad idea at the time, but I didn't have > enough energy to speak up about it. I see... Thanks for the information, Mark. From debbugs-submit-bounces@debbugs.gnu.org Tue Nov 03 12:45:08 2020 Received: (at 35594) by debbugs.gnu.org; 3 Nov 2020 17:45:08 +0000 Received: from localhost ([127.0.0.1]:46340 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1ka0Mm-00077r-3w for submit@debbugs.gnu.org; Tue, 03 Nov 2020 12:45:08 -0500 Received: from mail-qk1-f176.google.com ([209.85.222.176]:34766) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1ka0Mk-000772-0h for 35594@debbugs.gnu.org; Tue, 03 Nov 2020 12:45:07 -0500 Received: by mail-qk1-f176.google.com with SMTP id x20so15557427qkn.1 for <35594@debbugs.gnu.org>; Tue, 03 Nov 2020 09:45:05 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:cc:subject:references:date:in-reply-to:message-id :user-agent:mime-version; bh=PSoD9YM847poRF/XNZf2+w+w5nNdRIG+R/v/uD0N2Ss=; b=HOnBkB+q8K9Zm38x2KUO3wCTQTdmKP1z9QMHrR3ui5qIhm55bVacby6iyExtkfYsUM 9Bn2P+RnGtlBZifnIHMzktUiW6d4qbDLr8Npk9V4/mPYbhGZHYZJqKTKvJB+gYvS22aO h/Z1nFVMmuXn7TP0Vcv7qtUEYTn/ruVfc0SJatK2IAjkjpjODEd6C1G3ggVPr/deUuLc 5oH/Z30L5xZfalRryHX0EUZUBzq3ZzYLr7JEtd9Ie6m42xXruArnKpTDh58CPWhlDgIq GE+HQdJiQZ0gOn7Rv78t1e8OhDwi9Kw7tFJP2t7Ds+KtZ1oSJpTU52H7i/0q+Z0JYO0R pOpQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:references:date:in-reply-to :message-id:user-agent:mime-version; bh=PSoD9YM847poRF/XNZf2+w+w5nNdRIG+R/v/uD0N2Ss=; b=Wg62Oh+ee8zBi6mj6WQd2ldd2UCuyfUNd6GeVlhcFx2HGBQr9tCAs7TUrhCcqPAHcZ YVItqfztVGWeo9BqHGlO2/ysyFSQAmY7KzXKjZBU5NNFJjh6tDeEsAz65sR2RNg6Air4 umqB1wOHWuMoYprE1trjdfw+Sv7wAytQnwVulsr/QI49i8OQwiMs1FN7fntS3YbgZy8K YOzZMANYYC0bUToisqCVjU5V12w8e8e4jjQRGgZDFJbsN7oo2f4e6bm1mxgGaXbk8ulT i1vCsXcB3vEuwIJiStrlwtnmpVXR+K02KElLZTBi4ScumbObbKFul5ahLiUNQJIvf+PH pj9g== X-Gm-Message-State: AOAM530pSD+4X9ATrmrEb0uGFQvFNLVWvxyU60OlApqfqPX2vfYRFIRn pNd5g9FyqApiE1/J+BESwn7waOEI1gk= X-Google-Smtp-Source: ABdhPJwxxrXGseaocqHAn1UapDQ7QYj+1TluOFwhr2l1R3UOmE9mVA5J3ikD+n9JOOTtsQ7+u7CjxQ== X-Received: by 2002:a05:620a:112a:: with SMTP id p10mr21120216qkk.446.1604425500472; Tue, 03 Nov 2020 09:45:00 -0800 (PST) Received: from hurd (dsl-236-123-206.b2b2c.ca. [207.236.123.206]) by smtp.gmail.com with ESMTPSA id d133sm9523175qke.106.2020.11.03.09.44.59 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 03 Nov 2020 09:44:59 -0800 (PST) From: Maxim Cournoyer To: sirgazil Subject: Re: bug#35594: GNOME: Application icons are not displayed immediately after installation References: <16a8a4b4c07.ad1f7a9a40480.985002149086753257@zoho.com> Date: Tue, 03 Nov 2020 12:44:58 -0500 In-Reply-To: <16a8a4b4c07.ad1f7a9a40480.985002149086753257@zoho.com> (sirgazil@zoho.com's message of "Sun, 05 May 2019 18:19:11 -0500") Message-ID: <87eelaz65h.fsf@gmail.com> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/27.1 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain X-Spam-Score: 0.0 (/) X-Debbugs-Envelope-To: 35594 Cc: ludo@gnu.org, 35594@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.0 (-) Hello, sirgazil writes: > Hi, > > I installed the GNU system in a real machine using Guix 1.0 ISO > installer > (https://ftp.gnu.org/gnu/guix/guix-system-install-1.0.0.x86_64-linux.iso.xz). > > Whenever I install a desktop application, the application icon does > not show up immediately in the list of available applications. I have > to log out and log in again to be able to see it. > > > ## Steps to reproduce > > 1. Install a desktop application (I tried GIMP, Scribus, Inkscape, Audacity) > 2. Click on "Activities". > 3. Click on "Show Applications" (the button with nine dots). > > > ## Unexpected result > > The icon of the installed application is not in the list. > > > ## Expected result. > > The icon of the installed application is in the list. After asking in the #gnome channel on freenode, the problem is likely caused by GNOME Shell using inotify to watch the $XDG_DATA_DIRS referenced $HOME/.guix-profile/share/applications directory. The problem is that the inode of such directory will never change, as it points to the current profile under /gnu/store: --8<---------------cut here---------------start------------->8--- $ ls -id $HOME/.guix-profile/share/applications 72653730 /home/maxim/.guix-profile/share/applications/ maxim@hurd ~/src/guix$ realpath $HOME/.guix-profile/share/applications /gnu/store/ph6a7fy735w5nycmf3za77m6v3g0r7xb-profile/share/applications maxim@hurd ~/src/guix$ ls -id /gnu/store/ph6a7fy735w5nycmf3za77m6v3g0r7xb-profile/share/applications 72653730 /gnu/store/ph6a7fy735w5nycmf3za77m6v3g0r7xb-profile/share/applications/ --8<---------------cut here---------------end--------------->8--- Any applications making use of inotify to discover changes (to plugins, for example) is at risk of having the same problem in Guix. I don't currently have an idea of how we can fix this. Maxim From debbugs-submit-bounces@debbugs.gnu.org Tue Nov 03 14:14:19 2020 Received: (at 35594) by debbugs.gnu.org; 3 Nov 2020 19:14:19 +0000 Received: from localhost ([127.0.0.1]:46457 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1ka1l5-0000y7-3x for submit@debbugs.gnu.org; Tue, 03 Nov 2020 14:14:19 -0500 Received: from mail-qk1-f169.google.com ([209.85.222.169]:36445) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1ka1l2-0000xt-BC for 35594@debbugs.gnu.org; Tue, 03 Nov 2020 14:14:18 -0500 Received: by mail-qk1-f169.google.com with SMTP id r7so16051446qkf.3 for <35594@debbugs.gnu.org>; Tue, 03 Nov 2020 11:14:16 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:cc:subject:references:date:in-reply-to:message-id :user-agent:mime-version; bh=6VpOM7PH1jnatVX2gU3oZHtD1IyZzkfpeeQn2jkBNGo=; b=kcqu4Mc5KB6D16pYi4Eo8cEK3c1r9zVsw/1Q45jkJsRK48ME8Bepx7S0q4C0+b+CAx shmBxnU6/rDJvJHCrVmg6v0DEKu/Wuo4vw2T40k600Q4rYh3vF/BpYwUxB2KYP65kMqM X6vfPnDh2sq56o5G6YOPe5fwWA9ckYgDrGO08zC2Cmug8Jmy06RyP+LnAsEwkoaNF9GN iA3O1UN5VieE7osTE2yHG3yC36FLuV/I3U6PPvLHZq41EtDNbi7diS1/PvM/+wDrAf2v +QLSH8DYueckAX/HJLZNtKkzMxXDT+13oaSt8qmC6l5PDOeh4BPPrLpYcyIr41P57HmD cS5w== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:references:date:in-reply-to :message-id:user-agent:mime-version; bh=6VpOM7PH1jnatVX2gU3oZHtD1IyZzkfpeeQn2jkBNGo=; b=D1QoOxzbl/xJhiVBQli3XeNi5IIFEsvPGzIC40H6zokm5g1LRWDNSby5duAsbcG6ov ccwGL7EiJOy8V82IM6J5cLpuTX9WKl3Y/cSD6xHWNBOIqfagEAt38Izg4NnNFnwMynkH Zx2vAWoYiQhscYB6fo/S1ey39iJSCgqI2w00yKsFY2s5JAJyTWrkrTsyW+F0qQ8d4h0d q7qSTe6ZPNabYNHrqAuc+W2gSWu5i0NM9UbygaoRssq85oP/FXY7adRG90QvmaiZa+Pk zIGeUBsaXu2BoDCcncCbcLnzo9vi/YiEy0NjbM9DukfasEvk7YfhKikgBrxu3JVm4vgM Lkhg== X-Gm-Message-State: AOAM53282HD3p9OaLgw5nbFbqeELcMi/7cZ77KtA1opLaO0rY04rAUHL gFLpImf7nMmHHqHxUwV30+D/I2i11Mk= X-Google-Smtp-Source: ABdhPJxRC1PtcV2BEIfYKPaq0P5wG16HjVIuzidfnHNh0QJXVgSKWXTCcjxileL1Ic1t6+ph9SmO3Q== X-Received: by 2002:a37:6610:: with SMTP id a16mr16433146qkc.118.1604430850617; Tue, 03 Nov 2020 11:14:10 -0800 (PST) Received: from hurd (dsl-236-123-206.b2b2c.ca. [207.236.123.206]) by smtp.gmail.com with ESMTPSA id x75sm11551055qka.59.2020.11.03.11.14.09 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 03 Nov 2020 11:14:09 -0800 (PST) From: Maxim Cournoyer To: sirgazil Subject: Re: bug#35594: GNOME: Application icons are not displayed immediately after installation References: <16a8a4b4c07.ad1f7a9a40480.985002149086753257@zoho.com> <87eelaz65h.fsf@gmail.com> Date: Tue, 03 Nov 2020 14:14:09 -0500 In-Reply-To: <87eelaz65h.fsf@gmail.com> (Maxim Cournoyer's message of "Tue, 03 Nov 2020 12:44:58 -0500") Message-ID: <87a6vyz20u.fsf@gmail.com> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/27.1 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain X-Spam-Score: 0.0 (/) X-Debbugs-Envelope-To: 35594 Cc: ludo@gnu.org, 35594@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.0 (-) Hello, Maxim Cournoyer writes: > After asking in the #gnome channel on freenode, the problem is likely > caused by GNOME Shell using inotify to watch the $XDG_DATA_DIRS > referenced $HOME/.guix-profile/share/applications directory. The > problem is that the inode of such directory will never change, as it > points to the current profile under /gnu/store: > > $ ls -id $HOME/.guix-profile/share/applications > 72653730 /home/maxim/.guix-profile/share/applications/ > maxim@hurd ~/src/guix$ realpath $HOME/.guix-profile/share/applications > /gnu/store/ph6a7fy735w5nycmf3za77m6v3g0r7xb-profile/share/applications > maxim@hurd ~/src/guix$ ls -id /gnu/store/ph6a7fy735w5nycmf3za77m6v3g0r7xb-profile/share/applications > 72653730 /gnu/store/ph6a7fy735w5nycmf3za77m6v3g0r7xb-profile/share/applications/ > > Any applications making use of inotify to discover changes (to plugins, > for example) is at risk of having the same problem in Guix. > > I don't currently have an idea of how we can fix this. Watching of the directory is done via Glib's GAppInfoMonitor (gpio/gdesktopappinfo.c). A suggested idea from #gnome-shell would be to patch its desktop_file_dir_init() procedure with Guix-specifics; I don't know *how* yet. The folks in #gtk may provide some clues. Maxim From debbugs-submit-bounces@debbugs.gnu.org Tue Nov 03 17:33:26 2020 Received: (at 35594) by debbugs.gnu.org; 3 Nov 2020 22:33:26 +0000 Received: from localhost ([127.0.0.1]:46712 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1ka4rm-0001md-En for submit@debbugs.gnu.org; Tue, 03 Nov 2020 17:33:26 -0500 Received: from mail-qv1-f67.google.com ([209.85.219.67]:40978) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1ka4rl-0001mQ-MP for 35594@debbugs.gnu.org; Tue, 03 Nov 2020 17:33:26 -0500 Received: by mail-qv1-f67.google.com with SMTP id t20so8800184qvv.8 for <35594@debbugs.gnu.org>; Tue, 03 Nov 2020 14:33:25 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:cc:subject:references:date:in-reply-to:message-id :user-agent:mime-version; bh=fLc3HbS0pcI0wtGAYODqF98nBLcPYyIhe95pN/8fYhg=; b=YM8yReWQMzGECedZuT1PJ4wFdtWjw4wklbwmGOBZdoSRctHR7wZUNpVFvZZXR02trF tyhKBmfkeERZ7OKy8rtgkUv3wsId9b0QGhiOoh4rQ4MvSukcfPTFpdGE3o0Otz47ybQX tldJZtfyts+uyGUr1Ymu40kzMemYOfrhgnYTRwWqaYr/ZoIyYZ+b4UDLcKDjREFNcU9o ZpIchkPvdK2kksYF7Kmxsl6Uzfd0/kX4RXiNiPFbUYK+xrXYh8b1jmEPbhGH05im4lBI 1owd1gWWlSQ+8xW7C5Wd84V7jy1VtHzLLraGuvicOLRsc/Zwv9ajAM90vuTnKiSzioQ5 gLpg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:references:date:in-reply-to :message-id:user-agent:mime-version; bh=fLc3HbS0pcI0wtGAYODqF98nBLcPYyIhe95pN/8fYhg=; b=AVzvnvVU+PjJgCFgODOE3dV6FGqDyJNioX9oa/Dq/h29cLSMQqvLD32Q8XCdUSWj6a 9h3SUgx7AAulav2W9GVrHib9/1gCyw8/tjQS7/7n8quKLj8adX7dd6yajvYtasemJHPs 3WmThsqZBhmYaBJdFAq06I9yDbXb0R2ziu/YmCZo8pecVKfDMkbaU38tF4RCxzmJACVV kh9JgGKXV2fuvG9oolwySsIszUKIpHBuSKlIeXo9G6FDcWufqz6wO42hVEgwZfc3RQNV 3fS1QwWcmAFPSDccY2F/CVQwlkZfLBmKYmQ7euDJ1PRJz+tATbAV+RHzQPy/tFyClOkc vqaw== X-Gm-Message-State: AOAM533eIYifqNpJaZqmhwWgT2KFkApljRpGh//gGpLZZQBR0MJh7SqN ZcKG988mHl6aFWF67BzoWK8q/TD19q4= X-Google-Smtp-Source: ABdhPJy17o2TFLv866J4TwbNOyI+Y9M5KUN/+5/1NtgkxdeuXB/GsHRFxIXoWZ61k1k/GlMTOIs86A== X-Received: by 2002:a0c:85e3:: with SMTP id o90mr27398818qva.46.1604442799896; Tue, 03 Nov 2020 14:33:19 -0800 (PST) Received: from hurd (dsl-236-123-206.b2b2c.ca. [207.236.123.206]) by smtp.gmail.com with ESMTPSA id 19sm159955qkf.93.2020.11.03.14.33.18 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 03 Nov 2020 14:33:19 -0800 (PST) From: Maxim Cournoyer To: sirgazil Subject: Re: bug#35594: GNOME: Application icons are not displayed immediately after installation References: <16a8a4b4c07.ad1f7a9a40480.985002149086753257@zoho.com> <87eelaz65h.fsf@gmail.com> <87a6vyz20u.fsf@gmail.com> Date: Tue, 03 Nov 2020 17:33:18 -0500 In-Reply-To: <87a6vyz20u.fsf@gmail.com> (Maxim Cournoyer's message of "Tue, 03 Nov 2020 14:14:09 -0500") Message-ID: <875z6myssx.fsf@gmail.com> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/27.1 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain X-Spam-Score: 0.0 (/) X-Debbugs-Envelope-To: 35594 Cc: ludo@gnu.org, 35594@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.0 (-) Hi again, Maxim Cournoyer writes: > Hello, > > Maxim Cournoyer writes: > >> After asking in the #gnome channel on freenode, the problem is likely >> caused by GNOME Shell using inotify to watch the $XDG_DATA_DIRS >> referenced $HOME/.guix-profile/share/applications directory. The >> problem is that the inode of such directory will never change, as it >> points to the current profile under /gnu/store: >> >> $ ls -id $HOME/.guix-profile/share/applications >> 72653730 /home/maxim/.guix-profile/share/applications/ >> maxim@hurd ~/src/guix$ realpath $HOME/.guix-profile/share/applications >> /gnu/store/ph6a7fy735w5nycmf3za77m6v3g0r7xb-profile/share/applications >> maxim@hurd ~/src/guix$ ls -id /gnu/store/ph6a7fy735w5nycmf3za77m6v3g0r7xb-profile/share/applications >> 72653730 /gnu/store/ph6a7fy735w5nycmf3za77m6v3g0r7xb-profile/share/applications/ >> >> Any applications making use of inotify to discover changes (to plugins, >> for example) is at risk of having the same problem in Guix. >> >> I don't currently have an idea of how we can fix this. > > Watching of the directory is done via Glib's GAppInfoMonitor > (gpio/gdesktopappinfo.c). A suggested idea from #gnome-shell would be > to patch its desktop_file_dir_init() procedure with Guix-specifics; I > don't know *how* yet. The folks in #gtk may provide some clues. > > Maxim I've analyzed the situation a bit; I'll explain the big lines of what I think might be a solution. The idea would be to patch desktop_file_dir_init() as mentioned earlier with a procedure similar to desktop_file_dir_get_alternative_dir in that same gdesktopappinfo.c file. This new procedure would search for a parent symlink of the dir argument (dir being one of the entries constructed via XDG_DATA_DIRS, such as $HOME/.guix-profile/share/applications.). The algorithm for this new procedure would be like: 1. Check if a parent of DIR is a symlink. When there are none, return NULL. 2. Resolve the symlink parent until the last symlink, e.g. for symlink1 -> symlink2 -> directory, it saves symlink2. 3. Return the parent directory of the symlink resulting from 2 (i.e. dirname symlink2). In most cases (guix environment, build environment, extra user profiles), the entries in XDG_DATA_DIRS are not symlinks but directly store entries so there's nothing we can do about it. The case of interest here is the default user profile or $HOME/.guix-profile, which gets added to XDG_DATA_DIRS via /etc/profile (on Guix System). Because of the indirect links to the store, and the mutable /var/guix/profiles/per-user/$USER directory used to store the profile links, it is possible to have inotify work correctly. The algorithm described above would resolve $HOME/.guix-profile into /var/guix/profiles/per-user/$USER, and /run/current-system into /run. While adding a watch to /run is not optimal, it's not dramatic either given the watch is not recursive and only watch for specific actions: #define IP_INOTIFY_DIR_MASK (IN_MODIFY|IN_ATTRIB|IN_MOVED_FROM|IN_MOVED_TO|IN_DELETE|IN_CREATE|IN_DELETE_SELF|IN_UNMOUNT|IN_MOVE_SELF|IN_CLOSE_WRITE) (from gio/inotify/inotify-path.c) Thoughts? Thanks, Maxim From debbugs-submit-bounces@debbugs.gnu.org Wed Nov 04 11:55:07 2020 Received: (at 35594) by debbugs.gnu.org; 4 Nov 2020 16:55:07 +0000 Received: from localhost ([127.0.0.1]:50448 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1kaM3t-0007Yf-NE for submit@debbugs.gnu.org; Wed, 04 Nov 2020 11:55:06 -0500 Received: from eggs.gnu.org ([209.51.188.92]:54018) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1kaM3r-0007Y1-FV for 35594@debbugs.gnu.org; Wed, 04 Nov 2020 11:55:03 -0500 Received: from fencepost.gnu.org ([2001:470:142:3::e]:43265) by eggs.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1kaM3m-0003v3-40; Wed, 04 Nov 2020 11:54:58 -0500 Received: from [2a01:e0a:1d:7270:af76:b9b:ca24:c465] (port=56794 helo=ribbon) by fencepost.gnu.org with esmtpsa (TLS1.2:RSA_AES_256_CBC_SHA1:256) (Exim 4.82) (envelope-from ) id 1kaM3l-0001E7-Gt; Wed, 04 Nov 2020 11:54:57 -0500 From: =?utf-8?Q?Ludovic_Court=C3=A8s?= To: Maxim Cournoyer Subject: Re: bug#35594: GNOME: Application icons are not displayed immediately after installation References: <16a8a4b4c07.ad1f7a9a40480.985002149086753257@zoho.com> <87eelaz65h.fsf@gmail.com> <87a6vyz20u.fsf@gmail.com> <875z6myssx.fsf@gmail.com> X-URL: http://www.fdn.fr/~lcourtes/ X-Revolutionary-Date: 14 Brumaire an 229 de la =?utf-8?Q?R=C3=A9volution?= X-PGP-Key-ID: 0x090B11993D9AEBB5 X-PGP-Key: http://www.fdn.fr/~lcourtes/ludovic.asc X-PGP-Fingerprint: 3CE4 6455 8A84 FDC6 9DB4 0CFB 090B 1199 3D9A EBB5 X-OS: x86_64-pc-linux-gnu Date: Wed, 04 Nov 2020 17:54:56 +0100 In-Reply-To: <875z6myssx.fsf@gmail.com> (Maxim Cournoyer's message of "Tue, 03 Nov 2020 17:33:18 -0500") Message-ID: <875z6l83kv.fsf@gnu.org> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/27.1 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable X-Spam-Score: -2.3 (--) X-Debbugs-Envelope-To: 35594 Cc: sirgazil , 35594@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -3.3 (---) Hello! Maxim Cournoyer skribis: > The case of interest here is the default user profile or > $HOME/.guix-profile, which gets added to XDG_DATA_DIRS via /etc/profile > (on Guix System). Because of the indirect links to the store, and the > mutable /var/guix/profiles/per-user/$USER directory used to store the > profile links, it is possible to have inotify work correctly. The > algorithm described above would resolve $HOME/.guix-profile into > /var/guix/profiles/per-user/$USER, and /run/current-system into /run. > > While adding a watch to /run is not optimal, it's not dramatic either > given the watch is not recursive and only watch for specific actions: > > #define IP_INOTIFY_DIR_MASK > (IN_MODIFY|IN_ATTRIB|IN_MOVED_FROM|IN_MOVED_TO|IN_DELETE|IN_CREATE|IN_DE= LETE_SELF|IN_UNMOUNT|IN_MOVE_SELF|IN_CLOSE_WRITE) > > (from gio/inotify/inotify-path.c) I think our messages crossed. :-) I agree with your conclusions. I posted a preliminary patch following our discussion: https://issues.guix.gnu.org/36376#2 It=E2=80=99s only taking care of ~/.guix-profile, not /run, because I think that=E2=80=99s the most common case. (Usually you=E2=80=99d only add appli= cations to /run when reconfiguring, and then you may reboot shortly after in a laptop kind of setting. Also, one typically doesn=E2=80=99t *add* applicat= ions to /run.) Thoughts? Ludo=E2=80=99. From debbugs-submit-bounces@debbugs.gnu.org Wed Nov 04 15:54:55 2020 Received: (at control) by debbugs.gnu.org; 4 Nov 2020 20:54:55 +0000 Received: from localhost ([127.0.0.1]:50741 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1kaPnz-0007Bc-Jx for submit@debbugs.gnu.org; Wed, 04 Nov 2020 15:54:55 -0500 Received: from eggs.gnu.org ([209.51.188.92]:49364) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1kaPnw-0007BL-K0 for control@debbugs.gnu.org; Wed, 04 Nov 2020 15:54:54 -0500 Received: from fencepost.gnu.org ([2001:470:142:3::e]:47125) by eggs.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1kaPnr-0001hc-9P for control@debbugs.gnu.org; Wed, 04 Nov 2020 15:54:47 -0500 Received: from [2a01:e0a:1d:7270:af76:b9b:ca24:c465] (port=57522 helo=ribbon) by fencepost.gnu.org with esmtpsa (TLS1.2:RSA_AES_256_CBC_SHA1:256) (Exim 4.82) (envelope-from ) id 1kaPnq-0008QW-Px for control@debbugs.gnu.org; Wed, 04 Nov 2020 15:54:47 -0500 Date: Wed, 04 Nov 2020 21:54:44 +0100 Message-Id: <87mtzw7sh7.fsf@gnu.org> To: control@debbugs.gnu.org From: =?utf-8?Q?Ludovic_Court=C3=A8s?= Subject: control message for bug #35594 MIME-version: 1.0 Content-type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Spam-Score: -2.3 (--) X-Debbugs-Envelope-To: control X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -3.3 (---) severity 35594 important quit From debbugs-submit-bounces@debbugs.gnu.org Wed Nov 04 15:55:31 2020 Received: (at control) by debbugs.gnu.org; 4 Nov 2020 20:55:31 +0000 Received: from localhost ([127.0.0.1]:50745 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1kaPoY-0007DG-Uz for submit@debbugs.gnu.org; Wed, 04 Nov 2020 15:55:31 -0500 Received: from eggs.gnu.org ([209.51.188.92]:49392) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1kaPoX-0007D3-Vr for control@debbugs.gnu.org; Wed, 04 Nov 2020 15:55:30 -0500 Received: from fencepost.gnu.org ([2001:470:142:3::e]:47131) by eggs.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1kaPoS-0001jl-MC for control@debbugs.gnu.org; Wed, 04 Nov 2020 15:55:24 -0500 Received: from [2a01:e0a:1d:7270:af76:b9b:ca24:c465] (port=57530 helo=ribbon) by fencepost.gnu.org with esmtpsa (TLS1.2:RSA_AES_256_CBC_SHA1:256) (Exim 4.82) (envelope-from ) id 1kaPoS-000065-51 for control@debbugs.gnu.org; Wed, 04 Nov 2020 15:55:24 -0500 Date: Wed, 04 Nov 2020 21:55:22 +0100 Message-Id: <87lffg7sg5.fsf@gnu.org> To: control@debbugs.gnu.org From: =?utf-8?Q?Ludovic_Court=C3=A8s?= Subject: control message for bug #36376 MIME-version: 1.0 Content-type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Spam-Score: -2.3 (--) X-Debbugs-Envelope-To: control X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -3.3 (---) merge 36376 35594 quit From debbugs-submit-bounces@debbugs.gnu.org Wed Nov 04 16:42:07 2020 Received: (at 35594) by debbugs.gnu.org; 4 Nov 2020 21:42:07 +0000 Received: from localhost ([127.0.0.1]:50817 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1kaQXf-0004C8-6B for submit@debbugs.gnu.org; Wed, 04 Nov 2020 16:42:07 -0500 Received: from mail-qv1-f48.google.com ([209.85.219.48]:45716) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1kaQXd-0004Bc-ME; Wed, 04 Nov 2020 16:42:06 -0500 Received: by mail-qv1-f48.google.com with SMTP id w5so10651799qvn.12; Wed, 04 Nov 2020 13:42:05 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:cc:subject:references:date:in-reply-to:message-id :user-agent:mime-version:content-transfer-encoding; bh=IUVs2FcsLpDo0mRLUJPPqOH8SkCfGj6g8fu6WRpeUN4=; b=TMjW7Z6v2bUO2UgEVJVBQci6y0erKRZilp+o96jeVF7pZ1vt4+DrYrOHJoYM1QRpfP 54HLDQVdLMCF3KtUbE47AxZW2psW95i+g0Nw3xh0hkVPK97KDP2CLCdXi3scR1XjrInI Y3OhOZTvXA4rJrsdRq++2ffwcRA+RdvbY9gCIFBYrzrwWVk3ASCXEyupqoFbLp2CDVEo RwqnNO1oLOeQegIOMHy1Hcx4vuQxTbEdtz8ib+JqkBR/QUvVNosXk7Pc2wXwm0OSW4ng 04YuvEXW1zYVT4RVLnEHuZFs4M1AY5a9re/bKyt3hg1UaRlhviUVMzqovUo96GD0KjEg /zGA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:references:date:in-reply-to :message-id:user-agent:mime-version:content-transfer-encoding; bh=IUVs2FcsLpDo0mRLUJPPqOH8SkCfGj6g8fu6WRpeUN4=; b=i9dUbgl5B9x/WL8uiK/7UVDdHMDdp4W4na8f4u3jQdCpxQfGn6Lh8eHNk2jDwF/llf dKtf85XQ5rYIroYhZNNFjltPMTKCNYsbVk4jR9baJlPCMvAWjsCWJfrafcA9PL3ouvtT KyfblGMPM8GDPk7JfjrFFEyxpRbdYdI1Si4gAdU2Vl8vGQtYdyyTWC10M3xs3wO888PP jrQIvkaEfyevG85yxOroKUj4sVF0qKYj1/J8B5Oh4NZd+yNEkX+05GY5EJPDmfnbRKik CITLKx3WHXjiH/zWMGfcgRkNEZjAI4aQZbhvBTPNqegZKArFpxcQP2TzB+NroHXWRx+D e++A== X-Gm-Message-State: AOAM533rPpLMXR+ATU/3F06wk0sa9bZdVMzmGSKUcZyyVxI5UiiGxIds CJ7VVCt2IuQS6CXrdZDZ/XXVFyUYTd8= X-Google-Smtp-Source: ABdhPJxYwOTfpXfagHsnYqVEw6248ZNzmQ3Sfr1mr4QYPnKx4SonL1vuN377YvqDY5JbFalgQrMPCQ== X-Received: by 2002:a0c:edb1:: with SMTP id h17mr32651997qvr.7.1604526119830; Wed, 04 Nov 2020 13:41:59 -0800 (PST) Received: from hurd (dsl-154-213.b2b2c.ca. [66.158.154.213]) by smtp.gmail.com with ESMTPSA id z2sm652021qkg.76.2020.11.04.13.41.58 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 04 Nov 2020 13:41:59 -0800 (PST) From: Maxim Cournoyer To: Leo Prikler Subject: Re: bug#36376: Application menu of desktop environment not automatically updated References: <871rzhn483.fsf@gnu.org> <87o8keawju.fsf@gnu.org> <63d4101b796673602872997b7680d6b04a189de3.camel@student.tugraz.at> Date: Wed, 04 Nov 2020 16:41:58 -0500 In-Reply-To: <63d4101b796673602872997b7680d6b04a189de3.camel@student.tugraz.at> (Leo Prikler's message of "Wed, 04 Nov 2020 00:28:51 +0100") Message-ID: <87v9ekyf2x.fsf@gmail.com> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/27.1 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable X-Spam-Score: 0.0 (/) X-Debbugs-Envelope-To: 35594 Cc: Ludovic =?utf-8?Q?Court=C3=A8s?= , 35594@debbugs.gnu.org, 36376@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.0 (-) Hello Ludovic and Leo, Leo Prikler writes: > Hi Ludo, > > Am Dienstag, den 03.11.2020, 23:46 +0100 schrieb Ludovic Court=C3=A8s: >> Ludovic Court=C3=A8s skribis: >>=20 >> > This is not news to us, but as >> > notes, >> > the >> > application menu of desktop environments is not automatically >> > updated >> > when a package is installed or removed. It=E2=80=99d be great if we c= ould >> > somehow notify the desktop environment. >>=20 >> We=E2=80=99ve investigated today on IRC with Maxim and Leo P. and here= =E2=80=99s the >> summary of our findings: > Seeing my name thrown around more and more lately makes me blush a > little. >> [...] >>=20 >> The GLib patch below is an attempt to monitor ~/.guix-profile and to >> treat changes to that symlink as if they were changes to >> ~/.guix-profile/share/applications (which contains =E2=80=98.desktop=E2= =80=99 files.) >> It actually builds but I haven=E2=80=99t tested it yet. :-) >>=20 >> WDYT? Pretty cool! It'd keep on working even if we even clean up /etc/profile from the hardcoded defauts environment variables (say, if we merge one of the proposed solution of https://issues.guix.gnu.org/22138). > Not having tested it either, I think that we should also listen on > /run/current-system/ (if it exists), so that changes to the system as > done by `reconfigure` are picked up. This includes most importantly > changes to the GNOME ecosystem itself. I agree that it seems useful and important to add a monitor on the /run/current-system as well. Thank you! Maxim From debbugs-submit-bounces@debbugs.gnu.org Wed Nov 04 17:28:34 2020 Received: (at control) by debbugs.gnu.org; 4 Nov 2020 22:28:34 +0000 Received: from localhost ([127.0.0.1]:50878 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1kaRGc-0007SA-Em for submit@debbugs.gnu.org; Wed, 04 Nov 2020 17:28:34 -0500 Received: from mail-qt1-f176.google.com ([209.85.160.176]:37513) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1kaRGa-0007Rt-Mf for control@debbugs.gnu.org; Wed, 04 Nov 2020 17:28:32 -0500 Received: by mail-qt1-f176.google.com with SMTP id n63so195877qte.4 for ; Wed, 04 Nov 2020 14:28:32 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=date:message-id:to:from:subject; bh=1en13TYDxZ467ZDvrVMo+LVOPmY8oyApK3N0k8uCEzM=; b=vRVlPB9DX1AUy/EExMx0cPNzslnEOSmpJJSJemDFwgC65GMlXE6fHRZ+7DY96/4coN 9tno4sG/bKyABt8lQmCaGQmwFoVRBfrrK9hJ7Xf5ekOXFpcCo3MO6zF7AeJGoKw2zDl6 v5XGeKaz+6OEnj5xyggOCd8myeGKzzuaPXH9Yj8dpcRPFmULEhVwiHkja1LW3Hgg52zE 8T67WxwGi9DYG5PvvTPH7w0fK0CpoC/rfr+wwa0fyhtRdBQgbOkLXso7IGtnbto5fgXp yv1jA7majw6aYmrI7vPJx1PJPKqFvqHGosEMjxU3NSLHHq0W8jTwn+zK7xoLnpVhLm2m kZ3w== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:date:message-id:to:from:subject; bh=1en13TYDxZ467ZDvrVMo+LVOPmY8oyApK3N0k8uCEzM=; b=BsKet/MuVY1T1WdACTBXCkud7KmavihKMvVIAA9BFdR5cSp8zejVvLwVkd0r12gQl6 r6txvGm5/uWKEhiJk/yeK6lPwGxsfgFvSi0ae8oVBgm0om53cESUeibAPXjb9v4CHu+E AbhZbqdxw5dnHFsmeIc+NWUOGnV4TltOJIDDjghTLOlV7sO8gN/iywGrwHMP/eOGg/dL eDVfKqdEIJ1fzGkhbDCcZhtSeTN4d7xSkBPr9jKfTClSbhjE1Z3oToC3vrK/c63JS5qb dhvxYjJJHLgdGEZiNwBSBNxxysntLjsxcZngKOESXNUJQmQITJw8iYJn/LvP7SCxo5eW pd6w== X-Gm-Message-State: AOAM531KieVzLBftcHme+vHAFxdAMD47bsxeLGlxKuYpV1tmvBEQ4Mdr mbG4coVDaMy3ix60pXRD8+ULiS6yU3s= X-Google-Smtp-Source: ABdhPJzF10imXcmR7Q2/ovnJ8wVirZNlcCpG1iaxOCcVEjfG3PGL1/fKFexQs+qlduDfsvBSd/3QPA== X-Received: by 2002:aed:3809:: with SMTP id j9mr246050qte.197.1604528907225; Wed, 04 Nov 2020 14:28:27 -0800 (PST) Received: from hurd (dsl-154-213.b2b2c.ca. [66.158.154.213]) by smtp.gmail.com with ESMTPSA id k145sm3422323qke.79.2020.11.04.14.28.26 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 04 Nov 2020 14:28:26 -0800 (PST) Date: Wed, 04 Nov 2020 17:28:26 -0500 Message-Id: <87r1p8ycxh.fsf@gmail.com> To: control@debbugs.gnu.org From: Maxim Cournoyer Subject: control message for bug #41298 X-Spam-Score: 0.0 (/) X-Debbugs-Envelope-To: control X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.0 (-) merge 41298 35594 quit From debbugs-submit-bounces@debbugs.gnu.org Tue Nov 10 10:24:10 2020 Received: (at 35594) by debbugs.gnu.org; 10 Nov 2020 15:24:10 +0000 Received: from localhost ([127.0.0.1]:38650 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1kcVVB-0005lY-W9 for submit@debbugs.gnu.org; Tue, 10 Nov 2020 10:24:10 -0500 Received: from eggs.gnu.org ([209.51.188.92]:49652) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1kcVVA-0005lG-8A; Tue, 10 Nov 2020 10:24:08 -0500 Received: from fencepost.gnu.org ([2001:470:142:3::e]:34304) by eggs.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1kcVV3-0006sa-Fk; Tue, 10 Nov 2020 10:24:01 -0500 Received: from [2a01:e0a:1d:7270:af76:b9b:ca24:c465] (port=44716 helo=ribbon) by fencepost.gnu.org with esmtpsa (TLS1.2:RSA_AES_256_CBC_SHA1:256) (Exim 4.82) (envelope-from ) id 1kcVV0-0006xD-2l; Tue, 10 Nov 2020 10:23:59 -0500 From: =?utf-8?Q?Ludovic_Court=C3=A8s?= To: Maxim Cournoyer Subject: Re: bug#36376: Application menu of desktop environment not automatically updated References: <871rzhn483.fsf@gnu.org> <87o8keawju.fsf@gnu.org> <87d00swboe.fsf@gmail.com> <878sbexylp.fsf@gnu.org> <87r1p6tiut.fsf@gmail.com> Date: Tue, 10 Nov 2020 16:23:55 +0100 In-Reply-To: <87r1p6tiut.fsf@gmail.com> (Maxim Cournoyer's message of "Fri, 06 Nov 2020 13:56:10 -0500") Message-ID: <87lff9nsl0.fsf@gnu.org> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/27.1 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable X-Spam-Score: -2.3 (--) X-Debbugs-Envelope-To: 35594 Cc: Leo Prikler , 35594@debbugs.gnu.org, 36376@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -3.3 (---) Hi Maxim, So I went further to test the initial GLib patch I posted in =E2=80=9Creal conditions=E2=80=9D. =E2=80=98guix system vm-image=E2=80=99 takes an awful lot of time for big i= mages; I patiently waited for completion for an image of =E2=80=98desktop.tmpl=E2=80= =99, but then its root file system turned out to be too small for me to run =E2=80=98guix install=E2=80=99. So instead I tried this: 1. =E2=80=98guix system vm desktop.tmpl=E2=80=99; 2. =E2=80=98guix install inkscape -p /tmp/test=E2=80=99 on my actual mach= ine; 3. Start the GNOME VM created above; 4. Inside the VM, search for Inkscape, notice it=E2=80=99s not there; 5. Inside the VM, have ~/.guix-profile point to the profile created on the host above, and notice that Inkscape becomes available. Video! mpv http://web.fdn.fr/~lcourtes/tmp/gnome-desktop-app-detection.webm So I think we should include this fix in 1.2. What do people think? The main downside is extra grafting, which means extra disk and CPU usage for our users. However, libx11 (11K dependents) is also grafted, so it shouldn=E2=80=99t make things worse (GLib has 6K dependents). Maxim, did you have a variant of the GLib patch that also checks /run/current-system? Thanks, Ludo=E2=80=99. From debbugs-submit-bounces@debbugs.gnu.org Tue Nov 10 12:49:11 2020 Received: (at 35594) by debbugs.gnu.org; 10 Nov 2020 17:49:11 +0000 Received: from localhost ([127.0.0.1]:38830 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1kcXlX-0000zB-HJ for submit@debbugs.gnu.org; Tue, 10 Nov 2020 12:49:11 -0500 Received: from mail-qk1-f173.google.com ([209.85.222.173]:33634) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1kcXlW-0000yu-CD; Tue, 10 Nov 2020 12:49:10 -0500 Received: by mail-qk1-f173.google.com with SMTP id l2so12307187qkf.0; Tue, 10 Nov 2020 09:49:10 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc:content-transfer-encoding; bh=AWv0EOPHdsIvm3TQn2LuYMB3+hb9ro80ANCUBKwOOkY=; b=h+DD7slxo0w67uxjSpTgKzAJpuQwfqBiur0G+TSTquHluIxVg/FeUMb4RaxAvdyoAe ZqtbNQMvG0+YYqTItxr3OUjduRM953AwCQczad4Ms57+5UZ4/asKg/eDejfpBJ+9XaUW rhzpJQh8KuuYVgd91Kc7FfsWzx2d1xtCvdv5mT64R8fg/Eg6NuWrxVWLFUrX/K+OfMyw iaLVuRxOJcl7kQkL1JRu4UdlU3SE8nlIaXdy1uxeGeU22HAJENVAvQk0VcftGQzgMX+Y JStdPofNgiYfCj4YHxG6xet/3F8OZa0OXauC67z+6HujMQIsQPrPtAhroc+QpImQ2jd7 DL7g== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc:content-transfer-encoding; bh=AWv0EOPHdsIvm3TQn2LuYMB3+hb9ro80ANCUBKwOOkY=; b=FXCMn7fRZ1iUu+ggjjV466CpqkoXi4O1RYfgT2TrKkWNNWAPEsxp6iNanzldYdVNQv gLunSR0vpSetJj1wY8lYrpLcDK1y02rSwawZNmYkJhiPsDw+5QORKuJcx19MOVhUWXqR bfQhuoYA/nUoNzdn9nQHlgcFR9RtUHowhitr/ma+tXQ65ltP7+b8v9qoHNFAvG01DSOS lQfCAg8Cu+aJORBo6rjFhc585aoGQGtufLZJerIT/KWTqoJyOqx24s75LirRuONAkJz7 OSbqnufQYBxP+1IgTHnIL5ZD2S68PJEsfevtqmsHDosO53tzk74dUHXdW2v2f72/2X3O edWQ== X-Gm-Message-State: AOAM533tGbvnQjX1AEJpZWe2nHU34ub7tbkpAr4NmUnJa1BsDXY5YJcF z2T1LCw482HRsUHb6+B/SmZhLjg34d2v7hAWw/8= X-Google-Smtp-Source: ABdhPJzKyS+nZeNsBKjd3zmzi+RMTPRnaPKjrfy1KvRRfBbEC0Bj8wZpIxStHpA4dqcbFvgUcJmP6xu88ShYhZmu3jc= X-Received: by 2002:a37:a54f:: with SMTP id o76mr18179072qke.201.1605030544722; Tue, 10 Nov 2020 09:49:04 -0800 (PST) MIME-Version: 1.0 References: <871rzhn483.fsf@gnu.org> <87o8keawju.fsf@gnu.org> <87d00swboe.fsf@gmail.com> <878sbexylp.fsf@gnu.org> <87r1p6tiut.fsf@gmail.com> <87lff9nsl0.fsf@gnu.org> In-Reply-To: <87lff9nsl0.fsf@gnu.org> From: zimoun Date: Tue, 10 Nov 2020 18:48:53 +0100 Message-ID: Subject: Re: bug#36376: Application menu of desktop environment not automatically updated To: =?UTF-8?Q?Ludovic_Court=C3=A8s?= Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable X-Spam-Score: 0.0 (/) X-Debbugs-Envelope-To: 35594 Cc: 36376@debbugs.gnu.org, Leo Prikler , 35594@debbugs.gnu.org, Maxim Cournoyer X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.0 (-) On Tue, 10 Nov 2020 at 16:25, Ludovic Court=C3=A8s wrote: > Video! H=C3=A9h=C3=A9! Nice :-) > So I think we should include this fix in 1.2. What do people think? You mean only the initial patch. If it works in "real conditions" for bob on 'antelope' (desktop.tmpl), then it would nice to have for 1.2, > The main downside is extra grafting, which means extra disk and CPU > usage for our users. However, libx11 (11K dependents) is also grafted, > so it shouldn=E2=80=99t make things worse (GLib has 6K dependents). No free lunch. :-) Is it really slow or acceptable? All the best, simon From debbugs-submit-bounces@debbugs.gnu.org Tue Nov 10 16:23:40 2020 Received: (at 35594) by debbugs.gnu.org; 10 Nov 2020 21:23:40 +0000 Received: from localhost ([127.0.0.1]:39181 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1kcb76-0006Z6-DZ for submit@debbugs.gnu.org; Tue, 10 Nov 2020 16:23:40 -0500 Received: from eggs.gnu.org ([209.51.188.92]:53522) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1kcb75-0006Yl-Gb; Tue, 10 Nov 2020 16:23:39 -0500 Received: from fencepost.gnu.org ([2001:470:142:3::e]:41714) by eggs.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1kcb6t-0006u9-1B; Tue, 10 Nov 2020 16:23:27 -0500 Received: from [2a01:e0a:1d:7270:af76:b9b:ca24:c465] (port=46970 helo=ribbon) by fencepost.gnu.org with esmtpsa (TLS1.2:RSA_AES_256_CBC_SHA1:256) (Exim 4.82) (envelope-from ) id 1kcb6o-0007AD-Va; Tue, 10 Nov 2020 16:23:23 -0500 From: =?utf-8?Q?Ludovic_Court=C3=A8s?= To: zimoun Subject: Re: bug#36376: Application menu of desktop environment not automatically updated References: <871rzhn483.fsf@gnu.org> <87o8keawju.fsf@gnu.org> <87d00swboe.fsf@gmail.com> <878sbexylp.fsf@gnu.org> <87r1p6tiut.fsf@gmail.com> <87lff9nsl0.fsf@gnu.org> X-URL: http://www.fdn.fr/~lcourtes/ X-Revolutionary-Date: 20 Brumaire an 229 de la =?utf-8?Q?R=C3=A9volution?= X-PGP-Key-ID: 0x090B11993D9AEBB5 X-PGP-Key: http://www.fdn.fr/~lcourtes/ludovic.asc X-PGP-Fingerprint: 3CE4 6455 8A84 FDC6 9DB4 0CFB 090B 1199 3D9A EBB5 X-OS: x86_64-pc-linux-gnu Date: Tue, 10 Nov 2020 22:23:21 +0100 In-Reply-To: (zimoun's message of "Tue, 10 Nov 2020 18:48:53 +0100") Message-ID: <871rh0oqie.fsf@gnu.org> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/27.1 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable X-Spam-Score: -2.3 (--) X-Debbugs-Envelope-To: 35594 Cc: 36376@debbugs.gnu.org, Leo Prikler , 35594@debbugs.gnu.org, Maxim Cournoyer X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -3.3 (---) Hi, zimoun skribis: > On Tue, 10 Nov 2020 at 16:25, Ludovic Court=C3=A8s wrote: [...] >> The main downside is extra grafting, which means extra disk and CPU >> usage for our users. However, libx11 (11K dependents) is also grafted, >> so it shouldn=E2=80=99t make things worse (GLib has 6K dependents). > > No free lunch. :-) > Is it really slow or acceptable? If you=E2=80=99re installing a graphical applications, it=E2=80=99s already= being grafted, so the extra graft doesn=E2=80=99t make a difference. Non-graphical applications that depend on GLib will now need to be grafted, but I think there aren=E2=80=99t many of them, and they too might = also be grafted for other reasons. Ludo=E2=80=99. From debbugs-submit-bounces@debbugs.gnu.org Thu Nov 12 10:56:31 2020 Received: (at 35594) by debbugs.gnu.org; 12 Nov 2020 15:56:31 +0000 Received: from localhost ([127.0.0.1]:45394 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1kdExX-0006q9-Lk for submit@debbugs.gnu.org; Thu, 12 Nov 2020 10:56:31 -0500 Received: from eggs.gnu.org ([209.51.188.92]:34270) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1kdExP-0006pk-Bj; Thu, 12 Nov 2020 10:56:22 -0500 Received: from fencepost.gnu.org ([2001:470:142:3::e]:54776) by eggs.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1kdExI-00073Z-E6; Thu, 12 Nov 2020 10:56:12 -0500 Received: from [2a01:e0a:1d:7270:af76:b9b:ca24:c465] (port=56842 helo=ribbon) by fencepost.gnu.org with esmtpsa (TLS1.2:RSA_AES_256_CBC_SHA1:256) (Exim 4.82) (envelope-from ) id 1kdExF-00051s-Oj; Thu, 12 Nov 2020 10:56:11 -0500 From: =?utf-8?Q?Ludovic_Court=C3=A8s?= To: Maxim Cournoyer Subject: Re: bug#36376: Application menu of desktop environment not automatically updated References: <871rzhn483.fsf@gnu.org> <87o8keawju.fsf@gnu.org> <87d00swboe.fsf@gmail.com> <878sbexylp.fsf@gnu.org> <87r1p6tiut.fsf@gmail.com> <87lff9nsl0.fsf@gnu.org> Date: Thu, 12 Nov 2020 16:56:07 +0100 In-Reply-To: <87lff9nsl0.fsf@gnu.org> ("Ludovic =?utf-8?Q?Court=C3=A8s=22'?= =?utf-8?Q?s?= message of "Tue, 10 Nov 2020 16:23:55 +0100") Message-ID: <87d00iin6w.fsf@gnu.org> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/27.1 (gnu/linux) MIME-Version: 1.0 Content-Type: multipart/mixed; boundary="=-=-=" X-Spam-Score: -2.3 (--) X-Debbugs-Envelope-To: 35594 Cc: Leo Prikler , 35594@debbugs.gnu.org, 36376@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -3.3 (---) --=-=-= Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable Hi! Ludovic Court=C3=A8s skribis: > So I went further to test the initial GLib patch I posted in =E2=80=9Creal > conditions=E2=80=9D. I did some more testing using a similar workflow: this time I repeatedly changed the profile (installing/removing packages), which showed that the first patch was buggy (it would only notice the creation of ~/.guix-profile and nothing beyond that). This is in part due to the fact that =E2=80=98GFileMonitor=E2=80=99 follows= symlinks (it doesn=E2=80=99t pass the =E2=80=98IN_DONT_FOLLOW=E2=80=99 inotify flag). T= hus, when it monitors ~/.guix-profile, it=E2=80=99s really monitoring /gnu/store/=E2=80=A6-profil= e, which never changes. So with this new patch it=E2=80=99s monitoring /var/guix/profiles/per-user/= USER and /var/guix/profiles instead, which correctly detects changes. It detects a bit =E2=80=9Ctoo much=E2=80=9D (for instance, running =E2=80=98gu= ix pull=E2=80=99 triggers the inotify hook because it changes /var/guix/profiles/per-user/USER/current-guix) but that=E2=80=99s probably = OK. If you=E2=80=99re using GNOME, Xfce, or another GLib-based desktop environm= ent, I=E2=80=99d welcome tests on the bare metal! Just apply the patch on a che= ckout of =E2=80=98master=E2=80=99 and run: sudo -E ./pre-inst-env guix system reconfigure =E2=80=A6 If there are no objections, I=E2=80=99d like to apply this patch shortly so= we can go ahead with a last round of pre-release tests. Ludo=E2=80=99. --=-=-= Content-Type: text/x-patch Content-Disposition: inline; filename=0001-gnu-glib-Graft-patch-to-detect-changes-to-the-instal.patch Content-Description: the patch >From 7d03b2b823951219ece46c7f34e25ae36a8ba12c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ludovic=20Court=C3=A8s?= Date: Thu, 12 Nov 2020 16:35:24 +0100 Subject: [PATCH] gnu: glib: Graft patch to detect changes to the installed applications. Fixes . Reported by sirgazil and others. * gnu/packages/patches/glib-appinfo-watch.patch: New file. * gnu/local.mk (dist_patch_DATA): Add it. * gnu/packages/glib.scm (glib)[replacement]: New field. (glib-with-gio-patch): New variable. (glib-with-documentation): Use 'package/inherit'. --- gnu/local.mk | 1 + gnu/packages/glib.scm | 14 ++- gnu/packages/patches/glib-appinfo-watch.patch | 92 +++++++++++++++++++ 3 files changed, 105 insertions(+), 2 deletions(-) create mode 100644 gnu/packages/patches/glib-appinfo-watch.patch diff --git a/gnu/local.mk b/gnu/local.mk index d5a13cbdbd..2301a04d2f 100644 --- a/gnu/local.mk +++ b/gnu/local.mk @@ -1050,6 +1050,7 @@ dist_patch_DATA = \ %D%/packages/patches/ghostscript-no-header-id.patch \ %D%/packages/patches/ghostscript-no-header-uuid.patch \ %D%/packages/patches/ghostscript-no-header-creationdate.patch \ + %D%/packages/patches/glib-appinfo-watch.patch \ %D%/packages/patches/glib-tests-timer.patch \ %D%/packages/patches/glibc-CVE-2018-11236.patch \ %D%/packages/patches/glibc-CVE-2018-11237.patch \ diff --git a/gnu/packages/glib.scm b/gnu/packages/glib.scm index 901222476a..43523e516d 100644 --- a/gnu/packages/glib.scm +++ b/gnu/packages/glib.scm @@ -181,6 +181,7 @@ shared NFS home directories.") (package (name "glib") (version "2.62.6") + (replacement glib-with-gio-patch) (source (origin (method url-fetch) (uri (string-append "mirror://gnome/sources/" @@ -387,11 +388,20 @@ dynamic loading, and an object system.") (home-page "https://developer.gnome.org/glib/") (license license:lgpl2.1+))) +(define glib-with-gio-patch + ;; GLib with a fix for . + ;; TODO: Fold into 'glib' above in the next rebuild cycle. + (package + (inherit glib) + (source (origin + (inherit (package-source glib)) + (patches (cons (search-patch "glib-appinfo-watch.patch") + (origin-patches (package-source glib)))))))) + (define-public glib-with-documentation ;; glib's doc must be built in a separate package since it requires gtk-doc, ;; which in turn depends on glib. - (package - (inherit glib) + (package/inherit glib (properties (alist-delete 'hidden? (package-properties glib))) (outputs (cons "doc" (package-outputs glib))) ; 20 MiB of GTK-Doc reference (native-inputs diff --git a/gnu/packages/patches/glib-appinfo-watch.patch b/gnu/packages/patches/glib-appinfo-watch.patch new file mode 100644 index 0000000000..638a5e0949 --- /dev/null +++ b/gnu/packages/patches/glib-appinfo-watch.patch @@ -0,0 +1,92 @@ +This patch lets GLib's GDesktopAppInfo API watch and notice changes +to the Guix user and system profiles. That way, the list of available +applications shown by the desktop environment is immediately updated +when the user runs "guix install", "guix remove", or "guix system +reconfigure" (see ). + +It does so by monitoring /var/guix/profiles (for changes to the system +profile) and /var/guix/profiles/per-user/USER (for changes to the user +profile) and crawling their share/applications sub-directory when +changes happen. + +diff --git a/gio/gdesktopappinfo.c b/gio/gdesktopappinfo.c +index f1e2fdd..095c110 100644 +--- a/gio/gdesktopappinfo.c ++++ b/gio/gdesktopappinfo.c +@@ -148,6 +148,7 @@ typedef struct + gchar *alternatively_watching; + gboolean is_config; + gboolean is_setup; ++ gchar *guix_profile_watch_dir; + GFileMonitor *monitor; + GHashTable *app_names; + GHashTable *mime_tweaks; +@@ -180,6 +181,7 @@ desktop_file_dir_unref (DesktopFileDir *dir) + { + desktop_file_dir_reset (dir); + g_free (dir->path); ++ g_free (dir->guix_profile_watch_dir); + g_free (dir); + } + } +@@ -204,6 +206,13 @@ desktop_file_dir_get_alternative_dir (DesktopFileDir *dir) + { + gchar *parent; + ++ /* If DIR is a profile, watch the specified directory--e.g., ++ * /var/guix/profiles/per-user/$USER/ for the user profile. Do not watch ++ * ~/.guix-profile or /run/current-system/profile because GFileMonitor does ++ * not pass IN_DONT_FOLLOW and thus cannot notice any change. */ ++ if (dir->guix_profile_watch_dir != NULL) ++ return g_strdup (dir->guix_profile_watch_dir); ++ + /* If the directory itself exists then we need no alternative. */ + if (g_access (dir->path, R_OK | X_OK) == 0) + return NULL; +@@ -249,11 +258,11 @@ desktop_file_dir_changed (GFileMonitor *monitor, + * + * If this is a notification for a parent directory (because the + * desktop directory didn't exist) then we shouldn't fire the signal +- * unless something actually changed. ++ * unless something actually changed or it's in /var/guix/profiles. + */ + g_mutex_lock (&desktop_file_dir_lock); + +- if (dir->alternatively_watching) ++ if (dir->alternatively_watching && dir->guix_profile_watch_dir == NULL) + { + gchar *alternative_dir; + +@@ -1555,6 +1564,32 @@ desktop_file_dirs_lock (void) + for (i = 0; dirs[i]; i++) + g_ptr_array_add (desktop_file_dirs, desktop_file_dir_new (dirs[i])); + ++ { ++ /* Monitor the system and user profile under /var/guix/profiles and ++ * treat modifications to them as if they were modifications to their ++ * /share sub-directory. */ ++ const gchar *user; ++ DesktopFileDir *system_profile_dir, *user_profile_dir; ++ ++ system_profile_dir = ++ desktop_file_dir_new ("/var/guix/profiles/system/profile/share"); ++ system_profile_dir->guix_profile_watch_dir = g_strdup ("/var/guix/profiles"); ++ g_ptr_array_add (desktop_file_dirs, desktop_file_dir_ref (system_profile_dir)); ++ ++ user = g_get_user_name (); ++ if (user != NULL) ++ { ++ gchar *profile_dir, *user_data_dir; ++ ++ profile_dir = g_build_filename ("/var/guix/profiles/per-user", user, NULL); ++ user_data_dir = g_build_filename (profile_dir, "guix-profile", "share", NULL); ++ user_profile_dir = desktop_file_dir_new (user_data_dir); ++ user_profile_dir->guix_profile_watch_dir = profile_dir; ++ g_ptr_array_add (desktop_file_dirs, desktop_file_dir_ref (user_profile_dir)); ++ g_free (user_data_dir); ++ } ++ } ++ + /* The list of directories will never change after this, unless + * g_get_user_config_dir() changes due to %G_TEST_OPTION_ISOLATE_DIRS. */ + desktop_file_dirs_config_dir = user_config_dir; -- 2.29.2 --=-=-=-- From debbugs-submit-bounces@debbugs.gnu.org Fri Nov 13 15:39:03 2020 Received: (at 35594-done) by debbugs.gnu.org; 13 Nov 2020 20:39:03 +0000 Received: from localhost ([127.0.0.1]:49418 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1kdfqV-0007ek-VH for submit@debbugs.gnu.org; Fri, 13 Nov 2020 15:39:03 -0500 Received: from eggs.gnu.org ([209.51.188.92]:47698) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1kdfqN-0007eI-1x; Fri, 13 Nov 2020 15:38:54 -0500 Received: from fencepost.gnu.org ([2001:470:142:3::e]:39910) by eggs.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1kdfqF-0000fm-UQ; Fri, 13 Nov 2020 15:38:43 -0500 Received: from [2a01:e0a:1d:7270:af76:b9b:ca24:c465] (port=38016 helo=ribbon) by fencepost.gnu.org with esmtpsa (TLS1.2:RSA_AES_256_CBC_SHA1:256) (Exim 4.82) (envelope-from ) id 1kdfqF-00022W-Cz; Fri, 13 Nov 2020 15:38:43 -0500 From: =?utf-8?Q?Ludovic_Court=C3=A8s?= To: Maxim Cournoyer Subject: Re: bug#35594: bug#36376: Application menu of desktop environment not automatically updated References: <871rzhn483.fsf@gnu.org> <87o8keawju.fsf@gnu.org> <87d00swboe.fsf@gmail.com> <878sbexylp.fsf@gnu.org> <87r1p6tiut.fsf@gmail.com> <87lff9nsl0.fsf@gnu.org> <87d00iin6w.fsf@gnu.org> Date: Fri, 13 Nov 2020 21:38:41 +0100 In-Reply-To: <87d00iin6w.fsf@gnu.org> ("Ludovic =?utf-8?Q?Court=C3=A8s=22'?= =?utf-8?Q?s?= message of "Thu, 12 Nov 2020 16:56:07 +0100") Message-ID: <87a6vlat66.fsf@gnu.org> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/27.1 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable X-Spam-Score: -2.3 (--) X-Debbugs-Envelope-To: 35594-done Cc: Leo Prikler , 36376-done@debbugs.gnu.org, 35594-done@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -3.3 (---) Ludovic Court=C3=A8s skribis: >>>From 7d03b2b823951219ece46c7f34e25ae36a8ba12c Mon Sep 17 00:00:00 2001 > From: =3D?UTF-8?q?Ludovic=3D20Court=3DC3=3DA8s?=3D > Date: Thu, 12 Nov 2020 16:35:24 +0100 > Subject: [PATCH] gnu: glib: Graft patch to detect changes to the installed > applications. > > Fixes . > Reported by sirgazil and others. > > * gnu/packages/patches/glib-appinfo-watch.patch: New file. > * gnu/local.mk (dist_patch_DATA): Add it. > * gnu/packages/glib.scm (glib)[replacement]: New field. > (glib-with-gio-patch): New variable. > (glib-with-documentation): Use 'package/inherit'. Pushed as ae10ec441aa524bf267f9cefd4a319b44d0b8b44 (version-1.2.0). Ludo=E2=80=99. From debbugs-submit-bounces@debbugs.gnu.org Mon Nov 16 23:57:39 2020 Received: (at 35594) by debbugs.gnu.org; 17 Nov 2020 04:57:39 +0000 Received: from localhost ([127.0.0.1]:58043 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1ket3j-0004uZ-CA for submit@debbugs.gnu.org; Mon, 16 Nov 2020 23:57:39 -0500 Received: from mail-qv1-f66.google.com ([209.85.219.66]:47050) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1ket3Y-0004u0-Gk; Mon, 16 Nov 2020 23:57:31 -0500 Received: by mail-qv1-f66.google.com with SMTP id r12so10030752qvq.13; Mon, 16 Nov 2020 20:57:28 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:cc:subject:references:date:in-reply-to:message-id :user-agent:mime-version:content-transfer-encoding; bh=yhMlf/JNRiKsnlOh27ToU6cC0XGJm+ns0LmNRNTfgCs=; b=nhUuZq6odN+MZVnbbkv4k0rX+QqC5aa5tEKPET+5BP4XQo1P4eB1iAit4Tg2HeBT0t 1o3PW6eftNbIzNVJ5CaQFBiW8wN21tqye+zIqH2dBg/7zRCvXSWwiDUerab9ubHTZHLd 9F6UEoaAngKVntsv9erI62EN/aDZpmrrU5RBukiMmftGtzX2KAPSqUGTZoO4p/GTwApl Fl7gekMQNAzbhDAG64PILoRqE2qcMWnPN8U6lLf5SthoJYvkknFEQtbFk7NGqTBXi8C+ b0w7dgnCYZHQeFwKvfaM6/ll7vG49/Gk2HvTVdIoPExts0r9fwsf4c79a9YcEv2ieHVt FCuQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:references:date:in-reply-to :message-id:user-agent:mime-version:content-transfer-encoding; bh=yhMlf/JNRiKsnlOh27ToU6cC0XGJm+ns0LmNRNTfgCs=; b=l548cZsCehS2fGT53dgfyv4mfvA5s7JkaGo374bJjC/Xl4lRhnKmfCaWHS7UEkFw6G oBk4c8wdBnxTuqCgxHn2JQFsbzJTzZnmBdKyAp9QZZcwYGuNuOsHdhF/jcSWDw5coSu4 mfgw0ZhZY9nn9423YJ8E1urqFU9MfvyGfqiFCIswhw2cck1V3ujBiAWqMNqzaDoe7i/s qnN6rafrUq5DfccAjXBFSqPK6RFKGO6mvMNN3561x2hn4MiXRkEXxs/rrxm0S5C7CRvJ 7ruy33JCdtwvnSF+I2nbZ+MDjFV1dZkUeHEZTnFcY2q6W+2O2fZcV91fS9WUVICxt9gV 0fVw== X-Gm-Message-State: AOAM532fXjvt7hHq5pGxyhXw8ukFvx8LxkwKxXnNQy6MJOKiuZk0c4RQ NVXbAnzhglqdcwA422hvy9DhmCtioXU= X-Google-Smtp-Source: ABdhPJx5cHl1YTZM+lfqTs6imzkiDbRKc2Xqg1iqgLMflz1IFNkdcLoJxh4if1CfPtQ6qdLhSTtdyw== X-Received: by 2002:a0c:e585:: with SMTP id t5mr18454770qvm.6.1605589042438; Mon, 16 Nov 2020 20:57:22 -0800 (PST) Received: from hurd (dsl-205-236-230-198.b2b2c.ca. [205.236.230.198]) by smtp.gmail.com with ESMTPSA id o125sm13544914qke.56.2020.11.16.20.57.21 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 16 Nov 2020 20:57:21 -0800 (PST) From: Maxim Cournoyer To: Ludovic =?utf-8?Q?Court=C3=A8s?= Subject: Re: bug#36376: Application menu of desktop environment not automatically updated References: <871rzhn483.fsf@gnu.org> <87o8keawju.fsf@gnu.org> <87d00swboe.fsf@gmail.com> <878sbexylp.fsf@gnu.org> <87r1p6tiut.fsf@gmail.com> <87lff9nsl0.fsf@gnu.org> <87d00iin6w.fsf@gnu.org> Date: Mon, 16 Nov 2020 23:57:20 -0500 In-Reply-To: <87d00iin6w.fsf@gnu.org> ("Ludovic =?utf-8?Q?Court=C3=A8s=22'?= =?utf-8?Q?s?= message of "Thu, 12 Nov 2020 16:56:07 +0100") Message-ID: <875z64d1hr.fsf@gmail.com> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/27.1 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable X-Spam-Score: 0.0 (/) X-Debbugs-Envelope-To: 35594 Cc: Leo Prikler , 35594@debbugs.gnu.org, 36376@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.0 (-) Hello Ludovic! Ludovic Court=C3=A8s writes: [...] > So with this new patch it=E2=80=99s monitoring /var/guix/profiles/per-use= r/USER > and /var/guix/profiles instead, which correctly detects changes. It > detects a bit =E2=80=9Ctoo much=E2=80=9D (for instance, running =E2=80=98= guix pull=E2=80=99 triggers the > inotify hook because it changes > /var/guix/profiles/per-user/USER/current-guix) but that=E2=80=99s probabl= y OK. > > If you=E2=80=99re using GNOME, Xfce, or another GLib-based desktop enviro= nment, > I=E2=80=99d welcome tests on the bare metal! Just apply the patch on a c= heckout > of =E2=80=98master=E2=80=99 and run: I've now done so! It works :-)! I do have noticed something a bit off, see the comments below. [...] > diff --git a/gnu/packages/patches/glib-appinfo-watch.patch b/gnu/packages= /patches/glib-appinfo-watch.patch > new file mode 100644 > index 0000000000..638a5e0949 > --- /dev/null > +++ b/gnu/packages/patches/glib-appinfo-watch.patch > @@ -0,0 +1,92 @@ > +This patch lets GLib's GDesktopAppInfo API watch and notice changes > +to the Guix user and system profiles. That way, the list of available > +applications shown by the desktop environment is immediately updated > +when the user runs "guix install", "guix remove", or "guix system > +reconfigure" (see ). > + > +It does so by monitoring /var/guix/profiles (for changes to the system > +profile) and /var/guix/profiles/per-user/USER (for changes to the user > +profile) and crawling their share/applications sub-directory when > +changes happen. > + > +diff --git a/gio/gdesktopappinfo.c b/gio/gdesktopappinfo.c > +index f1e2fdd..095c110 100644 > +--- a/gio/gdesktopappinfo.c > ++++ b/gio/gdesktopappinfo.c > +@@ -148,6 +148,7 @@ typedef struct > + gchar *alternatively_watching; > + gboolean is_config; > + gboolean is_setup; > ++ gchar *guix_profile_watch_dir; > + GFileMonitor *monitor; > + GHashTable *app_names; > + GHashTable *mime_tweaks; > +@@ -180,6 +181,7 @@ desktop_file_dir_unref (DesktopFileDir *dir) > + { > + desktop_file_dir_reset (dir); > + g_free (dir->path); > ++ g_free (dir->guix_profile_watch_dir); > + g_free (dir); > + } > + } > +@@ -204,6 +206,13 @@ desktop_file_dir_get_alternative_dir (DesktopFileDi= r *dir) > + { > + gchar *parent; > + > ++ /* If DIR is a profile, watch the specified directory--e.g., > ++ * /var/guix/profiles/per-user/$USER/ for the user profile. Do not w= atch > ++ * ~/.guix-profile or /run/current-system/profile because GFileMonito= r does > ++ * not pass IN_DONT_FOLLOW and thus cannot notice any change. */ > ++ if (dir->guix_profile_watch_dir !=3D NULL) > ++ return g_strdup (dir->guix_profile_watch_dir); > ++ > + /* If the directory itself exists then we need no alternative. */ > + if (g_access (dir->path, R_OK | X_OK) =3D=3D 0) > + return NULL; > +@@ -249,11 +258,11 @@ desktop_file_dir_changed (GFileMonitor *monit= or, > + * > + * If this is a notification for a parent directory (because the > + * desktop directory didn't exist) then we shouldn't fire the signal > +- * unless something actually changed. > ++ * unless something actually changed or it's in /var/guix/profiles. > + */ > + g_mutex_lock (&desktop_file_dir_lock); > + > +- if (dir->alternatively_watching) > ++ if (dir->alternatively_watching && dir->guix_profile_watch_dir =3D=3D= NULL) ^^^^^^ Why is this needed/desirable? OK, I think I get it. The API seems to imply that users (such as gnome-shell) need to keep asking about a desktop directory entry as they are otherwise "forgotten". Since we are inserting entries at the level of glib ourselves, these will never be asked for by gnome-shell, so must not be cleared. Is that correct? > + { > + gchar *alternative_dir; > + > +@@ -1555,6 +1564,32 @@ desktop_file_dirs_lock (void) > + for (i =3D 0; dirs[i]; i++) > + g_ptr_array_add (desktop_file_dirs, desktop_file_dir_new (dirs[= i])); > + > ++ { > ++ /* Monitor the system and user profile under /var/guix/profiles= and > ++ * treat modifications to them as if they were modifications to= their > ++ * /share sub-directory. */ > ++ const gchar *user; > ++ DesktopFileDir *system_profile_dir, *user_profile_dir; > ++ > ++ system_profile_dir =3D > ++ desktop_file_dir_new ("/var/guix/profiles/system/profile/shar= e"); > ++ system_profile_dir->guix_profile_watch_dir =3D g_strdup ("/var/= guix/profiles"); > ++ g_ptr_array_add (desktop_file_dirs, desktop_file_dir_ref (syste= m_profile_dir)); > ++ > ++ user =3D g_get_user_name (); This seems to get the user of the running glib application; e.g. for GNOME Shell it returns 'gdm'... > ++ if (user !=3D NULL) > ++ { > ++ gchar *profile_dir, *user_data_dir; > ++ > ++ profile_dir =3D g_build_filename ("/var/guix/profiles/per-u= ser", user, NULL); > ++ user_data_dir =3D g_build_filename (profile_dir, "guix-prof= ile", "share", NULL); > ++ user_profile_dir =3D desktop_file_dir_new (user_data_dir); > ++ user_profile_dir->guix_profile_watch_dir =3D profile_dir; > ++ g_ptr_array_add (desktop_file_dirs, desktop_file_dir_ref (u= ser_profile_dir)); > ++ g_free (user_data_dir); > ++ } > ++ } > ++ ...which means the above puts the watch on the "/var/guix/profiles/per-user/gdm" directory, which doesn't exist. sudo strace -f -s200 -p$(pgrep gnome-shell | head -n1) reports entries such as: --8<---------------cut here---------------start------------->8--- 92 00:48:47 poll([{fd=3D6, events=3DPOLLIN}, {fd=3D7, events=3DPOLLIN}, {= fd=3D9, events=3DPOLLIN}, {fd=3D19, events=3DPOLLIN}, {fd=3D28, events=3DPO= LLIN}], 5, -1 390 00:48:47 <... poll resumed>) =3D 0 (Timeout) 390 00:48:47 inotify_add_watch(17, "/var/guix/profiles/per-user/gdm", IN_= MODIFY|IN_ATTRIB|IN_CLOSE_WRITE|IN_MOVED_FROM|IN_MOVED_TO|IN_CREATE|IN_DELE= TE|IN_DELETE_SELF|IN_MOVE_SELF|IN_UNMOUNT|IN_ONLYDIR) =3D -1 ENOENT (No suc= h file or directory) 390 00:48:47 poll([{fd=3D3, events=3DPOLLIN}, {fd=3D17, events=3DPOLLIN}]= , 2, 3996) =3D 0 (Timeout) 390 00:48:51 inotify_add_watch(17, "/var/guix/profiles/per-user/gdm", IN_= MODIFY|IN_ATTRIB|IN_CLOSE_WRITE|IN_MOVED_FROM|IN_MOVED_TO|IN_CREATE|IN_DELE= TE|IN_DELETE_SELF|IN_MOVE_SELF|IN_UNMOUNT|IN_ONLYDIR) =3D -1 ENOENT (No suc= h file or directory) 390 00:48:51 poll([{fd=3D3, events=3DPOLLIN}, {fd=3D17, events=3DPOLLIN}]= , 2, 3998) =3D 0 (Timeout) 390 00:48:55 inotify_add_watch(17, "/var/guix/profiles/per-user/gdm", IN_= MODIFY|IN_ATTRIB|IN_CLOSE_WRITE|IN_MOVED_FROM|IN_MOVED_TO|IN_CREATE|IN_DELE= TE|IN_DELETE_SELF|IN_MOVE_SELF|IN_UNMOUNT|IN_ONLYDIR) =3D -1 ENOENT (No suc= h file or directory) --8<---------------cut here---------------end--------------->8--- The fallback mechanism should have been disabled in desktop_file_dir_changed (dir->guix-profile_watch_dir !=3D NULL so desktop_file_dir_get_alternative_dir doesn't get called), so it seems this shouldn't work. Could it be that the watches used by glib implement a recursive inotify-based watch and that it works because any changes under the /var/guix/profiles directory get picked up, including those of user profiles. The sources seem to suggest so, for example in gio/inotify/inotify-path.c. If that is the case, it could lead to a new interesting problems: applications from other users could end up being shown inadvertently. I'll try to validate the above hypothesis, but this takes time. In any case, the current situation is already an improvement, so thank you for your efforts! Maxim From debbugs-submit-bounces@debbugs.gnu.org Tue Nov 17 04:09:01 2020 Received: (at 35594) by debbugs.gnu.org; 17 Nov 2020 09:09:01 +0000 Received: from localhost ([127.0.0.1]:58279 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1kewyz-0002o8-7f for submit@debbugs.gnu.org; Tue, 17 Nov 2020 04:09:01 -0500 Received: from eggs.gnu.org ([209.51.188.92]:41954) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1kewyx-0002nq-08; Tue, 17 Nov 2020 04:08:59 -0500 Received: from fencepost.gnu.org ([2001:470:142:3::e]:50810) by eggs.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1kewyp-0002hE-Pi; Tue, 17 Nov 2020 04:08:51 -0500 Received: from [2a01:e0a:1d:7270:af76:b9b:ca24:c465] (port=53968 helo=ribbon) by fencepost.gnu.org with esmtpsa (TLS1.2:RSA_AES_256_CBC_SHA1:256) (Exim 4.82) (envelope-from ) id 1kewyp-0004n9-Bb; Tue, 17 Nov 2020 04:08:51 -0500 From: =?utf-8?Q?Ludovic_Court=C3=A8s?= To: Maxim Cournoyer Subject: Re: bug#36376: Application menu of desktop environment not automatically updated References: <871rzhn483.fsf@gnu.org> <87o8keawju.fsf@gnu.org> <87d00swboe.fsf@gmail.com> <878sbexylp.fsf@gnu.org> <87r1p6tiut.fsf@gmail.com> <87lff9nsl0.fsf@gnu.org> <87d00iin6w.fsf@gnu.org> <875z64d1hr.fsf@gmail.com> X-URL: http://www.fdn.fr/~lcourtes/ X-Revolutionary-Date: 27 Brumaire an 229 de la =?utf-8?Q?R=C3=A9volution?= X-PGP-Key-ID: 0x090B11993D9AEBB5 X-PGP-Key: http://www.fdn.fr/~lcourtes/ludovic.asc X-PGP-Fingerprint: 3CE4 6455 8A84 FDC6 9DB4 0CFB 090B 1199 3D9A EBB5 X-OS: x86_64-pc-linux-gnu Date: Tue, 17 Nov 2020 10:08:49 +0100 In-Reply-To: <875z64d1hr.fsf@gmail.com> (Maxim Cournoyer's message of "Mon, 16 Nov 2020 23:57:20 -0500") Message-ID: <87eekstkny.fsf@gnu.org> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/27.1 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable X-Spam-Score: -2.3 (--) X-Debbugs-Envelope-To: 35594 Cc: Leo Prikler , 35594@debbugs.gnu.org, 36376@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -3.3 (---) Hi Maxim, Maxim Cournoyer skribis: > Ludovic Court=C3=A8s writes: > > [...] > >> So with this new patch it=E2=80=99s monitoring /var/guix/profiles/per-us= er/USER >> and /var/guix/profiles instead, which correctly detects changes. It >> detects a bit =E2=80=9Ctoo much=E2=80=9D (for instance, running =E2=80= =98guix pull=E2=80=99 triggers the >> inotify hook because it changes >> /var/guix/profiles/per-user/USER/current-guix) but that=E2=80=99s probab= ly OK. >> >> If you=E2=80=99re using GNOME, Xfce, or another GLib-based desktop envir= onment, >> I=E2=80=99d welcome tests on the bare metal! Just apply the patch on a = checkout >> of =E2=80=98master=E2=80=99 and run: > > I've now done so! It works :-)! I do have noticed something a bit off, > see the comments below. Thanks for testing! >> +@@ -249,11 +258,11 @@ desktop_file_dir_changed (GFileMonitor *moni= tor, >> + * >> + * If this is a notification for a parent directory (because the >> + * desktop directory didn't exist) then we shouldn't fire the signal >> +- * unless something actually changed. >> ++ * unless something actually changed or it's in /var/guix/profiles. >> + */ >> + g_mutex_lock (&desktop_file_dir_lock); >> + >> +- if (dir->alternatively_watching) >> ++ if (dir->alternatively_watching && dir->guix_profile_watch_dir =3D= =3D NULL) > ^^^^^^ > Why is this needed/desirable? As the comment above states it, the =E2=80=98if=E2=80=99 is here so that th= e =E2=80=9Cchanged=E2=80=9D signal is not fired when we=E2=80=99re just watching a parent directory. However, in our case, =E2=80=98dir->alternatively_watching !=3D NULL=E2=80= =99 possibly means that we=E2=80=99re watching a Guix profile, in which case we do want = to fire the =E2=80=9Cchanged=E2=80=9D signal. This =E2=80=9C&&=E2=80=9D allows us to disambiguate between =E2=80=9Cwatchi= ng a parent directory=E2=80=9D and =E2=80=9Cwatching a Guix profile=E2=80=9D. >> +@@ -1555,6 +1564,32 @@ desktop_file_dirs_lock (void) >> + for (i =3D 0; dirs[i]; i++) >> + g_ptr_array_add (desktop_file_dirs, desktop_file_dir_new (dirs= [i])); >> + >> ++ { >> ++ /* Monitor the system and user profile under /var/guix/profile= s and >> ++ * treat modifications to them as if they were modifications t= o their >> ++ * /share sub-directory. */ >> ++ const gchar *user; >> ++ DesktopFileDir *system_profile_dir, *user_profile_dir; >> ++ >> ++ system_profile_dir =3D >> ++ desktop_file_dir_new ("/var/guix/profiles/system/profile/sha= re"); >> ++ system_profile_dir->guix_profile_watch_dir =3D g_strdup ("/var= /guix/profiles"); >> ++ g_ptr_array_add (desktop_file_dirs, desktop_file_dir_ref (syst= em_profile_dir)); >> ++ >> ++ user =3D g_get_user_name (); > > This seems to get the user of the running glib application; e.g. for > GNOME Shell it returns 'gdm'... > >> ++ if (user !=3D NULL) >> ++ { >> ++ gchar *profile_dir, *user_data_dir; >> ++ >> ++ profile_dir =3D g_build_filename ("/var/guix/profiles/per-= user", user, NULL); >> ++ user_data_dir =3D g_build_filename (profile_dir, "guix-pro= file", "share", NULL); >> ++ user_profile_dir =3D desktop_file_dir_new (user_data_dir); >> ++ user_profile_dir->guix_profile_watch_dir =3D profile_dir; >> ++ g_ptr_array_add (desktop_file_dirs, desktop_file_dir_ref (= user_profile_dir)); >> ++ g_free (user_data_dir); >> ++ } >> ++ } >> ++ > > ...which means the above puts the watch on the > "/var/guix/profiles/per-user/gdm" directory, which doesn't exist. Yes, that profile is typically never populated. > sudo strace -f -s200 -p$(pgrep gnome-shell | head -n1) reports entries > such as: > > 92 00:48:47 poll([{fd=3D6, events=3DPOLLIN}, {fd=3D7, events=3DPOLLIN},= {fd=3D9, events=3DPOLLIN}, {fd=3D19, events=3DPOLLIN}, {fd=3D28, events=3D= POLLIN}], 5, -1 > 390 00:48:47 <... poll resumed>) =3D 0 (Timeout) > 390 00:48:47 inotify_add_watch(17, "/var/guix/profiles/per-user/gdm", I= N_MODIFY|IN_ATTRIB|IN_CLOSE_WRITE|IN_MOVED_FROM|IN_MOVED_TO|IN_CREATE|IN_DE= LETE|IN_DELETE_SELF|IN_MOVE_SELF|IN_UNMOUNT|IN_ONLYDIR) =3D -1 ENOENT (No s= uch file or directory) > 390 00:48:47 poll([{fd=3D3, events=3DPOLLIN}, {fd=3D17, events=3DPOLLIN= }], 2, 3996) =3D 0 (Timeout) > 390 00:48:51 inotify_add_watch(17, "/var/guix/profiles/per-user/gdm", I= N_MODIFY|IN_ATTRIB|IN_CLOSE_WRITE|IN_MOVED_FROM|IN_MOVED_TO|IN_CREATE|IN_DE= LETE|IN_DELETE_SELF|IN_MOVE_SELF|IN_UNMOUNT|IN_ONLYDIR) =3D -1 ENOENT (No s= uch file or directory) > 390 00:48:51 poll([{fd=3D3, events=3DPOLLIN}, {fd=3D17, events=3DPOLLIN= }], 2, 3998) =3D 0 (Timeout) > 390 00:48:55 inotify_add_watch(17, "/var/guix/profiles/per-user/gdm", I= N_MODIFY|IN_ATTRIB|IN_CLOSE_WRITE|IN_MOVED_FROM|IN_MOVED_TO|IN_CREATE|IN_DE= LETE|IN_DELETE_SELF|IN_MOVE_SELF|IN_UNMOUNT|IN_ONLYDIR) =3D -1 ENOENT (No s= uch file or directory) > > The fallback mechanism should have been disabled in > desktop_file_dir_changed (dir->guix-profile_watch_dir !=3D NULL so > desktop_file_dir_get_alternative_dir doesn't get called), so it seems > this shouldn't work. What shouldn=E2=80=99t work? We keep adding a watch on a non-existent directory, but I think that=E2=80= =99s fine. > Could it be that the watches used by glib implement a recursive > inotify-based watch and that it works because any changes under the > /var/guix/profiles directory get picked up, including those of user > profiles. The sources seem to suggest so, for example in > gio/inotify/inotify-path.c. If that is the case, it could lead to a new > interesting problems: applications from other users could end up being > shown inadvertently. We=E2=80=99re watching /var/guix/profiles (for the system profile) and /var/guix/profiles/per-user/USER, but .desktop files are loaded from the user=E2=80=99s own profile, so that should be fine. Thanks a lot for looking into this! Ludo=E2=80=99. From debbugs-submit-bounces@debbugs.gnu.org Tue Nov 17 23:34:59 2020 Received: (at 35594) by debbugs.gnu.org; 18 Nov 2020 04:34:59 +0000 Received: from localhost ([127.0.0.1]:33712 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1kfFBK-0006so-Ps for submit@debbugs.gnu.org; Tue, 17 Nov 2020 23:34:59 -0500 Received: from mail-qt1-f176.google.com ([209.85.160.176]:39618) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1kfFBC-0006sI-Qo; Tue, 17 Nov 2020 23:34:51 -0500 Received: by mail-qt1-f176.google.com with SMTP id b16so761682qtb.6; Tue, 17 Nov 2020 20:34:50 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:cc:subject:references:date:in-reply-to:message-id :user-agent:mime-version:content-transfer-encoding; bh=Bd9oIEjSyZuk6aWNKTNmB+GXKPMIrMh25apWZUMsk30=; b=oFgZxTYDU7qGHgYnLcWtJAw/du+wBKrj62NkvMosYerZq6bwYhrokL1C6p56zktYFz WGqaOCfkONQKbXHeqIQDWPMwJrm8E3dre8qKK51iYNT+2vASC28KjBVPedUpTHLw7y4G LjhwYNx8fwWY137SEEVDXV2HUy2MfE3z4tbisVvLc7x+w5oj+U2GWZkycpnlSei78slK i0EuwzFTSRyHi5p+zEGr5FWr47rjkHHbWaWi2GFLqxWtTZ61lS7lIKAsUl2Vs3KPtt8w 74IbjQDajOr3IifH3kIvGPeXImLs8PsUgYSufg6KYWhHQJeepOhwKUVvD5XxULoetM/e qfJw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:references:date:in-reply-to :message-id:user-agent:mime-version:content-transfer-encoding; bh=Bd9oIEjSyZuk6aWNKTNmB+GXKPMIrMh25apWZUMsk30=; b=J9qXW7ZQJD/BXxfxfF+yCyq3/zRQf4ZJjSsiPVoiPGG1AR3I2dTdUIG0+u5gnbmDxj 8JFL93Rs/3z3B4zEQx5ZSXXGyDjULPVibJNjgXtZ5gF6xXowR9uJ9AmXBTJQ2wbc7eBC Jbok0bdr2iUz/pdGZiItZuZDNK7mcPlvMn4KfBO6LlKALfSevco3CK/MBtYbEyI73ULX qVPEQa5B2PIhnm+dxxP8+kjbadw2xGx1cSean6DESGN2eQB5MnxgAJ9B+8oQjuq3Ujme HZnLjrJB29zl14LHXEYvpRiIYUe0bO7CYRD4QOYId9ICtq4WMistPE40u1pr1sCAKv6T 64wg== X-Gm-Message-State: AOAM5308Afs0dCWicoVhgSJY4Ktx0SYNW7eUBr55hZ+BYsfJWvBvYBeX 5Xhdpcl1/4T/Ol4xTjJm4aMwVJ1gElIaJw== X-Google-Smtp-Source: ABdhPJxYpy/zWreOpA2IGi9YisQ4UgjTOSA2BMhUtUp/o5kk7X8gZ0jcZaeHwzHFMuXAjr3LeDKeJQ== X-Received: by 2002:ac8:7b30:: with SMTP id l16mr2668636qtu.360.1605674084874; Tue, 17 Nov 2020 20:34:44 -0800 (PST) Received: from hurd (dsl-205-236-230-198.b2b2c.ca. [205.236.230.198]) by smtp.gmail.com with ESMTPSA id 137sm15908441qkj.109.2020.11.17.20.34.43 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 17 Nov 2020 20:34:44 -0800 (PST) From: Maxim Cournoyer To: Ludovic =?utf-8?Q?Court=C3=A8s?= Subject: Re: bug#36376: Application menu of desktop environment not automatically updated References: <871rzhn483.fsf@gnu.org> <87o8keawju.fsf@gnu.org> <87d00swboe.fsf@gmail.com> <878sbexylp.fsf@gnu.org> <87r1p6tiut.fsf@gmail.com> <87lff9nsl0.fsf@gnu.org> <87d00iin6w.fsf@gnu.org> <875z64d1hr.fsf@gmail.com> <87eekstkny.fsf@gnu.org> Date: Tue, 17 Nov 2020 23:34:42 -0500 In-Reply-To: <87eekstkny.fsf@gnu.org> ("Ludovic =?utf-8?Q?Court=C3=A8s=22'?= =?utf-8?Q?s?= message of "Tue, 17 Nov 2020 10:08:49 +0100") Message-ID: <87d00b8eql.fsf@gmail.com> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/27.1 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable X-Spam-Score: 0.0 (/) X-Debbugs-Envelope-To: 35594 Cc: Leo Prikler , 35594@debbugs.gnu.org, 36376@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.0 (-) Hello Ludovic! Ludovic Court=C3=A8s writes: > Hi Maxim, > > Maxim Cournoyer skribis: > >> Ludovic Court=C3=A8s writes: [...] >>> +@@ -249,11 +258,11 @@ desktop_file_dir_changed (GFileMonitor *mon= itor, >>> + * >>> + * If this is a notification for a parent directory (because the >>> + * desktop directory didn't exist) then we shouldn't fire the signal >>> +- * unless something actually changed. >>> ++ * unless something actually changed or it's in /var/guix/profiles. >>> + */ >>> + g_mutex_lock (&desktop_file_dir_lock); >>> + >>> +- if (dir->alternatively_watching) >>> ++ if (dir->alternatively_watching && dir->guix_profile_watch_dir =3D= =3D NULL) >> ^^^^^^ >> Why is this needed/desirable? > > As the comment above states it, the =E2=80=98if=E2=80=99 is here so that = the =E2=80=9Cchanged=E2=80=9D > signal is not fired when we=E2=80=99re just watching a parent directory. > > However, in our case, =E2=80=98dir->alternatively_watching !=3D NULL=E2= =80=99 possibly > means that we=E2=80=99re watching a Guix profile, in which case we do wan= t to > fire the =E2=80=9Cchanged=E2=80=9D signal. > > This =E2=80=9C&&=E2=80=9D allows us to disambiguate between =E2=80=9Cwatc= hing a parent > directory=E2=80=9D and =E2=80=9Cwatching a Guix profile=E2=80=9D. Yes, this makes sense. I got confused by the wording of the (existing) comment that mentions "unless something actually changed". I used to think this meant the contents of whatever directory is being watched, but looking more closely, it's really just about if the parent directory of a non-existing data directory changed... Makes senses, we don't want that. >>> +@@ -1555,6 +1564,32 @@ desktop_file_dirs_lock (void) >>> + for (i =3D 0; dirs[i]; i++) >>> + g_ptr_array_add (desktop_file_dirs, desktop_file_dir_new (dir= s[i])); >>> + >>> ++ { >>> ++ /* Monitor the system and user profile under /var/guix/profil= es and >>> ++ * treat modifications to them as if they were modifications = to their >>> ++ * /share sub-directory. */ >>> ++ const gchar *user; >>> ++ DesktopFileDir *system_profile_dir, *user_profile_dir; >>> ++ >>> ++ system_profile_dir =3D >>> ++ desktop_file_dir_new ("/var/guix/profiles/system/profile/sh= are"); >>> ++ system_profile_dir->guix_profile_watch_dir =3D g_strdup ("/va= r/guix/profiles"); >>> ++ g_ptr_array_add (desktop_file_dirs, desktop_file_dir_ref (sys= tem_profile_dir)); >>> ++ >>> ++ user =3D g_get_user_name (); >> >> This seems to get the user of the running glib application; e.g. for >> GNOME Shell it returns 'gdm'... >> >>> ++ if (user !=3D NULL) >>> ++ { >>> ++ gchar *profile_dir, *user_data_dir; >>> ++ >>> ++ profile_dir =3D g_build_filename ("/var/guix/profiles/per= -user", user, NULL); >>> ++ user_data_dir =3D g_build_filename (profile_dir, "guix-pr= ofile", "share", NULL); >>> ++ user_profile_dir =3D desktop_file_dir_new (user_data_dir); >>> ++ user_profile_dir->guix_profile_watch_dir =3D profile_dir; >>> ++ g_ptr_array_add (desktop_file_dirs, desktop_file_dir_ref = (user_profile_dir)); >>> ++ g_free (user_data_dir); >>> ++ } >>> ++ } >>> ++ >> >> ...which means the above puts the watch on the >> "/var/guix/profiles/per-user/gdm" directory, which doesn't exist. > > Yes, that profile is typically never populated. Ah, I now understand the source of my confusion; there are multiple gnome-shell instances (components?) running, one apparently started by the greeter (GDM), which doesn't have a profile, and others started by the users which logged in. Thanks again for the fix and explanations! Maxim From unknown Wed Jun 18 00:28:21 2025 Received: (at fakecontrol) by fakecontrolmessage; To: internal_control@debbugs.gnu.org From: Debbugs Internal Request Subject: Internal Control Message-Id: bug archived. Date: Wed, 16 Dec 2020 12:24:04 +0000 User-Agent: Fakemail v42.6.9 # This is a fake control message. # # The action: # bug archived. thanks # This fakemail brought to you by your local debbugs # administrator