Bug 577122 - Javadoc first line is not copied
Summary: Javadoc first line is not copied
Status: RESOLVED FIXED
Alias: None
Product: Platform
Classification: Eclipse Project
Component: Text (show other bugs)
Version: 4.22   Edit
Hardware: All All
: P3 major (vote)
Target Milestone: 4.23 M3   Edit
Assignee: Mickael Istria CLA
QA Contact:
URL:
Whiteboard:
Keywords: regression
: 577810 579254 (view as bug list)
Depends on:
Blocks:
 
Reported: 2021-11-08 03:01 EST by Fabrice Tiercelin CLA
Modified: 2022-03-18 15:23 EDT (History)
7 users (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Fabrice Tiercelin CLA 2021-11-08 03:01:07 EST
To reproduce:
1. Open a Java file starting with Javadoc (for instance, UnboxingCleanUp.java)
2. Make sure the JavaDoc is collapsed with a plus
3. Copy all the file (Ctlr+A -> Ctrl+C)
4. Paste anywhere

-> The first line of JavaDoc is missing:

 * Copyright (c) 2019 Fabrice TIERCELIN and others.
 *
 * This program and the accompanying materials
 * are made available under the terms of the Eclipse Public License 2.0
 * which accompanies this distribution, and is available at
 * https://www.eclipse.org/legal/epl-2.0/
 *
 * SPDX-License-Identifier: EPL-2.0
 *
 * Contributors:
 *     Fabrice TIERCELIN - initial API and implementation
 *******************************************************************************/
...

The bug has appeared between the builds:
I20210913-2050
I20210920-1800

Unfortunately, during those 7 days, we have merged the Java 17 branch so the bug has appeared somewhere in a huge number of commits 😬
Comment 1 Jeff Johnston CLA 2021-11-09 16:03:19 EST
Doing some testing, the problem isn't just Javadoc comments, but also fails for regular comments.  It only fails if the collapsed comment shows the 2nd line instead of the first.

For example,

/*
 * second line
 * third line
 */

will show "2+ * second line" when collapsed

whereas

/* first line
 * second line
 * third line
 */

will show 1+ /* first line

This last scenario works fine and copies properly.
Comment 2 Andrey Loskutov CLA 2022-02-01 10:35:09 EST
Jeff, in which time range do you want I-Builds?
Comment 3 Jeff Johnston CLA 2022-02-01 10:38:18 EST
(In reply to Andrey Loskutov from comment #2)
> Jeff, in which time range do you want I-Builds?

I would be happy to have at least: I20210913-2050 so I can check out various components at the same level and then do bisection to the I20210920-1800 tag.
Comment 4 Andrey Loskutov CLA 2022-02-01 10:48:27 EST
(In reply to Jeff Johnston from comment #3)
> (In reply to Andrey Loskutov from comment #2)
> > Jeff, in which time range do you want I-Builds?
> 
> I would be happy to have at least: I20210913-2050 so I can check out various
> components at the same level and then do bisection to the I20210920-1800 tag.

I don't have exact these builds (it is 4.22, so I've cleaned some), but I've put 

eclipse-SDK-I20210912-1800-linux-gtk-x86_64.tar.gz
eclipse-SDK-I20210914-1800-linux-gtk-x86_64.tar.gz
eclipse-SDK-I20210921-1800-linux-gtk-x86_64.tar.gz

to

https://drive.google.com/drive/folders/18PXX5b4omdpinoZTrlKgpOhhczYMSoQM?usp=sharing
Comment 5 Vikas Chandra CLA 2022-02-01 12:00:11 EST
I have eclipse-SDK-I20210914-1800-linux-gtk-x86_64.tar.gz and eclipse-SDK-I20210915-0150-linux-gtk-x86_64.tar.gz
Comment 6 Jeff Johnston CLA 2022-02-01 12:22:58 EST
(In reply to Andrey Loskutov from comment #4)
> (In reply to Jeff Johnston from comment #3)
> > (In reply to Andrey Loskutov from comment #2)
> > > Jeff, in which time range do you want I-Builds?
> > 
> > I would be happy to have at least: I20210913-2050 so I can check out various
> > components at the same level and then do bisection to the I20210920-1800 tag.
> 
> I don't have exact these builds (it is 4.22, so I've cleaned some), but I've
> put 
> 
> eclipse-SDK-I20210912-1800-linux-gtk-x86_64.tar.gz
> eclipse-SDK-I20210914-1800-linux-gtk-x86_64.tar.gz
> eclipse-SDK-I20210921-1800-linux-gtk-x86_64.tar.gz
> 
> to
> 
> https://drive.google.com/drive/folders/
> 18PXX5b4omdpinoZTrlKgpOhhczYMSoQM?usp=sharing

Thanks Andrey and Vikas.  I think the I20210912-1800 SDK and I20210914-1800 builds should be a good start.  If the bug doesn't occur for I20210914, I can try the I20210915 build.  I can also build on top of them with various components to see which one causes the error.
Comment 7 Andrey Loskutov CLA 2022-02-01 13:04:17 EST
(In reply to Jeff Johnston from comment #6)
> I think the I20210912-1800 SDK and I20210914-1800
> builds should be a good start.  If the bug doesn't occur for I20210914, I
> can try the I20210915 build.  I can also build on top of them with various
> components to see which one causes the error.

Just in case you will need another version, here is my complete list for 4.22:

eclipse-SDK-I20210907-1800-linux-gtk-x86_64.tar.gz
eclipse-SDK-I20210909-1800-linux-gtk-x86_64.tar.gz
eclipse-SDK-I20210912-1800-linux-gtk-x86_64.tar.gz
eclipse-SDK-I20210914-1800-linux-gtk-x86_64.tar.gz
eclipse-SDK-I20210915-1800-linux-gtk-x86_64.tar.gz
eclipse-SDK-I20210917-0000-linux-gtk-x86_64.tar.gz
eclipse-SDK-I20210919-1800-linux-gtk-x86_64.tar.gz
eclipse-SDK-I20210921-1800-linux-gtk-x86_64.tar.gz
eclipse-SDK-I20210923-1800-linux-gtk-x86_64.tar.gz
eclipse-SDK-I20210924-0200-linux-gtk-x86_64.tar.gz
eclipse-SDK-I20210926-1800-linux-gtk-x86_64.tar.gz
eclipse-SDK-I20210928-1800-linux-gtk-x86_64.tar.gz
eclipse-SDK-I20210929-1800-linux-gtk-x86_64.tar.gz
eclipse-SDK-I20211002-1800-linux-gtk-x86_64.tar.gz
eclipse-SDK-I20211004-2030-linux-gtk-x86_64.tar.gz
eclipse-SDK-I20211006-1800-linux-gtk-x86_64.tar.gz
eclipse-SDK-I20211007-1800-linux-gtk-x86_64.tar.gz
eclipse-SDK-I20211009-1800-linux-gtk-x86_64.tar.gz
eclipse-SDK-I20211011-1800-linux-gtk-x86_64.tar.gz
eclipse-SDK-I20211013-1800-linux-gtk-x86_64.tar.gz
eclipse-SDK-I20211014-1800-linux-gtk-x86_64.tar.gz
eclipse-SDK-I20211017-1800-linux-gtk-x86_64.tar.gz
eclipse-SDK-I20211019-1800-linux-gtk-x86_64.tar.gz
eclipse-SDK-I20211020-1800-linux-gtk-x86_64.tar.gz
eclipse-SDK-I20211022-0130-linux-gtk-x86_64.tar.gz
eclipse-SDK-I20211024-1800-linux-gtk-x86_64.tar.gz
eclipse-SDK-I20211026-1800-linux-gtk-x86_64.tar.gz
eclipse-SDK-I20211028-1800-linux-gtk-x86_64.tar.gz
eclipse-SDK-I20211030-1800-linux-gtk-x86_64.tar.gz
eclipse-SDK-I20211101-1800-linux-gtk-x86_64.tar.gz
eclipse-SDK-I20211103-1800-linux-gtk-x86_64.tar.gz
eclipse-SDK-I20211104-1800-linux-gtk-x86_64.tar.gz
eclipse-SDK-I20211107-1800-linux-gtk-x86_64.tar.gz
eclipse-SDK-I20211108-1800-linux-gtk-x86_64.tar.gz
eclipse-SDK-I20211109-1800-linux-gtk-x86_64.tar.gz
eclipse-SDK-I20211110-1800-linux-gtk-x86_64.tar.gz
eclipse-SDK-I20211111-0910-linux-gtk-x86_64.tar.gz
eclipse-SDK-I20211114-1800-linux-gtk-x86_64.tar.gz
eclipse-SDK-I20211116-0000-linux-gtk-x86_64.tar.gz
eclipse-SDK-I20211116-1800-linux-gtk-x86_64.tar.gz
eclipse-SDK-I20211117-1830-linux-gtk-x86_64.tar.gz
eclipse-SDK-I20211122-1800-linux-gtk-x86_64.tar.gz
eclipse-SDK-I20211124-1800-linux-gtk-x86_64.tar.gz
Comment 8 Vikas Chandra CLA 2022-02-02 01:50:40 EST
The problem happens on Version: I20210914-1800 ( this doesn't have java compiler compiaance of Java 17)

>The bug has appeared between the builds:
>I20210913-2050
>I20210920-1800

Based on this, the problem got introduced BETWEEN I20210913-2050 and I20210914-1800

As far as I remember, based on I builds on my machine, the 1st build to have Java 17 changes was I20210915-0150 ( as you can also see Java compiler compliance option of 17).
Comment 9 Vikas Chandra CLA 2022-02-02 01:51:24 EST
I had a previous build of 6th September and things work fine there.
Comment 10 Vikas Chandra CLA 2022-02-07 09:29:10 EST
Caused by fix of bug Bug 466532 

Commit id : bf5933129b8eb15b5b7cdefa781eacc1c4a5e3b9
Comment 11 Mickael Istria CLA 2022-02-10 10:05:10 EST
Definitely an issue in JFace Text. I'm about to submit a test case that showcase the problem with plain JFace.
Comment 12 Eclipse Genie CLA 2022-02-10 10:06:04 EST
New Gerrit change created: https://git.eclipse.org/r/c/platform/eclipse.platform.text/+/190679
Comment 14 Jeff Johnston CLA 2022-02-10 14:27:04 EST
Thanks Mickael.
Comment 15 Jeff Johnston CLA 2022-02-16 10:58:39 EST
*** Bug 577810 has been marked as a duplicate of this bug. ***
Comment 16 Jeff Johnston CLA 2022-03-18 15:23:49 EDT
*** Bug 579254 has been marked as a duplicate of this bug. ***