This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import soaplib | |
from soaplib.core.service import rpc, soap, DefinitionBase | |
from soaplib.core.model.primitive import String, Integer | |
from soaplib.core.server import wsgi | |
from soaplib.core.model.clazz import Array | |
from flask import Flask | |
flask_app = Flask(__name__) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
from flask import Flask, make_response | |
app = Flask(__name__) | |
@app.route("/simple.png") | |
def simple(): | |
import datetime | |
import StringIO | |
import random | |
from matplotlib.backends.backend_agg import FigureCanvasAgg as FigureCanvas |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?xml version='1.0' encoding='UTF-8'?> | |
<wsdl:definitions xmlns:wsa="http://schemas.xmlsoap.org/ws/2003/03/addressing" xmlns:tns="tns" xmlns:plink="http://schemas.xmlsoap.org/ws/2003/05/partner-link/" xmlns:xop="http://www.w3.org/2004/08/xop/include" xmlns:senc="http://schemas.xmlsoap.org/soap/encoding/" xmlns:s1="__main__" xmlns:s12env="http://www.w3.org/2003/05/soap-envelope/" xmlns:s12enc="http://www.w3.org/2003/05/soap-encoding/" xmlns:xs="http://www.w3.org/2001/XMLSchema" xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:senv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/" targetNamespace="tns" name="Application"><wsdl:types><xs:schema targetNamespace="tns" elementFormDefault="qualified"><xs:import namespace="http://www.w3.org/2001/XMLSchema"/><xs:import namespace="__main__"/><xs:complexType name="GetHISParamAvailableSources"><xs:sequence><xs:element name="TXHISParameterCode" type="xs:string" minOccurs= |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import tables | |
path = "./itersorted_example.h5" | |
class Value(tables.IsDescription): | |
index = tables.IntCol() | |
value = tables.IntCol() |
This file has been truncated, but you can view the full file.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
The output from HOMEBREW_MAKE_JOBS=1 VERBOSE=1 brew install foo 2>&1: | |
----------------------------- | |
/usr/bin/env python -c import numpy | |
/usr/bin/env python -c import numpy | |
==> Downloading http://download.osgeo.org/gdal/1.10.0/gdal-1.10.0.tar.gz | |
Already downloaded: /Library/Caches/Homebrew/gdal-1.10.0.tar.gz | |
tar xf /Library/Caches/Homebrew/gdal-1.10.0.tar.gz |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import flask | |
class LaxFlask(flask.Flask): | |
def add_url_rule(self, *args, **kwargs): | |
if 'strict_slashes' not in kwargs: | |
kwargs['strict_slashes'] = False | |
super(LaxFlask, self).add_url_rule(*args, **kwargs) | |
# instantiate with LaxFlask instead of Flask | |
app = LaxFlask(..) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
from flask import Flask, redirect | |
from flask.ext.sqlalchemy import SQLAlchemy | |
from werkzeug.wsgi import DispatcherMiddleware | |
from werkzeug.serving import run_simple | |
from wtforms import validators | |
from flask.ext import admin | |
from flask.ext.admin.contrib import sqla | |
from flask.ext.admin.contrib.sqla import filters |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
$ brew install -v qgis 2>&1 | |
python -c from PyQt4 import QtCore | |
/usr/bin/env python -c import numpy | |
python -c from PyQt4 import QtCore | |
/usr/bin/env python -c import numpy | |
==> Downloading http://qgis.org/downloads/qgis-1.8.0.tar.bz2 | |
Already downloaded: /Library/Caches/Homebrew/qgis-1.8.0.tar.bz2 | |
==> Verifying qgis-1.8.0.tar.bz2 checksum | |
tar xf /Library/Caches/Homebrew/qgis-1.8.0.tar.bz2 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
def _s3_multipart_copy(old_bucket, old_key, new_bucket, new_key): | |
old_key_obj = old_bucket.lookup(old_key) | |
key_size = old_key_obj.size | |
part_size = 1000000000 | |
parts = [ | |
(i+1, i * part_size, min(key_size - 1, ((i + 1) * part_size) - 1)) | |
for i in range((old_key_obj.size / part_size) + 1) | |
] | |
multipart = new_bucket.initiate_multipart_upload(new_key) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
'use strict'; | |
var _ = require('lodash'); | |
var csv = require('csv-write-stream'); | |
var fs = require('fs'); | |
var mapquest = require('mapquest'); | |
var nconf = require('nconf'); | |
nconf.file({file: 'credentials.json'}); |
OlderNewer