Skip to content

Instantly share code, notes, and snippets.

NoMethodError: undefined method `call' for nil:NilClass
C:/development/langs/jruby-1.3.1/lib/ruby/gems/1.8/gems/rack-1.0.0/lib/rack/lint.rb:35:in `call'
C:/development/langs/jruby-1.3.1/lib/ruby/gems/1.8/gems/rack-1.0.0/lib/rack/showexceptions.rb:24:in `call'
C:/development/langs/jruby-1.3.1/lib/ruby/gems/1.8/gems/rack-1.0.0/lib/rack/commonlogger.rb:20:in `_call'
C:/development/langs/jruby-1.3.1/lib/ruby/gems/1.8/gems/rack-1.0.0/lib/rack/commonlogger.rb:13:in `call'
C:/development/langs/jruby-1.3.1/lib/ruby/gems/1.8/gems/rack-1.0.0/lib/rack/content_length.rb:13:in `call'
C:/development/langs/jruby-1.3.1/lib/ruby/gems/1.8/gems/rack-1.0.0/lib/rack/chunked.rb:15:in `call'
C:/development/langs/jruby-1.3.1/lib/ruby/gems/1.8/gems/rack-1.0.0/lib/rack/handler/mongrel.rb:61:in `process'
C:/development/langs/jruby-1.3.1/lib/ruby/gems/1.8/gems/mongrel-1.1.5-java/lib/mongrel.rb:159:in `process_client'
C:/development/langs/jruby-1.3.1/lib/ruby/gems/1.8/gems/mongrel-1.1.5-java/lib/mongrel.rb:158:in `each'
# app.rb
require 'rubygems'
require 'sinatra'
get '/' do
haml :index
end
-#views/index.haml
%html
%head
%script{:type => "text/javascript", :charset => "utf-8", :src => "http://www.google.com/jsapi?key=ABQIAAAAR21mr2vnfC9-sjIojad2WhSmbtbI58sJnUq1AueY0BvTVoVv3BSw-I1OHpTaa0zZiaSEsDrZf9fGWQ"}
%script{:type => "text/javascript"}
google.load("maps", "2");
// Call this function when the page has been loaded
function initialize() {
var map = new google.maps.Map2(document.getElementById("map"));
C:\development\spaces\workspace\vigil>gem list
*** LOCAL GEMS ***
actionmailer (2.3.4)
actionpack (2.3.4)
active_documentum (0.3.0)
activerecord (2.3.4)
activerecord-jdbc-adapter (0.9.2)
activerecord-jdbcsqlite3-adapter (0.9.2)
# Disable automatic framework detection by uncommenting/setting to false
# Warbler.framework_detection = false
# Warbler web application assembly configuration file
Warbler::Config.new do |config|
# Temporary directory where the application is staged
# config.staging_dir = "tmp/war"
# Application directories to be included in the webapp.
config.dirs = %w(app config lib log vendor tmp)
Warbler::Config.new do |config|
config.dirs = %w(app config tmp)
config.includes = FileList["init.rb"]
config.gems += ["sinatra", "haml"]
config.gems -= ["rails"]
config.gem_dependencies = true
end
<html>
<head>
<script type="text/javascript" src="jquery-1.3.2.js"></script>
<script type="text/javascript">
function getItems(path) {
$.getJSON(path,
function(data){
$.each(data.dataPackage.dataObject, function(i,item){
$("#results").append("<a href=\"#\" onclick='link(\""+item.relationshipsUri+"\");'>"+item.properties.object_name+"</a><br/>")
});
<?xml version="1.0" encoding="UTF-8"?>
<kml xmlns="http://www.opengis.net/kml/2.2">
<Folder>
<name>CrisisCamp</name>
<open>1</open>
<description>
Entries from CrisisCamp
</description>
<Placemark>
<name>Khairewala</name>
Server Software: nginx/0.7.67
Server Port: 80
Document Path: /
Document Length: 20266 bytes
Concurrency Level: 5
Time taken for tests: 304.670 seconds
Complete requests: 1000
Failed requests: 0
Server Software: Apache/2.2.14
Server Port: 80
Document Path: /
Document Length: 20266 bytes
Concurrency Level: 5
Time taken for tests: 344.008 seconds
Complete requests: 1000
Failed requests: 47