From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Drew Adams via "Bug reports for GNU Emacs, the Swiss army knife of text editors" Newsgroups: gmane.emacs.bugs Subject: bug#70593: 30.0.50; Dired: buffers of renamed dirs are broken Date: Thu, 9 May 2024 21:20:09 +0000 Message-ID: References: <87a5lguygb.fsf@web.de> <861q6syxzb.fsf@gnu.org> <87plu8xmb9.fsf@web.de> <87msozqes5.fsf@web.de> <87ikzmg50t.fsf@web.de> Reply-To: Drew Adams Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="18658"; mail-complaints-to="usenet@ciao.gmane.io" Cc: eliz@gnu.org To: michael_heerdegen@web.de, 70593@debbugs.gnu.org Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Thu May 09 23:21:27 2024 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane-mx.org Original-Received: from lists.gnu.org ([209.51.188.17]) by ciao.gmane.io with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1s5BCg-0004ex-Pu for geb-bug-gnu-emacs@m.gmane-mx.org; Thu, 09 May 2024 23:21:27 +0200 Original-Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1s5BCM-0008TE-Fu; Thu, 09 May 2024 17:21:06 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1s5BCK-0008SW-9h for bug-gnu-emacs@gnu.org; Thu, 09 May 2024 17:21:04 -0400 Original-Received: from debbugs.gnu.org ([2001:470:142:5::43]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1s5BCK-00084x-0W for bug-gnu-emacs@gnu.org; Thu, 09 May 2024 17:21:04 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1s5BCH-0001Zg-Vl for bug-gnu-emacs@gnu.org; Thu, 09 May 2024 17:21:02 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Drew Adams Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Thu, 09 May 2024 21:21:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 70593 X-GNU-PR-Package: emacs X-Debbugs-Original-To: Michael Heerdegen , "Drew Adams via Bug reports for GNU Emacs, the Swiss army knife of text editors" X-Debbugs-Original-Cc: "70593@debbugs.gnu.org" <70593@debbugs.gnu.org>, Eli Zaretskii Original-Received: via spool by submit@debbugs.gnu.org id=B.17152896235995 (code B ref -1); Thu, 09 May 2024 21:21:01 +0000 Original-Received: (at submit) by debbugs.gnu.org; 9 May 2024 21:20:23 +0000 Original-Received: from localhost ([127.0.0.1]:40868 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1s5BBe-0001Yd-PE for submit@debbugs.gnu.org; Thu, 09 May 2024 17:20:23 -0400 Original-Received: from lists.gnu.org ([209.51.188.17]:49424) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1s5BBb-0001YX-Ol for submit@debbugs.gnu.org; Thu, 09 May 2024 17:20:20 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1s5BBc-0008Fu-36 for bug-gnu-emacs@gnu.org; Thu, 09 May 2024 17:20:20 -0400 Original-Received: from mx0b-00069f02.pphosted.com ([205.220.177.32]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1s5BBY-0007Hk-Tt; Thu, 09 May 2024 17:20:19 -0400 Original-Received: from pps.filterd (m0246630.ppops.net [127.0.0.1]) by mx0b-00069f02.pphosted.com (8.17.1.19/8.17.1.19) with ESMTP id 449LJx9x020339; Thu, 9 May 2024 21:20:12 GMT DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=oracle.com; h=from : to : cc : subject : date : message-id : references : in-reply-to : content-type : content-transfer-encoding : mime-version; s=corp-2023-11-20; bh=j/CmVpdC2fwbwkRgkYVTac7RYPZFBZSyl7rfM9Rq5wo=; b=a9z76mq+o0qLZRlW21LQuF0yH/FfnJnZgji2t3/hjnVc0h6DZarvcXCB9SylEsWKv/s9 PioR+vMNYLd7FD9a3/OxAG+HhEGEgHMuGfN7IVdQFrCl0FkNzXU/93TGXiYqRvCsbtbB kyW03Q4HREzLgMLphsG0357WmaudDM1WLqjm7jWiZOk/+P5KMzuTvv4G1/s/l8fbv63D Q/2lelryoYFWNvSjkkj4KaGd71VfXfmR8mGA+UgCDBCIEO8ltVp8PBFhJM8Kvr6AZNIE IhotgKRen5QR8tY/OG8EsMg7bQEJVEZyLRsirEH6MJHBIeMiJVLy7psEXpZsNRqOU5wR +Q== Original-Received: from iadpaimrmta03.imrmtpd1.prodappiadaev1.oraclevcn.com (iadpaimrmta03.appoci.oracle.com [130.35.103.27]) by mx0b-00069f02.pphosted.com (PPS) with ESMTPS id 3y14xfr417-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=OK); Thu, 09 May 2024 21:20:12 +0000 Original-Received: from pps.filterd (iadpaimrmta03.imrmtpd1.prodappiadaev1.oraclevcn.com [127.0.0.1]) by iadpaimrmta03.imrmtpd1.prodappiadaev1.oraclevcn.com (8.17.1.19/8.17.1.19) with ESMTP id 449L5WoF024331; Thu, 9 May 2024 21:20:11 GMT Original-Received: from nam10-dm6-obe.outbound.protection.outlook.com (mail-dm6nam10lp2101.outbound.protection.outlook.com [104.47.58.101]) by iadpaimrmta03.imrmtpd1.prodappiadaev1.oraclevcn.com (PPS) with ESMTPS id 3xysfqcjns-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=OK); Thu, 09 May 2024 21:20:11 +0000 ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=LS1kZsOUxLL732VPkys1UzogJL/qHqI0Ok6f97VPKrTqjya5l2T3c6IGTvYwX1ArIxfRC2N7q8EZN74Rh2Qn/XujlBKAMczq8Xg8PsK61UMRcOTF6dSR3KaWYepccvIDSbdV7jXAKn6Lf52sa0kOjOMRQ7p4dHzXzpFu7EFD4TtvdmdrbJws8iXagrJMu3HNLLLK9yK0Eg3j/l8BYfg4lmarT9UIEGsMZXcMQ4y3bvHX/YNyPL0RUA3s8QdmuXTLVIJBv7fTp6Z/NPcd/XuszDGLHKmVpxxQHF2sxFeE7wLCb6k7OAX7GeiqKaRXBs6M4czWwmgaYq+XoEuGmTTq4g== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=j/CmVpdC2fwbwkRgkYVTac7RYPZFBZSyl7rfM9Rq5wo=; b=SvmoBEBYsEELzm6U0rlAFCvLrm546ftW8esYsg5aBxDx9yO/ftyyg6ldf2AvWPtanDt+59Woy9WOWk06ZijHX5og70Wk2vbxzj6C4bO/E+dWFJdZt32gBiGKOdGwb4ja+WlK1K+H1OQfTzQ0Q8I3ZnCg6AyqtBEHUKhfBjczWl2lFn2L/b75vFyJvDql/WeycoP6mz2zdIhuLsj68J3hGyXnIJc0yEqDQ87q51lp8UTrpLNOSrrdzyGxb350bklQu0jTqW0aUhyayZpd6FdhXMAS+TUc+EFuj8VNsn+8Ha1LFXQ6jaITfM55e3264LF2COQKAFaW4KMsnNIcXGcuWA== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=oracle.com; dmarc=pass action=none header.from=oracle.com; dkim=pass header.d=oracle.com; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=oracle.onmicrosoft.com; s=selector2-oracle-onmicrosoft-com; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=j/CmVpdC2fwbwkRgkYVTac7RYPZFBZSyl7rfM9Rq5wo=; b=kb5E+uV+ty/hLGRuKrrD4GpL5xmDUtRYxd8SdvawKP0BAPbz1Fr8IQ2DtEqPY8tTwZJAhXGQb3AWH6Aq3IK9aVyZqe2dynH1HDCap2b4QM9cDAnWoxduO4jO8z5RKYPQ1snhjXMenRu7ky8FzIDgkrInTyCL9R8ZUHUfpwXa5qQ= Original-Received: from SJ0PR10MB5488.namprd10.prod.outlook.com (2603:10b6:a03:37e::19) by CY8PR10MB6466.namprd10.prod.outlook.com (2603:10b6:930:62::10) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.7544.45; Thu, 9 May 2024 21:20:09 +0000 Original-Received: from SJ0PR10MB5488.namprd10.prod.outlook.com ([fe80::380d:4e6d:faae:a72a]) by SJ0PR10MB5488.namprd10.prod.outlook.com ([fe80::380d:4e6d:faae:a72a%7]) with mapi id 15.20.7544.046; Thu, 9 May 2024 21:20:09 +0000 Thread-Topic: [External] : Re: bug#70593: 30.0.50; Dired: buffers of renamed dirs are broken Thread-Index: AQHaokba3q8/h/S5mE6SpOHQYpYaZ7GPX03g In-Reply-To: <87ikzmg50t.fsf@web.de> Accept-Language: en-US Content-Language: en-US x-ms-publictraffictype: Email x-ms-traffictypediagnostic: SJ0PR10MB5488:EE_|CY8PR10MB6466:EE_ x-ms-office365-filtering-correlation-id: 7ade5017-587b-4ecf-51aa-08dc706dce2d x-ms-exchange-senderadcheck: 1 x-ms-exchange-antispam-relay: 0 x-microsoft-antispam: BCL:0; ARA:13230031|1800799015|376005|366007|38070700009; x-microsoft-antispam-message-info: EQ2+DjSdW2AwW3nl+pZOJY7BAJddGqulGAeiCzhl99n7VknWcIiELmQhUWSGLBWOnYUN9XA2nRo7p+wyDPcCjHfhqPtUG4ahFuV54eq8FnLC645U6cIhixe+Jg+Zlj1I3bFTxyCCUGGKTAZCTTU1pvBNrKOIFwWAP+t+l5JT0GfGzDET3HtRUqT1X9cjwBebeThP1qK8HU6JrDpzPShV9tG57/zNkgYUnHL/qORxnKMKAaNOTyVgJNHLCGrPqTBoanndubdRPfVdgbQOLw9oDzY28JhZRw2O38n609UU1D9JWe8w2+hMEE2WVUZ8QX6SLFHeHMUFnLpBQa5pkFIkqbA+InbMdgm+poFMFLLUx4JaBh90hdvwlCn19folgg3uhTA4ecao2PuuEturKXzqUX3qirrRVz4ZnVAR1NYocD2LkDWKqYw/ivi8xLThj3rP3SA+dAA73dRGE2OwhpXRysz8IrvvEivfPLi2W8ZZ5jXRIYj74VsUluP7y3puJszGvK/mz4NUaOliuBRQRty+AqNo0hB05hQpQmdus7bHhd/dUfmekXz+WqLnPdx+3YbJyKuEJJ/10/6ccN7cMBAFSYb0iSneBr8+b2oD00sFoyfHt4sc0YrTAZj7xjL4zNx1YVDKCk0nLQy0uZjwhO/ZM+4flBT8Wd9seKzdV/kZa3GQ0y7o7hyNvXd1jX/SetURHtDaxkvdzAyWStWKy0tPVN8XNeXM2H/CQDwpFmDZodC6rcrEuQEjJ1cq6K1+Z HOQ+frSt2HO8MPj3K0ALuoMizojaHNYjZwz2psQ45B9lKfZi/3sQM51nGDvdBONazw8Go0W+ZTuqGQbnFYoAhaZW1acBXFHsQm x-forefront-antispam-report: CIP:255.255.255.255; CTRY:; LANG:en; SCL:1; SRV:; IPV:NLI; SFV:NSPM; H:SJ0PR10MB5488.namprd10.prod.outlook.com; PTR:; CAT:NONE; SFS:(13230031)(1800799015)(376005)(366007)(38070700009); DIR:OUT; SFP:1101; x-ms-exchange-antispam-messagedata-chunkcount: 1 x-ms-exchange-antispam-messagedata-0: on8AMvYii8D/1C9vQNufWUqTJPcWTYTTH3fQ5Z4ybb99gj/Yq+tTMypSuFMk8l3gk2aAhBQHZcPgZwti9imfrl7w9obJHfjqcQwefCmUWKHHMx+0WtgNaisCaD+VvtWt8uOybs9DjCJ6TG8qar+y5JScHEBGbSOR7C5mQVdCUpjPDImj7ITWOwaluw+Up9KePjehrd5CtUZPKrPhwHx3rysFnWIBZnhoXQhTxigbxoxP6Ya2eq7x2jZWpksKaLrINg6UHLX3SyWIQTtFp9gwOUuRpr6+k3227aTKdJhWP5NcfadYuj5Rwvp9D0NvSOJ3OV7W0tvF7zguZXM0AU6ooNyu2MFabPun180n2bu6zc5rTbm4/ovYxuk8uLTgGeBnBbYnWg3XBb3Lhpw2Rz0Hi9MYU721OZLQR0iC6EcSIGjaT8/kX2pz5MTVNe2TwobIcgXORO9Db+LVdAiA03Pk4zl4VdYn9TGtwJJpfio6yczUeZgUJ/nZeS10GUFDV8CKf/0V/sISzxZA+OGI1+V0qt08i+MgJC6ridbYXnrbSe1Uf/HCh3Otl7TVPaDcN9bnXCKnMVBw9oYyQvUDU/4DMwC4qTFhZPL45I+E36vrf0iDvTvc8uBoKxMB6mer59ifMWNpY2zuopCMA2BbwtkKRsiK+jfqCXqsBOip8rG6pXalWVxBT/CAe3wvbcRWOuV/Q5PokEHtytDSyWMM1lUHDlJG3k+j5BcVNZnl1l+Y/QsSXUq+EPlZuQx9Fj h6zpQUBRgXZA68r/NlknLsQjr8zh6y5ci+NGT0wNJuFOIRu9ZYc6jHMwSunhbSTboUvpUvitJIy+LRFsjFR5GG8mEMCbXF8a55 X-MS-Exchange-AntiSpam-ExternalHop-MessageData-ChunkCount: 1 X-MS-Exchange-AntiSpam-ExternalHop-MessageData-0: lQb4ip6TRz956t+nZZT5q9+XNk6GQ/MmduAvOKcPOVQIlPutBpe6XQaetm5T2tXgH06o80/TI4mBWhmmpFzzyVDp11HtfgbJxv2xZeC/CUl6arNuxu7FI3KwoDsg7kyz69TMP7pRxHWLuI6AC/x4ZBStDmjuoiTmYoI+WI7oe2IOP/iF7JvTmWzWazwfNmdx8S8qH+ivwLyz4YwDX4WWNU02Vh4OeE6GkB+q8V37j+KeZ3bhWYbAEJymOi+YbfeZMk5WiAiYu5s94sdoShtrXV6nI70C2M+Y5r4AmskJKOUDb6WJXNQayjzIhVojDsmvJ2kaC1f/0mo6QIqXlGiJw2Abl9VHscNTbX/nOpUyXtGX+WZuq6+LwjMSnb11P3zOT4ZUdfL0S/Jko69TIn8m90wHazdXhTAIb3vtKx+Nu2Z3cCLVYsZKgzLCkb85AdXj6OtFuLeRm3uXtTdLtXQFzcwOUMBcxmVOPSjzM1QB8aH2ncOPj+a/eJS5kr9Q6dGjaOZj5YfvhX+08vBxDU9npRpGDKEvl8ykLXmYHMLf32bVcixz/fUmOA1g5AfeC8UZlFvxgFc82svbP320bDp76sgDfh6mm7h7FiTYYXZ0iWo= X-OriginatorOrg: oracle.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-AuthSource: SJ0PR10MB5488.namprd10.prod.outlook.com X-MS-Exchange-CrossTenant-Network-Message-Id: 7ade5017-587b-4ecf-51aa-08dc706dce2d X-MS-Exchange-CrossTenant-originalarrivaltime: 09 May 2024 21:20:09.2204 (UTC) X-MS-Exchange-CrossTenant-fromentityheader: Hosted X-MS-Exchange-CrossTenant-id: 4e2c6054-71cb-48f1-bd6c-3a9705aca71b X-MS-Exchange-CrossTenant-mailboxtype: HOSTED X-MS-Exchange-CrossTenant-userprincipalname: tfd8c7Tyawa/381uLs0orxhKZbXa7iUow3OnQE/GM1IJDq/WgPl5AEFdEZXqT56diHLPtXEmPxTpst7P+wxnWg== X-MS-Exchange-Transport-CrossTenantHeadersStamped: CY8PR10MB6466 X-Proofpoint-Virus-Version: vendor=baseguard engine=ICAP:2.0.293,Aquarius:18.0.1039,Hydra:6.0.650,FMLib:17.11.176.26 definitions=2024-05-09_12,2024-05-09_01,2023-05-22_02 X-Proofpoint-Spam-Details: rule=notspam policy=default score=0 adultscore=0 suspectscore=0 mlxscore=0 mlxlogscore=999 spamscore=0 bulkscore=0 phishscore=0 malwarescore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.12.0-2405010000 definitions=main-2405090150 X-Proofpoint-ORIG-GUID: 7sLNg6Tfb53eTWS_slPks7e2FbKqijXY X-Proofpoint-GUID: 7sLNg6Tfb53eTWS_slPks7e2FbKqijXY Received-SPF: pass client-ip=205.220.177.32; envelope-from=drew.adams@oracle.com; helo=mx0b-00069f02.pphosted.com X-Spam_score_int: -27 X-Spam_score: -2.8 X-Spam_bar: -- X-Spam_report: (-2.8 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_LOW=-0.7, RCVD_IN_MSPIKE_H4=0.001, RCVD_IN_MSPIKE_WL=0.001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-BeenThere: bug-gnu-emacs@gnu.org List-Id: "Bug reports for GNU Emacs, the Swiss army knife of text editors" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Original-Sender: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Xref: news.gmane.io gmane.emacs.bugs:284778 Archived-At: > When I call dired with a cons DIRNAME, `dired-directory' will be bound > to that cons. And it is consulted for reverting. >=20 > When I overwrite it with just `default-directory' and revert, the result > will be a "normal" dired buffer showing this directory - the explicit > listing is lost. Right. > In the scenario of the bug this surely makes a difference. OK; sounds right. > My latest patch seems to work as expected. > Any comment about the patch btw? I can't really judge. Eyeballing it, it looks reasonable. What I see is that when `dired-directory' is a cons you replace its car, DIRED-DIR, applying this to that car: (abbreviate-file-name (file-name-as-directory DIRED-DIR)) But the car of a cons `dired-directory' isn't necessarily a directory name or any file name. It's just a string used as the Dired buffer name. (Often it is a directory name, but it need not be.) If it's a directory name then what you're doing looks right to me. If it's not then I think it's probably still OK - that code would generally just append a `/' to the string. But if the string has some particular file-name syntax then maybe there could be some other=20 resulting behavior; dunno. =20 > Subdir insertion in cons value `dired-directory' buffers=20 > are not really supported currently it seems Not sure what you mean. Even in vanilla Emacs, I think subdir insertion is supported. E.g.: M-: (dired (list "foobar" "/tata/file.txt" "/toto/dir/" "/titi/")) You get a Dired listing in buffer `foobar' with those 3 filename entries. Hitting `i' when on the second entry inserts a listing of directory=20 /toto/dir. Hitting `i' on the third entry inserts a listing of directory /titi. That's what I see, at least. But maybe you meant something else? > so I took this complication aside for now. > The code does handle the subdir alists, though. By "the subdir alists" I guess you mean `dired-subdir-alist'. ___ What I think you've done seems reasonable. It should probably be checked in various scenarios, however - at least a sanity check.