<?xml version="1.0" encoding="UTF-8" standalone="yes" ?>
<!DOCTYPE bugzilla SYSTEM "https://bugs.kde.org/page.cgi?id=bugzilla.dtd">

<bugzilla version="5.0.6"
          urlbase="https://bugs.kde.org/"
          
          maintainer="sysadmin@kde.org"
>

    <bug>
          <bug_id>423501</bug_id>
          
          <creation_ts>2020-06-25 13:55:33 +0000</creation_ts>
          <short_desc>insertSingleFileBasicData ignorant of mounted remote file systems and causing gui blocks</short_desc>
          <delta_ts>2025-05-29 21:50:50 +0000</delta_ts>
          <reporter_accessible>1</reporter_accessible>
          <cclist_accessible>1</cclist_accessible>
          <classification_id>3</classification_id>
          <classification>Frameworks and Libraries</classification>
          <product>baloo-widgets</product>
          <component>general</component>
          <version>unspecified</version>
          <rep_platform>Other</rep_platform>
          <op_sys>Linux</op_sys>
          <bug_status>RESOLVED</bug_status>
          <resolution>FIXED</resolution>
          
          <see_also>https://bugs.kde.org/show_bug.cgi?id=178678</see_also>
          <bug_file_loc></bug_file_loc>
          <status_whiteboard></status_whiteboard>
          <keywords>efficiency-and-performance</keywords>
          <priority>NOR</priority>
          <bug_severity>normal</bug_severity>
          <target_milestone>---</target_milestone>
          
          <blocked>504984</blocked>
          <everconfirmed>1</everconfirmed>
          <reporter name="Harald Sitter">sitter</reporter>
          <assigned_to name="Stefan Brüns">stefan.bruens</assigned_to>
          <cc>bharadwaj.raju777</cc>
    
    <cc>nate</cc>
    
    <cc>postix</cc>
    
    <cc>tagwerk19</cc>
          
          <cf_commitlink>https://invent.kde.org/libraries/baloo-widgets/commit/7aeedc4492e7eb368261f5de9314a96a18cc357a</cf_commitlink>
          <cf_versionfixedin></cf_versionfixedin>
          <cf_sentryurl></cf_sentryurl>
          <votes>0</votes>

      

      

      

          <comment_sort_order>oldest_to_newest</comment_sort_order>  
          <long_desc isprivate="0" >
    <commentid>1939755</commentid>
    <comment_count>0</comment_count>
    <who name="Harald Sitter">sitter</who>
    <bug_when>2020-06-25 13:55:33 +0000</bug_when>
    <thetext>When browsing remote mounted file systems dolphin can intermittently lock up on subdirectory counting. This appears primarily the case because the insertSingleFileBasicData function is checking if an url has a local path, but a local path doesn&apos;t mean it&apos;s a local disk

```
          bool isSizeUnknown = !item.isLocalFile();
          if (!isSizeUnknown) {
              const QPair&lt;int, int&gt; counts = subDirectoriesCount(item.url().path());
```

I&apos;m not super sure what to do about it, possibly simply checking item-&gt;isSlow().

Along a similar note `static bool isDirectoryMounted` in KFileItem seems also relevant for this.

#0  __GI___getdents64 (fd=29, buf=buf@entry=0x31e27f0, nbytes=&lt;optimized out&gt;) at ../sysdeps/unix/sysv/linux/getdents64.c:32
#1  0x00007f0766355365 in __GI___readdir64 (dirp=0x31e27c0) at ../sysdeps/posix/readdir.c:65
#2  0x00007f076851cfb7 in Baloo::FileMetaDataProvider::subDirectoriesCount (path=...)
    at /home/me/src/baloo-widgets/src/filemetadataprovider.cpp:546
#3  0x00007f076851c565 in Baloo::FileMetaDataProvider::insertSingleFileBasicData (this=0x29a51a0)
    at /home/me/src/baloo-widgets/src/filemetadataprovider.cpp:159
#4  0x00007f076851e4ff in Baloo::FileMetaDataProvider::setFileItem (this=0x29a51a0)
    at /home/me/src/baloo-widgets/src/filemetadataprovider.cpp:336
#5  0x00007f076851eae7 in Baloo::FileMetaDataProvider::setItems (this=0x29a51a0, items=...)
    at /home/me/src/baloo-widgets/src/filemetadataprovider.cpp:408
#6  0x00007f07685163cc in Baloo::FileMetaDataWidget::setItems (this=0x29a52f0, items=...)
    at /home/me/src/baloo-widgets/src/filemetadatawidget.cpp:297
#7  0x00007f076908f9e7 in InformationPanelContent::refreshMetaData (this=0x28a89a0)
    at /home/me/src/dolphin/src/panels/information/informationpanelcontent.cpp:299</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>2100270</commentid>
    <comment_count>1</comment_count>
    <who name="Bharadwaj Raju">bharadwaj.raju777</who>
    <bug_when>2022-02-02 08:45:46 +0000</bug_when>
    <thetext>https://invent.kde.org/libraries/baloo-widgets/-/merge_requests/14</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>2101066</commentid>
    <comment_count>2</comment_count>
    <who name="Méven Car">meven.car</who>
    <bug_when>2022-02-04 19:35:48 +0000</bug_when>
    <thetext>Git commit 7aeedc4492e7eb368261f5de9314a96a18cc357a by Méven Car, on behalf of Bharadwaj Raju (away; can&apos;t respond).
Committed on 04/02/2022 at 19:35.
Pushed by meven into branch &apos;master&apos;.

Skip slow files

Skips files which are slow according to `KFileItem::isSlow()`. Makes browsing local mounts of remote filesystems (like with rclone) much faster.

M  +4    -4    src/filemetadataprovider.cpp

https://invent.kde.org/libraries/baloo-widgets/commit/7aeedc4492e7eb368261f5de9314a96a18cc357a</thetext>
  </long_desc>
      
      

    </bug>

</bugzilla>