[IronPython] Newbie question about 'import'

2006-01-06 Thread Fabio
I'm new in python (and IronPython).   I have used the tutorial of IronPython 1.0 Beta, and when I "import first" I receive this error:   >>> import firstTraceback (most recent call last):  File , line 0, in input##0ImportError: No module named first   I think what I need set some like import "Tutor

[IronPython] List of Python Libraries you think to implement

2006-01-06 Thread Paparipote .
Hello: Do you have an established list of Pyhton 2.4 libraries pending of implementation in future IP versions? Is this possible to know the list? Many, many thanks. Best regards. _ MSN Amor: busca tu ½ naranja http://latam.msn.com/a

Re: [IronPython] Calling a method with arguments from C#

2006-01-06 Thread Brandon Furtwangler
Woot, I think I just wrote the exact method I was requesting…   I haven’t tested it extensively but it seems to work so far.  Here is an example:   My python script looks like this (MethodTest.py):   def Add(s1, s2):   return s1 + s2     And my C# is like this:      

Re: [IronPython] calling multiple python methods

2006-01-06 Thread Martin Maly
This is a bug in IronPython. A workaround you can use before we release the fix is following:   In the Options.cs (Src\IronPython\Compiler\Options.cs), change the GenerateDynamicMethods to false:       public static bool GenerateDynamicMethods = false;   Hope this helps for now and we'll

Re: [IronPython] Pyenchant

2006-01-06 Thread Martin Maly
IronPython doesn't, by default, look under site-packages directory for imported modules. That may be one part of the problem. Also, since as you do "import enchant" and get error "no module named _enchant", I assume that there may be C extension coming with the enchant library. IronPython do

Re: [IronPython] ValueError: Absolute path information is required

2006-01-06 Thread Martin Maly
Before we release fix for this in the next IronPython release, what you can do is load the assembly using the System.Reflection.Assembly.LoadFrom method and then use: clr.AddReference with the assembly object. That gives you absolute control over the assembly loading process: >>> import System

Re: [IronPython] ValueError: Absolute path information is required

2006-01-06 Thread Dino Viehland
Does clr.AddReference (instead of AddReferenceToFile) work for you instead? I think it should if AgentServerObjects.dll is in the app base (usually iron python's directory), a subdir of the app base called "bin", or a subdir called AgentServerObjects. This is probably due to the change from u

[IronPython] Pyenchant

2006-01-06 Thread Mohammed QadeerAhmed
Hi all,   I am trying to use Pyenchant with IronPython but have not been successful. Here are few things that I tried to get it to work. I have python 2.4 installed and the Pyenchant library using the pre-built windows installer for python 2.4 downloaded from the pyenchant website. Afte

[IronPython] calling multiple python methods

2006-01-06 Thread Brandon Furtwangler
I am hosting iron python I my C# app and I’m running into problems calling python methods.  For example given the following script:   (in MethodTest.py)   def Method1():     return 5   def Method2():     return 10   and the following C# code:   PythonEngine pe = new PythonEngine

[IronPython] ValueError: Absolute path information is required

2006-01-06 Thread Paparipote .
In Exercise 1: Merlin the Wizard, task 2: >>>import clr >>>clr.AddReferenceToFile("AgentServerObjects.dll") Traceback (most recent call last): File , line 0, in input##1 File , line 0, in .ctor File , line 0, in AddPathList File , line 0, in CreateListFromExpressions ValueError: Absolute p