i setup debug differently but still based on the lux-render tutorial.
first, create the a .py file, lets call it debug.py, which will contain a function which we will call later to setup debugging. put this file in the same folder as the main
__init__.py of your module. as per the lux-renderer tutorial, add the following code, updating pydev_source_dir.
import sys def startdebug(): try: # set the pydev_source_dir correctly before using the debugger pydev_source_dir = 'c:\program files\eclipse\plugins\org.python.pydev.debug_220.127.116.112040618\pysrc' # test if pydev_source_dir already in sys.path, otherwise append it if sys.path.count(pydev_source_dir) < 1: sys.path.append(pydev_source_dir) # import pydevd module import pydevd # set debugging enabled pydevd.settrace(none, true, true, 5678, false, false) except: pass
when setting the pydev_source_dir ensure you point it to the org.python.pydev.debug_xxxxx. there is another folder similiar to this. to ensure you have the correct folder it will contain a /pysrc folder.
now in your main
__init__.py, this must come before any other import statements to work correctly. add the following directly under the bl_info section, as strangely blender parses this itself.
debugging = true if(debugging): import debug debug.startdebug()
having it here will avoids adding per file traces like the lux-render tutorial.
- add some breakpoint to the version in the add-ons folder,
- switch to the debug perspective,
- start eclipses debug server,
- start blender
- run the script and it will hit the breakpoint.
the common problems i find people encounter:
- pointing the path to the wrong pydev debug folder, ensure that there is a /pysrc folder
- when pydev updates, update the pydev_source_dir as the debug_xxxxx will have change
- not having eclipse server running,
- setting breakpoints on a local copy of the files instead of the version in the blender add-on directory
- saving the script does not mean that blender will reload it, use imp, disable/renable the add-on or restart blender.
there are good instructions for setting up blender and eclipse for debugging. http://wiki.blender.org/index.php/user:z0r/pydevandprofiling
while this is for blenders game engine, much of it applies to regular blender. hope this help!
edit: i deleted it because i felt that this doesn't answer your question. but here it is since you insisted.
- Setup of PyDev and Eclipse for Blender Add-Ons
- How to setup remote debugging with Eclipse and PyDev
- How to add existing files to project using Eclipse and PyDev
- How do you add a PHP framework to code completion/assist in Eclipse PDT and can the framework be added as default for all projects?
- Installing pyDev and other plugins for Eclipse
- How to install and setup Cucumber jar files in Eclipse for WebDriver Testing
- How do you setup eclipse so that it parses and underlines errors for C like it does for Java?
- Are there command line arguments to import and setup projects for Eclipse + EGit?
- Eclipse - setup for both RIM Blackberry and Android development
- Configure Eclipse and PyDev for PyQt5 QtWebEngineWidgets?
- Eclipse and Pydev integration for Edx souce code
- Is there a way to enable autocompletion for PyQt5 with Eclipse Kepler and PyDev 2.8?
- "unable to read repository" for "all" Red Hat add ons into Eclipse 2020-06
- Eclipse Blender and PyDev Unresolved import pydevd
- Config for ubuntu 14.04, eclipse Neon, python 2.7, Django 1.9, Pydev and virtualenv doesn't create src folder
- I cannot add python interpreter for PyDev in eclipse
- How to setup development environment for Google Appengine Java Managed VM using Eclipse and Maven
- How to add tags noautocollapse and NoClose in partstack for Eclipse 3.x perspectives
- how to setup tomcat and eclipse for centralized evironment
- how to add taglibs and jar files in eclipse for autosuggest?
- Eclipse Workspaces: What for and why?
- What is the difference between Eclipse for Java (EE) Developers and Eclipse Classic?
- What is the eclipse shortcut for auto-generating a default and field constructor?
- How to add shortcut keys for java code in eclipse
- Aptana Plugin for Eclipse and jQuery code assist
- Eclipse with Lombok - search for getter and setter usages
- How to remove trailing whitespace in PyDev plugin for Eclipse
- How to use Gradle to generate Eclipse and Intellij project files for Android projects
- Alternative to Eclipse for C and C++ development?
- Setting up Eclipse Juno with PyDev and Virtualenv
More Query from same tag
- xdebug not seeing class variables
- Ruby selenium cannot load such file -- selenium-webdriver (LoadError)
- Eclipse with Groovy-eclipse not showing New > Groovy Class option
- IBM Worklight 6.2 Development Server Stops Automatically
- What is M2M Mihini framework?
- How to get getStateLocation() in the eclipse plugin that implements BundleActivator?
- Pydev + Eclipse not doing code analysis on a new project
- Why does my Eclipse keep not responding?
- how to run sonar lint on Spring tool suite
- Mylyn in Eclipse - No Finish or Next?
- Can we directly point to a node from Eclipse AST instead of visiting all the nodes
- Deploy a web application that depends on standalone application
- CSV Conversion Does not recognize special characters
- How do I set a bookmark in Zend Studio?
- Petclinic spring-mvc example not building
- TestNG cannot contact RemoteTestNG on Eclipse
- JRebel: how to disable hbm2dll schema export in JRebel?
- Hibernate: How can i resolve java.lang.IncompatibleClassChangeError:
- How to edit google spreadsheets using java in eclipse
- How do I code a recursive a recursive method that forms the integer sum of all valid numerics substrings in a string?
- Configuring Log 4j for GWT Application in Eclipse
- Android Accelerometer App detects only two directions
- Tycho: Dependencies to other plugins of the project cannot be resolved when building plugins separately
- How to sending data from android studio with asychronous http post to xampp and run it in real device?
- Android Studio : Unable to find any references to the Android Gradle plug-in in build.gradle files
- How to specify the correct URL to a file in a Eclipse project
- Error in GMaven Plugin
- Gradle Multi-project test dependencies no longer working in Eclipse for Gradle 6.7