Skip to content

[NETBEANS-3164]:Fixed issue in Text-Block#1547

Merged
jlahoda merged 3 commits intoapache:masterfrom
Akshay-Gupta-19:nb11.2_issu_3164
Oct 14, 2019
Merged

[NETBEANS-3164]:Fixed issue in Text-Block#1547
jlahoda merged 3 commits intoapache:masterfrom
Akshay-Gupta-19:nb11.2_issu_3164

Conversation

@Akshay-Gupta-19
Copy link
Contributor

[NETBEANS-3164]:Fixed issue in Text-Block

@Akshay-Gupta-19
Copy link
Contributor Author

Akshay-Gupta-19 commented Oct 4, 2019

JDK13 preview feature:
nb-javac jars are modified to fix compilation issue of text block in this particular scenario
https://issues.apache.org/jira/browse/NETBEANS-3164

CRC generated using chcksum command in windows cygwin64.

@graben
Copy link
Contributor

graben commented Oct 4, 2019

What issue does this fix address? Still having errors with IDE running different JDK version than 13.

@geertjanw
Copy link
Member

Yes, you'll get an updated nb-javac in the next days, we're very aware of this issue, and are working on it.

@graben
Copy link
Contributor

graben commented Oct 4, 2019

That's why I'm asking. I manually switched the nb-javac impl in current beta2 to the one that this patch does link to. But it does not work better than before.

@geertjanw
Copy link
Member

You're going to need to sit tight a bit, we'll announce it when it's there.

@geertjanw
Copy link
Member

Most likely not intended.

[NETBEANS-3164]:Fixed issue in Text-Block
@neilcsmith-net
Copy link
Member

So, I'm assuming intended for NB11.2-beta3? Adding milestone - please remember to add for future PR intended for releases. Thanks!

With revised nb-javac support ( cc @jlahoda ) would we be able to push updates to these files via distribution update centre to trigger download of new external binaries if we need to update the library after release rather than falling back to plugin centre?

@neilcsmith-net neilcsmith-net requested a review from jlahoda October 5, 2019 10:51
@neilcsmith-net neilcsmith-net added this to the 11.2 milestone Oct 5, 2019
@Akshay-Gupta-19
Copy link
Contributor Author

Akshay-Gupta-19 commented Oct 5, 2019

That's why I'm asking. I manually switched the nb-javac impl in current beta2 to the one that this patch does link to. But it does not work better than before.

How did you switch it to new impl
In order to change the nb-javac-impl and nb-javac-api jars you have to follow following steps

First install nb-javac plugin and then restart NB
After that stop NB and then you have to replace the jar files (whose address can be found written in netbeans About->help->User directory, for windows it is C:\Users<username>\AppData\Roaming\NetBeans\11.2-beta1 ) in that directory further go inside modules->ext there you can find the jars. replace the jar files with new downloaded jars( rename the downloaded jars by removing hash and removing -13- to match the name with old jars).

Then go back to location - C:\Users<username>\AppData\Roaming\NetBeans\11.2-beta1
you can see .lastModified file, use following command there(from bash)
touch .lastModified
This will update the jars of nb-javac for netbeans

I did the same and after that text blocks are working for me with base jdk of net beans as JDK8.

@graben
Copy link
Contributor

graben commented Oct 5, 2019

I did it exactly this way but with JDK 11 as runtime JDK without success.

@geertjanw
Copy link
Member

Can you put here the exact URLs you used to get the two JARs?

@graben
Copy link
Contributor

graben commented Oct 5, 2019

Well, I did another clean install of beta2 with fresh profile and manual "patch" of nb-javac. Now it seems to work. Maybe my latest profile got buggy by manipulation. ;-)

@geertjanw
Copy link
Member

Excellent, thanks for the help in verifying this fix, much appreciated.

@graben
Copy link
Contributor

graben commented Oct 5, 2019

Welcome! But there are still funny behaviours in the editor for textblocks:
public static String x = """test""";
trying to correct with line break ends in
public static String x = """"
+ "test""";
trying to remove the crappy forth " in the first line doesn't make it better :)

Maybe something for a deeper NETCAT

@geertjanw
Copy link
Member

Can you create a new issue for this?

@graben
Copy link
Contributor

graben commented Oct 5, 2019

Copy link
Contributor

@jlahoda jlahoda left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good. Next time, we could probably also increase the spec versions of the modules, so that people that already have the previous modules installed would get an update, but hopefully OK for now (users need to either use a new userdir, or manually uninstall/delete the module and reinstall, I believe).

We could distribute an update using an update center, as long as we use an update center that is specific to this release (so that we don't break previous releases).

@neilcsmith-net
Copy link
Member

@jlahoda what is the current spec version? I currently see same version in NB 11.2-beta2 as NB 11.1. Just tried with clean userdir and disabling plugin centre first - I don't see nb-javac at all, although I do see JavaFX modules available ??? Enabling Java cluster fails when plugin centre disabled. That doesn't sound right?!

@jlahoda
Copy link
Contributor

jlahoda commented Oct 7, 2019

Ok, I know now what is going on - the nb-javac modules are not part of the "3rdparty" cluster, and hence are not part of the source zip built by build-source-config (for cluster.config=release). And so they are not in the beta :-(. I didn't realize the cluster.properties need to change as well, and all is working for a build from the sources in git (as the modules are in the checkout). I apologize for that.

I've submitted:
#1556

to add the modules to the 3rdparty cluster, which should ensure they are part of the source distro.

For the record, the spec versions of these modules is "2.0".

@Akshay-Gupta-19
Copy link
Contributor Author

@jlahoda can this pull request be merge before #1556

@neilcsmith-net
Copy link
Member

@Akshay-Gupta-Oracle #1556 has been closed in favour of #1560 Perhaps coordinate there with @jlahoda to make sure that fix includes these changes?

@neilcsmith-net neilcsmith-net added the do not merge Don't merge this PR, it is not ready or just demonstration purposes. label Oct 14, 2019
@jlahoda
Copy link
Contributor

jlahoda commented Oct 14, 2019

@neilcsmith-net are you OK with me merging this? (I'll then merge master into #1560.)

@neilcsmith-net
Copy link
Member

@jlahoda yes, said same on 1560. If you can merge them both, then I'll look at beta3 tomorrow. Thanks!

@neilcsmith-net neilcsmith-net removed the do not merge Don't merge this PR, it is not ready or just demonstration purposes. label Oct 14, 2019
@jlahoda jlahoda merged commit 4099efe into apache:master Oct 14, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants