problem with import autotest ...

Collapse
This topic is closed.
X
X
 
  • Time
  • Show
Clear All
new posts
  • bravegag

    #1

    problem with import autotest ...

    Hi all,

    Please beware I am new to Python and have little experience with it.

    I have a script that works just fine on linux but when I try to debug
    from Windows using Eclipse and PyDEV plugin then it does not
    work. The Python version is the same 2.3.x , and command line
    is roughly the same.

    from Unix:
    mymodule.py <my-params>
    [color=blue]
    >From Windows (Eclipse)[/color]
    python.exe mymodule.py <my-params>

    The point is that from Linux the "import autotest" works as
    intended i.e. just allow the importing module use some functions
    but from Windows it autoruns itself just by importing it, I do not
    get why or how?
    [color=blue]
    >From Windows it does:[/color]

    "Regression test.

    This will find all modules whose name is "test_*" in the test
    directory, and run them. Various command line options provide
    additional facilities"

    and then starts executing tests without ever getting to the main
    of my module ...

    Any clues?

    TIA,
    Best Regards,
    Giovanni

  • Ben Finney

    #2
    Re: problem with import autotest ...

    "bravegag" <bravegag@gmail .com> writes:
    [color=blue]
    > I have a script that works just fine on linux but when I try to
    > debug from Windows using Eclipse and PyDEV plugin then it does not
    > work. The Python version is the same 2.3.x , and command line is
    > roughly the same.[/color]

    2.3.x is not a version. Which versions are you using on each?
    [color=blue][color=green][color=darkred]
    >>> import sys
    >>> sys.version[/color][/color][/color]
    '2.3.5 (#2, Sep 4 2005, 22:01:42) \n[GCC 3.3.5 (Debian 1:3.3.5-13)]'
    [color=blue]
    > The point is that from Linux the "import autotest" works as intended
    > i.e. just allow the importing module use some functions but from
    > Windows it autoruns itself just by importing it, I do not get why or
    > how?[/color]
    [color=blue][color=green][color=darkred]
    >>> import autotest[/color][/color][/color]
    Traceback (most recent call last):
    File "<stdin>", line 1, in ?
    ImportError: No module named autotest

    What is this 'autotest' module? Where are you expecting it to come
    from?

    --
    \ "If it ain't bust don't fix it is a very sound principle and |
    `\ remains so despite the fact that I have slavishly ignored it |
    _o__) all my life." -- Douglas Adams |
    Ben Finney

    Comment

    Working...