Summary: | Add collection fails on similarly named directories (seems that check is not strict enough) | ||
---|---|---|---|
Product: | [Applications] digikam | Reporter: | Luka Renko <lure> |
Component: | Setup-Collections | Assignee: | Digikam Developers <digikam-bugs-null> |
Status: | RESOLVED FIXED | ||
Severity: | normal | CC: | doc.evans, marcel.wiesweg |
Priority: | NOR | ||
Version: | 1.0.0 | ||
Target Milestone: | --- | ||
Platform: | Ubuntu | ||
OS: | Linux | ||
Latest Commit: | Version Fixed In: | 1.2.0 | |
Sentry Crash Report: | |||
Attachments: | screenshot of the error |
Description
Luka Renko
2010-01-03 21:27:58 UTC
Message error is this one ? http://lxr.kde.org/source/extragear/graphics/digikam/utilities/setup/setupcollectionview.cpp#466 Gilles Caulier Created attachment 39536 [details]
screenshot of the error
No, it is the error as shown in attachment.
rootPath = ~/Images/apn filePath = ~/Images/apn-reflex/xyz if (filePath.startsWith(rootPath)) { ... } That's the current code. The mistake is obvious, you already point to it above. I want to avoid accessing the filesystem here, just compare strings. SVN commit 1078190 by mwiesweg: Add extra check to compare directories CCBUG: 221155 M +7 -3 collectionmanager.cpp WebSVN link: http://websvn.kde.org/?view=rev&revision=1078190 Luka, would you like to test? *** Bug 216017 has been marked as a duplicate of this bug. *** Marcel, I tested it now with 1.1, and the problem is not fixed. :-( Ok I see. It does not work when you add the two collections in one go, does it? Didn't test that case. When you close the dialog in between, it works. And at least you get now a meaningful error message ;-) Will fix this. Or did you test another case? Marcel, you are correct: - if I add both collections in one go (same dialog) -> fail - add first collection, close, add second connection -> OK A side note: when adding directories of local FS (it is on dm-crypt+LVM volume), I get the following warning: It is not possible on your system to identify the storage medium of this path. It will be added using the file path as the only identifier. This will work well for your local disk. Since this is the local disk, I think this warning will just confuse the user... (In reply to comment #9) > > A side note: when adding directories of local FS (it is on dm-crypt+LVM > volume), I get the following warning: > It is not possible on your system to identify the storage medium of this path. > It will be added using the file path as the only identifier. This will work > well for your local disk. > > Since this is the local disk, I think this warning will just confuse the > user... I agree that I always find this a very odd warning. Basically it seems to say "here's a problem -- although what the problem is isn't at all obvious -- but you can ignore this message if you're using a local disk". I've always ignored it, but also every time I see it I wonder "what would I do if I received this message but was using a FUSE filesystem that was physically remote but appeared as a local disk to the system?" There doesn't seem to be any advice given as to what to do if you're not using a local disk. So, yes, all-in-all, the user is left with no clear idea what the message means, nor whether it really affects him, nor what to do about it. So anything you can do to improve this situation would be A Good Thing. Any better suggestions for the message? The technical background is that Solid does not provide information for such storage devices, so in fact we dont now what it is and fall back to the mount path. This can happen is Solid/HAL does not support the local setup - as I would suspect for the LVM mentioned above. This should be fixed in HAL. The problem can also happen when Solid is not working correctly, which is a platform or installation issue. It also covers all other cases, which we did not expect and which I dont mention here therefore. SVN commit 1086098 by mwiesweg: Apply the same fix as for CollectionManager in the setup code as well (this code test not-yet-added collections, which are unknown to collectionmanager) BUG: 221155 M +2 -1 NEWS M +10 -5 utilities/setup/setupcollectionview.cpp WebSVN link: http://websvn.kde.org/?view=rev&revision=1086098 |