apache / netbeans

Apache NetBeans
https://netbeans.apache.org/
Apache License 2.0
2.62k stars 840 forks source link

Kotlin Plugin Donation #1398

Closed SerVB closed 3 years ago

SerVB commented 5 years ago

This is a follow up of the https://github.com/JetBrains/kotlin-netbeans/issues/137 .

@mglukhikh , @geertjanw

mglukhikh commented 5 years ago

I should mention that we intentionally do not include content of https://github.com/JetBrains/kotlin-netbeans/tree/master/lib folder in this donation. This folder contain jar files built from intellij-community and kotlin project sources. Of course you can use them if you wish, but we can't donate them because they are parts of other JetBrains projects.

Of course it would be much better (in both legal and technical aspects) for these jars not to be stored in the repo directly. I can give some advices how to avoid it (but sorry, can't do it myself due to lack of time):

geertjanw commented 5 years ago

Great and many thanks.

fwcd commented 5 years ago

What do you think about combining the efforts on building great Kotlin support by focusing on improving the Kotlin language server?

An LSP client for NetBeans seems to have been merged some time ago (#629) and having a well-maintained language server would benefit other editors/IDEs too.

jlahoda commented 5 years ago

What do you think about combining the efforts on building great Kotlin support by focusing on improving the Kotlin language server?

An LSP client for NetBeans seems to have been merged some time ago (#629) and having a well-maintained language server would benefit other editors/IDEs too.

I think using the LSP server may be a viable alternative, but those who will decide to work on the support for Kotlin in NetBeans will need to decide between two alternatives: -using the LSP server, which is easier to integrate (the biggest issue will probably be categorizing licenses and finding places from where NB can download the binaries - the NetBeans build likes to download stuff from Maven central, but my understanding is that most of the binaries required here are not in central), the con being that there are limits in how well such integration may work without special tweaks in the IDE. (Like having a Java class referring to a Kotlin class, or support for features that are not supported by the LSP.)

-have a plugin directly in the IDE, where there are no limits on the integration with other features; the obvious con being this is much more work.

dejlek commented 4 years ago

Any progress here?

geertjanw commented 4 years ago

Nope, though you can take charge, pick it up, engage with the community on the dev mailing list, and make it happen. :-)

dejlek commented 4 years ago

I would rather do that with the nbpython plugin...

ebarboni commented 4 years ago

Hi, we must go through ip clearance process. The most paperwork are from donators JetBrains s.r.o should transmit a software agreement https://www.apache.org/licenses/software-grant-template.pdf It's important that each contributor (I hope the list is complete here: https://github.com/JetBrains/kotlin-netbeans/graphs/contributors) also have iCLA
Workflow may be found over here. https://www.apache.org/licenses/contributor-agreements.html

Then Apache NetBeans PMC have to vote for accepting code.

Then a lazy vote occurs on incubator list to ip clear.

Regards

mglukhikh commented 4 years ago

Hi, we must go through ip clearance process. The most paperwork are from donators JetBrains s.r.o should transmit a software agreement https://www.apache.org/licenses/software-grant-template.pdf It's important that each contributor (I hope the list is complete here: https://github.com/JetBrains/kotlin-netbeans/graphs/contributors) also have iCLA Workflow may be found over here. https://www.apache.org/licenses/contributor-agreements.html

Then Apache NetBeans PMC have to vote for accepting code.

Then a lazy vote occurs on incubator list to ip clear.

Regards

Hi Eric, Ok, we will process your request and answer after some time.

ebarboni commented 4 years ago

I cannot check all parameters, but I guess a package refactory to org.apache.netbeans (or org.netbeans) will also be needed.

mglukhikh commented 4 years ago

@ebarboni Hi, excuse me, do you have an editable version of the software agreement you need? (https://www.apache.org/licenses/software-grant-template.pdf). Our (JetBrains) legal department are now processing it, and they need to change something.

Comment from legal department: It (software agreement) is very basic and missing some key provisions, such as governing law etc.

mglukhikh commented 4 years ago

Also I cite below the comment from our (JetBrain) legal department about iCLA.

The individual contribution agreements (CLAs) should be modified to reflect that they cover only your contributions to the NetBeans plugin project, not all other contributions you may have made or might make in the future. Apache should be able to narrow it down easily but if not we can help them with the wording provided that we have an editable version of their documentation.

@ebarboni So you or somebody other from Apache could either modify iCLA this way yourself or provide an editable version for us.

vieiro commented 4 years ago

Hi @mglukhikh , I think you'd better fitted with the Corporate Contributor License Agreement (CCLA). Please see [1].

If you read point number 8. there:

It is your responsibility to notify the Foundation when any change is required to the list of designated employees authorized to submit Contributions on behalf of the Corporation, or to the Corporation's Point of Contact with the Foundation.

You'll see that JetBrains has the possibility to modify the list of designated employees authorized to submit Contributions on behalf of JetBrans at any time.

So, for instance, JetBrains could authorize you to submit this contribution and once the contribution is made then remove your authorization to submit any futher contributions.

Would that fit JetBrains' Legal needs?

Thanks, Antonio

[1] https://www.apache.org/licenses/contributor-agreements.html

vieiro commented 4 years ago

Hi @mglukhikh ,

We could find no CCLA or SGA from JetBrains.

The purpose of IP clearance is to make sure that the owners of any IP explicitly grant Apache the rights needed to modify and redistribute the material.

If JetBrains owns all of the IP, then a CCLA or SGA is usually needed.

Where there is a small number of people who wrote all of the material, even if the IP is owned by their employer, then having each of them submit an ICLA (which states in section 4 that they have permission of the IP owner to contribute) will suffice. If there are other IP owners of material here, we need another discussion.

To make forward progress, it might be useful for JetBrains to create a new repository containing only the material that they are granting to Apache.

Please feel free to contact the NetBeans PMC with any questions at private@netbeans.apache.org.

Thanks, Antonio

mglukhikh commented 4 years ago

Hi Antonio @vieiro ,

Our legal department is still processing CCLA. I think this process will be finished after the New Year.

Thanks, Mikhail.

mglukhikh commented 4 years ago

Hi, I have just sent CLA & iCLA to private@netbeans.apache.org.

Chris2011 commented 4 years ago

Hey, what is the state here?

mglukhikh commented 4 years ago

Hey, what is the state here?

+1. Signed documents were sent long ago in January...

geertjanw commented 4 years ago

Did you hear back from Apache about it? If not, we can find out.

Once we’re able to do so, we should create a Kotlin branch on our NetBeans GitHub for the contributed Kotlin code.

mglukhikh commented 4 years ago

Did you hear back from Apache about it? If not, we can find out.

I received only a short e-mail confirming that documents arrived to Apache, nothing else.

geertjanw commented 4 years ago

That's all that you need, great. The documents have been received, there are no objections, so we can go ahead and create a branch with your code -- do you foresee any problems with it, how solid is it in your opinion?

mglukhikh commented 4 years ago

I'd say that when you are doing something first time, you almost always have some problems. This code will definitely need some attention, see e.g. issues in https://github.com/JetBrains/kotlin-netbeans/issues.

asbachb commented 3 years ago

I wonder if there's any status update and/or if someone is working on this and/or the issues @mglukhikh mentioned is blocking getting this into NetBeans.

mglukhikh commented 3 years ago

I just don't know. I was asked about CLA & iCLA, well, we have signed & sent them in the beginning of 2020.

Chris2011 commented 3 years ago

Maybe we should ask @SerVB here. I mean there is still a branch at his repo as far as I can see. The thing is what needs to be done to merge this into master. I think we should not merge this into master until it is stable to use. My 2 cents.

SerVB commented 3 years ago

Sorry, I've just opened the PR to the apache/netbeans repo – my work starts and ends here.

We haven't been asked and haven't planned to make this plugin "stable to use" before merging. That's the idea – we just donate it as is. We hope the new owner will make the plugin working and stable again. I think we've done anything that's required from our side.

SerVB commented 3 years ago

Probably we should try to ask @geertjanw because he asked the initial question here: https://github.com/JetBrains/kotlin-netbeans/issues/137#issue-438694751

neilcsmith-net commented 3 years ago

Agree with @Chris2011 that it probably shouldn't be merged to master until stable to use (although could be left out of builds). Suggest we need a person or persons who have an interest to take ownership, set up a kotlin branch here, and change the base branch for the PR. Probably worth asking about that / galvanising action on dev@ otherwise it's probably going to keep sitting here.

hectorespert commented 3 years ago

I created a new branch called kotlin-donation on Netbeans project. If there isn't any objection, I will merge this PR in that branch.

dayron9110 commented 3 years ago

Any update?

jkost commented 2 years ago

Hallo, I switched to the kotlin-donation branch and tried to build it, after having changed NetBeans dependencies to RELEASE123 (was RELEASE82). After a little of effort I 'm now stuck in the various configurations (pom.xml) which are supposed to be inside ${project.basedir}/lib but of course aren't:

  1. kotlin-ide-common.jar
  2. openapi-formatter.jar
  3. kotlin-formatter.jar
  4. idea-formatter.jar
  5. intellij-core.jar
  6. kotlin-converter.jar
  7. asm-all.jar

I couldn't locate them in maven central repo under group id org.jetbrains.kotlin.

Maybe the JetBrains guys could direct us here?

SerVB commented 2 years ago

Hi @jkost, the answer is inside "hidden items" above in this thread: https://github.com/apache/netbeans/pull/1398#issuecomment-514526578. It won't solve the problem right away but should definitely give some directions.

jkost commented 2 years ago

Thank you for your reply @SerVB. Since it is not a good idea to pollute the NetBeans (or any) repository with binaries, I instead modified the pom.xml like so:

but then I get a number of unresolved references in kotlin code, like e.g.:

--- kotlin-maven-plugin:1.5.31:compile (compile) @ kotlin.netbeans.plugin ---
/Projects/netbeans/netbeans/contrib/kotlin/src/main/java/org/jetbrains/kotlin/completion/KotlinCompletionProposal.kt: (66, 44) Unresolved reference: rawCommentText
/Projects/netbeans/netbeans/contrib/kotlin/src/main/java/org/jetbrains/kotlin/completion/KotlinKeywordCompletion.kt: (39, 66) Unresolved reference: INNER_CLASS
/Projects/netbeans/netbeans/contrib/kotlin/src/main/java/org/jetbrains/kotlin/completion/KotlinKeywordCompletion.kt: (278, 63) Unresolved reference: possibleParentTargetMap
/Projects/netbeans/netbeans/contrib/kotlin/src/main/java/org/jetbrains/kotlin/completion/KotlinKeywordCompletion.kt: (281, 65) Cannot access 'deprecatedParentTargetMap': it is private in 'ModifierCheckerCore'
/Projects/netbeans/netbeans/contrib/kotlin/src/main/java/org/jetbrains/kotlin/completion/completionUtils.kt: (96, 22) Unresolved reference: isVisibleWithAnyReceiver
....

and many many others which I 'm not sure if they are due to the kotlin version (1.5.31) or to something else (I 'm new to kotlin).

ebresie commented 2 years ago

Are any of the dependencies found here?

https://mvnrepository.com/artifact/org.jetbrains.kotlin

devMls commented 1 year ago

Maybe for NetBeans 16?

xhevahir commented 1 year ago

Seems like a functioning Kotlin plugin might be a good way to bring in more users (if indeed they're wanted). Netbeans was ranked last among IDE's in the latest StackOverflow survey: https://survey.stackoverflow.co/2022/?utm%5C_source=so-owned&utm%5C_medium=announcement-banner&utm%5C_campaign=dev-survey-2022&utm%5C_content=results#section-most-loved-dreaded-and-wanted-integrated-development-environment

jkost commented 1 year ago

Are any of the dependencies found here?

https://mvnrepository.com/artifact/org.jetbrains.kotlin

Unfortunately not. As explained in the wiki, there is already an editor that recognizes .kt files. Source code is in 'kotlin-donation' branch.

sndcrde commented 1 year ago

Ioannis (John) Kostaras has managed to resolve the maven dependencies.

Is it versioned somewhere (I mean the code with resolved dependencies) and, if so, can you post a link to it?

there is already an editor that recognizes .kt files.

What good does it really do? Can you compile Kotlin files in NB? Can compiler errors be easily traced back to the source? Anyhow, please post a link to that editor.

Regards,

devMls commented 1 year ago

I agree with @jkost . Kotlin Will be a Big annunce yo the ide

jkost commented 1 year ago

Please see this page https://cwiki.apache.org/confluence/display/NETBEANS/Kotlin+plugin for more information.

Regarding the original plugin https://github.com/JetBrains/kotlin-netbeans donated by JetBrains, help is needed to fix the bugs in the Kotlin code. Anyone fluent in Kotlin that could help?

Regarding the Kotlin support that can already be found under contrib folder of NetBeans, more work is required. What you can do with it is already described in the above page. This page https://cwiki.apache.org/confluence/display/NETBEANS/Adding+New+Language+Support is also useful.

On Fri, Jan 27, 2023 at 6:47 AM devMls @.***> wrote:

I agree with @jkost https://github.com/jkost . Kotlin Will be a Big annunce yo the ide

— Reply to this email directly, view it on GitHub https://github.com/apache/netbeans/pull/1398#issuecomment-1406049265, or unsubscribe https://github.com/notifications/unsubscribe-auth/AADJUYGQSUHEEFOMP2Y36UTWUNOPXANCNFSM4IGNKK3Q . You are receiving this because you were mentioned.Message ID: @.***>

jkost commented 1 year ago

Hello again,

the Kotlin editor (using TextMate language support) can be found here https://github.com/apache/netbeans/tree/kotlin-donation/java/kotlin.editor. The JetBrains contribution (JavaCC) can be found here https://github.com/apache/netbeans/tree/kotlin-donation/contrib/kotlin. I will push my progress to my personal git repo in order not to pollute the NetBeans repo.

Thanks.

John.

On Sat, Feb 4, 2023 at 10:38 PM John Kostaras @.***> wrote:

Please see this page https://cwiki.apache.org/confluence/display/NETBEANS/Kotlin+plugin for more information.

Regarding the original plugin https://github.com/JetBrains/kotlin-netbeans donated by JetBrains, help is needed to fix the bugs in the Kotlin code. Anyone fluent in Kotlin that could help?

Regarding the Kotlin support that can already be found under contrib folder of NetBeans, more work is required. What you can do with it is already described in the above page. This page https://cwiki.apache.org/confluence/display/NETBEANS/Adding+New+Language+Support is also useful.

On Fri, Jan 27, 2023 at 6:47 AM devMls @.***> wrote:

I agree with @jkost https://github.com/jkost . Kotlin Will be a Big annunce yo the ide

— Reply to this email directly, view it on GitHub https://github.com/apache/netbeans/pull/1398#issuecomment-1406049265, or unsubscribe https://github.com/notifications/unsubscribe-auth/AADJUYGQSUHEEFOMP2Y36UTWUNOPXANCNFSM4IGNKK3Q . You are receiving this because you were mentioned.Message ID: @.***>

jkost commented 1 year ago

It seems that the only thing I must have done (it was sometime ago) was to follow the JetBrains' guys advice and update my local maven repo with the dependencies from the kotlin-eclipse plugin (see this thread https://github.com/apache/netbeans/pull/1398) as I don't see and local commits or changed files from my side.

Here are only a few of the compiler errors I see when I maven build the plugin.

Module name is kotlin.netbeans.plugin Supertypes of the following classes cannot be resolved. Please make sure you have the required dependencies in the classpath: class org.jetbrains.kotlin.installer.Yenta, unresolved supertypes: ModuleInstall class org.jetbrains.kotlin.filesystem.KotlinVirtualSourceProvider, unresolved supertypes: VirtualSourceProvider

kotlin-netbeans/src/main/java/org/jetbrains/kotlin/builder/KotlinPsiManager.kt: (19, 29) Unresolved reference: util kotlin-netbeans/src/main/java/org/jetbrains/kotlin/builder/KotlinPsiManager.kt: (20, 29) Unresolved reference: util kotlin-netbeans/src/main/java/org/jetbrains/kotlin/builder/KotlinPsiManager.kt: (21, 29) Unresolved reference: vfs kotlin-netbeans/src/main/java/org/jetbrains/kotlin/builder/KotlinPsiManager.kt: (22, 21) Unresolved reference: psi kotlin-netbeans/src/main/java/org/jetbrains/kotlin/builder/KotlinPsiManager.kt: (23, 21) Unresolved reference: psi kotlin-netbeans/src/main/java/org/jetbrains/kotlin/builder/KotlinPsiManager.kt: (32, 29) Unresolved reference: idea kotlin-netbeans/src/main/java/org/jetbrains/kotlin/builder/KotlinPsiManager.kt: (33, 29) Unresolved reference: idea kotlin-netbeans/src/main/java/org/jetbrains/kotlin/builder/KotlinPsiManager.kt: (35, 29) Unresolved reference: psi kotlin-netbeans/src/main/java/org/jetbrains/kotlin/builder/KotlinPsiManager.kt: (36, 21) Unresolved reference: api kotlin-netbeans/src/main/java/org/jetbrains/kotlin/builder/KotlinPsiManager.kt: (37, 21) Unresolved reference: api kotlin-netbeans/src/main/java/org/jetbrains/kotlin/builder/KotlinPsiManager.kt: (38, 12) Unresolved reference: openide ....

I would propose to use the #plugin-developers slack channel to provide support to those who wish to help resolve these issues on how to build the java part and then concentrate on the kotlin part.

Kind regards,

John.

On Sun, Feb 5, 2023 at 11:11 PM John Kostaras @.***> wrote:

Hello again,

the Kotlin editor (using TextMate language support) can be found here https://github.com/apache/netbeans/tree/kotlin-donation/java/kotlin.editor. The JetBrains contribution (JavaCC) can be found here https://github.com/apache/netbeans/tree/kotlin-donation/contrib/kotlin. I will push my progress to my personal git repo in order not to pollute the NetBeans repo.

Thanks.

John.

On Sat, Feb 4, 2023 at 10:38 PM John Kostaras @.***> wrote:

Please see this page https://cwiki.apache.org/confluence/display/NETBEANS/Kotlin+plugin for more information.

Regarding the original plugin https://github.com/JetBrains/kotlin-netbeans donated by JetBrains, help is needed to fix the bugs in the Kotlin code. Anyone fluent in Kotlin that could help?

Regarding the Kotlin support that can already be found under contrib folder of NetBeans, more work is required. What you can do with it is already described in the above page. This page https://cwiki.apache.org/confluence/display/NETBEANS/Adding+New+Language+Support is also useful.

On Fri, Jan 27, 2023 at 6:47 AM devMls @.***> wrote:

I agree with @jkost https://github.com/jkost . Kotlin Will be a Big annunce yo the ide

— Reply to this email directly, view it on GitHub https://github.com/apache/netbeans/pull/1398#issuecomment-1406049265, or unsubscribe https://github.com/notifications/unsubscribe-auth/AADJUYGQSUHEEFOMP2Y36UTWUNOPXANCNFSM4IGNKK3Q . You are receiving this because you were mentioned.Message ID: @.***>

bdrx312 commented 1 year ago

I was looking to use gradle with netbeans, but want to kotlin to have statically type configuration instead of groovy. Having a kotlin plugin in order to better use gradle in netbeans would be useful. Did netbeans ever get a functioning kotlin plugin?

jkost commented 1 year ago

Please look at the current status here https://cwiki.apache.org/confluence/display/NETBEANS/Kotlin+plugin.

K/r,

John

On Sat, Jun 10, 2023 at 12:07 AM bdrx312 @.***> wrote:

I was looking to use gradle with netbeans, but want to kotlin to have statically type configuration instead of groovy. Having a kotlin plugin in order to better use gradle in netbeans would be useful. Did netbeans ever get a functioning kotlin plugin?

— Reply to this email directly, view it on GitHub https://github.com/apache/netbeans/pull/1398#issuecomment-1585179485, or unsubscribe https://github.com/notifications/unsubscribe-auth/AADJUYDXPSMXA6BC7YIW7JLXKOND3ANCNFSM4IGNKK3Q . You are receiving this because you were mentioned.Message ID: @.***>