Evennia, Code Complete & Subprocess Debugging

So, my friend and I started to use Evennia to build a mud (yes, we are headed back to the 90's).  We decided to use PyCharm, but are struggling with this particular code base on a couple of fronts.

1) The code base uses some very dynamic setup routines so for instance evennia/__init__.py has lines in it like:

    DefaultAccount = None

    Those get updated later through some dynamic structures to point to various objects in the evennia code base.  I fully understand why PyCharm can't resolve code completion due to this.  However, is there a way to add something to my project to "tell" pycharm what these objects are and therefore restore the code completion functionality?

 

2) The code base spawns multiple subprocesses using something called "twisted".  This is fine, and I can attach to the existing code, but the standard coding pattern is to make some code changes and then issue a @reload on the mud.  This results in one of the subprocesses being shutdown and restarted.  PyCharm doesn't seem to detect this subprocess (or the initial one for that matter), resulting in the debugging not being attached to the new server process.  Is there some form of configuration that I can do to make this work better?

Loving PyCharm otherwise, but working on this particular code base is showing me some of the more complex sides of Python.  ;)

 

0

Please sign in to leave a comment.