cyberdelia / heroku-geo-buildpack

Geo libraries for Heroku
https://github.com/heroku/heroku-geo-buildpack
113 stars 135 forks source link

fails to build (NoMethodError) #26

Closed smcoll closed 9 years ago

smcoll commented 9 years ago

i was able to build from this buildback for months until yesterday. Here's what happens when i try, and following is the output from 'docker version'.

$ docker build .
[...]
Step 4 : RUN /build/builder
 ---> Running in 4901240c33dc
-----> Fetching custom buildpack
-----> geos/gdal/proj app detected
       Using geos version: 3.4.2
       Using gdal version: 1.11.1
       Using proj version: 4.8.0_1
-----> Fetching and vendoring geos
-----> Fetching and vendoring gdal
-----> Fetching and vendoring proj
-----> Vendoring geo libraries done
-----> Discovering process types
       Procfile declares types -> web
-e:1:in `<main>': undefined method `[]' for false:FalseClass (NoMethodError)
2015/02/25 10:06:08 The command [/bin/sh -c /build/builder] returned a non-zero code: 1
$ docker version
Client version: 1.0.1
Client API version: 1.12
Go version (client): go1.2.1
Git commit (client): 990021a
Server version: 1.0.1
Server API version: 1.12
Go version (server): go1.2.1
Git commit (server): 990021a

My procfile:

web: gunicorn myproject.wsgi --log-file -

i'm running this on Ubuntu 14.10, with 3.13.0-46-generic as the kernel. If there's any additional info needed, let me know.

smcoll commented 9 years ago

More context:

# .buildpacks
https://github.com/heroku/heroku-buildpack-python.git#v55
https://github.com/cyberdelia/heroku-geo-buildpack.git#1.3

# .env
export BUILDPACK_URL=https://github.com/ddollar/heroku-buildpack-multi.git
cyberdelia commented 9 years ago

Put the geo buildpack first, and the python buildpack last in your .buildpack file, this should help.

smcoll commented 9 years ago

@cyberdelia interestingly, the reason the buildpacks are in that order is because otherwise it was building but without GIS support:

>>> from django.contrib.gis import gdal
>>> gdal.HAS_GDAL
False

i presumed that was because the multi-buildpack only uses the release configuration from the latter buildback (i mentioned this in a comment here: https://github.com/cyberdelia/heroku-geo-buildpack/issues/23#issuecomment-77044811)

smcoll commented 9 years ago

Turns out the issue had to do with a cached progrium/buildstep image. This solved it:

$ docker pull progrium/buildstep