bit-team / backintime

Back In Time - An easy-to-use backup tool for GNU Linux using rsync in the back
https://backintime.readthedocs.io
GNU General Public License v2.0
1.9k stars 175 forks source link

Individual files showing in "Backup Folders" section of places section of GUI. #1760

Closed fallingrock closed 1 week ago

fallingrock commented 2 weeks ago

Individual files showing in "Backup Folders" section of places section of GUI with the 'file list' showing 'This folder doesn't exist in the current selected snapshot'.

This appears to be related to a change made by @rafaelhdr for #1585

image

$ backintime --diagnostics
WARNING: Failed to connect to Udev serviceHelper daemon via D-Bus: org.freedesktop.DBus.Error.Spawn.ChildExited
WARNING: D-Bus message: Launch helper exited with unknown return code 1
WARNING: Udev-based profiles cannot be changed or checked due to Udev serviceHelper connection failure
{
    "backintime": {
        "name": "Back In Time",
        "version": "1.4.4-dev.ba1ff787",
        "running-as-root": false,
        "latest-config-version": 6,
        "local-config-file": "/home/UsernameReplaced/.config/backintime/config",
        "local-config-file-found": true,
        "global-config-file": "/etc/backintime/config",
        "global-config-file-found": false,
        "started-from": "/usr/share/backintime/common",
        "user-callback": "/home/UsernameReplaced/.config/backintime/user-callback",
        "keyring-supported": true
    },
    "host-setup": {
        "OS": {
            "/etc/os-release": "Ubuntu 22.04.4 LTS",
            "/etc/lsb-release": "DISTRIB_ID=Ubuntu\nDISTRIB_RELEASE=22.04\nDISTRIB_CODENAME=jammy\nDISTRIB_DESCRIPTION=\"Ubuntu 22.04.4 LTS\"\n",
            "/etc/debian_version": "bookworm/sid\n"
        },
        "platform": "Linux-6.5.0-35-generic-x86_64-with-glibc2.35",
        "system": "Linux #35~22.04.1-Ubuntu SMP PREEMPT_DYNAMIC Tue May  7 09:00:52 UTC 2",
        "display-system": "x11",
        "locale": "en_US, UTF-8",
        "PATH": "/home/UsernameReplaced/.local/bin:/home/UsernameReplaced/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/usr/local/games:/snap/bin:/snap/bin",
        "RSYNC_OLD_ARGS": "(not set)",
        "RSYNC_PROTECT_ARGS": "(not set)"
    },
    "python-setup": {
        "python": "3.10.12 main Nov 20 2023 15:14:05 CPython GCC 11.4.0",
        "python-executable": "/usr/bin/python3",
        "python-executable-symlink": true,
        "python-executable-resolved": "/usr/bin/python3.10",
        "sys.path": [
            "/usr/share/backintime/qt/plugins",
            "/usr/share/backintime/common/plugins",
            "/usr/share/backintime/plugins",
            "/usr/share/backintime/common",
            "/usr/lib/python310.zip",
            "/usr/lib/python3.10",
            "/usr/lib/python3.10/lib-dynload",
            "/usr/local/lib/python3.10/dist-packages",
            "/usr/lib/python3/dist-packages"
        ],
        "qt": {
            "Version": "PyQt 6.6.1 / Qt 6.6.1",
            "Theme": "breeze",
            "Theme Search Paths": [
                "/home/UsernameReplaced/.local/share/icons",
                "/var/lib/flatpak/exports/share/icons",
                "/usr/share/icons",
                "/var/lib/snapd/desktop/icons",
                ":/icons"
            ],
            "Fallback Theme": "breeze",
            "Fallback Search Paths": []
        }
    },
    "external-programs": {
        "rsync": {
            "version": "3.2.7",
            "protocol": "31.0",
            "capabilities": {
                "file_bits": 64,
                "inum_bits": 64,
                "timestamp_bits": 64,
                "long_int_bits": 64,
                "socketpairs": true,
                "symlinks": true,
                "symtimes": true,
                "hardlinks": true,
                "hardlink_specials": true,
                "hardlink_symlinks": true,
                "IPv6": true,
                "atimes": true,
                "batchfiles": true,
                "inplace": true,
                "append": true,
                "ACLs": true,
                "xattrs": true,
                "secluded_args": "optional",
                "iconv": true,
                "prealloc": true,
                "stop_at": true,
                "crtimes": false
            },
            "optimizations": {
                "SIMD_roll": true,
                "asm_roll": false,
                "openssl_crypto": true,
                "asm_MD5": false
            },
            "checksum_list": [
                "xxh128",
                "xxh3",
                "xxh64",
                "md5",
                "md4",
                "sha1",
                "none"
            ],
            "compress_list": [
                "zstd",
                "lz4",
                "zlibx",
                "zlib",
                "none"
            ],
            "daemon_auth_list": [
                "sha512",
                "sha256",
                "sha1",
                "md5",
                "md4"
            ]
        },
        "ssh": "OpenSSH_8.9p1 Ubuntu-3ubuntu0.7, OpenSSL 3.0.2 15 Mar 2022",
        "sshfs": "3.7.1",
        "encfs": "(no encfs)",
        "shell": "/bin/bash",
        "shell-version": "GNU bash, version 5.1.16(1)-release (x86_64-pc-linux-gnu)"
    }
}
fallingrock commented 2 weeks ago

Appears to be when the include_folders array is being built.

include_entries = [(os.path.join(base, f), 0) for f in folders]

buhtz commented 2 weeks ago

Hello David,

Thank you for taking the time to report the bug and providing the details. I appreciate your feedback.

I slightly remember that I touched that part of the code some weeks ago. Might have introduced a new bug. I assuming a solution is simple. The variable folders should contain folders only of course but doesn't.

Would you like to provide a fix and open a Pull Request?

Best regards,

fallingrock commented 2 weeks ago

@buhtz I'll take a stab at it.

buhtz commented 1 week ago

Fixed via 085fb6b