Eclipse - servlet creation error - eclipse-plugin

I am getting the following error when I try to use the Eclipse IDE wizard to create a Servlet:
"java.lang.Eror: Unresolved compilation problems:
The import org.eclipse.jst.j2ee.internal.common cannot be resolved.
CreateServletTemplateModel cannot be resolved to a type
....
"
The settings of the IDE are as follows:
Eclipse Version: 3.4.2
WTP Servlet UI Plug-in: 1.1.203.v20081022000
(org.eclipse.jst.servlet.ui)
I don't have any problems manually creating the Servlets, I just would like the IDE to work as it's supposed to in order to avoid the overhead.
Any help would be greatly appreciated.

As mentioned here, that could be linked to a WTP installation issue.
Try to see if you still have the problem with:
WTP3.0.5 (compatible with your eclipse3.4.2)
or
with the J2EE package (all-in-one distribution, see here for ganymede - 3.4.2 - packages)
Note: in both cases, you can duplicate your eclipse 3.4 installation, points to a fresh workspace and do your tests here (in order to avoid modifying anything from your current setup).

Related

Error while Installing TestNG Eclipse Plugin 6.14.3 Version

I am getting the following error while installing TestNG plugin( 6.14.3) in Eclipse.
Missing requirement: TestNG Eclipse Support 6.14.3.201902250526
(org.testng.eclipse 6.14.3.201902250526) requires 'bundle
org.eclipse.jdt.launching 3.10.0' but it could not be found Cannot
satisfy dependency: From: TestNG 6.14.3.201902250526
(org.testng.eclipse.feature.group 6.14.3.201902250526) To:
org.testng.eclipse [6.14.3.201902250526]
I am using Eclipse Oxygen- March Edition. Could anyone please help me here?
Your version on Eclipse (Oxygen) is too old for that version of TestNG.
Version 3.10.0 of org.eclipse.jdt.launching was not introduced until Eclipse Photon so you need at least that version of Eclipse, but preferably the current version (Eclipse 2018-12 at time time of writing)
We had same issue for several employees. In our case it doesn't relate to Eclipse version.
Seems as new WebSense antivirus blocked the installation of the TestNG from default location. Eclipse showed the error from the description and continued to look for "alternative solution" which took many hours, but finally TestNG was installed successfully. Just have patience. Or try to disable antivirus.
let process to continue in spite of the error
Thanks Greg and Ilana.
TestNG installed successfully when the Eclipse was updated to 2018-12 Version.
If you are facing issue while installing TestNG in Eclipse version there are few simple steps to follow:
Download zipped latest version of Eclipse from below location (http://dl.bintray.com/testng-team/testng-eclipse-release/)
Store it your drive (zipped folder suppose in C drive)
After that go to Eclipse and install new software, click on add, archive, and complete the installation by selecting Next option when prompted)
Restart Eclipse you will see TestNG option in there.
while installing from add new software ,there is an option to check for solution rather than default selection. Please select different version of TestNG which is compatible with your eclipse version .This solution worked for me while using eclipse Mars(4.5.2)

How to debug an IntelliJ plugin in a different platform (eg. Pycharm)

I have a license for PyCharm Professional and am using IntelliJ IDEA Community Edition to develop a plugin for it. I need to run the plugin in PyCharm to test it out. I can't use the Python plugin for IntelliJ IDEA to test it as only the Community edition of the plugin appears to be available for me. If I manually download the professional version and try to install it I get Plugin 'Python' is incompatible with this installation. I assume I would need IntelliJ IDEA Ultimate to be able to use the professional version of the Python plugin.
I saw this question, which suggests it is possible to use PyCharm as the target for a "Plugin" run configuration, but I haven't had any luck following those steps. I set the JRE to /opt/pycharm-professional/jre64 but got Exception in thread "main" java.lang.ClassNotFoundException: com.intellij.idea.Main. I then grabbed the java command line args from a running instance of PyCharm and added those in (particularly the classpath) but got Error: Could not find or load main class com.intellij.rt.execution.application.AppMainV2. I haven't been able to find anything in the docs on how to set this up.

Inspecting code on a non-java IntelliJ IDEA project

I'm using IntelliJ IDEA to build a non-java project, it is just a PHP + Javascript project, everything is working just fine but when I try to Inspect all the code in the project (Analyze -> Inspect Code) I get an error:
The JDK is not configured properly for this project. Inspection cannot proceed.
Am I doing something wrong? Do I have to configure an SDK even though the project is not java?
Note: The automatic code inspection for working files opened in the editor is working fine, the only problem is when I try to inspec all the code in the project.
Note 2: I cannot use PHPStorm neither Webstorm.
Thanks.
In my case, I didn't wanted to delete the module since I have a bunch of stuff configured (data sources, dictionaries, http requests) and a lot of code in the shelf (which I believe it's stored along the project/module). I found that you can skip the "delete your module" part and instead just update the module config:
Find the $module.iml file (in my case it's inside the .idea directory) and at the top there's was a line:
<module type="JAVA_MODULE" version="4">
which I changed to:
<module type="WEB_MODULE" version="4">
The issue was fixed and I haven't seen any side-effects but, just in case, you might want to backup the .idea directory.
I raised this over at https://youtrack.jetbrains.com/issue/IDEA-188017 - after some back and forth, the Jetbrains employee helped me figure out that I had a Java module in there.
If you are not using Java, please crate a module of a Static Web type. Now you have a module of a Java type, that is why the error is reported, so such behaviour is expected.
Delete your Java module.
Once you enter in the menu in the screenshot below, find the Static Web type and create your module like that.
Seems like adding a SDK the code analyzer works just fine, even though the project has no single java module.
Maybe it is a bug, so I will report it.
My project's .idea/<project>.iml file had an entry:
<orderEntry type="inheritedJdk" />
I quit Idea, removed the line above from the iml file, restarted Idea and the next Inspection ran without any issues.
I recently ran into this issue with my purely Python project.
After much frustation, I bumped into a rather bizarre solution:
When IntelliJ complained that JDK is not configured, in the following dialog box, I just selected JDK8 (instead of Python 3.7.2 path) and viola! its gone.
My environment was
IntelliJ IDEA 2018.3.4 (Community Edition)
Build #IC-183.5429.30, built on January 29, 2019
JRE: 1.8.0_152-release-1343-b26 x86_64
JVM: OpenJDK 64-Bit Server VM by JetBrains s.r.o
macOS 10.14.2

IntelliJ Datanucleus Enhancer plugin not working

The project I'm developing uses Datanucleus 2.0.3, so I'm using those libraries for enhancement (plugin is configured to use the module dependencies as well). IntelliJ version 12.0.1 on a Ubuntu 12.4 machine. I know the 2.0.3 is ancient history but upgrading it at least now is not an option for me.
From gradle all works fine. I imported by project to IntelliJ and when I ran the tests from junit I got the usual ClassNotPersistenceCapableException so I recalled I need a plugin for this.
I installed the newest plugin (tried both the beta and the last stable version) and configured the plugin to enhance my this one module. I chose JDO and applied, it discovered all the classes annotated for persistence, I rebuilt the whole project, ran the tests again and the same error occurs.
some things I've noticed / checked:
- the Enchaner is ticked in "Build / Datanucleus Enhancer"
- looked for multiple datanucleus jars, but there is only one
- haven't seen any message in IntelliJ in the Event Log saying is has done enhancing (the gradle enhancer logs such a message)
- haven't seen any error messages in IntelliJ saying enhancement failed, I also didn't find any log files outside IntelliJ (should there be any?)
- when I manually added the gradle built classes at the top of the classpath for the test the tests passed - but this is no good
- the module has the following datanucleus 2.0.3 jars on it's classpath: datanucleus-core, datanucleus-enhancer, datanucleus-connectionpool, datanucleus-rdbms and the asm-3.1.jar (the dependencies say it's 3.0-4.0 so this one should fit)
I have no idea why it sees the classes but doesn't enhance them, or maybe it does try and silently fail ... but then I don't know how to diagnose the problem
No other ideas come to my mind, please advise what to check or what to try.

FindBugs Plugin In NetBeans.

I get the following error when I try to install FindBugs plugin in Netbeans. Can anyone help me how to resolve -
The plugin org.apache.commons.lang is requested in version 2.4.0.
The following plugin is affected:       FindBugs
Some plugins require plugin Settings API to be installed.
The plugin Settings API is requested in version >= 1.33.1 but only 1.31.1 was found. The following plugin is affected:       FindBugs
Some plugins require plugin UI Utilities API to be installed.
The plugin UI Utilities API is requested in version >= 7.39.1 but only 7.31.2 was found.
The following plugin is affected:       FindBugs
Some plugins not installed to avoid potential installation problems.
As it is answered here, you might be using an old ScanOnDemand plugin, you can add the latest Development Plugins to your Plugins: Plugins > Settings Tab > Add and use the following URL to add a new NB Plugins source:
http://deadlock.netbeans.org/hudson/job/nbms-and-javadoc/lastStableBuild/artifact/nbbuild/nbms/updates.xml.gz
I have tried this solvation, added the source above with name 'Plugin Resource' and checked available plugins. There, Findbugs Integration plugin appeared and installed successfully. When i restarted the ide to finish the installation, it generated an error and never started again.
Thus, i have downloaded netbeans 7.3 from this link and replaced with the old one (7.0.1) on my computer. Now Findbugs plugin is availabe in the list of available plugins without any additional configuration and works flawless. I recommend you to upgrade your ide to 7.3 and solve your problem. This will fix the problems that may occure in the future because of the lack of version of your current netbeans ide.
In addition, after updating the ide, you can use the findbugs plugin installing from this source. This plugin provides to use findbugs explicitly from the inspector.