Summary: | Error opening files for comparison from Visual Studio/Command Line | ||
---|---|---|---|
Product: | [Applications] kdiff3 | Reporter: | Sven Moderow <s.moderow> |
Component: | application | Assignee: | michael <reeves.87> |
Status: | RESOLVED FIXED | ||
Severity: | normal | CC: | a-spid3r, cfis, chuanyu.wang, elydgolden, jweems, kde-bugs, kde, zidad |
Priority: | NOR | ||
Version: | 1.11.0 | ||
Target Milestone: | --- | ||
Platform: | Microsoft Windows | ||
OS: | Microsoft Windows | ||
Latest Commit: | Version Fixed In: | 1.12 | |
Sentry Crash Report: | |||
Attachments: |
error shown when opening kdiff3 from Visual Studio
kdiff3 adds special characters example on MacOS No Horizontal Scroll Bars Error message context menu |
In addition, merging files automatically or manually sometime corrupt the files with strange special character at the beginning and the end of line. Created attachment 169871 [details]
kdiff3 adds special characters
"ZWNBSP" characters!?
Same error and behavior within Git Extension (v4.2.1). I have installed kdiff3 version 1.11.0. I tried downgrading but that worsened things and KDiff did either throw that exception or was not opening at all. So my final conclusion was to uninstall and use another tool. (In reply to Sven Moderow from comment #4) > I tried downgrading but that worsened things and KDiff did either throw that > exception or was not opening at all. So my final conclusion was to uninstall > and use another tool. Just FYI, I downgraded to version 1.10.7, it works well with Git Extension. But I have to admit that it takes dozens of seconds to launch dkiff3 (OS: windows 11, CPU: i7-1270P). The odd characters were the result of an encoding detection problem that was introduced in 1.11. Whatever is going with the git extention launch does not seem to happen under arch-linux. Going try and setup a test environment under windows. Created attachment 171000 [details]
example on MacOS
I have the same problem on MacOS with the latest KDIFF3 release, it corrupts my files on every merge
Please use a separate bug for the file corruption issue. This is solely about the error when opening. Just tagged 1.11.2 if that does not fix the document corruption then a new bug will needed for that. The error doesn't reproduce on my setup under linux. Maybe a windows specific thing. How is git setup of your machine? git config: [diff] tool = vsdiffmerge colorMoved = zebra colorMovedWS = allow-indentation-change [merge] tool = vsdiffmerge guitool = vsdiffmerge colorMoved = zebra colorMovedWS = allow-indentation-change conflictstyle = diff3 [difftool] prompt = true keepBackup = false [mergetool] prompt = true keepBackup = false trustExitCode = true [fetch] prune = true [gui] recentrepo = C:/Source/Repos/xyz [difftool "vsdiffmerge"] cmd = \"C:\\Program Files\\Microsoft Visual Studio\\2022\\Professional\\Common7\\IDE\\CommonExtensions\\Microsoft\\TeamFoundation\\Team Explorer\\vsdiffmerge.exe\" \"$LOCAL\" \"$REMOTE\" //t keepBackup = false [mergetool "vsdiffmerge"] cmd = \"C:\\Program Files\\Microsoft Visual Studio\\2022\\Professional\\Common7\\IDE\\CommonExtensions\\Microsoft\\TeamFoundation\\Team Explorer\\vsdiffmerge.exe\" \"$REMOTE\" \"$LOCAL\" \"$BASE\" \"$MERGED\" //m keepBackup = false trustExitCode = true [difftool "kdiff3"] cmd = \"C:\\Users\\xyz\\AppData\\Local\\KDiff3\\bin\\kdiff3.exe\" \"$LOCAL\" \"$REMOTE\" [mergetool "kdiff3"] cmd = \"C:\\Users\\xyz\\AppData\\Local\\KDiff3\\bin\\kdiff3.exe\" \"$BASE\" \"$REMOTE\" \"$LOCAL\" -o \"$MERGED\" (In reply to zidad from comment #7) > Created attachment 171000 [details] > example on MacOS > > I have the same problem on MacOS with the latest KDIFF3 release, it corrupts > my files on every merge New ticket for special characters error: https://bugs.kde.org/show_bug.cgi?id=489538 Confirming the bug on Arch Linux, it has also been reported https://bbs.archlinux.org/viewtopic.php?id=295528 . A simple "kdiff3 Makefile Makefile" will show the error, and pressing "OK" when the prepopulated files then opens everything. The interesting part: When I press Ctrl + C immediately and then restart kdiff3 the same way, it does find the files. I am about to compare the straces of these two events now. Note, I used kdiff3 1.11.1 . From comparing the strace, I could not find out the issue. (In reply to michael from comment #9) > Just tagged 1.11.2 if that does not fix the document corruption then a new > bug will needed for that. The error doesn't reproduce on my setup under > linux. Maybe a windows specific thing. How is git setup of your machine? The issue is the same in version 1.11.2. I tried it with Windows 11 + GitExtension 4.2.1 [difftool "kdiff3"] cmd = \"C:/Program Files/KDiff3/bin/kdiff3.exe\" \"$LOCAL\" \"$REMOTE\" path = C:/Program Files/KDiff3/bin/kdiff3.exe [mergetool "kdiff3"] path = C:/Program Files/KDiff3/bin/kdiff3.exe cmd = \"C:/Program Files/KDiff3/bin/kdiff3.exe\" \"$BASE\" \"$LOCAL\" \"$REMOTE\" -o \"$MERGED\" *** Bug 490028 has been marked as a duplicate of this bug. *** I can confirm this is not a git issue. I get the same error when calling kdiff3 directly from the command line. I opened bug 490082 not realizing it was a duplicate of this one and have more details attached to that bug. (In reply to jweems from comment #16) > I can confirm this is not a git issue. I get the same error when calling > kdiff3 directly from the command line. I opened bug 490082 not realizing it > was a duplicate of this one and have more details attached to that bug. the duplicate is bug 490028, I transposed the last 2 numbers in my first reply Git commit dbc690d7c5ae8e1917b214e14f21fedd4200c314 by Michael Reeves. Committed on 10/08/2024 at 02:36. Pushed by mreeves into branch '1.11'. Move SourceData init to constructor for KDiff3App FIXED-IN: 1.11.3 M +17 -16 src/kdiff3.cpp M +6 -2 src/kdiff3.h M +2 -2 src/kdiff3_shell.cpp https://invent.kde.org/sdk/kdiff3/-/commit/dbc690d7c5ae8e1917b214e14f21fedd4200c314 Git commit 9d2a70ea420778ef0a543d463c9ca71a29105b6c by Michael Reeves. Committed on 10/08/2024 at 02:38. Pushed by mreeves into branch 'master'. Move SourceData init to constructor for KDiff3App FIXED-IN: 1.11.3 M +17 -16 src/kdiff3.cpp M +6 -2 src/kdiff3.h M +2 -2 src/kdiff3_shell.cpp https://invent.kde.org/sdk/kdiff3/-/commit/9d2a70ea420778ef0a543d463c9ca71a29105b6c *** Bug 489786 has been marked as a duplicate of this bug. *** I still have this problem with 1.11.4 (Arch Linux), when I open 3 files from the command line. With 2 files it is ok. (In reply to Arnd from comment #21) > I still have this problem with 1.11.4 (Arch Linux), when I open 3 files from > the command line. With 2 files it is ok. Coming from bug 489786 I am also still having this problem when comparing two files from Dolphin in 1.11.4 The same issue still exist in version 1.11.4, tested in Windows 11 x64 (Launch kdiff3 from Git Extension 5.0 version). Finally triggered this while looking at an unrelated bug not sure why it was only triggering for three way compare. Git commit 2e3e6e0f16e7865b41ffa5995d157bd4c55360d8 by Michael Reeves. Committed on 21/10/2024 at 20:44. Pushed by mreeves into branch 'master'. Fix bogus error gererated by FileAccess::open This seems to have been triggered only in command line drive compares. Also reported to require a three way compare to reliably trigger. FIXED-IN: 1.11.5 M +8 -0 src/autotests/FileAccessTest.cpp M +4 -2 src/fileaccess.cpp https://invent.kde.org/sdk/kdiff3/-/commit/2e3e6e0f16e7865b41ffa5995d157bd4c55360d8 Git commit f87cf8d03934a5c31c40f16e049dfe0913883f33 by Michael Reeves. Committed on 21/10/2024 at 20:47. Pushed by mreeves into branch '1.11'. Fix bogus error gererated by FileAccess::open This seems to have been triggered only in command line drive compares. Also reported to require a three way compare to reliably trigger. FIXED-IN: 1.11.5 M +8 -0 src/autotests/FileAccessTest.cpp M +4 -2 src/fileaccess.cpp https://invent.kde.org/sdk/kdiff3/-/commit/f87cf8d03934a5c31c40f16e049dfe0913883f33 *** Bug 495734 has been marked as a duplicate of this bug. *** I still get that error with version 1.11.5 on Windows. The same issue still exist in version 1.11.5, tested in Windows 11 x64 (Launch kdiff3 from Git Extension 5.0 version). Also on Arch Linux still same problem with 1.11.5
To reproduce it:
> echo a > a
> echo b > b
> echo c > c
> kdiff3 a b c
Mysteriously this no longer happens on my test machine so far. 1.11.5 fixes the only trigger I've been able to find so far. Going to have a closer looker. From what I've gather the GUI should come up with files pre-filled after the error. There seems to be no issue after clicking "ok' on the open dialog which tells something weird is happening with the command line use. I have been using both vs-code/git and direct command line tests. So far I haven't triggered this with 1.11.5 or master Version 1.11.5 on Windows 11 (2024H2) is now working again with TortoiseGit! This version also looks much better on Windows than Version 1.10.* and earlier did. Rendering size is normal (used to be super small), fonts are better, icon spacing is better, weirdness with window drawing is fixed. It actually looks pretty good now. Thanks for all the great updates! Part of that is coming from Qt as well as the windows and mac os versions are built using craft which is periodicly updated with the latest bug fixes. They are also now Qt6 bassed which may have more support for high res monitors than the legacy Qt5 framework. So I spoke a bit to soon - the new version has no horizontal scroll bars nor can you scroll horizontally using the keyboard or trackpad. It seems like horizontal scrolling is totally disabled. Created attachment 175896 [details]
No Horizontal Scroll Bars
Notice there are no horizontal scroll bars (Windows 11, Kidff 1.11.5). Nor does scrolling work at all.
Go ahead and file a seprate bug for the missing scrollbar. Just a spurious error trigger that is fixed in the 1.12 branch. @Arnd are you able to verify if your issue is fixed in that branch Cool - see https://bugs.kde.org/show_bug.cgi?id=496444 Created attachment 175973 [details]
Error message context menu
I am still getting an error message when comparing from the dolphin context menu (as in Bug 489786) as of version 1.11.5 Branch 1.12 seems to work! Thanks The last remaining issues with the command line appears fixed in 1.12. This will now be be released. |
Created attachment 169317 [details] error shown when opening kdiff3 from Visual Studio SUMMARY STEPS TO REPRODUCE 1. change source files in Visual Studio 2. compare source files in Visual Studio OBSERVED RESULT Files will not open with error. See attachment. When confirming the error dialog and then conforming the files dialog (without any changes in paths), comparison will open as expected. EXPECTED RESULT Open file comparison without any error directly. SOFTWARE/OS VERSIONS Windows: 11 Pro kdiff3: 1.11.0 (64-bit)