Bug 101359 - Impossible to insert, delete or rename bookmarks
Summary: Impossible to insert, delete or rename bookmarks
Status: VERIFIED FIXED
Alias: None
Product: LibreOffice
Classification: Unclassified
Component: Writer (show other bugs)
Version:
(earliest affected)
5.2.0.4 release
Hardware: All All
: medium normal
Assignee: Caolán McNamara
URL:
Whiteboard: target:5.2.1 target:5.3.0 target:5.2.3
Keywords: bibisectRequest, regression
Depends on:
Blocks:
 
Reported: 2016-08-06 18:30 UTC by Stefan_Lange_KA@T-Online.de
Modified: 2016-09-29 17:31 UTC (History)
4 users (show)

See Also:
Crash report or crash signature:


Attachments
shortened copy of my document to reproduce the described bug (188.86 KB, application/vnd.oasis.opendocument.text)
2016-08-06 18:30 UTC, Stefan_Lange_KA@T-Online.de
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Stefan_Lange_KA@T-Online.de 2016-08-06 18:30:34 UTC
Created attachment 126631 [details]
shortened copy of my document to reproduce the described bug

I have one odt document with existing bookmarks that makes problems when I try to insert new bookmarks: The bookmark dialog opens and the edit field for the bookmark name contains "Bookmark 1". When I try to insert any text, the edit fields is cleared and it remains empty even what key I press.
Also I cannot select an existing bookmark from the list to delete or rename the bookmark.
This is not a general problem. In other documents this error does not appear.
I have no idea about the special difference beetween the documents.

With the attached shortened copy of my original document I have reproduced the errors on 3 different commputers (all Windows 10 1607, 2x x64 with LO 5.2.0 64bit, 1x x86).
Comment 1 Thomas Hackert 2016-08-07 08:06:50 UTC
Hello Stefan, *,
I can confirm your bug with
OS: Debian Testing AMD64 (so changing Hardware to "All" "All" instead of "All" "Windows")
LO: Version: 5.2.0.4
Build-ID: 066b007f5ebcc236395c7d282ba488bca6720265
CPU-Threads: 4; BS-Version: Linux 4.5; UI-Render: Standard; 
Gebietsschema: de-DE (de_DE.UTF-8)
(parallel installed, following the instructions from https://wiki.documentfoundation.org/Installing_in_parallel/Linux)

It is also reproducible in
LO: Version: 5.3.0.0.alpha0+
Build-ID: 39e300612c97b7742c8d8417d4dc6c0022cfa040
CPU-Threads: 4; BS-Version: Linux 4.5; UI-Render: Standard; 
TinderBox: Linux-rpm_deb-x86_64@70-TDF, Branch:master, Time: 2016-08-05_01:22:59
Gebietsschema: de-DE (de_DE.UTF-8); Calc: group

and

LO: Version: 5.2.1.0.0+
Build-ID: 0b168901ed5e767651262686af65994029b3039b
CPU-Threads: 4; BS-Version: Linux 4.5; UI-Render: Standard; 
TinderBox: Linux-rpm_deb-x86_64@70-TDF, Branch:libreoffice-5-2, Time: 2016-08-04_23:35:41
Gebietsschema: de-DE (de_DE.UTF-8); Calc: group

It is not reproducible in
LO: Version: 5.1.5.2
Build-ID: 1:5.1.5~rc2-1
CPU-Threads: 4; BS-Version: Linux 4.5; UI-Render: GL; 
Gebietsschema: de-DE (de_DE.UTF-8); Calc: group

and

LO: Version: 5.1.6.0.0+
Build-ID: 21639ac7f5b075808925186cdd5a102eb8d7a02a
CPU-Threads: 4; BS-Version: Linux 4.5; UI-Render: Standard; 
TinderBox: Linux-rpm_deb-x86_64@70-TDF, Branch:libreoffice-5-1, Time: 2016-08-05_00:28:06
Gebietsschema: de-DE (de_DE.UTF-8); Calc: group

so it seems the bug was introduced somewhere in LO's 5.2 line ... :(
HTH
Thomas.
Comment 2 Stefan_Lange_KA@T-Online.de 2016-08-07 11:42:28 UTC
Because the error not occurs in LO 5.1 versions I think that it is related to the changes for redesigned (extended) dialogue for bookmark insert in LO 5.2 writer.
Comment 3 Stefan_Lange_KA@T-Online.de 2016-08-07 20:09:44 UTC
Addition:
With my example document it is not completely impossible to insert bookmarks: When one doesn't change the preset bookmark name ("Bookmark 1" etc.), a bookmark with this preset name will be inserted by pressing the insert button.
The described error occurs when one tries to enter an other bookmark name or to select a bookmark for deete, rename or go to.
Comment 4 Caolán McNamara 2016-08-08 14:36:18 UTC
I think the problem here is that getBookmarkCount was assumed to return the number of bookmarks, which is a reasonable assumption given its name, but it returns the number of bookmarks, crossref_numitem bookmarks and crossref_heading bookmarks
Comment 5 Caolán McNamara 2016-08-08 15:15:48 UTC
This is fixed with https://cgit.freedesktop.org/libreoffice/core/commit/?id=cdb708291b59ac89b43c24154f0edc77f237eadd

5-2 backport in gerrit
Comment 6 Commit Notification 2016-08-09 19:37:23 UTC
Caolán McNamara committed a patch related to this issue.
It has been pushed to "libreoffice-5-2":

http://cgit.freedesktop.org/libreoffice/core/commit/?id=11aa7278659d5f56288df620978107947aec4adc&h=libreoffice-5-2

Resolves: tdf#101359 getBookmarksCount includes more than aTableBookmarks

It will be available in 5.2.1.

The patch should be included in the daily builds available at
http://dev-builds.libreoffice.org/daily/ in the next 24-48 hours. More
information about daily builds can be found at:
http://wiki.documentfoundation.org/Testing_Daily_Builds

Affected users are encouraged to test the fix and report feedback.
Comment 7 Stefan_Lange_KA@T-Online.de 2016-08-15 18:28:25 UTC
Test: The error still occurs in the builds installed with "libreoffice-5-2~2016-08-10_00.04.18_LibreOfficeDev_5.2.1.0.0_Win_x86_en-US_de_ar_ja_ru_qtz.msi" and also "libreoffice-5-2~2016-08-11_00.12.47_LibreOfficeDev_5.2.2.0.0_Win_x86_en-US_de_ar_ja_ru_qtz.msi".
Newer builds from LO 5.2 not seem to exist in daily builds until now (2016-08-15 20.25).
With the LO 5.3 versions in the master the error also occurs.
Comment 8 Stefan_Lange_KA@T-Online.de 2016-08-28 20:11:38 UTC
Succesful test until now was not possible, because I haven't found now builds for LO 5.2 for Windows (LO 5.2.1 and LO 5.2.2) since 2016-08-11.
Comment 9 Stefan_Lange_KA@T-Online.de 2016-08-28 20:46:08 UTC
Because there are no LO 5.2 for Windows in daily, I have looked for in /pre-releases/win/x86_64.
Result: In the test with LO 5.2.1 installed with LibreOffice_5.2.1.2_Win_x64.msi from 25-Aug-2016 05:46 the error still occurs with the appended test document!
Comment 10 Stefan_Lange_KA@T-Online.de 2016-09-09 19:22:21 UTC
In the recently published version LO 5.2.1 (Windows x86 + Windows x64) the error still occurs. It can be reproduced with the test odt document that I have attached when I have reported the bug. 
Because I could never succesfully check the correction and because the error still has occured  in the pre-release builds (see comments #7 until #9) and because the published release msi files are identical to the pre-release msi files, this is not a surprise for me.
What is to do to look for the reason of the error again? Do I have the authorization to re-open the bug?
Comment 11 Buovjaga 2016-09-12 16:49:55 UTC
Caolán: the original reporter can still reproduce the problem.

Thomas: can you also reproduce the bug with 5.2.1?
Comment 12 Thomas Hackert 2016-09-13 06:57:27 UTC
Hello Buoviaga, *,
(In reply to Buovjaga from comment #11)
> Caolán: the original reporter can still reproduce the problem.
> 
> Thomas: can you also reproduce the bug with 5.2.1?

I am also still able to reproduce it with
OS: Debian Testing AMD64
LO: Version: 5.2.1.2
Build-ID: 1:5.2.1-1
CPU-Threads: 4; BS-Version: Linux 4.5; UI-Render: GL; 
Gebietsschema: de-DE (de_DE.UTF-8); Calc: group
(Debian's own version)

and

LO: Version: 5.2.1.2
Build-ID: 31dd62db80d4e60af04904455ec9c9219178d620
CPU-Threads: 4; BS-Version: Linux 4.5; UI-Render: Standard; 
Gebietsschema: de-DE (de_DE.UTF-8); Calc: group
(parallel installed, following the instructions from https://wiki.documentfoundation.org/Installing_in_parallel/Linux)
Should this bug's status be changed to something different than "Resolved fixed"?
Have a nice day
Thomas.
Comment 13 Buovjaga 2016-09-13 12:23:45 UTC
Yep, changing to reopened.
Comment 14 Alexander Z 2016-09-13 19:32:47 UTC
It seems that bug 100647 is the same, isn't it? Could they be merged?
Comment 15 Stefan_Lange_KA@T-Online.de 2016-09-13 19:50:10 UTC
I have tested in LO 5.2.1.2 with the document attached to bug #100647: same behavior as with my document attached to bug #101359!
Comment 16 Commit Notification 2016-09-16 20:19:04 UTC
Jan-Marek Glogowski committed a patch related to this issue.
It has been pushed to "master":

http://cgit.freedesktop.org/libreoffice/core/commit/?id=96454829f7dc6480f9ddd4262bc03d5ccabadea4

tdf#101359 Just advance list box for BOOKMARKs

It will be available in 5.3.0.

The patch should be included in the daily builds available at
http://dev-builds.libreoffice.org/daily/ in the next 24-48 hours. More
information about daily builds can be found at:
http://wiki.documentfoundation.org/Testing_Daily_Builds

Affected users are encouraged to test the fix and report feedback.
Comment 17 Stefan_Lange_KA@T-Online.de 2016-09-17 14:23:59 UTC
I have tested with build installed with libo-master~2016-09-17_11.59.43_LibreOfficeDev_5.3.0.0.alpha0_Win_x86.msi: The errors doesn't occur no more! I can insert bookmarks with names according to my own systematics now and I can rename, delete and go to existing bookmarks.

I have succesfully tested with my small test document attached to the bug report as well as with my big original document. 
	
It would be nice if the correction is published earlier than in the version 5.3, but already in a build of LO 5.2.
Comment 18 Buovjaga 2016-09-17 17:14:42 UTC
Ok, changing to fixed.
Comment 19 Commit Notification 2016-09-19 12:48:49 UTC
Jan-Marek Glogowski committed a patch related to this issue.
It has been pushed to "libreoffice-5-2":

http://cgit.freedesktop.org/libreoffice/core/commit/?id=89c87ab94bb5960187c178f556f871b2c1bfde8f&h=libreoffice-5-2

tdf#101359 Just advance list box for BOOKMARKs

It will be available in 5.2.3.

The patch should be included in the daily builds available at
http://dev-builds.libreoffice.org/daily/ in the next 24-48 hours. More
information about daily builds can be found at:
http://wiki.documentfoundation.org/Testing_Daily_Builds

Affected users are encouraged to test the fix and report feedback.
Comment 20 Commit Notification 2016-09-20 15:18:25 UTC
Jan-Marek Glogowski committed a patch related to this issue.
It has been pushed to "master":

http://cgit.freedesktop.org/libreoffice/core/commit/?id=ccb979c53931ab3f4712d0a3f7d0f844dcfc5c5d

tdf#101359 Really walk the document mark list

It will be available in 5.3.0.

The patch should be included in the daily builds available at
http://dev-builds.libreoffice.org/daily/ in the next 24-48 hours. More
information about daily builds can be found at:
http://wiki.documentfoundation.org/Testing_Daily_Builds

Affected users are encouraged to test the fix and report feedback.
Comment 21 Commit Notification 2016-09-21 12:32:17 UTC
Jan-Marek Glogowski committed a patch related to this issue.
It has been pushed to "master":

http://cgit.freedesktop.org/libreoffice/core/commit/?id=adfb650bec005a46c2192852a8f5801497a19611

tdf#101359 handle less bookmarks then expected

It will be available in 5.3.0.

The patch should be included in the daily builds available at
http://dev-builds.libreoffice.org/daily/ in the next 24-48 hours. More
information about daily builds can be found at:
http://wiki.documentfoundation.org/Testing_Daily_Builds

Affected users are encouraged to test the fix and report feedback.
Comment 22 Commit Notification 2016-09-21 19:43:38 UTC
Jan-Marek Glogowski committed a patch related to this issue.
It has been pushed to "libreoffice-5-2":

http://cgit.freedesktop.org/libreoffice/core/commit/?id=a1468f50241c87ac7687128f852d6f2f2e705b93&h=libreoffice-5-2

tdf#101359 Really walk the document mark list

It will be available in 5.2.3.

The patch should be included in the daily builds available at
http://dev-builds.libreoffice.org/daily/ in the next 24-48 hours. More
information about daily builds can be found at:
http://wiki.documentfoundation.org/Testing_Daily_Builds

Affected users are encouraged to test the fix and report feedback.
Comment 23 Stefan_Lange_KA@T-Online.de 2016-09-23 18:47:42 UTC
Will be published for test in /daily/libreoffice-5-2 also new builds of LO 5.2.3 for Windows? Until now there are only new (actual) builds for Linux, but for Windows exist only "old" builds from 2016-09-15.
Comment 24 Stefan_Lange_KA@T-Online.de 2016-09-29 16:55:03 UTC
Now I could also test with LO 5.2.3

It's all OK: The Bookmarks dialog works properly!

Tested with
Version: 5.2.3.0.0+
Build-ID: de299945d0b2ef24c4557db670dc7d78301f1ba7
CPU-Threads: 4; BS-Version: Windows 6.2; UI-Render: Standard; 
TinderBox: Win-x86@62-merge-TDF, Branch:libreoffice-5-2, Time: 2016-09-28_16:00:05
Gebietsschema: de-DE (de_DE); Calc: group

Succesful test already earlier with LO 5.3.0
and today again with
Version: 5.3.0.0.alpha0+
Build ID: a87a31602165cb2a37c32f5928e4f9daade7271d
CPU Threads: 2; OS Version: Windows 6.19; UI Render: default; 
TinderBox: Win-x86@42, Branch:master, Time: 2016-09-29_04:18:44
Locale: de-DE (de_DE); Calc: group
Comment 25 Buovjaga 2016-09-29 17:31:10 UTC
Hurrah! Let's set to verified.