Skip to content

Instantly share code, notes, and snippets.

View springmeyer's full-sized avatar

Dane Springmeyer springmeyer

View GitHub Profile
npm verb caching /Users/dane/.npm/generic-pool/1.0.5/package/package.json
npm verb loadDefaults [email protected]
npm info shasum f65e83ec1d7b73ee24412a3853336e8d771ea985
npm info shasum /Users/dane/.npm/generic-pool/1.0.5/package.tgz
npm verb from cache /Users/dane/.npm/generic-pool/1.0.5/package/package.json
npm verb chmod /Users/dane/.npm/generic-pool/1.0.5/package.json 644
npm verb chmod /Users/dane/.npm/generic-pool/1.0.5/package.tgz 644
$ carto tornado.mml <?xml version="1.0" encoding="utf-8"?>
<!DOCTYPE Map[]>
<Map srs="+proj=merc +a=6378137 +b=6378137 +lat_ts=0.0 +lon_0=0.0 +x_0=0.0 +y_0=0 +k=1.0 +units=m +nadgrids=@null +wktext +no_defs +over">
</Map>
d:tornado dane$ /Users/dane/.nvm/v0.4.7/bin/node batchTornado.js tornado.mml mbtiles/tornado3-1951.mbtiles "Tornado Map 1951" overlay "Tornado map data for the year 1951"
setup
fillGridData
node.js:134
throw e; // process.nextTick error, or 'error' event on first tick
^
TypeError: Object generated/style.mss,@year: 1951;
#tracks[YEAR_=@year]{
diff --git a/lib/generic-pool.js b/lib/generic-pool.js
index e98d9ca..5808d1b 100644
--- a/lib/generic-pool.js
+++ b/lib/generic-pool.js
@@ -242,10 +242,10 @@ exports.Pool = function (factory) {
*/
me.release = function (obj) {
//log("return to pool");
+ dispense();
var objWithTimeout = { obj: obj, timeout: (new Date().getTime() + idleTimeoutMillis) };
@springmeyer
springmeyer / mapnik2.rb
Created May 20, 2011 21:42
mapnik2 homebrew formula
require 'formula'
class Mapnik2 < Formula
head 'http://svn.mapnik.org/trunk/', :using => :svn
homepage 'http://www.mapnik.org/'
depends_on 'pkg-config' => :build
depends_on 'scons' => :build
depends_on 'libtiff'
depends_on 'jpeg'
@springmeyer
springmeyer / line-offsets-mapnik2.diff
Created May 25, 2011 22:32
line offsets in mapnik
Index: bindings/python/mapnik_stroke.cpp
===================================================================
--- bindings/python/mapnik_stroke.cpp (revision 2900)
+++ bindings/python/mapnik_stroke.cpp (working copy)
@@ -68,14 +68,15 @@
dashes,
s.get_line_cap(),
s.get_line_join(),
- s.get_gamma());
+ s.get_gamma(),
clang++ -o src/grid/process_shield_symbolizer.os -c -g -Wno-unused-function -Wno-array-bounds -Wno-parentheses -DHAVE_JPEG -ansi -Wall -ftemplate-depth-200 -DDARWIN -DBOOST_SPIRIT_THREADSAFE -DMAPNIK_THREADSAFE -O3 -finline-functions -Wno-inline -DNDEBUG -fPIC -Iagg/include -I. -Iinclude -I/opt/proj/include -I/opt/icu/include -I/opt/boost-46/include -I/Library/Frameworks/UnixImageIO.framework/unix/include -I/usr/local/pgsql-9.0/include -I/usr/local/Cellar/geos/3.2.2/include -I/usr/local/include -I/usr/local/Cellar/sqlite/3.7.5/include -I/usr/include -I/usr/X11/include/freetype2 -I/usr/X11/include -I/usr/include/libxml2 src/grid/process_shield_symbolizer.cpp
-I/opt/icu/include -I/opt/boost-46/include -I/Library/Frameworks/UnixImageIO.framework/unix/include -I/usr/local/pgsql-9.0/include -I/usr/local/Cellar/geos/3.2.2/include -I/usr/local/include -I/usr/local/Cellar/sqlite/3.7.5/include -I/usr/include -I/usr/X11/include/freetype2 -I/usr/X11/include -I/usr/include/libxml2 src/grid/process_shield_symbolizer.cpp
e
ccache clang++ -o src/libxml2_loader.os -c -g -DHAVE_JPEG -ansi -Wall -Wno-unused-function -Wno-array-bounds -Wno-parentheses -ftemplate-depth-200 -DDARWIN -DBOOST_SPIRIT_THREADSAFE -DMAPNIK_THREADSAFE -O3 -finline-functions -Wno-inline -DNDEBUG -DHAVE_LIBXML2 -fPIC -Iagg/include -I. -Iinclude -I/opt/proj/include -I/opt/icu/include -I/opt/boost-46/include -I/Library/Frameworks/UnixImageIO.framework/unix/include -I/usr/local/pgsql-9.0/include -I/usr/local/Cellar/geos/3.2.2/include -I/usr/local/include -I/usr/local/Cellar/sqlite/3.7.5/include -I/usr/include -I/usr/X11/include/freetype2 -I/usr/X11/include -I/usr/include/libxml2 src/libxml2_loader.cpp
clang: warning: argument unused during compilation: '-D HAVE_JPEG'
clang: warning: argument unused during compilation: '-D DARWIN'
clang: warning: argument unused during compilation: '-D BOOST_SPIRIT_THREADSAFE'
clang: warning: argument unused during compilation: '-D MAPNIK_THREADSAFE'
clang: warning: argument unused during compilation: '-D NDEBUG'
clang: warning: a
In file included from src/image_util.cpp:32:
include/mapnik/png_io.hpp:91:16: error: no matching function for call to 'png_set_longjmp_fn'
if (setjmp(png_jmpbuf(png_ptr)))
^~~~~~~~~~~~~~~~~~~
In file included from src/image_util.cpp:27:
/Library/Frameworks/UnixImageIO.framework/unix/include/png.h:988:9: note: instantiated from:
(*png_set_longjmp_fn((png_ptr), longjmp, sizeof (jmp_buf)))
^~~~~~~~~~~~~~~~~~
/Library/Frameworks/UnixImageIO.framework/unix/include/png.h:985:1: note: candidate function not viable: no
@springmeyer
springmeyer / mode_tile_client.py
Created June 3, 2011 06:46
python client for talkin' sockets with mod_tile.py
#!/usr/bin/env python
# client for mod_tile
import struct
import socket
def print_resp(data):
print 'Received', repr(data)
version, request, x, y, z, xmlname = struct.unpack("5i41sxxx", data)