This forum is shutting down! Please post new discussions at community.naturalcapitalproject.org

Not able to install pywin32-214.win32-py2.7

Hello all,

I've bee trying to install the Marine Python Extensions for the InVEST Coastal Protection Model. All have installed ok on my computer, except pywin32-214.win32-py2.7, which renders the following error message:

close failed in file object destructor:
sys.excepthook is missing
lost sys.stderr

Does anyone have an idea why this might be happening?

Thanks a lot!
Tagged:

Comments

  • jdouglassjdouglass Administrator, NatCap Staff
    Very interesting!  Is there any chance that you're trying to run the installer as administrator?  Sometimes that can yield this type of error.
  • I tried installing it both ways; with and without administrator rights. Always showed same error message.

    It's funny that of all the modules that are required to be installed for the coastal protection model, pywin was the only one that yielded this error.
  • jdouglassjdouglass Administrator, NatCap Staff
    edited February 2015
    Yeah, this looks like an error that's specific to pywin32 (judging by this SO post and the related mailing list post here).  This SO answer had an interesting solution ... could you try opening up a CMD or powershell prompt and (assuming python is installed to c:\Program Files\ArcGIS\python27):

    > cd "c:\Program Files\ArcGIS\python27"
    > .\python.exe Scripts\pywin32_postinstall.py -install

    I'm hoping that maybe running this script would finish the installation.
    Post edited by jdouglass on
  • JPrussmannJPrussmann Member
    edited February 2015
    Thanks a lot jdouglass!

    Apparently the installation was succesfull (See attached screenshot). I'll try running the coastal protection model and let you know how it goes.

    I appreciate your help.
    688 x 543 - 77K
    Post edited by JPrussmann on
  • I tried running the profile generator again, but I'm still getting the following error message :(

    Executing: ProfileGenerator22 "C:\_InVEST_Costas\Prueba v01.30" Prueba0130 "C:\InVEST_dev148_3_1_0b1 [44597b073599]_x86\CoastalProtection\Input\LandPoint_BarkSound.shp" "C:\InVEST_dev148_3_1_0b1 [44597b073599]_x86\CoastalProtection\Input\LandPolygon_WCVI.shp" "(1) Yes" "C:\InVEST_dev148_3_1_0b1 [44597b073599]_x86\Base_Data\Marine\DEMs\claybark_dem" "C:\InVEST_dev148_3_1_0b1 [44597b073599]_x86\CoastalProtection\Input\NaturalHabitat" 250 25 # 5 "C:\InVEST_dev148_3_1_0b1 [44597b073599]_x86\CoastalProtection\Input\ErosionProtection_WCVI_BarkSound.xls" "C:\InVEST_dev148_3_1_0b1 [44597b073599]_x86\CoastalProtection\Input\WaveWatchIII.shp" 50 "(1) Yes"
    Start Time: Sun Feb 01 17:13:58 2015
    Running script ProfileGenerator22...

    Checking and preparing inputs...

    Error checking and preparing inputs.
    ERROR 000578: Cannot access environment.
    Completed script ProfileGenerator22...
    Failed to execute (ProfileGenerator22).
    Failed at Sun Feb 01 17:14:12 2015 (Elapsed Time: 14.00 seconds)

    I though this could be because the error on the pywin module, but I'm still getting the error after installing the module through CMD.
  • jdouglassjdouglass Administrator, NatCap Staff
    Huh ... based on some quick Googling, it looks like this is an ArcGIS-specific error indicating that it can't locate the geoprocessing environment.  Were you getting this error before installing pywin32?

    Given this help page on the ArcGIS site, it looks like the issue is probably related to your current geoprocessing environment settings, though I'm not really sure what's fundamentally causing this issue.  Perhaps someone with more ArcGIS experience on the forums here can provide insight?

Sign In or Register to comment.