Can't install csv parser

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

    Can't install csv parser

    Hi, all....

    I'm hoping someone can help me. I've downloaded the csv.pyd file from

    and put it into my C:\Python22\DLL s directory. Typing

    import csv

    into a python window results in the following error message:

    Traceback (most recent call last):
    File "<pyshell#0 >", line 1, in ?
    import csv
    ImportError: DLL load failed: One of the library files needed to run this
    application cannot be found.

    Can someone help me get this running?

    Thanks,
    BogAl
  • Bernard Delmée

    #2
    Re: Can't install csv parser

    > I'm hoping someone can help me. I've downloaded the csv.pyd file from[color=blue]
    > http://www.object-craft.com.au/proje.../download.html
    > and put it into my C:\Python22\DLL s directory.[/color]

    Mmh...works for me - ActivePython 2.2.2
    Are you sure you downloaded the pyd file corresponding to
    your python version? Running the MS "depends" utility on
    csv.pyd reveals that it only needs python22.dll, msvcrt.dll
    and kernel32.dll. Are these all on your PATH?
    [color=blue]
    > Traceback (most recent call last):
    > File "<pyshell#0 >", line 1, in ?
    > import csv[/color]

    What's pyshell? did you try from good ole trusty python.exe
    in a DOS box?

    Hope this'll help you diagnose,

    Bernard.



    Comment

    • BogAl

      #3
      Re: Can't install csv parser

      Thanks for the reply, Bernard....
      [color=blue]
      > Mmh...works for me - ActivePython 2.2.2
      > Are you sure you downloaded the pyd file corresponding to
      > your python version?[/color]

      Yes, Python 2.2.2 here.

      [color=blue]
      > Running the MS "depends" utility on
      > csv.pyd reveals that it only needs python22.dll, msvcrt.dll
      > and kernel32.dll. Are these all on your PATH?
      >[/color]

      I think they are now....
      "...C:\WINDOWS\ SYSTEM\python22 .dll;C:\WINDOWS \SYSTEM\KERNEL3 2.dll;\C:
      \WINDOWS\SYSTEM \MSVCRT.dll;... "

      [color=blue][color=green]
      > > Traceback (most recent call last):
      > > File "<pyshell#0 >", line 1, in ?
      > > import csv[/color]
      >
      > What's pyshell? did you try from good ole trusty python.exe
      > in a DOS box?[/color]

      No difference. Still the same error message.
      Any further help is greatly appreciated.

      Comment

      • Dave Cole

        #4
        Re: Can't install csv parser

        >>>>> "Bernard" == Bernard Delmée <bdelmee@advalv as.REMOVEME.be> writes:
        [color=blue][color=green]
        >> I'm hoping someone can help me. I've downloaded the csv.pyd file
        >> from http://www.object-craft.com.au/proje.../download.html and
        >> put it into my C:\Python22\DLL s directory.[/color][/color]

        Bernard> Mmh...works for me - ActivePython 2.2.2 Are you sure you
        Bernard> downloaded the pyd file corresponding to your python version?
        Bernard> Running the MS "depends" utility on csv.pyd reveals that it
        Bernard> only needs python22.dll, msvcrt.dll and kernel32.dll. Are
        Bernard> these all on your PATH?
        [color=blue][color=green]
        >> Traceback (most recent call last): File "<pyshell#0 >", line 1, in ?
        >> import csv[/color][/color]

        Bernard> What's pyshell? did you try from good ole trusty python.exe
        Bernard> in a DOS box?

        Try putting the .pyd in C:\Python22\Lib \site-packages

        - Dave

        --

        Comment

        • BogAl

          #5
          Re: Can't install csv parser

          Thanks for the reply, Dave....
          [color=blue]
          > Try putting the .pyd in C:\Python22\Lib \site-packages[/color]

          Unfortunately, I'm still getting the error message.

          :(

          Comment

          • Dave Cole

            #6
            Re: Can't install csv parser

            >>>>> "BogAl" == BogAl <bogal2@comcast .net> writes:

            BogAl> Thanks for the reply, Dave....
            [color=blue][color=green]
            >> Try putting the .pyd in C:\Python22\Lib \site-packages[/color][/color]

            BogAl> Unfortunately, I'm still getting the error message.

            Does it work if you put the csv.pyd file in the current directory?

            - Dave

            --

            Comment

            • John Machin

              #7
              Re: Can't install csv parser

              BogAl <bogal2@comcast .net> wrote in message news:<MPG.197c8 8885d4542c09896 a8@news.in.comc ast.giganews.co m>...[color=blue]
              > Thanks for the reply, Dave....
              >[color=green]
              > > Try putting the .pyd in C:\Python22\Lib \site-packages[/color]
              >
              > Unfortunately, I'm still getting the error message.
              >[/color]

              I would suggest that you
              (1) Remove all your copies of csv.pyd
              (2) Install the csv module properly by following the instructions on
              Dave's website (i.e. briefly, you unpack the distribution into a
              directory, and then run setup.py)
              (3) If you still have a problem, post a message that shows
              (a) what version of Windows you are running
              (b) what version of Python
              (c) your windows path
              (d) your Python path (import sys; print sys.path)
              (e) what you get when you run Python (at the DOS command line!!) with
              -v and try to import the csv module
              (f) what the MS depends utility says about
              C:\Python22\Lib \site-packages\csv.py d

              Another thought: I found I had a python22.dll (dated Oct 2002, must be
              from Python 2.2.2) in my c:\WINNT\system 32 directory and one dated May
              2003 (must be from Python 2.2.3) in my c:\Python22 directory ... don't
              know how that happened; puzzling ... I've killed off the older one.
              You might like to search python22.dll *AND* msvcrt.dll and ensure that
              you are using the latest.

              HTH,
              John

              Comment

              • John Machin

                #8
                Re: Can't install csv parser

                BogAl <bogal2@comcast .net> wrote in message news:<MPG.197b8 c26ad33253e9896 a7@news.in.comc ast.giganews.co m>...[color=blue]
                > Thanks for the reply, Bernard....
                >[color=green]
                > > Running the MS "depends" utility on
                > > csv.pyd reveals that it only needs python22.dll, msvcrt.dll
                > > and kernel32.dll. Are these all on your PATH?
                > >[/color]
                >
                > I think they are now....
                > "...C:\WINDOWS\ SYSTEM\python22 .dll;C:\WINDOWS \SYSTEM\KERNEL3 2.dll;\C:
                > \WINDOWS\SYSTEM \MSVCRT.dll;... "[/color]

                I think not; path should contain a list of *directories*, not *files*
                -- Windows is silently ignoring the non-existence of directories
                called "C:\WINDOWS\SYS TEM\python22.dl l" etc.

                Rephrasing Bernard's question: do you have those 3 files in
                directories that are listed in your system path?

                After a normal Python installation, you would expect to have
                c:\Python22 in your path, and Python22.dll in that directory.

                Comment

                • BogAl

                  #9
                  Re: Can't install csv parser

                  > >> Try putting the .pyd in C:\Python22\Lib \site-packages[color=blue]
                  >
                  > BogAl> Unfortunately, I'm still getting the error message.
                  >
                  > Dave> Does it work if you put the csv.pyd file in the current directory?[/color]

                  Yes, it does. What does that mean I should do now?

                  Comment

                  • BogAl

                    #10
                    Re: Can't install csv parser

                    Thanks for the reply, John....
                    [color=blue]
                    > I would suggest that you
                    > (1) Remove all your copies of csv.pyd
                    > (2) Install the csv module properly by following the instructions on
                    > Dave's website (i.e. briefly, you unpack the distribution into a
                    > directory, and then run setup.py)[/color]

                    I tried this first; went to the suggested alternative second. Here's
                    what happens when I run setup.py:

                    C:\Python22\Lib \site-packages\csv>
                    python.exe C:\PYTHON22\LIB \SITE-P~1\CSV\SETUP.P Y

                    usage: SETUP.PY [global_opts] cmd1 [cmd1_opts] [cmd2 [cmd2_opts] ...]
                    or: SETUP.PY --help [cmd1 cmd2 ...]
                    or: SETUP.PY --help-commands
                    or: SETUP.PY cmd --help

                    error: no commands supplied
                    [color=blue]
                    > (3) If you still have a problem, post a message that shows
                    > (a) what version of Windows you are running
                    > (b) what version of Python
                    > (c) your windows path
                    > (d) your Python path (import sys; print sys.path)
                    > (e) what you get when you run Python (at the DOS command line!!) with
                    > -v and try to import the csv module
                    > (f) what the MS depends utility says about
                    > C:\Python22\Lib \site-packages\csv.py d
                    >
                    > Another thought: I found I had a python22.dll (dated Oct 2002, must be
                    > from Python 2.2.2) in my c:\WINNT\system 32 directory and one dated May
                    > 2003 (must be from Python 2.2.3) in my c:\Python22 directory ... don't
                    > know how that happened; puzzling ... I've killed off the older one.
                    > You might like to search python22.dll *AND* msvcrt.dll and ensure that
                    > you are using the latest.
                    >
                    > HTH,
                    > John[/color]

                    Comment

                    • Skip Montanaro

                      #11
                      Re: Can't install csv parser


                      bogal> I tried this first; went to the suggested alternative second.
                      bogal> Here's what happens when I run setup.py:

                      bogal> C:\Python22\Lib \site-packages\csv>
                      bogal> python.exe C:\PYTHON22\LIB \SITE-P~1\CSV\SETUP.P Y

                      bogal> usage: SETUP.PY [global_opts] cmd1 [cmd1_opts] [cmd2 [cmd2_opts] ...]
                      bogal> or: SETUP.PY --help [cmd1 cmd2 ...]
                      bogal> or: SETUP.PY --help-commands
                      bogal> or: SETUP.PY cmd --help

                      bogal> error: no commands supplied

                      Setup.py needs to know what of several things you want to do (just build the
                      package, build and install the package, build a distribution, etc). Try
                      this command:

                      python.exe C:\PYTHON22\LIB \SITE-P~1\CSV\SETUP.P Y install

                      That should do any necessary building and install all the files.

                      Skip

                      Comment

                      • BogAl

                        #12
                        Re: Can't install csv parser

                        > Setup.py needs to know what of several things you want to do (just build the[color=blue]
                        > package, build and install the package, build a distribution, etc). Try
                        > this command:
                        >
                        > python.exe C:\PYTHON22\LIB \SITE-P~1\CSV\SETUP.P Y install
                        >
                        > That should do any necessary building and install all the files.
                        >
                        > Skip[/color]

                        Thanks, Skip. I'm too used to just double-clicking things to run them
                        and missed the part about supplying an argument.

                        At least I've learned a couple of things and maybe improved my setup a
                        bit in the process.

                        BogAl

                        Comment

                        Working...