Nautilus displays invalid directory content after deleting

Bug #2022851 reported by Aleksey Tumbaev
218
This bug affects 41 people
Affects Status Importance Assigned to Milestone
GTK+
Fix Released
Unknown
gtk4 (Ubuntu)
Fix Released
Critical
Jeremy Bícha
Lunar
Fix Released
Critical
Jeremy Bícha

Bug Description

Impact
------
When files are deleted in Nautilus, they can still show up but in the wrong order. This can also happen if the files are rearranged.

This bug is marked Critical because it happen with gtk4 4.10.3+ds-0ubuntu1 in lunar-updates but not with 4.10.1+ds-2ubuntu1 which was originally released with Lunar.

Test Case
---------
Install the gtk4 update

1. Close the file browser windows if they are open
2. From a terminal, run these commands:
mkdir delete-test
cd delete-test
touch a b c d e f
3. Open the Nautilus file browser window
4. Navigate to the delete-test folder
5. Select the f file and press the Delete key to delete the file.

The file should be deleted and you should see only the files
a b c d e
in the current folder view

What Could Go Wrong
-------------------
This fix is included in gtk4 4.10.4 update so see the master bug LP: #2023031

Original Bug Report
-------------------
When I delete or reorganize files, they can be displayed wrong. After going to another directory and then back, everything displays properly.

ProblemType: Bug
DistroRelease: Ubuntu 23.04
Package: nautilus 1:44.0-1ubuntu2
ProcVersionSignature: Ubuntu 6.2.0-20.20-generic 6.2.6
Uname: Linux 6.2.0-20-generic x86_64
ApportVersion: 2.26.1-0ubuntu2
Architecture: amd64
CasperMD5CheckResult: pass
CurrentDesktop: ubuntu:GNOME
Date: Sun Jun 4 18:25:47 2023
GsettingsChanges:
 b'org.gnome.nautilus.preferences' b'migrated-gtk-settings' b'true'
 b'org.gnome.nautilus.window-state' b'initial-size' b'(725, 456)'
InstallationDate: Installed on 2022-07-22 (317 days ago)
InstallationMedia: Ubuntu 22.04 LTS "Jammy Jellyfish" - Release amd64 (20220419)
SourcePackage: nautilus
UpgradeStatus: No upgrade log present (probably fresh install)
usr_lib_nautilus:
 file-roller 43.0-1
 nautilus-extension-gnome-terminal 3.48.0-1ubuntu1

Revision history for this message
Aleksey Tumbaev (alekseytumbaev) wrote :
Revision history for this message
Launchpad Janitor (janitor) wrote :

Status changed to 'Confirmed' because the bug affects multiple users.

Changed in nautilus (Ubuntu):
status: New → Confirmed
Revision history for this message
Raymond van Rooijen (vanrooijenr) wrote (last edit ):

Same problem, just another explanation of the symptoms.

Whenever I delete files, or move files (move files from one nautilus window to another).

I find that any random file (usually\always the top file in the UI) is removed from the UI (or users view). The file that is removed from the users view is not the file meant to be moved or deleted.

Importantly however, the right files seem to still be removed and moved.
As stated above, changing directory before changing back (as a sort of "refresh"), shows all files were moved or deleted as expected.

Since I am horrible at explaining here is an short example.

bar.txt and foo.txt are located in home/ray/Documents/

I delete foo.txt, however now nautilus only shows foo.txt.

This leaves you to assume bar.txt was deleted.

(However a pop up comes up and says foo.txt has been, do you want to undo)

So if you then move back to home/ray/ and then move back to home/ray/Documents, you will find that indeed only bar.txt is displayed.
Hence foo.txt was deleted correctly.

Revision history for this message
Andreas Hasenack (ahasenack) wrote :

To illustrate this bug, in this video capture I:
- selected file3
- hit the delete key
- hit the F5 (refresh) key

Revision history for this message
Andreas Hasenack (ahasenack) wrote :

After some googling, maybe this is the fix?

https://gitlab.gnome.org/GNOME/gtk/-/merge_requests/5873

Revision history for this message
Sebastien Bacher (seb128) wrote :

Jeremy, could you check if there is a gtk point update coming or if we should perhaps SRU https://gitlab.gnome.org/GNOME/gtk/-/merge_requests/5873 ?

affects: nautilus (Ubuntu) → gtk4 (Ubuntu)
Changed in gtk4 (Ubuntu):
assignee: nobody → Jeremy Bícha (jbicha)
importance: Undecided → High
status: Confirmed → Fix Committed
Changed in gtk4 (Ubuntu):
status: Fix Committed → Triaged
summary: - Inappropriate files display
+ Nautilus displays invalid directory content after deleting
tags: added: udeng-614
Jeremy Bícha (jbicha)
Changed in gtk4 (Ubuntu):
status: Triaged → Fix Released
Changed in gtk4 (Ubuntu Lunar):
status: New → In Progress
importance: Undecided → High
assignee: nobody → Jeremy Bícha (jbicha)
Jeremy Bícha (jbicha)
description: updated
Jeremy Bícha (jbicha)
Changed in gtk4 (Ubuntu Lunar):
importance: High → Critical
Changed in gtk4 (Ubuntu):
importance: High → Critical
tags: added: regression-release
description: updated
Changed in gtk:
status: Unknown → Fix Released
Jeremy Bícha (jbicha)
tags: added: regression-update
removed: regression-release
Revision history for this message
Brian Murray (brian-murray) wrote : Please test proposed package

Hello Aleksey, or anyone else affected,

Accepted gtk4 into lunar-proposed. The package will build now and be available at https://launchpad.net/ubuntu/+source/gtk4/4.10.4+ds-0ubuntu1 in a few hours, and then in the -proposed repository.

Please help us by testing this new package. See https://wiki.ubuntu.com/Testing/EnableProposed for documentation on how to enable and use -proposed. Your feedback will aid us getting this update out to other Ubuntu users.

If this package fixes the bug for you, please add a comment to this bug, mentioning the version of the package you tested, what testing has been performed on the package and change the tag from verification-needed-lunar to verification-done-lunar. If it does not fix the bug for you, please add a comment stating that, and change the tag to verification-failed-lunar. In either case, without details of your testing we will not be able to proceed.

Further information regarding the verification process can be found at https://wiki.ubuntu.com/QATeam/PerformingSRUVerification . Thank you in advance for helping!

N.B. The updated package will be released to -updates after the bug(s) fixed by this package have been verified and the package has been in -proposed for a minimum of 7 days.

Changed in gtk4 (Ubuntu Lunar):
status: In Progress → Fix Committed
tags: added: verification-needed verification-needed-lunar
Revision history for this message
Ubuntu SRU Bot (ubuntu-sru-bot) wrote : Autopkgtest regression report (gtk4/4.10.4+ds-0ubuntu1)

All autopkgtests for the newly accepted gtk4 (4.10.4+ds-0ubuntu1) for lunar have finished running.
The following regressions have been reported in tests triggered by the package:

libreoffice/4:7.5.3-0ubuntu0.23.04.1 (armhf)

Please visit the excuses page listed below and investigate the failures, proceeding afterwards as per the StableReleaseUpdates policy regarding autopkgtest regressions [1].

https://people.canonical.com/~ubuntu-archive/proposed-migration/lunar/update_excuses.html#gtk4

[1] https://wiki.ubuntu.com/StableReleaseUpdates#Autopkgtest_Regressions

Thank you!

Revision history for this message
Luis Alvarado (luisalvarado) wrote :

If it helps, I enabled proposed, updated but the issue is still there. Maybe I needed to wait some more for the proposed repositories to show the correct packages?

Revision history for this message
Christians (script-vollbio) wrote :

While lunar-proposed fixes above issue for me, I have a new issue:

* selecting multiple files with left-mouse + CTRL does not work

(* selecting multiple files with left-mouse + SHIFT DOES work)

Revision history for this message
Jeremy Bícha (jbicha) wrote :

Luis, proposed updates work differently in Ubuntu 23.04 than in previous Ubuntu releases. We haven't updated our documentation yet to include that change.

I described a technique on my blog that can be used:

https://jeremy.bicha.net/2022/03/29/how-to-install-a-bunch-of-debs/

For step 2, you can do
pull-lp-debs gtk4 4.10.4+ds-0ubuntu1

You don't need Step 4.

Revision history for this message
Jeremy Bícha (jbicha) wrote :

Christians, I am unable to reproduce that issue. Ctrl+ left mouse click does work to select multiple files in Nautilus for me with gtk 4.10.4+ds-0ubuntu1.

I suggest you follow my suggestion in the previous comment to ensure that you have all the binaries of gtk4 instead of just libgtk-4-1. That may not fix your issue at all, but it's best to have all the parts of gtk4 at the same version anyway.

If you still have the issue. Please report a new bug using the command

ubuntu-bug libgtk-4-1

Then leave a comment here with the bug number.

Revision history for this message
JF Lim (jflim) wrote :

Unbuntu Lunar Arm64 device. Just to inform after manually upgraded to gtk4-4.10.4+ds-0ubuntu1 from the Lunar "Proposed" repo, it resolve:

"When files are deleted in Nautilus, they can still show up but in the wrong order. This can also happen if the files are rearranged."

Revision history for this message
Julien Olivier (julo) wrote :

I confirm that CTRL-Click is indeed broken in list view, but works in grid view.

Revision history for this message
Jeremy Bícha (jbicha) wrote :

Julien & Christians, I am unable to duplicate that issue if I use Nautilus 1:44.2.1-0ubuntu1 which is now also available in mantic-proposed.

It does look like that issue was another regression triggered by GTK 4.10.3 since it seems to work correctly with GTK 4.10.1 but not with 4.10.3 (4.10.4 doesn't help it either).

Revision history for this message
Jurgen Schellaert (jurgen-schellaert-j) wrote (last edit ):

My system is fully updated but I am still seeing the bug described in the opening post when my client system is manipulating files on my NFS server (which worked fine before and continues to do so when accessed from my openSuse Tumbleweed install). If i use the command line instead of copy-paste, the file view does get updated as it should.

To sum it up, if I move a file in nautilus to different directory:
* the moved files keeps showing in the original directory
* trying to move that file to the trash folder pops up an error message stating that the file is unknown
* refreshing the view (F5) makes the file vanish from the original directory

Revision history for this message
Jeremy Bícha (jbicha) wrote :

Jurgen, yes, if you do not yet have libgtk-4-1 4.10.4+ds-0ubuntu1 on Ubuntu 23.04, you will experience the bug described here. We are finishing testing the new version before it will be made available in updates for everyone.

Revision history for this message
Jeremy Bícha (jbicha) wrote :

I successfully completed the test case with gtk4 4.10.4+ds-0ubuntu1 on Ubuntu 23.04.

tags: added: verification-done verification-done-lunar
removed: verification-needed verification-needed-lunar
Revision history for this message
RonsonK (ronsonk) wrote :

Christians - I had the same CTRL-click issue in Nautilus. Upgrading to Nautilus 1:44.2.1-0ubuntu1 from Proposed solved that issue

Revision history for this message
JOD (jackal-kr) wrote :

Also confirm that Nautilus 44.2.1 fixes the issue. :)

Revision history for this message
Christians (script-vollbio) wrote :

My CTRL-click issue is fixed with

libnautilus-extension4=1:44.2.1-0ubuntu1
nautilus-data=1:44.2.1-0ubuntu1
nautilus=1:44.2.1-0ubuntu1

Tks RonsonK #19

Revision history for this message
Andreas Hasenack (ahasenack) wrote :

> It does look like that issue was another regression triggered by GTK 4.10.3 since it seems to work
> correctly with GTK 4.10.1 but not with 4.10.3 (4.10.4 doesn't help it either).

I confirmed that. Current lunar + updates shows the ctrl-click selection issue already, without updating to gtk 4.10.4 (udpates has 4.10.3).

Revision history for this message
Launchpad Janitor (janitor) wrote :

This bug was fixed in the package gtk4 - 4.10.4+ds-0ubuntu1

---------------
gtk4 (4.10.4+ds-0ubuntu1) lunar; urgency=medium

  * New upstream release (LP: #2023031)
    - Fix Nautilus showing wrong content when files are deleted or rearranged
      (LP: #2022851)
  * Drop cherry-picked patch for Mutter 44.1: applied in new release
  * Add patch to revert an unnecessary buildsystem change that affected our
    installed-tests patch

 -- Jeremy Bícha <email address hidden> Tue, 06 Jun 2023 08:40:17 -0400

Changed in gtk4 (Ubuntu Lunar):
status: Fix Committed → Fix Released
Revision history for this message
Andreas Hasenack (ahasenack) wrote : Update Released

The verification of the Stable Release Update for gtk4 has completed successfully and the package is now being released to -updates. Subsequently, the Ubuntu Stable Release Updates Team is being unsubscribed and will not receive messages about this bug report. In the event that you encounter a regression using the package from -updates please report a new bug using ubuntu-bug and tag the bug report regression-update so we can easily find any regressions.

Revision history for this message
Felix Moreno (info-justdust) wrote (last edit ):

I think control for selecting files in list mode is not fixed with latest updates. Maybe still not in main repository?
I have Nautillus 1:44.0-1ubuntu2

I enabled proposed for lunar and nothing happened... also i installed

sudo apt install ubuntu-dev-tools
pull-lp-debs gtk4 4.10.4+ds-0ubuntu1
and then...
sudo apt install --only-upgrade --mark-auto ./*.deb

And it says i already have latest version.

But still bug of control not fixed.

Revision history for this message
Frantisek Sklenar (frantisek-sklenar) wrote :

Thank you all, for me both bugs are fixed:
- selecting files in list mode
- nautilus displays invalid directory content after deleting

nautilus 1:44.2.1-0ubuntu1

Revision history for this message
Xargon (xargonwan) wrote :

I can confirm that on Lunar "vanilla" the file selection in list mode is still broken.

Revision history for this message
Jeremy Bícha (jbicha) wrote :

Felix and Xargon, you need nautilus 1:44.2.1-0ubuntu1 to fix that issue. It is rolling out in updates this week.

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.