elevation icon indicating copy to clipboard operation
elevation copied to clipboard

Issue with AppData Folder and Make on Windows

Open lmonninger opened this issue 6 years ago • 3 comments

Hi @alexamici, I've run into an error when requesting a DEM through using elevation.clip() in a Python script on Windows. It appears make is running into some kind of problem entering an AppData subdirectory. Here's the output I'm getting the Visual Studio console:

make: Entering directory 'C:/Users/lmonn/AppData/Local/bopen/elevation/Cache/SRTM1'
The system cannot find the path specified.
The syntax of the command is incorrect.
make: *** [Makefile:17: spool/N41/N41E012.hgt.gz] Error 1
make: Leaving directory 'C:/Users/lmonn/AppData/Local/bopen/elevation/Cache/SRTM1'
Traceback (most recent call last):
  File "test_one.py", line 338, in <module>
    elevation.clip(bounds=(12.35, 41.8, 12.65, 42), output=output, product='SRTM1')
  File "C:\Users\lmonn\AppData\Local\Programs\Python\Python37-32\lib\site-packages\elevation\datasource.py", line 181, in clip
    datasource_root = seed(bounds=bounds, **kwargs)
  File "C:\Users\lmonn\AppData\Local\Programs\Python\Python37-32\lib\site-packages\elevation\datasource.py", line 153, in seed
    ensure_tiles(datasource_root, ensure_tiles_names, **kwargs)
  File "C:\Users\lmonn\AppData\Local\Programs\Python\Python37-32\lib\site-packages\elevation\datasource.py", line 115, in ensure_tiles
    return util.check_call_make(path, targets=['download'], variables=variables_items, **kwargs)
  File "C:\Users\lmonn\AppData\Local\Programs\Python\Python37-32\lib\site-packages\elevation\util.py", line 93, in check_call_make
    subprocess.check_call(cmd, shell=True)
  File "C:\Users\lmonn\AppData\Local\Programs\Python\Python37-32\lib\subprocess.py", line 347, in check_call
    raise CalledProcessError(retcode, cmd)
subprocess.CalledProcessError: Command 'make -C C:\Users\lmonn\AppData\Local\bopen\elevation\Cache\SRTM1 download ENSURE_TILES="N41/N41E012.tif"' returned non-zero exit status 2.

What do you think the issue could be?

Note: I've tried this with 'SRTM3' as well.

lmonninger avatar May 02 '19 20:05 lmonninger

Getting this on Mac also. subprocess.CalledProcessError: Command 'make -C ~/Library/Caches/elevation/SRTM3 all ' returned non-zero exit status 2.

daimeng avatar Jun 25 '19 20:06 daimeng

I ran into a similar error message today, I realised that I was missing a required dependencies. In my instance I had forgotten to include 'curl', check the project README and make sure you have all the specified dependencies installed.

owvarley avatar Oct 24 '19 16:10 owvarley

hi ,this problem have hero solve

1261136052 avatar Oct 18 '23 01:10 1261136052