None, False, True reported as undefined variables - pydev

I am using PyDev 3.0.0 (Eclipse 4.4.1). After an update a few days ago, PyDev is reporting "Undefined variable" one a large number of keywords, most notably None, True and False; errors are being reported on 30-40% lines of code in all projects. However, all projects and scripts can be run from Eclipse without issue.
In Juno there was an issue with similar symptoms caused by an interpreter misconfiguration. But in Luna these false errors are being reported with the interpreter auto-configured. I have tried switching between the 2.7 and 3.4 interpreters, but these errors remain.
Update I: the precise versions reported at the About Eclipse menu:
Version: Luna Service Release 1 (4.4.1)
Build id: 20140925-1800
Feature Name: Pydev - Python Development
Version: 3.0.0.201406111920-7v777uVyx2EKHY
Update II: this is now bug #549 at the PyDev bug tracker.

Related

Error when open eclipse - MAC

I have installed eclipse on my iMac and when I try to open it, it gives me this error:
Failed to find a Main Class in
"/Applications/Eclipse.app/Contents/MacOS//../Eclipse/ plugins/org.eclipse.equinox.launcher_1.5.0.v20180512-1130.jar".
On my MacBook Pro, everything works fine, but I have done nothing different.
I have checked other posts, but most of them refer to a windows OS. There was an answer which said that it can just open when everything is in an English folder and this is true for me!
Thanking you in advance!
I came across this error after installing Eclipse PDT.
Open your terminal and run the version command: java -version.
If your java version is below 1.8, you will have to update your Java
Runtime Environment to at least 1.8.0 by installing an updated JDK
here.
Then re-run the java version command and your version
should be updated.
You should now be able to install and run
Eclipse.
I have the same issue, but on my MacBookPro. I first installed eclipse Photon, which when starting up prompted me to install Java 6, which I did from https://support.apple.com/kb/DL1572?locale=en_US
Then I also installed the latest JRE (jre-8u171-macosx-x64 as of yesterday). When running eclipse again I started getting this error. Then I tried to run from the command line, and got this error:
Exception in thread "main" java.lang.UnsupportedClassVersionError: org/eclipse/equinox/launcher/Main : Unsupported major.minor version 51.0
When googling that, the answers said that the reason for that is that the Oracle installer does not update the symlink in /usr/bin, which seemed to be confirmed by the fact that running java -version returned this:
java -version
java version "1.6.0_65"
The solutions I found for that were not feasible in MacOS starting in version El Capitan, and I am on High Sierra, so I followed the instructions in this post to fix that, and it worked, now I get:
java -version
java version "1.8.0_171"
Java(TM) SE Runtime Environment (build 1.8.0_171-b11)
Java HotSpot(TM) 64-Bit Server VM (build 25.171-b11, mixed mode)
After all of this, however, I get the same "Failed to find a Main Class" error on the dialog as reported initially here, and the same "UnsupportedClassVersionError" on the CLI that I had when the system was still on java 6, so now I am still stuck and out of ideas.
EDIT: FIXED IT!!
I kept thinking that the problem was the java version, it was somehow still using java 6 (which I had installed due to the initial prompt).
So I followed the instructions here to remove what I had installed for the alleged java 6 issue. Then I found this post in the eclipse forums, which stated at the end (comment added by Eric Rizzo on Tue, 14 February 2017 21:56) that this is not an Eclipse message, but rather an OS message, and that one should NOT do that as apple messed things up with that patch. And then it goes to explain that one should install java 8 JDK (NOT just the JRE as I had done). Once I removed Java 6 and installed the full java 8 JDK, it ran fine :)
You can edit the eclipse.ini with your vm configuration in the beginning of the file
-vm
/yourJvmPath/jdk-12.0.1.jdk/bin/java
cat /Applications/Eclipse.app/Contents/Eclipse/eclipse.ini
-vm
/Users/SomeUser/jdk-12.0.1.jdk/bin/java
-startup
../Eclipse/plugins/org.eclipse.equinox.launcher_1.5.400.v20190515-0925.jar
--launcher.library
../Eclipse/plugins/org.eclipse.equinox.launcher.cocoa.macosx.x86_64_1.1.1000.v20190125-2016
PD. It works with ApacheDirectoryStudio for MAC
This one works for me with MAC OS Mojave.
You can download the Java SE Development Kit 8u221 for mac from the below link.
jdk-8u221-macosx-x64.dmg
https://www.oracle.com/technetwork/java/javase/downloads/jdk8-downloads-2133151.html

RoboVM not working on JDK 1.8.0 b112

I'm running Eclipse with RoboVM plugin and I wanted to try IOSDemo sample project described on robovm.org (http://www.robovm.org/docs.html). When creating the project in Eclipse and running it I got following error message.
An internal error occurred during: "Launching IOSDemo".
java.lang.IllegalAccessError: tried to access method java.lang.Object.clone()Ljava/lang/Object; from class soot.toolkits.scalar.LocalSplitter
I found out that it's related to JDK version (I'm running JDK 8.0 ea, build 112). When running on JDK 1.7.0_45 and building the project on cmd line it builds and runs OK.
Is it known problem, is there any workaround or fix? Thanks
This is most probably due to a bug [1] in the recent early access builds of Java8. It looks like the bug was resolved a few days ago but as far as I can see the fix didn't make it into the b113 build. Please use the latest Java7 release or an earlier Java8 EA build until a Java8 build is available with this fix included.
[1] https://bugs.openjdk.java.net/browse/JDK-8026394

Worklight Studio plug-in for Indigo in Windows 7

I cannot seem to get Worklight to install properly. I am using Windows 7 32 bit Operating System and a clean installation of Indigo(eclipse-jee-indigo-win32). When trying to install Worklight from Help -> Eclipse Marketplace
I got the following message:
An error occurred while collecting items to be installed
session context was:(profile=epp.package.jee, phase=org.eclipse.equinox.internal.p2.engine.phases.Collect, operand=, action=).
Artifact not found: osgi.bundle,org.eclipse.wst.jsdt.support.ie,1.0.500.v20130201_1508.
http://public.dhe.ibm.com/ibmdl/export/pub/software/mobile-solutions/worklight/wdeupdate/plugins/org.eclipse.wst.jsdt.support.ie_1.0.500.v20130201_1508.jar
Artifact not found: osgi.bundle,com.ibm.etools.attrview,1.0.100.v20120918_0208.
http://public.dhe.ibm.com/ibmdl/export/pub/software/mobile-solutions/worklight/wdeupdate/plugins/com.ibm.etools.attrview_1.0.100.v20120918_0208.jar
Artifact not found: osgi.bundle,com.ibm.etools.webtools.dojo.library,1.0.600.v20130222_1636.
http://public.dhe.ibm.com/ibmdl/export/pub/software/mobile-solutions/worklight/wdeupdate/plugins/com.ibm.etools.webtools.dojo.library_1.0.600.v20130222_1636.jar
Artifact not found: osgi.bundle,com.ibm.etools.webtools.views,7.0.400.v20120918_0238.
http://public.dhe.ibm.com/ibmdl/export/pub/software/mobile-solutions/worklight/wdeupdate/plugins/com.ibm.etools.webtools.views_7.0.400.v20120918_0238.jar
Problems downloading artifact: osgi.bundle,com.ibm.imp.webtools.dojo.library.distributions,2.0.0.v20130222_1636.
MD5 hash is not as expected. Expected: f684f4987bf9c1c8fd7a11b0e236c696 and found ebfb1b8103c514843cfa6df80943b177.
Problems downloading artifact: osgi.bundle,com.ibm.imp.worklight.simulation.ui,1.0.300.201303110941.
MD5 hash is not as expected. Expected: 0365031246d3315fa96efeea94516084 and found b188214e58bf88bb7ea89f88e08c6d2c.
Problems downloading artifact: osgi.bundle,com.worklight.worklight-builder,5.0.6.20130311-0918-developer-edition.
MD5 hash is not as expected. Expected: 8dc2626664d5e6a2e04ee222602ba13d and found 2205fbf0b7dfd192232aba0e9eda0820.
When I tried to Install again from Help > Install new software(By adding Worklight Studio - http://www.ibm.com/developerworks/mobile/worklight/).
I got the following messages in the add new software window:
Coudnt find http://www.ibm.com/developerworks/mobile/worklight/
Is anyone else seeing a (new) problem installing Developer Edition from the Marketplace in Indigo???
You have to install this version:
http://www.eclipse.org/downloads/packages/eclipse-ide-java-ee-developers/junosr2
"IBM Worklight Developer Edition on Eclipse Marketplace only supports Eclipse version 4.2.2 (SR2), Eclipse IDE for Java EE Developers edition. If you install on earlier versions or different editions of Eclipse you will see errors."
You are not using the correct repository URL (or a repository URL at all...).
Use this URL:
http://public.dhe.ibm.com/ibmdl/export/pub/software/mobile-solutions/worklight/wdeupdate/
Before doing so, make sure your Eclipse Java EE 3.7 (Indigo) installation is up-to-date.
Go to Help >> Check for updates. However, I strongly recommend starting fresh using a new installation of Eclipse Java EE 4.2.2 (Juno SR2).

PyDev "New Project" crashes Eclipse

I'm a Python and PyDev newbie. My environment is OS X 10.6.11, Eclipse Indigo, PyDev 2.7.1, Python 2.6 and 3.3.
Starting from any perspective (PyDev, Java, others), selecting New->Project->PyDev->PyDev Project results in an endless spinning color beachball. The only way out is to Force Quit Eclipse.
Starting from the PyDev perspective, if I select New->Project, and then select General->Project, the same crash occurs.
My only recourse seems to be to create a generic project from, say, the Java perspective, then right-click the project in the package explorer view and choose PyDev->Set as PyDev Project, then switch to the PyDev perspective, then configure the project folder manually.
Am I missing something in my installation? Is this a known problem with PyDev?
Very similar problem here. Commenting out in case there's any follow up.
I'm using Kubuntu 15.04, Eclipse 3.8, Python 2.7 and 3.4, and what I assume is PyDev 4.2 or 4.3.
I am also a newbie, trying django framework. Creating a new PyDev-django project crashes Eclipse. When opening it again, I cannot continue creating or import it.
Here is some info about the crash, thank you for your help.
# A fatal error has been detected by the Java Runtime Environment:
#
# SIGSEGV (0xb) at pc=0x00007fc966da042d, pid=9132, tid=140503295805184
#
# JRE version: OpenJDK Runtime Environment (7.0_79-b14) (build 1.7.0_79-b14)
# Java VM: OpenJDK 64-Bit Server VM (24.79-b02 mixed mode linux-amd64 compressed oops)
# Derivative: IcedTea 2.5.6
# Distribution: Ubuntu 15.04, package 7u79-2.5.6-0ubuntu1.15.04.1
# Problematic frame:
# C [libgobject-2.0.so.0+0x3342d] g_type_check_instance_is_fundamentally_a+0xd
#
# Failed to write core dump. Core dumps have been disabled. To enable core dumping, try "ulimit -c unlimited" before starting Java again

PyDev and Eclipse Juno

I am running Eclipse 4.2, PyDev worked fine with it until recently it stopped working (there is no longer a PyDev View), if I try to update pydev, I get this error:
Cannot complete the install because one or more required items could not be found.
Software currently installed: Eclipse SDK 4.2.0.I20120608-1400 (org.eclipse.sdk.ide 4.2.0.I20120608-1400)
Missing requirement for filter properties ~= $0: Eclipse Product Configuration 1.0.0.I20120608-1400 (org.eclipse.rcp.configuration.feature.group 1.0.0.I20120608-1400) requires 'org.eclipse.rcp.configuration_root.gtk.linux.x86 [1.0.0.I20120608-1400]' but it could not be found
Cannot satisfy dependency:
From: Eclipse SDK 4.2.0.I20120608-1400 (org.eclipse.sdk.ide 4.2.0.I20120608-1400)
To: org.eclipse.rcp.configuration.feature.group [1.0.0.I20120608-1400]
I just realised it says: org.eclipse.rcp.configuration_root.gtk.linux.x86. I recently upgraded my system from 32bit to 64bit, might that be the reason and if it is the reason how can I fix it?
Removing ~/.eclipse and reinstalling all plugins solved the problem.