Description: In a master document, links to subdocuments which have 2 or more spaces in the filename fail. Windows 10 Pro 21H2 Libre Office 7.2.6.2 x64 Steps to Reproduce: 1. Create a new master doc. 2. Create or link to a subdocument. 3. If the subdocument has 2 spaces in the filename, the filename can't be found. My Filename.odt --> OK My Filname.odt --> Not Found Actual Results: Filename not found Expected Results: Linked subdocument file Reproducible: Always User Profile Reset: No Additional Info: It appears the 'convert to URL' step fails as the file path displays with spaces instead of '%20'. From the navigator, right click the bad file > edit link. Manually adding %20 into the link path fails. When checking the file link from within the master document, the link path has only one space. Manually adding a 2nd space doesn't work (after re-opening the dialog, the path shows with only 1 space). It appears that file path whitespace of any length is being reduced to a single space.
Tested with Version: 7.4.0.0.alpha0+ (x64) / LibreOffice Community Build ID: d34d1db55978bdcff082af1e0f75b18fa6fc94f4 CPU threads: 4; OS: Windows 10.0 Build 19044; UI render: Skia/Raster; VCL: win Locale: de-DE (de_DE); UI: en-GB Calc: CL Actual result Filename is displayed in red and no content is added to master document. (John, I hope this is equal to your result "Filename not found" But what is your expected result a) LO should find files with more than one space in filename (any limits?) b) There should be an explanation, why filename becomes red c) ... Personally I think, file names with two or more consecutive spaces should not be used and so i won't expect LO to find them.
Hi Dieter, appreciate you looking into this! For context I was writing specifications, with file names following a standard format "## ## ## - Title". Occasionally I'd double-tap the space bar, or an extra space would sneak in there while renaming. The extra space is nearly invisible, so it just appeared to me like the file was randomly corrupted. It wasn't until I was looking at the files in windows explorer that my OCD compelled me to figure out why some of the file names weren't kerning properly, that I found the root cause. Multiple spaces in the filename is not at all a requirement, just a nearly-invisible accident. Long story short: a more descriptive error would be a fine solution. Cheers!
[Automated Action] NeedInfo-To-Unconfirmed
(In reply to John from comment #2) > Long story short: a more descriptive error would be a fine solution. O. K., let's take this as enhancement request and ask design-team for further input and decision. cc: Design-Team Steps to reproduce: 1. Create a new master doc 2. Create or link to a subdocument with 2 spaces in filename Actual result Filename is displayed in red and no content is added to master document. (John, I hope this is equal to your result "Filename not found" Enhancement request Instead of the current result it would be better to give an error message to the user like "Path of selected file is invalid, because it contains two censecutive spaces."
Posix recommends to use only A..Z, a..z, numbers, hyphen and underscore. But space are not forbidden. If the file system allows the name we should not mess with it.
(In reply to Heiko Tietze from comment #5) > Posix recommends to use only A..Z, a..z, numbers, hyphen and underscore. But > space are not forbidden. If the file system allows the name we should not > mess with it. Just for clarification: So bug summary would be something like "Master document doesn't allow filename/path with consecutive spaces", correct?
Yes, we should allow multiple spaces. No warning is needed.
Stephan Bergmann committed a patch related to this issue. It has been pushed to "master": https://git.libreoffice.org/core/commit/d7fbea57ef945c1444185581787d17a93dda8cd9 tdf#148299 Don't unmotivatedly mess with spaces in file names It will be available in 7.4.0. The patch should be included in the daily builds available at https://dev-builds.libreoffice.org/daily/ in the next 24-48 hours. More information about daily builds can be found at: https://wiki.documentfoundation.org/Testing_Daily_Builds Affected users are encouraged to test the fix and report feedback.
VERIFIED with Version: 7.4.0.0.alpha1 (x64) / LibreOffice Community Build ID: b871abad383583f02eb49c7e49aeae01f6941072 CPU threads: 4; OS: Windows 10.0 Build 19044; UI render: Skia/Raster; VCL: win Locale: de-DE (de_DE); UI: en-GB Calc: CL Stephan, thanks for fixing it!