On 12-May-08, at 11:10 AM, Nathan Dunfield wrote: > >> Oh, that's annoying, it doesn't display the Cython command line. >> Anyway, if you don't give the -p or --embed-positions option to >> Cython, then source introspection should *not* work: > > I cython'd on the command line with the -p option and then setup.py > installed. > > I now get a different error message when I try introspection: > > sage: import introtest > sage: introtest.intro?? > Error getting source: s must be a string > > instead of > > Error getting source: arg is not a module, class, method, function, > > Does the introtest.pyx file have to copied to somewhere in particular > for this to work, or is everything supposed to embedded in the *.so > module binary?
It is supposed to be embedded. Could you tell me what introtest.intro.__doc__ is? The embedding just includes the file info; for example sage: Integer.__doc__[0:100] 'File: sage/rings/integer.pyx (starting at line 241)\n\n The \ \class{Integer} class represents arbitr' That shows where the docstring starts in sage/rings/integer.pyx for class Integer. There are lots of way that info can be off, or that Sage can misparse/not find it. It's somewhat fragile. Nick --~--~---------~--~----~------------~-------~--~----~ To post to this group, send email to sage-devel@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/sage-devel URLs: http://www.sagemath.org -~----------~----~----~----~------~----~------~--~---