From: Alex R. <sh...@al...> - 2004-11-05 18:41:37
|
John, On 11/05/2004 11:12:08 AM, John Stoffel wrote: > Basically, the lines: >=20 > if self.print_report.get_active (): > os.environ["DOT"] =3D self.target_path > os.system ('dot -Tps "$DOT" | %s &' % > Report.get_print_dialog_app ()) >=20 > Don't make much sense to me, since the $DOT environment variable looks > to be wrong here. In my mind, that's the full path to the 'dot' > command, not the name of the input file generated by the plugin to > feed to the converter. Am I just missing something silly here? =20 You're correct, DOT is being set to the basic_report.dot or whatever filename was chosen by the user. I guess it's the confusing choice of names, but it makes its own sense :-). Note the DOT env var is _set_ to the filename, rather than being read from. > Also, how do I test plugins, without having to start/restart gramps > all the time? Mostly I want to find and cleanup syntax errors as I > hack on the code, because I know very little about python at all. I'm > sure I'll be learning more though! You may select File->Reload plugins menu item. Use Help->Show plugin status to see what failed to load and why. The plugins are attempted to load silently, and their failure is also silent, except for the tracebacks in the "Show plugin status" window. Note that there are two graphviz-based plugins: GraphViz and RelGraph. The latter is only loaded when python is >=3D2.3. So for python2.3 RelGraph is loaded and GraphViz is not, while for python<2.3 GraphViz is loaded, since RelGraph fails. This may be confusing when you make changes to the plugin only to find out that they're not vizible :-) Alex --=20 Alexander Roitman http://ebner.neuroscience.umn.edu/people/alex.html Dept. of Neuroscience, Lions Research Building 2001 6th Street SE, Minneapolis, MN 55455 Tel (612) 625-7566 FAX (612) 626-9201 |