Page 2 of 3

Re: PyCharm Problem?

PostPosted: Sat Nov 16, 2019 11:47 am
by jay (support)
So, the Plugins preference tab looks like this at the bottom:

grab4.png
grab4.png (11.48 KiB) Viewed 2210 times


but your plugin's menu doesn't look like this at the top:

grab3.png
grab3.png (13.02 KiB) Viewed 2210 times


Note that you have to close the preferences dialog for the change to take effect.

Re: PyCharm Problem?

PostPosted: Sun Nov 17, 2019 8:43 am
by dclonts
Correct. PyCharm enabled. Debug menus enabled. But I do not have the debug options. See attached.

Re: PyCharm Problem?

PostPosted: Sun Nov 17, 2019 8:45 am
by dclonts
Running Indigo 7.3.1 btw.

Re: PyCharm Problem?

PostPosted: Sun Nov 17, 2019 8:19 pm
by jay (support)
Can you take a screenshot of the Plugin tab in the Preferences dialog?

Re: PyCharm Problem?

PostPosted: Mon Nov 18, 2019 11:43 am
by dclonts
Here you go. Is there a pref file I can trash? seems off...

Re: PyCharm Problem?

PostPosted: Mon Nov 18, 2019 1:45 pm
by jay (support)
Email us (support AT indigodomo DOT com) the following file:

Code: Select all
/Library/Application Support/Perceptive Automation/Indigo 7.3/Preferences/Indigo Server Prefs.indiPref

Re: PyCharm Problem?

PostPosted: Mon Nov 18, 2019 3:13 pm
by jay (support)
Matt just had a thought: what ID are you using for your plugin? It should NOT start with "com.perceptiveautomation" or "com.indigodomo" since those are our private namespaces. You can make one up if you don't have a DNS hostname that you can reverse.

Re: PyCharm Problem?

PostPosted: Mon Nov 18, 2019 8:12 pm
by dclonts
So what did it was take the prefs out and put back in. Now it's working...not sure exactly why. But I'm good.

Thanks

Re: PyCharm Problem?

PostPosted: Thu Nov 21, 2019 4:06 pm
by dclonts
Well, closer.

When my plugin starts, get the following in the log, and the PyCharm debug config is still waiting for process to connect. is this related to the PyCharm fork of pydevd?..

Enabling plugin "Hayward 2.0.3"
Debugging plugin "Hayward 2.0.3" (pid 64492)
PyCharm Debugging Error Unable to load pydevd
PyCharm Debugging Error Make sure you have the most recent version of PyCharm installed and in your /Applications/ folder
Started plugin "Hayward 2.0.3"
PyCharm Debugging Error Unable to load pydevd
PyCharm Debugging Error Make sure you have the most recent version of PyCharm installed and in your /Applications/ folder

Nov 21, 2019 at 4:03:57 PM
Hayward Error device "new device 2" does not have a valid device type PL-PS-16-V
Received INSTEON "u-Thermostat" off (button 1)

Re: PyCharm Problem?

PostPosted: Thu Nov 21, 2019 4:12 pm
by dclonts
Final datapoint. Jetbrains was kind enough to install PyCharm in:

/Users/dclonts/Applications/JetBrains Toolbox/PyCharm Professional.app

that is, within a folder JetBrains Toolbox in my home directory, not in the root.

may be source of problem?

Re: PyCharm Problem?

PostPosted: Thu Nov 21, 2019 5:51 pm
by jay (support)
That's really weird - usually there isn't an installer, you just drag it to the /Applications folder. That's where it needs to be. And it should just be named PyCharm.app...

Re: PyCharm Problem?

PostPosted: Thu Nov 21, 2019 6:07 pm
by dclonts
Yeah, looks like new from JetBraIns--an app to manage/update/install their IDE's: https://www.jetbrains.com/toolbox-app/.

So, Ill try a symlink to the PyCharm Pro...if that does not work, will just install it as PyCharm in the application s directory.

AND...I assume it is the root app dirrectory, and not under user's home directory.

Will let you know.

Re: PyCharm Problem?

PostPosted: Fri Nov 22, 2019 9:24 am
by dclonts
Yay. Simlink did not work. Reinstall (direct install) of PyCharm in /applications. Did the trick.

Thanks for all the help!

Re: PyCharm Problem?

PostPosted: Fri Nov 22, 2019 10:21 am
by jay (support)
Good to know, thanks. We need to include the pydevd module that ships with PyCharm in order for debugging to work. We used to include that module with Indigo, but if the version of the module isn't the same as what ships with PyCharm then there are issues. So instead we just include the path to the module in the PyCharm install instead.

We'll see if we can figure out how to get the new location in (in some future release).

Re: PyCharm Problem?

PostPosted: Sat Jul 18, 2020 6:27 pm
by dclonts
So the debugger loading problem is back. get this in event log:

Reloading plugin "HaywardCurrent 2.0.3"
Stopping plugin "HaywardCurrent 2.0.3" (pid 18968)
Stopped plugin "HaywardCurrent 2.0.3"
Debugging plugin "HaywardCurrent 2.0.3" (pid 18985)
PyCharm Debugging Error Unable to load pydevd
PyCharm Debugging Error Make sure you have the most recent version of PyCharm installed and in your /Applications/ folder
Started plugin "HaywardCurrent 2.0.3"
PyCharm Debugging Error Unable to load pydevd
PyCharm Debugging Error Make sure you have the most recent version of PyCharm installed and in your /Applications/ folder

And the debug window in pycharm is stuck at:

Starting debug server at port 5678
Use the following code to connect to the debugger:
import pydevd_pycharm
pydevd_pycharm.settrace('localhost', port=5678, stdoutToServer=True, stderrToServer=True, suspend=False)
Waiting for process connection...