You are not logged in.
Hello All,
I use kdiff3 quite frequently, usually in combination with git (git difftool -t kdiff3). This has stopped working
for me recently, presumably after an archlinux update. It is not just in combination with git. Also attempting
to diff two random text files doing kdiff3 FILE1 FILE2 fails. It opens, does not display the contents for the
file but instead shows an error window saying 'Opening of these files failed: <name of file> Opening
<name of file> failed. Unknown error'.
Anyone any idea?
Kind Regards,
Chris
Offline
Worksforme™
Your system is up to date/no partial updates? Particularly kio is going to be relevant. Do you see any other message from a terminal run?
Online
Hello V1del,
Yes, I update the system quite regularly (pacman -Syu). Just did an update to check and I still have the problem.
kio is at 6.1.0. Terminal does not say anything particular.
[chrisd@chrispc ~]$ kdiff3 bla TODO
org.kde.kdiff3: Loading A: "/home/chrisd/bla"
org.kde.kdiff3: Loading B: "/home/chrisd/TODO"
I also tried on another PC and there kdiff3 works, so it does seem to be something particular about this
machine.
O well, it is not that important, I can also just kompare.
Kind Regards,
Chris
Offline
error window saying 'Opening of these files failed: <name of file> Opening <name of file> failed. Unknown error'.
strace -o /tmp/kdiff.strace -f -tt kdiff3 bla TODO
Then check/upload the strace.
Offline
Hello Seth,
I uploaded the strace: http://0x0.st/X8K8.txt .
Note that after the error appeared I pressed Ctrl-C to end kdiff3. This is also visible at the
end of the strace.
Kind Regards,
Chris
Offline
23386 14:11:21.012700 access("/home/chrisd/bla", F_OK) = 0
23386 14:11:21.012791 statx(AT_FDCWD, "/home/chrisd/bla", AT_STATX_SYNC_AS_STAT|AT_SYMLINK_NOFOLLOW|AT_NO_AUTOMOUNT, STATX_ALL, {stx_mask=STATX_ALL|STATX_MNT_ID, stx_attributes=0, stx_mode=S_IFREG|0644, stx_size=5, ...}) = 0
23386 14:11:21.012858 access("/home/chrisd/bla", W_OK) = 0
23386 14:11:21.012881 access("/home/chrisd/bla", R_OK) = 0
23386 14:11:21.012905 access("/home/chrisd/bla", X_OK) = -1 EACCES (Permission denied)
23386 14:11:21.013011 access("/home/chrisd/TODO", F_OK) = 0
23386 14:11:21.013092 statx(AT_FDCWD, "/home/chrisd/TODO", AT_STATX_SYNC_AS_STAT|AT_SYMLINK_NOFOLLOW|AT_NO_AUTOMOUNT, STATX_ALL, {stx_mask=STATX_ALL|STATX_MNT_ID, stx_attributes=0, stx_mode=S_IFREG|0644, stx_size=32932, ...}) = 0
23386 14:11:21.013148 access("/home/chrisd/TODO", W_OK) = 0
23386 14:11:21.013170 access("/home/chrisd/TODO", R_OK) = 0
23386 14:11:21.013192 access("/home/chrisd/TODO", X_OK) = -1 EACCES (Permission denied)
23386 14:11:21.143653 access("/home/chrisd/bla", F_OK) = 0
23386 14:11:21.143825 statx(AT_FDCWD, "/home/chrisd/bla", AT_STATX_SYNC_AS_STAT|AT_SYMLINK_NOFOLLOW|AT_NO_AUTOMOUNT, STATX_ALL, {stx_mask=STATX_ALL|STATX_MNT_ID, stx_attributes=0, stx_mode=S_IFREG|0644, stx_size=5, ...}) = 0
23386 14:11:21.143944 access("/home/chrisd/bla", W_OK) = 0
23386 14:11:21.143978 access("/home/chrisd/bla", R_OK) = 0
23386 14:11:21.144026 access("/home/chrisd/bla", X_OK) = -1 EACCES (Permission denied)
23386 14:11:21.144235 access("/home/chrisd/TODO", F_OK) = 0
23386 14:11:21.144424 statx(AT_FDCWD, "/home/chrisd/TODO", AT_STATX_SYNC_AS_STAT|AT_SYMLINK_NOFOLLOW|AT_NO_AUTOMOUNT, STATX_ALL, {stx_mask=STATX_ALL|STATX_MNT_ID, stx_attributes=0, stx_mode=S_IFREG|0644, stx_size=32932, ...}) = 0
23386 14:11:21.144513 access("/home/chrisd/TODO", W_OK) = 0
23386 14:11:21.144540 access("/home/chrisd/TODO", R_OK) = 0
23386 14:11:21.144564 access("/home/chrisd/TODO", X_OK) = -1 EACCES (Permission denied)
23386 14:11:21.196014 openat(AT_FDCWD, "/home/chrisd/bla", O_RDONLY|O_CLOEXEC) = 17
23386 14:11:21.210404 access("/home/chrisd/bla", F_OK) = 0
23386 14:11:21.210505 statx(AT_FDCWD, "/home/chrisd/bla", AT_STATX_SYNC_AS_STAT|AT_SYMLINK_NOFOLLOW|AT_NO_AUTOMOUNT, STATX_ALL, {stx_mask=STATX_ALL|STATX_MNT_ID, stx_attributes=0, stx_mode=S_IFREG|0644, stx_size=5, ...}) = 0
23386 14:11:21.210593 access("/home/chrisd/bla", W_OK) = 0
23386 14:11:21.210629 access("/home/chrisd/bla", R_OK) = 0
23386 14:11:21.210690 access("/home/chrisd/bla", X_OK) = -1 EACCES (Permission denied)
23386 14:11:21.210726 openat(AT_FDCWD, "/home/chrisd/bla", O_RDONLY|O_CLOEXEC) = 17
23386 14:11:21.219909 openat(AT_FDCWD, "/home/chrisd/TODO", O_RDONLY|O_CLOEXEC) = 17
23386 14:11:21.220225 access("/home/chrisd/TODO", F_OK <unfinished ...>
23386 14:11:21.220325 statx(AT_FDCWD, "/home/chrisd/TODO", AT_STATX_SYNC_AS_STAT|AT_SYMLINK_NOFOLLOW|AT_NO_AUTOMOUNT, STATX_ALL, {stx_mask=STATX_ALL|STATX_MNT_ID, stx_attributes=0, stx_mode=S_IFREG|0644, stx_size=32932, ...}) = 0
23386 14:11:21.220386 access("/home/chrisd/TODO", W_OK) = 0
23386 14:11:21.220411 access("/home/chrisd/TODO", R_OK) = 0
23386 14:11:21.220434 access("/home/chrisd/TODO", X_OK) = -1 EACCES (Permission denied)
23386 14:11:21.220464 openat(AT_FDCWD, "/home/chrisd/TODO", O_RDONLY|O_CLOEXEC) = 17
It tries to access the files r,w and x but ultimately actually opens them and also
23386 14:11:21.196129 read(17, "ziep\n", 16384) = 5
23386 14:11:21.209843 read(17, "", 16379) = 0
23386 14:11:21.210879 read(17, "ziep\n", 16384) = 5
23386 14:11:21.210905 read(17, "", 16379) = 0
23386 14:11:21.220010 read(17, "\n- teams aanzetten\n- schedule me"..., 16384) = 16384
23386 14:11:21.220565 read(17, "\n- teams aanzetten\n- schedule me"..., 32932) = 32932
reads them.
Going by
23386 14:11:21.220386 access("/home/chrisd/TODO", W_OK) = 0
23386 14:11:21.220411 access("/home/chrisd/TODO", R_OK) = 0
23386 14:11:21.220434 access("/home/chrisd/TODO", X_OK) = -1 EACCES (Permission denied)
23386 14:11:21.220464 openat(AT_FDCWD, "/home/chrisd/TODO", O_RDONLY|O_CLOEXEC) = 17
23386 14:11:21.220491 statx(17, "", AT_STATX_SYNC_AS_STAT|AT_NO_AUTOMOUNT|AT_EMPTY_PATH, STATX_ALL, {stx_mask=STATX_ALL|STATX_MNT_ID, stx_attributes=0, stx_mode=S_IFREG|0644, stx_size=32932, ...}) = 0
23386 14:11:21.220536 statx(17, "", AT_STATX_SYNC_AS_STAT|AT_NO_AUTOMOUNT|AT_EMPTY_PATH, STATX_ALL, {stx_mask=STATX_ALL|STATX_MNT_ID, stx_attributes=0, stx_mode=S_IFREG|0644, stx_size=32932, ...}) = 0
23386 14:11:21.220565 read(17, "\n- teams aanzetten\n- schedule me"..., 32932) = 32932
23386 14:11:21.220601 close(17) = 0
23386 14:11:21.222405 write(4, "\1\0\0\0\0\0\0\0", 8) = 8
23386 14:11:21.222485 write(4, "\1\0\0\0\0\0\0\0", 8) = 8
23386 14:11:21.222540 write(4, "\1\0\0\0\0\0\0\0", 8) = 8
23386 14:11:21.222950 poll([{fd=6, events=POLLIN|POLLOUT}], 1, -1) = 1 ([{fd=6, revents=POLLOUT}])
23386 14:11:21.222991 writev(6, [{iov_base="\27\0\2\0\333\1\0\0", iov_len=8}], 1) = 8
23386 14:11:21.223025 futex(0x7fff4b8bc088, FUTEX_WAIT_BITSET_PRIVATE|FUTEX_CLOCK_REALTIME, 0, NULL, FUTEX_BITSET_MATCH_ANY <unfinished ...>
23388 14:11:21.226282 <... poll resumed>) = 1 ([{fd=6, revents=POLLIN}])
23388 14:11:21.226351 recvmsg(6, {msg_name=NULL, msg_namelen=0, msg_iov=[{iov_base="\1\0f\2\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0", iov_len=4096}], msg_iovlen=1, msg_controllen=0, msg_flags=0}, 0) = 32
23388 14:11:21.226447 futex(0x7fff4b8bc088, FUTEX_WAKE_PRIVATE, 1 <unfinished ...>
23386 14:11:21.226504 <... futex resumed>) = 0
23388 14:11:21.226518 <... futex resumed>) = 1
23386 14:11:21.226541 futex(0x5bd7dba44f78, FUTEX_WAIT_PRIVATE, 2, NULL <unfinished ...>
23388 14:11:21.226713 futex(0x5bd7dba44f78, FUTEX_WAKE_PRIVATE, 1 <unfinished ...>
23386 14:11:21.226729 <... futex resumed>) = 0
23388 14:11:21.226736 <... futex resumed>) = 1
23386 14:11:21.226743 futex(0x5bd7dba44f78, FUTEX_WAKE_PRIVATE, 1 <unfinished ...>
23388 14:11:21.226750 poll([{fd=6, events=POLLIN}], 1, -1 <unfinished ...>
23386 14:11:21.226762 <... futex resumed>) = 0
23386 14:11:21.226783 poll([{fd=6, events=POLLIN|POLLOUT}], 1, -1) = 1 ([{fd=6, revents=POLLOUT}])
23386 14:11:21.226813 writev(6, [{iov_base="\27\0\2\0\333\1\0\0", iov_len=8}], 1) = 8
23386 14:11:21.226843 futex(0x7fff4b8bbef8, FUTEX_WAIT_BITSET_PRIVATE|FUTEX_CLOCK_REALTIME, 0, NULL, FUTEX_BITSET_MATCH_ANY <unfinished ...>
23388 14:11:21.229136 <... poll resumed>) = 1 ([{fd=6, revents=POLLIN}])
23388 14:11:21.229162 recvmsg(6, {msg_name=NULL, msg_namelen=0, msg_iov=[{iov_base="\1\0g\2\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0", iov_len=4096}], msg_iovlen=1, msg_controllen=0, msg_flags=0}, 0) = 32
23388 14:11:21.229216 futex(0x7fff4b8bbef8, FUTEX_WAKE_PRIVATE, 1) = 1
23386 14:11:21.229238 <... futex resumed>) = 0
23388 14:11:21.229248 poll([{fd=6, events=POLLIN}], 1, -1 <unfinished ...>
23386 14:11:21.229260 futex(0x5bd7dba44f78, FUTEX_WAKE_PRIVATE, 1) = 0
23386 14:11:21.229334 poll([{fd=6, events=POLLIN|POLLOUT}], 1, -1) = 1 ([{fd=6, revents=POLLOUT}])
23386 14:11:21.229368 writev(6, [{iov_base="\27\0\2\0\333\1\0\0", iov_len=8}], 1) = 8
23386 14:11:21.229426 futex(0x7fff4b8bbef8, FUTEX_WAIT_BITSET_PRIVATE|FUTEX_CLOCK_REALTIME, 0, NULL, FUTEX_BITSET_MATCH_ANY <unfinished ...>
23388 14:11:21.229435 <... poll resumed>) = 1 ([{fd=6, revents=POLLIN}])
23388 14:11:21.229454 recvmsg(6, {msg_name=NULL, msg_namelen=0, msg_iov=[{iov_base="\1\0h\2\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0", iov_len=4096}], msg_iovlen=1, msg_controllen=0, msg_flags=0}, 0) = 32
23388 14:11:21.229495 futex(0x7fff4b8bbef8, FUTEX_WAKE_PRIVATE, 1) = 1
23386 14:11:21.229512 <... futex resumed>) = 0
23388 14:11:21.229519 poll([{fd=6, events=POLLIN}], 1, -1 <unfinished ...>
23386 14:11:21.229529 futex(0x5bd7dba44f78, FUTEX_WAKE_PRIVATE, 1) = 0
23386 14:11:21.229711 write(4, "\1\0\0\0\0\0\0\0", 8) = 8
23386 14:11:21.229748 write(4, "\1\0\0\0\0\0\0\0", 8) = 8
23386 14:11:21.229775 write(4, "\1\0\0\0\0\0\0\0", 8) = 8
23386 14:11:21.229812 write(4, "\1\0\0\0\0\0\0\0", 8) = 8
23386 14:11:21.231934 statx(AT_FDCWD, "/usr/share/icons/breeze", AT_STATX_SYNC_AS_STAT|AT_NO_AUTOMOUNT, STATX_ALL, 0x7fff4b8bb620) = -1 ENOENT (No such file or directory)
23386 14:11:21.231982 statx(AT_FDCWD, "/usr/share/icons/breeze/index.theme", AT_STATX_SYNC_AS_STAT|AT_SYMLINK_NOFOLLOW|AT_NO_AUTOMOUNT, STATX_ALL, 0x7fff4b8bb5c0) = -1 ENOENT (No such file or directory)
23386 14:11:21.233437 statx(AT_FDCWD, "/usr/share/icons/breeze", AT_STATX_SYNC_AS_STAT|AT_NO_AUTOMOUNT, STATX_ALL, 0x7fff4b8bb330) = -1 ENOENT (No such file or directory)
23386 14:11:21.233490 statx(AT_FDCWD, "/usr/share/icons/breeze/index.theme", AT_STATX_SYNC_AS_STAT|AT_SYMLINK_NOFOLLOW|AT_NO_AUTOMOUNT, STATX_ALL, 0x7fff4b8bb2d0) = -1 ENOENT (No such file or directory)
23386 14:11:21.233550 statx(AT_FDCWD, "/usr/share/icons/breeze", AT_STATX_SYNC_AS_STAT|AT_NO_AUTOMOUNT, STATX_ALL, 0x7fff4b8bb910) = -1 ENOENT (No such file or directory)
23386 14:11:21.233584 statx(AT_FDCWD, "/usr/share/icons/breeze/index.theme", AT_STATX_SYNC_AS_STAT|AT_SYMLINK_NOFOLLOW|AT_NO_AUTOMOUNT, STATX_ALL, 0x7fff4b8bb8b0) = -1 ENOENT (No such file or directory)
23386 14:11:21.233623 access("/usr/share/pixmaps/dialog-error.png", F_OK) = -1 ENOENT (No such file or directory)
23386 14:11:21.233663 access("/usr/share/pixmaps/dialog-error.xpm", F_OK) = -1 ENOENT (No such file or directory)
23386 14:11:21.233689 access("/usr/share/pixmaps/dialog-error.svg", F_OK) = -1 ENOENT (No such file or directory)
and assuming the tail of that is to show you the error dialog, this seems a complete false positive.
The file contents seem to be vastly different, have you tried comparing two files where one is actually just a slight deviation of the other?
Offline
Hello Seth,
Yes, usually I use kdiff3 on files that only differ in a few places. But I just retried that again. It also
displays the error and not the files in that case.
The whole thing sounds like it reads the data correctly but for some reason, incorrectly, decides
that it failed reading the data and therefore displays the error instead of the content of the files.
Kind Regards,
Chris
Offline
Except
Worksforme™
so there must be some significant difference.
Wild guess
localectl
locale
locale -a
Also
23386 14:11:21.018713 access("/home/chrisd/.config/kdiff3rc", F_OK) = 0
not sure what a diff needs a config for, but try to move that away…
Offline
------------------ EDIT 2024-06-19 14:33 UTC ------------------
The issue is still happening occasionally with longer filenames / paths, same symptomatic as before. But I can no longer get it to reproduce with kdiff3 /tmp/a /tmp/b /tmp/c
Error is no longer occurring all the time. Some diffs work fine without an error, some don't.
------------------ EDIT 2024-06-19 14:30 UTC ------------------
*just* as I finished testing this, I was doing a system upgrade (apt-upgrade) after seeing new packages when installing strace - and with today's system upgrade, the issue is finally gone and kdiff3 works as intended again.
Here is my relevant /var/log/apt/history.log: http://0x0.st/XT2a.log
As you can see, the latest system update was only 2 days old, so that today's update (that fixed the issue? Or was it the system reboot I did after deleting .config/kdiff3rc?) only installed relatively few changes - but it did bring a kernel update to version 6.8.12:
$ uname -a
Linux computer 6.8.12-amd64 #1 SMP PREEMPT_DYNAMIC Debian 6.8.12-1 (2024-05-31) x86_64 GNU/Linux
The version of kdiff3 is unchanged at 1.11.1 (64 bit)
------------------ ORIGINAL POST BELOW ------------------
I would like to add a "can reproduce" to this issue - I am having the exact(?) same problem on debian since my upgrade to trixie a few months ago
$ uname -a
Linux computer 6.7.12-amd64 #1 SMP PREEMPT_DYNAMIC Debian 6.7.12-1 (2024-04-24) x86_64 GNU/Linux
$ kdiff3 --version
kdiff3 1.11.1 (64 bit)
Prior to submitting this report, and prior to getting the reported results, I deleted ~/.config/kdiff3rc
I performed an strace as recommended by seth 2024-05-07 08:29:42
strace -o /tmp/kdiff.strace -f -tt kdiff3 a b c
Resulting in this tracefile: http://0x0.st/XTew.strace
$ kdiff3 a b c
starts kdiff3 with the error message:
File open error -- KDiff3
Opening of these files failed:
- /tmp/a
Opening /tmp/a failed. Uknown error
- /tmp/b
Opening /tmp/b failed. Uknown error
Information I can add to the original issue description:
The error about file /tmp/a is not always reproducible, most of the time it only complains about /tmp/b.
I have never seen the error mentioning file /tmp/c.
Confirming the error with "OK" opens "Dialog -- KDiff3" which allows to select files to open and pre-selects the command line arguments with full path
A (Base): /tmp/a
B: /tmp/b
C: (Optional): /tmp/c
Confirming that dialog unchanged with "OK" succeeds in opening the three files in kdiff3 as expected.
Invoking kdiff3 with absolute paths like so
kdiff3 /tmp/a /tmp/b /tmp/c
exhibits the exact same error.
Additional info:
$ localectl
System Locale: LANG=en_US.UTF-8
LANGUAGE=en_US:en
LC_TIME=custom.UTF-8
VC Keymap: (unset)
X11 Layout: us
X11 Model: pc105
$ locale
LANG=en_US.UTF-8
LANGUAGE=en_US:en
LC_CTYPE="en_US.UTF-8"
LC_NUMERIC="en_US.UTF-8"
LC_TIME=custom.UTF-8
LC_COLLATE="en_US.UTF-8"
LC_MONETARY="en_US.UTF-8"
LC_MESSAGES="en_US.UTF-8"
LC_PAPER="en_US.UTF-8"
LC_NAME="en_US.UTF-8"
LC_ADDRESS="en_US.UTF-8"
LC_TELEPHONE="en_US.UTF-8"
LC_MEASUREMENT="en_US.UTF-8"
LC_IDENTIFICATION="en_US.UTF-8"
LC_ALL=
$ locale -a
C
custom
custom.utf8
C.utf8
en_US.utf8
POSIX
Last edited by aral (2024-06-19 14:34:26)
Offline
Edit this is from the above orignals post:
12746 15:16:03.049059 openat(AT_FDCWD, "/tmp/a", O_RDONLY|O_CLOEXEC) = 21
12746 15:16:03.049487 read(21, "Hello World!\n", 16384) = 13
12746 15:16:03.050366 read(21, "", 16371) = 0
12746 15:16:03.051178 openat(AT_FDCWD, "/tmp/a", O_RDONLY|O_CLOEXEC) = 21
12746 15:16:03.051362 read(21, "Hello World!\n", 16384) = 13
12746 15:16:03.051395 read(21, "", 16371) = 0
12746 15:16:03.052367 openat(AT_FDCWD, "/tmp/b", O_RDONLY|O_CLOEXEC) = 21
12746 15:16:03.052478 read(21, "Hello Planet!\n", 16384) = 14
12746 15:16:03.052536 read(21, "", 16370) = 0
12746 15:16:03.053209 openat(AT_FDCWD, "/tmp/b", O_RDONLY|O_CLOEXEC) = 21
12746 15:16:03.053325 read(21, "Hello Planet!\n", 16384) = 14
12746 15:16:03.053673 read(21, "", 16370) = 0
12746 15:16:03.056382 openat(AT_FDCWD, "/tmp/c", O_RDONLY|O_CLOEXEC) = 21
12746 15:16:03.057671 read(21, "Hello Galaxy!\n", 16384) = 14
12746 15:16:03.057724 read(21, "", 16370) = 0
12746 15:16:03.058881 <... openat resumed>) = 21
12746 15:16:03.059079 read(21, "Hello Galaxy!\n", 16384) = 14
12746 15:16:03.059246 read(21, "", 16370) = 0
locale looks unsupicious, but kdiff3rc still shows up in the strace?
=> https://bugs.kde.org/buglist.cgi?compon … esolution=---
Last edited by seth (2024-06-19 15:25:00)
Offline
locale looks unsupicious, but kdiff3rc still shows up in the strace?
If by kdiff3rc you refer to the file in .config - it appears to get re-created (as I would expect) on every start of kdiff3?
Is there a specific bug you wanted to point me to, or was the => arrow suggesting I should open a bug report?
Cheers,
Lars
Offline
I should open a bug report
There's no indication in either strace that "Opening /tmp/a failed. Uknown error" so there there's a bug in kdiff's logic that has to be identified and fixed.
Offline
I should open a bug report
There's no indication in either strace that "Opening /tmp/a failed. Uknown error" so there there's a bug in kdiff's logic that has to be identified and fixed.
One of the next days I'll try to open a bug report - I've been quite busy & just wanted to add something to the analysis here.
Offline
Still happening to me, but I add that when trying to open the very same files that failed in the GUI, they open correctly.
Offline
1.11.5 contains a fix for one cause of this error. This has was released within the last week. Still getting reports of this at least on windows. Its not imminently clear my the gui doesn't trigger the issue. I have been test with direct command line use to see there's another reproducible bug there.
Last edited by iameverywhere (2024-11-17 17:32:07)
Offline