pydev

PySpark in Eclipse: using PyDev

夙愿已清 提交于 2019-12-17 16:54:15
问题 I am running a local pyspark code from command line and it works: /Users/edamame/local-lib/apache-spark/spark-1.5.1/bin/pyspark --jars myJar.jar --driver-class-path myJar.jar --executor-memory 2G --driver-memory 4G --executor-cores 3 /myPath/myProject.py Is it possible to run this code from Eclipse using PyDev? What are the arguments required in the Run Configuration? I tried and got the following errors: Traceback (most recent call last): File "/myPath/myProject.py", line 587, in <module>

How to persist PYTHONPATH setting of an Eclipse Pydev project?

折月煮酒 提交于 2019-12-17 16:47:10
问题 I can setup a working PYTHONPATH using project properties, but it seems like after every reboot, I have to manually reset it. Is there a good way to persist the PYTHONPATH associated with a project? 回答1: When you set the PYTHONPATH for a project, pydev will create a .pydevproject file in the root of your project. Make sure that file is being properly written (it could be that your project is read-only or something like that which could prevent PyDev from writing that file where the settings

Unresolved import: models

落花浮王杯 提交于 2019-12-17 15:49:14
问题 I'm doing my VERY first project using python/django/eclipse/pydev following this guide http://docs.djangoproject.com/en/dev/intro/tutorial01/ My only addition is the use of Eclipse/pydev. I'm getting many errors related to "Unresolved imports". I can remove the errors using "remove error markers" and my site runs perfect (I can browse it) but I want to get rid definitively of this problem since errors pop up again after I removed them. Any ideas? EDIT Using Ubuntu 9.1 回答1: Check your

Can Eclipse refresh resources automatically?

放肆的年华 提交于 2019-12-17 04:45:07
问题 Eclipse (3.4.2 with PyDev) deals with out-of-sync resources (files that have been edited outside of the IDE) differently from other IDEs that I've used, where only resources with editors open are considered out-of-sync. In Eclipse, any resource can go out of sync. This means that when I perform a search after any file has changed outside of Eclipse, I get an error dialog telling me that files are out of sync, even if they have no open editors. As far as I can tell, there is no global refresh

Can Eclipse refresh resources automatically?

空扰寡人 提交于 2019-12-17 04:44:30
问题 Eclipse (3.4.2 with PyDev) deals with out-of-sync resources (files that have been edited outside of the IDE) differently from other IDEs that I've used, where only resources with editors open are considered out-of-sync. In Eclipse, any resource can go out of sync. This means that when I perform a search after any file has changed outside of Eclipse, I get an error dialog telling me that files are out of sync, even if they have no open editors. As far as I can tell, there is no global refresh

Unresolved Import Issues with PyDev and Eclipse

北城以北 提交于 2019-12-17 03:23:05
问题 I am very new to PyDev and Python, though I have used Eclipse for Java plenty. I am trying to work through some of the Dive Into Python examples and this feels like an extremely trivial problem that's just becoming exceedingly annoying. I am using Ubuntu Linux 10.04. I want to be able to use the file odbchelper.py, which is located in the directory /Desktop/Python_Tutorials/diveintopython/py Here is my example.py file that I'm working on in my PyDev/Eclipse project: import sys sys.path.append

Error of running an executable file from Python subprosess

旧时模样 提交于 2019-12-14 02:24:47
问题 I am trying to run an executable file (a linear programming solver CLP.exe) from Python 3.5. Import subprocess exeFile = " C:\\MyPath\\CLP.exe" arg1 = "C:\\Temp\\LpModel.mps" arg2 = "-max" arg3 = " -dualSimplex" arg4 = " -printi all" arg5 = "-solution t solutionFile.txt" subprocess.check_output([exeFile, arg1, arg2, arg3, arg4, arg5], stderr=subprocess.STDOUT, shell=False) When I run the python file in Eclipse PyDev, I can see the results in Eclipse console. But, no solution results are saved

Error during runfile in Eclipse with PyDev/ error initializing console

梦想的初衷 提交于 2019-12-13 22:16:21
问题 Using a PyDev console in Eclipse, which initially worked fine. Python code would work inside the console. When I started writing a file within a PyDev module, I tried executing runfile() but the console that had already initialized with python returns this error: Failed to parse server's response: Expected methodResponse element, got head127.0.0.1 - - [18/Jul/2015 13:55:14] code 400, message Bad HTTP/0.9 request type ('POST') After which, I closed the console and restarted Eclipse. Now, when

PyDev in Debug mode: NameError: dict_pop when importing pandas or xarray

久未见 提交于 2019-12-13 21:58:24
问题 I'm running code to read data from a NetCDF file from a URL with xarray. When I run this code in Eclipse/PyDev in debug mode I am seeing errors that don't happen when launching as a normal Python run or from the command line or as cells of a Jupyter notebook. I get the following error when I include an import xarray in my code: NameError: name 'dict_pop' is not defined Full stack trace looks like this: pydev debugger: starting (pid: 4004) URL: https://www.ncei.noaa.gov/data/nclimgrid

Code Coverage not working with PyDev

情到浓时终转凉″ 提交于 2019-12-13 19:15:11
问题 First, sorry for asking again. I found some posts on this topic, but none of the recommendations worked for me. The outcome is well known: PyDev always reports "File has no statistics". In a previous installation (Linux and Windows) I saw this working as described in the PyDev homepage. This is my installation: Ubuntu 15.10 Eclipse Mars.1 PyDev 4.4.0.201510052309 python 3.4 coverage 4.0.3 (found in /usr/local/lib/python3.4/dist-packages) In Eclipse/PyDev the Coverage view is shown, the basic