From ace9a686ea781fdee100586667d34de8e854bc99 Mon Sep 17 00:00:00 2001 From: brianschmitz Date: Fri, 10 Jan 2014 18:01:07 -0800 Subject: [PATCH 01/19] Client completed --- assignments/session01/echo_client.py | 22 +++++++++++++++++----- 1 file changed, 17 insertions(+), 5 deletions(-) diff --git a/assignments/session01/echo_client.py b/assignments/session01/echo_client.py index 61616c36..2dbc0a9c 100644 --- a/assignments/session01/echo_client.py +++ b/assignments/session01/echo_client.py @@ -6,16 +6,20 @@ def client(msg, log_buffer=sys.stderr): server_address = ('localhost', 10000) # TODO: Replace the following line with your code which will instantiate # a TCP socket with IPv4 Addressing, call the socket you make 'sock' - sock = None + sock = socket.socket( + socket.AF_INET, + socket.SOCK_STREAM, + socket.IPPROTO_IP) + print >>log_buffer, 'connecting to {0} port {1}'.format(*server_address) # TODO: connect your socket to the server here. - + sock.connect(server_address) # this try/finally block exists purely to allow us to close the socket # when we are finished with it try: print >>log_buffer, 'sending "{0}"'.format(msg) # TODO: send your message to the server here. - + sock.sendall(msg) # TODO: the server should be sending you back your message as a series # of 16-byte chunks. You will want to log them as you receive # each one. You will also need to check to make sure that @@ -24,12 +28,20 @@ def client(msg, log_buffer=sys.stderr): # # Make sure that you log each chunk you receive. Use the print # statement below to do it. (The tests expect this log format) - chunk = '' - print >>log_buffer, 'received "{0}"'.format(chunk) + amount_received = 0 + amount_expected = len(msg) + while amount_received < amount_expected: + chunk = sock.recv(16) + amount_received += len(chunk) + print >>log_buffer, 'received "{0}"'.format(chunk) + + + finally: # TODO: after you break out of the loop receiving echoed chunks from # the server you will want to close your client socket. print >>log_buffer, 'closing socket' + sock.close() if __name__ == '__main__': From 47f89aa26d65e84eb99ac3bb2e93a3f1d6885a33 Mon Sep 17 00:00:00 2001 From: brianschmitz Date: Fri, 10 Jan 2014 18:01:33 -0800 Subject: [PATCH 02/19] Server completed --- assignments/session01/echo_server.py | 28 ++++++++++++++++++++-------- 1 file changed, 20 insertions(+), 8 deletions(-) diff --git a/assignments/session01/echo_server.py b/assignments/session01/echo_server.py index 217380fb..927237c9 100644 --- a/assignments/session01/echo_server.py +++ b/assignments/session01/echo_server.py @@ -7,16 +7,21 @@ def server(log_buffer=sys.stderr): address = ('127.0.0.1', 10000) # TODO: Replace the following line with your code which will instantiate # a TCP socket with IPv4 Addressing, call the socket you make 'sock' - sock = None + sock = socket.socket( + socket.AF_INET, + socket.SOCK_STREAM, + socket.IPPROTO_TCP + ) # TODO: Set an option to allow the socket address to be reused immediately # see the end of http://docs.python.org/2/library/socket.html - + sock.setsockopt(socket.SOL_SOCKET, socket.SO_REUSEADDR, 1) # log that we are building a server print >>log_buffer, "making a server on {0}:{1}".format(*address) # TODO: bind your new sock 'sock' to the address above and begin to listen # for incoming connections - + sock.bind(address) + sock.listen(1) try: # the outer loop controls the creation of new connection sockets. The # server will handle each incoming connection one at a time. @@ -28,9 +33,10 @@ def server(log_buffer=sys.stderr): # the client so we can report it below. Replace the # following line with your code. It is only here to prevent # syntax errors - addr = ('bar', 'baz') + #addr = ('bar', 'baz') + conn, client_address = sock.accept() try: - print >>log_buffer, 'connection - {0}:{1}'.format(*addr) + print >>log_buffer, 'connection - {0}:{1}'.format(*client_address) # the inner loop will receive messages sent by the client in # buffers. When a complete message has been received, the @@ -41,12 +47,17 @@ def server(log_buffer=sys.stderr): # following line with your code. It's only here as # a placeholder to prevent an error in string # formatting - data = '' + data = conn.recv(16) print >>log_buffer, 'received "{0}"'.format(data) # TODO: you will need to check here to see if any data was # received. If so, send the data you got back to # the client. If not, exit the inner loop and wait # for a new connection from a client + if not data: + break + conn.send(data) + + finally: # TODO: When the inner loop exits, this 'finally' clause will @@ -54,14 +65,15 @@ def server(log_buffer=sys.stderr): # created above when a client connected. Replace the # call to `pass` below, which is only there to prevent # syntax problems - pass + conn.close() except KeyboardInterrupt: # TODO: Use the python KeyboardIntterupt exception as a signal to # close the server socket and exit from the server function. # Replace the call to `pass` below, which is only there to # prevent syntax problems - pass + sock.close() + sys.exit() if __name__ == '__main__': From 8389cc29418d54df431f47b1b559ec8cdc5e9c1b Mon Sep 17 00:00:00 2001 From: brianschmitz Date: Fri, 10 Jan 2014 18:06:57 -0800 Subject: [PATCH 03/19] Complete --- .idea/.name | 1 + .idea/encodings.xml | 5 + .idea/misc.xml | 5 + .idea/modules.xml | 9 + .idea/scopes/scope_settings.xml | 5 + .idea/training.python_web.iml | 16 + .idea/vcs.xml | 7 + .idea/workspace.xml | 547 ++++++++++++++++++++++++++++++++ 8 files changed, 595 insertions(+) create mode 100644 .idea/.name create mode 100644 .idea/encodings.xml create mode 100644 .idea/misc.xml create mode 100644 .idea/modules.xml create mode 100644 .idea/scopes/scope_settings.xml create mode 100644 .idea/training.python_web.iml create mode 100644 .idea/vcs.xml create mode 100644 .idea/workspace.xml diff --git a/.idea/.name b/.idea/.name new file mode 100644 index 00000000..9542d354 --- /dev/null +++ b/.idea/.name @@ -0,0 +1 @@ +training.python_web \ No newline at end of file diff --git a/.idea/encodings.xml b/.idea/encodings.xml new file mode 100644 index 00000000..e206d70d --- /dev/null +++ b/.idea/encodings.xml @@ -0,0 +1,5 @@ + + + + + diff --git a/.idea/misc.xml b/.idea/misc.xml new file mode 100644 index 00000000..39c829f6 --- /dev/null +++ b/.idea/misc.xml @@ -0,0 +1,5 @@ + + + + + diff --git a/.idea/modules.xml b/.idea/modules.xml new file mode 100644 index 00000000..743ed207 --- /dev/null +++ b/.idea/modules.xml @@ -0,0 +1,9 @@ + + + + + + + + + diff --git a/.idea/scopes/scope_settings.xml b/.idea/scopes/scope_settings.xml new file mode 100644 index 00000000..922003b8 --- /dev/null +++ b/.idea/scopes/scope_settings.xml @@ -0,0 +1,5 @@ + + + + \ No newline at end of file diff --git a/.idea/training.python_web.iml b/.idea/training.python_web.iml new file mode 100644 index 00000000..18de24d8 --- /dev/null +++ b/.idea/training.python_web.iml @@ -0,0 +1,16 @@ + + + + + + + + + + + + + diff --git a/.idea/vcs.xml b/.idea/vcs.xml new file mode 100644 index 00000000..c80f2198 --- /dev/null +++ b/.idea/vcs.xml @@ -0,0 +1,7 @@ + + + + + + + diff --git a/.idea/workspace.xml b/.idea/workspace.xml new file mode 100644 index 00000000..1579ebcb --- /dev/null +++ b/.idea/workspace.xml @@ -0,0 +1,547 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 1388873604217 + 1388873604217 + + + 1389405667962 + 1389405667962 + + + 1389405693782 + 1389405693782 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + From 75d74923a1f63e7e5c015b12e66c1baf6181a167 Mon Sep 17 00:00:00 2001 From: brianschmitz Date: Sat, 11 Jan 2014 08:10:13 -0800 Subject: [PATCH 04/19] update --- .idea/workspace.xml | 147 +++++++++++++++++++++++++------------------- 1 file changed, 84 insertions(+), 63 deletions(-) diff --git a/.idea/workspace.xml b/.idea/workspace.xml index 1579ebcb..50b9c045 100644 --- a/.idea/workspace.xml +++ b/.idea/workspace.xml @@ -2,12 +2,7 @@ - - - - - - + @@ -30,19 +25,10 @@ - - + + - - - - - - - - - - + @@ -50,21 +36,15 @@ - - + + - + - - - - - - - - + + @@ -92,7 +72,7 @@ - @@ -381,25 +405,25 @@ - - + + - - + - + + @@ -422,9 +446,16 @@ + + + + + + + - + @@ -432,9 +463,7 @@ - - - + @@ -462,9 +491,7 @@ - - - + @@ -484,63 +511,57 @@ - + - - - - + + - + - - - - - - - - + - + - + - + - + - + - + + + + From f4a0356133965ae8ade30b468ea09636da08bce0 Mon Sep 17 00:00:00 2001 From: brianschmitz Date: Sat, 11 Jan 2014 08:20:50 -0800 Subject: [PATCH 05/19] commit --- .idea/workspace.xml | 8 +++----- 1 file changed, 3 insertions(+), 5 deletions(-) diff --git a/.idea/workspace.xml b/.idea/workspace.xml index 50b9c045..4f7cd867 100644 --- a/.idea/workspace.xml +++ b/.idea/workspace.xml @@ -1,9 +1,7 @@ - - - + - + @@ -418,7 +416,7 @@ - + From 42309b44c4809fb9ab4a4d2415522f2d1a38c142 Mon Sep 17 00:00:00 2001 From: brianschmitz Date: Fri, 17 Jan 2014 16:42:51 -0800 Subject: [PATCH 06/19] save --- .idea/workspace.xml | 192 +++++++++++++++++-------- assignments/session02/http_server.py | 17 ++- assignments/session02/http_server_1.py | 74 ++++++++++ assignments/session02/tasks.txt | 1 + resources/session02/http_server.py | 11 +- 5 files changed, 229 insertions(+), 66 deletions(-) create mode 100644 assignments/session02/http_server_1.py diff --git a/.idea/workspace.xml b/.idea/workspace.xml index 4f7cd867..1b605e6b 100644 --- a/.idea/workspace.xml +++ b/.idea/workspace.xml @@ -1,7 +1,13 @@ - + + + + + + + - @@ -120,6 +147,38 @@ + + + + + - + - + - + - + @@ -446,120 +532,106 @@ - - - + - - - + - - - + - - - + - - - + - - - + - + - - - + - + - - - + - + - - - + - + - + - + - - + + + + - + - - + + + + - + - + - + - + - + + + + - + - - - diff --git a/assignments/session02/http_server.py b/assignments/session02/http_server.py index 12cbfeba..21a033f2 100644 --- a/assignments/session02/http_server.py +++ b/assignments/session02/http_server.py @@ -1,14 +1,21 @@ import socket import sys +import mimetypes -def response_ok(): +def response_ok(*args): """returns a basic HTTP response""" + if not args: + body = "this is a pretty minimal response" + mimetype = "text/plain" + else: + body = args[0] + mimetype = args[1] resp = [] resp.append("HTTP/1.1 200 OK") - resp.append("Content-Type: text/plain") + resp.append("Content-Type:" + mimetype) resp.append("") - resp.append("this is a pretty minimal response") + resp.append(body) return "\r\n".join(resp) @@ -26,6 +33,10 @@ def parse_request(request): if method != "GET": raise NotImplementedError("We only accept GET") print >>sys.stderr, 'request is okay' + return uri + +def resolve_uri(uri): + mime_res = (mimetypes.guess_type(uri))[0] def server(): diff --git a/assignments/session02/http_server_1.py b/assignments/session02/http_server_1.py new file mode 100644 index 00000000..d9d11800 --- /dev/null +++ b/assignments/session02/http_server_1.py @@ -0,0 +1,74 @@ +import socket +import sys + + +def response_ok(): + """returns a basic HTTP response""" + resp = [] + resp.append("HTTP/1.1 200 OK") + resp.append("Content-Type: text/plain") + resp.append("") + resp.append("this is a pretty minimal response") + return "\r\n".join(resp) + + +def response_method_not_allowed(): + """returns a 405 Method Not Allowed response""" + resp = [] + resp.append("HTTP/1.1 405 Method Not Allowed") + resp.append("") + return "\r\n".join(resp) + + +def parse_request(request): + first_line = request.split("\r\n", 1)[0] + method, uri, protocol = first_line.split() + if method != "GET": + raise NotImplementedError("We only accept GET") + print >>sys.stderr, 'request is okay' + return uri + +def resolve_uri(uri): + + +def server(): + address = ('127.0.0.1', 10000) + sock = socket.socket(socket.AF_INET, socket.SOCK_STREAM) + sock.setsockopt(socket.SOL_SOCKET, socket.SO_REUSEADDR, 1) + print >>sys.stderr, "making a server on %s:%s" % address + sock.bind(address) + sock.listen(1) + + try: + while True: + print >>sys.stderr, 'waiting for a connection' + conn, addr = sock.accept() # blocking + try: + print >>sys.stderr, 'connection - %s:%s' % addr + request = "" + while True: + data = conn.recv(1024) + request += data + if len(data) < 1024 or not data: + break + + try: + parse_request(request) + except NotImplementedError: + response = response_method_not_allowed() + else: + response = response_ok() + + print >>sys.stderr, 'sending response' + conn.sendall(response) + finally: + conn.close() + + except KeyboardInterrupt: + sock.close() + return + + +if __name__ == '__main__': + server() + sys.exit(0) diff --git a/assignments/session02/tasks.txt b/assignments/session02/tasks.txt index f7b397bd..e4eaacfe 100644 --- a/assignments/session02/tasks.txt +++ b/assignments/session02/tasks.txt @@ -77,3 +77,4 @@ Optional Tasks: If you choose to take on any of these optional tasks, try start by writing tests in tests.py that demostrate what the task should accomplish. Then write code that makes the tests pass. + diff --git a/resources/session02/http_server.py b/resources/session02/http_server.py index cac6911a..b5ede259 100644 --- a/resources/session02/http_server.py +++ b/resources/session02/http_server.py @@ -9,7 +9,11 @@ def server(log_buffer=sys.stderr): print >>log_buffer, "making a server on {0}:{1}".format(*address) sock.bind(address) sock.listen(1) - + + def response_ok(): + resp.[] + resp.append("HTTP/1.1 200 OK') + try: while True: print >>log_buffer, 'waiting for a connection' @@ -17,9 +21,10 @@ def server(log_buffer=sys.stderr): try: print >>log_buffer, 'connection - {0}:{1}'.format(*addr) while True: - data = conn.recv(16) + data = conn.recv(1024) print >>log_buffer, 'received "{0}"'.format(data) - if data: + if len(data) > 1024: + msg = 'sending data back to client' print >>log_buffer, msg conn.sendall(data) From 5560edd957ba535df7a0cef4e44cf2de12070369 Mon Sep 17 00:00:00 2001 From: brianschmitz Date: Sun, 2 Feb 2014 13:54:19 -0800 Subject: [PATCH 07/19] update --- .idea/workspace.xml | 364 +++++++++++++----- assignments/session02/http_server.py | 2 +- ...=test_key,22de6f7c4f73ac9c59368db27552cd97 | 8 + ...=test_key,b807e82ce475840821922fab3fb6aded | 8 + ...=test_key,e31b486f6c8afe2e0f4a3a994f47970c | 8 + ...=test_key,44b43d8d27c899b633db930a9d0fb1d6 | 8 + assignments/session03/eventful.py | 66 ++++ assignments/session03/eventmap_mash.py | 60 +++ resources/session03/mashup.py | 24 +- resources/session04/cgi/cgi-bin/cgi_1.py | 6 + resources/session04/cgi/cgi-bin/cgi_2.py | 2 +- resources/session04/wsgi/bookapp.py | 62 ++- resources/session05/sql/books.db | Bin 0 -> 4096 bytes resources/session05/sql/createdb.py | 21 +- resources/session05/sql/populatedb.py | 28 +- resources/session05/sql/utils.py | 2 +- 16 files changed, 545 insertions(+), 124 deletions(-) create mode 100644 assignments/session03/.cache/api.eventful.com,json,events,search,q=cycling&l=Seattle&app_key=test_key,22de6f7c4f73ac9c59368db27552cd97 create mode 100644 assignments/session03/.cache/api.eventful.com,json,events,search,q=cycling&l=WA&app_key=test_key,b807e82ce475840821922fab3fb6aded create mode 100644 assignments/session03/.cache/api.eventful.com,json,events,search,q=music&l=San+Diego&app_key=test_key,e31b486f6c8afe2e0f4a3a994f47970c create mode 100644 assignments/session03/.cache/api.eventful.com,json,events,search,q=running&l=Seattle&app_key=test_key,44b43d8d27c899b633db930a9d0fb1d6 create mode 100644 assignments/session03/eventful.py create mode 100644 assignments/session03/eventmap_mash.py create mode 100644 resources/session05/sql/books.db diff --git a/.idea/workspace.xml b/.idea/workspace.xml index 1b605e6b..859abe62 100644 --- a/.idea/workspace.xml +++ b/.idea/workspace.xml @@ -1,11 +1,17 @@ - - + + + + + + + - - + + + @@ -17,6 +23,10 @@ + + + + @@ -29,42 +39,30 @@ - - + + - - - - - - - - - - - - + - - + + - - + + + + - - - - - + + - + @@ -78,6 +76,7 @@ + @@ -93,14 +92,22 @@ - @@ -175,7 +182,11 @@ - - - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - - - + - + - - - - - + - + - - - - - + - + - - - + - + - - - - + + - + - + - - - - + - - + + + + diff --git a/assignments/session02/http_server.py b/assignments/session02/http_server.py index 21a033f2..1aff7f28 100644 --- a/assignments/session02/http_server.py +++ b/assignments/session02/http_server.py @@ -3,7 +3,7 @@ import mimetypes -def response_ok(*args): +def response_ok(body, mimetyp): """returns a basic HTTP response""" if not args: body = "this is a pretty minimal response" diff --git a/assignments/session03/.cache/api.eventful.com,json,events,search,q=cycling&l=Seattle&app_key=test_key,22de6f7c4f73ac9c59368db27552cd97 b/assignments/session03/.cache/api.eventful.com,json,events,search,q=cycling&l=Seattle&app_key=test_key,22de6f7c4f73ac9c59368db27552cd97 new file mode 100644 index 00000000..2878cf6c --- /dev/null +++ b/assignments/session03/.cache/api.eventful.com,json,events,search,q=cycling&l=Seattle&app_key=test_key,22de6f7c4f73ac9c59368db27552cd97 @@ -0,0 +1,8 @@ +status: 200 +content-length: 13688 +content-location: http://api.eventful.com/json//events/search?q=cycling&l=Seattle&app_key=test_key +server: lighttpd/1.4.28 +date: Tue, 28 Jan 2014 18:00:36 GMT +content-type: text/javascript; charset=utf-8 + +{"last_item":null,"total_items":"86","first_item":null,"page_number":"1","page_size":"10","page_items":null,"search_time":"0.028","page_count":"9","events":{"event":[{"watching_count":null,"calendar_count":null,"comment_count":null,"region_abbr":"WA","postal_code":"98073","going_count":null,"all_day":"0","latitude":"47.6742","groups":null,"url":"http://seattle.eventful.com/events/cycling-event-redspoke-2014-/E0-001-064398941-3@2014071607?utm_source=apis&utm_medium=apim&utm_campaign=apic","id":"E0-001-064398941-3@2014071607","privacy":"1","city_name":"Redmond","link_count":null,"longitude":"-122.121","country_name":"United States","country_abbr":"USA","region_name":"Washington","start_time":"2014-07-16 07:30:00","tz_id":null,"description":" ","modified":"2014-01-24 08:11:36","venue_display":"1","tz_country":null,"performers":null,"title":"Cycling Event - RedSpoke 2014","venue_address":null,"geocode_type":"Zip Code Based GeoCodes","tz_olson_path":null,"recur_string":"daily until July 20, 2014","calendars":null,"owner":"evdb","going":null,"country_abbr2":"US","image":null,"created":"2013-12-03 23:58:17","venue_id":"V0-001-002355411-0","tz_city":null,"stop_time":null,"venue_name":"Redmond, WA to Spokane, WA","venue_url":"http://seattle.eventful.com/venues/redmond-wa-to-spokane-wa-/V0-001-002355411-0?utm_source=apis&utm_medium=apim&utm_campaign=apic"},{"watching_count":null,"calendar_count":null,"comment_count":null,"region_abbr":"WA","postal_code":"98198","going_count":null,"all_day":"2","latitude":"47.3861","groups":null,"url":"http://seattle.eventful.com/events/ladies-only-cycling-tour-cycling-san-juans-/E0-001-064407533-7?utm_source=apis&utm_medium=apim&utm_campaign=apic","id":"E0-001-064407533-7","privacy":"1","city_name":"Seattle","link_count":null,"longitude":"-122.304","country_name":"United States","country_abbr":"USA","region_name":"Washington","start_time":"2014-05-11 00:00:00","tz_id":null,"description":" ","modified":"2014-01-17 02:42:18","venue_display":"1","tz_country":null,"performers":null,"title":"Ladies Only Cycling Tour - Cycling the San Juans","venue_address":"20717 International Blvd","geocode_type":"Zip Code Based GeoCodes","tz_olson_path":null,"recur_string":null,"calendars":null,"owner":"evdb","going":null,"country_abbr2":"US","image":null,"created":"2013-12-04 03:14:57","venue_id":"V0-001-007518635-2","tz_city":null,"stop_time":"2014-05-16 00:00:00","venue_name":"San Juan Islands","venue_url":"http://seattle.eventful.com/venues/san-juan-islands-/V0-001-007518635-2?utm_source=apis&utm_medium=apim&utm_campaign=apic"},{"watching_count":null,"calendar_count":null,"comment_count":null,"region_abbr":"WA","postal_code":"98040","going_count":null,"all_day":"0","latitude":"47.5602","groups":null,"url":"http://seattle.eventful.com/events/path-pedal-against-trafficking-humans-ride-/E0-001-064399183-4?utm_source=apis&utm_medium=apim&utm_campaign=apic","id":"E0-001-064399183-4","privacy":"1","city_name":"Mercer Island","link_count":null,"longitude":"-122.228","country_name":"United States","country_abbr":"USA","region_name":"Washington","start_time":"2014-03-30 08:00:00","tz_id":null,"description":" ","modified":"2014-01-07 13:39:48","venue_display":"1","tz_country":null,"performers":null,"title":"PATH (Pedal Against Trafficking Humans) Ride","venue_address":"2750 77th Ave SE","geocode_type":"Zip Code Based GeoCodes","tz_olson_path":null,"recur_string":null,"calendars":null,"owner":"evdb","going":null,"country_abbr2":"US","image":null,"created":"2013-12-04 00:12:22","venue_id":"V0-001-007516834-7","tz_city":null,"stop_time":null,"venue_name":"Veloce Velo Bicycles","venue_url":"http://seattle.eventful.com/venues/veloce-velo-bicycles-/V0-001-007516834-7?utm_source=apis&utm_medium=apim&utm_campaign=apic"},{"watching_count":null,"calendar_count":null,"comment_count":null,"region_abbr":"WA","postal_code":null,"going_count":null,"all_day":"0","latitude":"47.6514320","groups":null,"url":"http://seattle.eventful.com/events/tour-pro-performance-cycling-/E0-001-066157804-4?utm_source=apis&utm_medium=apim&utm_campaign=apic","id":"E0-001-066157804-4","privacy":"1","city_name":"Bellevue","link_count":null,"longitude":"-122.1451520","country_name":"United States","country_abbr":"USA","region_name":"Washington","start_time":"2014-02-10 06:00:00","tz_id":null,"description":" Location:
Bellevue - Cycling Studio

Description:
Maximize your cycling performance & get the results you want! This challenging ride will motivate you to increase your speed, stamina, and strength on the bike.","modified":"2014-01-25 16:33:23","venue_display":"1","tz_country":null,"performers":null,"title":"Tour de PRO: Performance Cycling","venue_address":"4455 148th Avenue N E","geocode_type":"EVDB Geocoder","tz_olson_path":null,"recur_string":null,"calendars":null,"owner":"evdb","going":null,"country_abbr2":"US","image":null,"created":"2014-01-25 16:33:23","venue_id":"V0-001-000610995-9","tz_city":null,"stop_time":null,"venue_name":"Pro Sports Club - Bellevue","venue_url":"http://seattle.eventful.com/venues/pro-sports-club-bellevue-/V0-001-000610995-9?utm_source=apis&utm_medium=apim&utm_campaign=apic"},{"watching_count":null,"calendar_count":null,"comment_count":null,"region_abbr":"WA","postal_code":null,"going_count":null,"all_day":"0","latitude":"47.6514320","groups":null,"url":"http://seattle.eventful.com/events/tour-pro-performance-cycling-/E0-001-066157802-6?utm_source=apis&utm_medium=apim&utm_campaign=apic","id":"E0-001-066157802-6","privacy":"1","city_name":"Bellevue","link_count":null,"longitude":"-122.1451520","country_name":"United States","country_abbr":"USA","region_name":"Washington","start_time":"2014-02-10 09:15:00","tz_id":null,"description":" Location:
Bellevue - Cycling Studio

Description:
Maximize your cycling performance & get the results you want! This challenging ride will motivate you to increase your speed, stamina, and strength on the bike.","modified":"2014-01-25 16:33:22","venue_display":"1","tz_country":null,"performers":null,"title":"Tour de PRO: Performance Cycling","venue_address":"4455 148th Avenue N E","geocode_type":"EVDB Geocoder","tz_olson_path":null,"recur_string":null,"calendars":null,"owner":"evdb","going":null,"country_abbr2":"US","image":null,"created":"2014-01-25 16:33:22","venue_id":"V0-001-000610995-9","tz_city":null,"stop_time":null,"venue_name":"Pro Sports Club - Bellevue","venue_url":"http://seattle.eventful.com/venues/pro-sports-club-bellevue-/V0-001-000610995-9?utm_source=apis&utm_medium=apim&utm_campaign=apic"},{"watching_count":null,"calendar_count":null,"comment_count":null,"region_abbr":"WA","postal_code":null,"going_count":null,"all_day":"0","latitude":"47.6514320","groups":null,"url":"http://seattle.eventful.com/events/tour-pro-performance-cycling-/E0-001-066157817-8?utm_source=apis&utm_medium=apim&utm_campaign=apic","id":"E0-001-066157817-8","privacy":"1","city_name":"Bellevue","link_count":null,"longitude":"-122.1451520","country_name":"United States","country_abbr":"USA","region_name":"Washington","start_time":"2014-02-12 09:15:00","tz_id":null,"description":" Location:
Bellevue - Cycling Studio

Description:
Maximize your cycling performance & get the results you want! This challenging ride will motivate you to increase your speed, stamina, and strength on the bike.","modified":"2014-01-25 16:33:41","venue_display":"1","tz_country":null,"performers":null,"title":"Tour de PRO: Performance Cycling","venue_address":"4455 148th Avenue N E","geocode_type":"EVDB Geocoder","tz_olson_path":null,"recur_string":null,"calendars":null,"owner":"evdb","going":null,"country_abbr2":"US","image":null,"created":"2014-01-25 16:33:41","venue_id":"V0-001-000610995-9","tz_city":null,"stop_time":null,"venue_name":"Pro Sports Club - Bellevue","venue_url":"http://seattle.eventful.com/venues/pro-sports-club-bellevue-/V0-001-000610995-9?utm_source=apis&utm_medium=apim&utm_campaign=apic"},{"watching_count":null,"calendar_count":null,"comment_count":null,"region_abbr":"WA","postal_code":null,"going_count":null,"all_day":"0","latitude":"47.6514320","groups":null,"url":"http://seattle.eventful.com/events/tour-pro-performance-cycling-/E0-001-066157815-0?utm_source=apis&utm_medium=apim&utm_campaign=apic","id":"E0-001-066157815-0","privacy":"1","city_name":"Bellevue","link_count":null,"longitude":"-122.1451520","country_name":"United States","country_abbr":"USA","region_name":"Washington","start_time":"2014-02-05 09:15:00","tz_id":null,"description":" Location:
Bellevue - Cycling Studio

Description:
Maximize your cycling performance & get the results you want! This challenging ride will motivate you to increase your speed, stamina, and strength on the bike.","modified":"2014-01-25 16:33:38","venue_display":"1","tz_country":null,"performers":null,"title":"Tour de PRO: Performance Cycling","venue_address":"4455 148th Avenue N E","geocode_type":"EVDB Geocoder","tz_olson_path":null,"recur_string":null,"calendars":null,"owner":"evdb","going":null,"country_abbr2":"US","image":null,"created":"2014-01-25 16:33:38","venue_id":"V0-001-000610995-9","tz_city":null,"stop_time":null,"venue_name":"Pro Sports Club - Bellevue","venue_url":"http://seattle.eventful.com/venues/pro-sports-club-bellevue-/V0-001-000610995-9?utm_source=apis&utm_medium=apim&utm_campaign=apic"},{"watching_count":null,"calendar_count":null,"comment_count":null,"region_abbr":"WA","postal_code":null,"going_count":null,"all_day":"0","latitude":"47.6514320","groups":null,"url":"http://seattle.eventful.com/events/tour-pro-performance-cycling-/E0-001-066157812-3?utm_source=apis&utm_medium=apim&utm_campaign=apic","id":"E0-001-066157812-3","privacy":"1","city_name":"Bellevue","link_count":null,"longitude":"-122.1451520","country_name":"United States","country_abbr":"USA","region_name":"Washington","start_time":"2014-02-10 18:00:00","tz_id":null,"description":" Location:
Bellevue - Cycling Studio

Description:
Maximize your cycling performance & get the results you want! This challenging ride will motivate you to increase your speed, stamina, and strength on the bike.","modified":"2014-01-25 16:33:34","venue_display":"1","tz_country":null,"performers":null,"title":"Tour de PRO: Performance Cycling","venue_address":"4455 148th Avenue N E","geocode_type":"EVDB Geocoder","tz_olson_path":null,"recur_string":null,"calendars":null,"owner":"evdb","going":null,"country_abbr2":"US","image":null,"created":"2014-01-25 16:33:34","venue_id":"V0-001-000610995-9","tz_city":null,"stop_time":null,"venue_name":"Pro Sports Club - Bellevue","venue_url":"http://seattle.eventful.com/venues/pro-sports-club-bellevue-/V0-001-000610995-9?utm_source=apis&utm_medium=apim&utm_campaign=apic"},{"watching_count":null,"calendar_count":null,"comment_count":null,"region_abbr":"WA","postal_code":null,"going_count":null,"all_day":"0","latitude":"47.6514320","groups":null,"url":"http://seattle.eventful.com/events/tour-pro-performance-cycling-/E0-001-065951104-6?utm_source=apis&utm_medium=apim&utm_campaign=apic","id":"E0-001-065951104-6","privacy":"1","city_name":"Bellevue","link_count":null,"longitude":"-122.1451520","country_name":"United States","country_abbr":"USA","region_name":"Washington","start_time":"2014-02-03 09:15:00","tz_id":null,"description":" Location:
Bellevue - Cycling Studio

Description:
Maximize your cycling performance & get the results you want! This challenging ride will motivate you to increase your speed, stamina, and strength on the bike.","modified":"2014-01-17 23:29:52","venue_display":"1","tz_country":null,"performers":null,"title":"Tour de PRO: Performance Cycling","venue_address":"4455 148th Avenue N E","geocode_type":"EVDB Geocoder","tz_olson_path":null,"recur_string":null,"calendars":null,"owner":"evdb","going":null,"country_abbr2":"US","image":null,"created":"2014-01-17 23:29:52","venue_id":"V0-001-000610995-9","tz_city":null,"stop_time":null,"venue_name":"Pro Sports Club - Bellevue","venue_url":"http://seattle.eventful.com/venues/pro-sports-club-bellevue-/V0-001-000610995-9?utm_source=apis&utm_medium=apim&utm_campaign=apic"},{"watching_count":null,"calendar_count":null,"comment_count":null,"region_abbr":"WA","postal_code":null,"going_count":null,"all_day":"0","latitude":"47.6514320","groups":null,"url":"http://seattle.eventful.com/events/tour-pro-performance-cycling-/E0-001-065951115-2?utm_source=apis&utm_medium=apim&utm_campaign=apic","id":"E0-001-065951115-2","privacy":"1","city_name":"Bellevue","link_count":null,"longitude":"-122.1451520","country_name":"United States","country_abbr":"USA","region_name":"Washington","start_time":"2014-02-03 18:00:00","tz_id":null,"description":" Location:
Bellevue - Cycling Studio

Description:
Maximize your cycling performance & get the results you want! This challenging ride will motivate you to increase your speed, stamina, and strength on the bike.","modified":"2014-01-17 23:30:01","venue_display":"1","tz_country":null,"performers":null,"title":"Tour de PRO: Performance Cycling","venue_address":"4455 148th Avenue N E","geocode_type":"EVDB Geocoder","tz_olson_path":null,"recur_string":null,"calendars":null,"owner":"evdb","going":null,"country_abbr2":"US","image":null,"created":"2014-01-17 23:30:01","venue_id":"V0-001-000610995-9","tz_city":null,"stop_time":null,"venue_name":"Pro Sports Club - Bellevue","venue_url":"http://seattle.eventful.com/venues/pro-sports-club-bellevue-/V0-001-000610995-9?utm_source=apis&utm_medium=apim&utm_campaign=apic"}]}} diff --git a/assignments/session03/.cache/api.eventful.com,json,events,search,q=cycling&l=WA&app_key=test_key,b807e82ce475840821922fab3fb6aded b/assignments/session03/.cache/api.eventful.com,json,events,search,q=cycling&l=WA&app_key=test_key,b807e82ce475840821922fab3fb6aded new file mode 100644 index 00000000..da3da59e --- /dev/null +++ b/assignments/session03/.cache/api.eventful.com,json,events,search,q=cycling&l=WA&app_key=test_key,b807e82ce475840821922fab3fb6aded @@ -0,0 +1,8 @@ +status: 200 +content-length: 161 +content-location: http://api.eventful.com/json//events/search?q=cycling&l=WA&app_key=test_key +server: lighttpd/1.4.28 +date: Tue, 28 Jan 2014 17:58:01 GMT +content-type: text/javascript; charset=utf-8 + +{"last_item":null,"total_items":"0","first_item":null,"page_number":"1","page_size":"10","page_items":null,"search_time":"0.018","page_count":"0","events":null} diff --git a/assignments/session03/.cache/api.eventful.com,json,events,search,q=music&l=San+Diego&app_key=test_key,e31b486f6c8afe2e0f4a3a994f47970c b/assignments/session03/.cache/api.eventful.com,json,events,search,q=music&l=San+Diego&app_key=test_key,e31b486f6c8afe2e0f4a3a994f47970c new file mode 100644 index 00000000..d9cd4ca0 --- /dev/null +++ b/assignments/session03/.cache/api.eventful.com,json,events,search,q=music&l=San+Diego&app_key=test_key,e31b486f6c8afe2e0f4a3a994f47970c @@ -0,0 +1,8 @@ +status: 200 +content-length: 21462 +content-location: http://api.eventful.com/json//events/search?q=music&l=San+Diego&app_key=test_key +server: lighttpd/1.4.28 +date: Sun, 26 Jan 2014 17:23:55 GMT +content-type: text/javascript; charset=utf-8 + +{"last_item":null,"total_items":"1851","first_item":null,"page_number":"1","page_size":"10","page_items":null,"search_time":"0.053","page_count":"186","events":{"event":[{"watching_count":null,"calendar_count":null,"comment_count":null,"region_abbr":"CA","postal_code":"92101","going_count":null,"all_day":"0","latitude":"32.7314520","groups":null,"url":"http://sandiego.eventful.com/events/first-friday-films-music-room-jalsaghar-/E0-001-066123521-9?utm_source=apis&utm_medium=apim&utm_campaign=apic","id":"E0-001-066123521-9","privacy":"1","city_name":"San Diego","link_count":null,"longitude":"-117.1512999","country_name":"United States","country_abbr":"USA","region_name":"California","start_time":"2014-03-07 19:00:00","tz_id":null,"description":"

7:00 p.m. Pre-Film Lecture | 8:00 p.m. Film

Satyaijt Ray (1921-1992) was a master of Indian cinema and his work continues to be studied and discovered by audiences around the world. The Music Room, also known by its original title Jalsaghar, follows an aristocrat's weakening grip on power and the destruction of his personal and public life during a radical shift in Indian society when the feudal system was outlawed. Set in West Bengal, the film's protagonist remains committed to tradition, pride, and above all, organizing concerts of beautiful Indian music in his home.

Prior to the film, scholar and professor Aditi Chandra, Ph.D., will deliver a lecture analyzing the ways in which historical Indian monuments can inform our ideas about the development of modern Indian society and its social relations. Chandra is Assistant Professor in the School of Social Sciences, Humanities and Art at University of California, Merced.

Charcuterie and a Movie Package for Two
Enjoy some nibbles and wine during the lecture and film.
$50 members | $60 nonmembers

Package includes:

  • Fruit + Fromage + Charcuterie Plate
  • Artisanal Cheeses / Cured Meats/ Seasonal Fruits
  • Infused Truffle Honey / Red Grape Mustard
  • Rosemary Roasted Marcona Almonds / Bread & Cie Baguette
  • Bottle of Wine (Chef's choice)
  • Tickets for two to the First Friday Film
To guarantee availability, reserve your package online or by calling 619.696.1935 by 4:00 p.m. on Wednesday, March 5, 2014.

","modified":"2014-01-24 15:34:33","venue_display":"1","tz_country":null,"performers":{"performer":{"creator":"themusicroomband","linker":"evdb","name":"The Music Room","url":"http://concerts.eventful.com/The-Music-Room?utm_source=apis&utm_medium=apim&utm_campaign=apic","id":"P0-001-000219393-2","short_bio":"Folk Rock, Rock, Acoustic, Folk"}},"title":"First Friday Films: The Music Room, or Jalsaghar","venue_address":"1450 El Prado Balboa Park","geocode_type":"EVDB Geocoder","tz_olson_path":null,"recur_string":null,"calendars":null,"owner":"evdb","going":null,"country_abbr2":"US","image":{"small":{"width":"48","url":"http://s3.evcdn.com/images/small/I0-001/002/779/294-9.jpeg_/the-music-room-94.jpeg","height":"48"},"width":"48","caption":null,"medium":{"width":"128","url":"http://s3.evcdn.com/images/medium/I0-001/002/779/294-9.jpeg_/the-music-room-94.jpeg","height":"128"},"url":"http://s3.evcdn.com/images/small/I0-001/002/779/294-9.jpeg_/the-music-room-94.jpeg","thumb":{"width":"48","url":"http://s3.evcdn.com/images/thumb/I0-001/002/779/294-9.jpeg_/the-music-room-94.jpeg","height":"48"},"height":"48"},"created":"2014-01-24 15:34:33","venue_id":"V0-001-000106700-1","tz_city":null,"stop_time":null,"venue_name":"The San Diego Museum of Art","venue_url":"http://sandiego.eventful.com/venues/the-san-diego-museum-of-art-/V0-001-000106700-1?utm_source=apis&utm_medium=apim&utm_campaign=apic"},{"watching_count":null,"calendar_count":null,"comment_count":null,"region_abbr":"CA","postal_code":null,"going_count":null,"all_day":"0","latitude":"32.8446120","groups":null,"url":"http://sandiego.eventful.com/events/la-jolla-music-society-presents-chamber-music-socie-/E0-001-059121063-6?utm_source=apis&utm_medium=apim&utm_campaign=apic","id":"E0-001-059121063-6","privacy":"1","city_name":"La Jolla","link_count":null,"longitude":"-117.2779420","country_name":"United States","country_abbr":"USA","region_name":"California","start_time":"2014-03-22 20:00:00","tz_id":null,"description":" La Jolla Music Society presents: Mozart: Quartet for Flute and Strings no 1 in D major, K 285; Mozart: Duo for Violin and Viola no 1 in G major, K 423; Currier: New Work; Villa-Lobos: Choros no 2 p...\n","modified":"2013-07-13 11:22:00","venue_display":"1","tz_country":null,"performers":{"performer":{"creator":"SPAHouston","linker":"evdb","name":"Chamber Music Society of Lincoln Center","url":"http://eventful.com/performers/chamber-music-society-of-lincoln-center-/P0-001-000144637-8?utm_source=apis&utm_medium=apim&utm_campaign=apic","id":"P0-001-000144637-8","short_bio":"one of 12 constituents of Lincoln Center for the Performing Arts, the largest performing arts complex in the world"}},"title":"La Jolla Music Society presents Chamber Music Society of Lincoln Center - Mozart Connections","venue_address":"700 Prospect Street","geocode_type":"EVDB Geocoder","tz_olson_path":null,"recur_string":null,"calendars":null,"owner":"evdb","going":null,"country_abbr2":"US","image":{"small":{"width":"48","url":"http://s2.evcdn.com/images/small/I0-001/014/374/981-0.jpeg_/la-jolla-music-society-presents-chamber-music-soci-81.jpeg","height":"48"},"width":"48","caption":null,"medium":{"width":"128","url":"http://s2.evcdn.com/images/medium/I0-001/014/374/981-0.jpeg_/la-jolla-music-society-presents-chamber-music-soci-81.jpeg","height":"128"},"url":"http://s2.evcdn.com/images/small/I0-001/014/374/981-0.jpeg_/la-jolla-music-society-presents-chamber-music-soci-81.jpeg","thumb":{"width":"48","url":"http://s2.evcdn.com/images/thumb/I0-001/014/374/981-0.jpeg_/la-jolla-music-society-presents-chamber-music-soci-81.jpeg","height":"48"},"height":"48"},"created":"2013-07-13 11:22:00","venue_id":"V0-001-001046075-0","tz_city":null,"stop_time":null,"venue_name":"Sherwood Auditorium at MCASD","venue_url":"http://sandiego.eventful.com/venues/sherwood-auditorium-at-mcasd-/V0-001-001046075-0?utm_source=apis&utm_medium=apim&utm_campaign=apic"},{"watching_count":null,"calendar_count":null,"comment_count":null,"region_abbr":"CA","postal_code":null,"going_count":null,"all_day":"0","latitude":"32.8446120","groups":null,"url":"http://sandiego.eventful.com/events/la-jolla-music-society-presents-chamber-music-socie-/E0-001-059121076-0?utm_source=apis&utm_medium=apim&utm_campaign=apic","id":"E0-001-059121076-0","privacy":"1","city_name":"La Jolla","link_count":null,"longitude":"-117.2779420","country_name":"United States","country_abbr":"USA","region_name":"California","start_time":"2014-04-26 20:00:00","tz_id":null,"description":" La Jolla Music Society presents: Beethoven: Piano Quartet in E-flat Major, Op. 16; Martinu: Madrigals (3) for Violin and Viola, H 313; Faur: Quartet for Piano and Strings no 1 in C minor, Op. 15\n","modified":"2013-07-13 11:24:04","venue_display":"1","tz_country":null,"performers":{"performer":{"creator":"SPAHouston","linker":"evdb","name":"Chamber Music Society of Lincoln Center","url":"http://eventful.com/performers/chamber-music-society-of-lincoln-center-/P0-001-000144637-8?utm_source=apis&utm_medium=apim&utm_campaign=apic","id":"P0-001-000144637-8","short_bio":"one of 12 constituents of Lincoln Center for the Performing Arts, the largest performing arts complex in the world"}},"title":"La Jolla Music Society presents Chamber Music Society of Lincoln Center - Defining Voices","venue_address":"700 Prospect Street","geocode_type":"EVDB Geocoder","tz_olson_path":null,"recur_string":null,"calendars":null,"owner":"evdb","going":null,"country_abbr2":"US","image":{"small":{"width":"48","url":"http://s4.evcdn.com/images/small/I0-001/014/374/987-4.jpeg_/la-jolla-music-society-presents-chamber-music-soci-87.jpeg","height":"48"},"width":"48","caption":null,"medium":{"width":"128","url":"http://s4.evcdn.com/images/medium/I0-001/014/374/987-4.jpeg_/la-jolla-music-society-presents-chamber-music-soci-87.jpeg","height":"128"},"url":"http://s4.evcdn.com/images/small/I0-001/014/374/987-4.jpeg_/la-jolla-music-society-presents-chamber-music-soci-87.jpeg","thumb":{"width":"48","url":"http://s4.evcdn.com/images/thumb/I0-001/014/374/987-4.jpeg_/la-jolla-music-society-presents-chamber-music-soci-87.jpeg","height":"48"},"height":"48"},"created":"2013-07-13 11:24:04","venue_id":"V0-001-001046075-0","tz_city":null,"stop_time":null,"venue_name":"Sherwood Auditorium at MCASD","venue_url":"http://sandiego.eventful.com/venues/sherwood-auditorium-at-mcasd-/V0-001-001046075-0?utm_source=apis&utm_medium=apim&utm_campaign=apic"},{"watching_count":null,"calendar_count":null,"comment_count":null,"region_abbr":"CA","postal_code":null,"going_count":null,"all_day":"0","latitude":"32.8446120","groups":null,"url":"http://sandiego.eventful.com/events/la-jolla-music-society-presents-chamber-music-socie-/E0-001-059121035-3?utm_source=apis&utm_medium=apim&utm_campaign=apic","id":"E0-001-059121035-3","privacy":"1","city_name":"La Jolla","link_count":null,"longitude":"-117.2779420","country_name":"United States","country_abbr":"USA","region_name":"California","start_time":"2014-02-08 20:00:00","tz_id":null,"description":" La Jolla Music Society presents: Debussy: Nocturnes, for 2 pianos; Debussy: Suite for Piano "Pour le piano"; Debussy: Jeux; Bizet: Jeux d'enfants, Op. 22; Gershwin: An American in Paris (Arr. for 2...\n","modified":"2013-07-13 11:19:24","venue_display":"1","tz_country":null,"performers":{"performer":{"creator":"SPAHouston","linker":"evdb","name":"Chamber Music Society of Lincoln Center","url":"http://eventful.com/performers/chamber-music-society-of-lincoln-center-/P0-001-000144637-8?utm_source=apis&utm_medium=apim&utm_campaign=apic","id":"P0-001-000144637-8","short_bio":"one of 12 constituents of Lincoln Center for the Performing Arts, the largest performing arts complex in the world"}},"title":"La Jolla Music Society presents Chamber Music Society of Lincoln Center - An American in Paris","venue_address":"700 Prospect Street","geocode_type":"EVDB Geocoder","tz_olson_path":null,"recur_string":null,"calendars":null,"owner":"evdb","going":null,"country_abbr2":"US","image":{"small":{"width":"48","url":"http://s2.evcdn.com/images/small/I0-001/014/374/973-1.jpeg_/la-jolla-music-society-presents-chamber-music-soci-73.jpeg","height":"48"},"width":"48","caption":null,"medium":{"width":"128","url":"http://s2.evcdn.com/images/medium/I0-001/014/374/973-1.jpeg_/la-jolla-music-society-presents-chamber-music-soci-73.jpeg","height":"128"},"url":"http://s2.evcdn.com/images/small/I0-001/014/374/973-1.jpeg_/la-jolla-music-society-presents-chamber-music-soci-73.jpeg","thumb":{"width":"48","url":"http://s2.evcdn.com/images/thumb/I0-001/014/374/973-1.jpeg_/la-jolla-music-society-presents-chamber-music-soci-73.jpeg","height":"48"},"height":"48"},"created":"2013-07-13 11:19:24","venue_id":"V0-001-001046075-0","tz_city":null,"stop_time":null,"venue_name":"Sherwood Auditorium at MCASD","venue_url":"http://sandiego.eventful.com/venues/sherwood-auditorium-at-mcasd-/V0-001-001046075-0?utm_source=apis&utm_medium=apim&utm_campaign=apic"},{"watching_count":null,"calendar_count":null,"comment_count":null,"region_abbr":"CA","postal_code":"92071","going_count":null,"all_day":"2","latitude":"32.8482","groups":null,"url":"http://sandiego.eventful.com/events/early-childhood-music-/E0-001-066111239-8?utm_source=apis&utm_medium=apim&utm_campaign=apic","id":"E0-001-066111239-8","privacy":"1","city_name":"Santee","link_count":null,"longitude":"-116.992","country_name":"United States","country_abbr":"USA","region_name":"California","start_time":"2014-01-25 00:00:00","tz_id":null,"description":" Event Overview

Early Childhood Music, in Santee, CA, takes place January 25, 2014 and ends on March 01, 2014. This event will be located at Staump Music School.

","modified":"2014-01-23 19:43:12","venue_display":"1","tz_country":null,"performers":null,"title":"Early Childhood Music","venue_address":"9530 Pathway St. #201","geocode_type":"Zip Code Based GeoCodes","tz_olson_path":null,"recur_string":null,"calendars":null,"owner":"evdb","going":null,"country_abbr2":"US","image":null,"created":"2014-01-23 19:32:51","venue_id":"V0-001-007520469-4","tz_city":null,"stop_time":"2014-03-01 00:00:00","venue_name":"Staump Music School","venue_url":"http://sandiego.eventful.com/venues/staump-music-school-/V0-001-007520469-4?utm_source=apis&utm_medium=apim&utm_campaign=apic"},{"watching_count":null,"calendar_count":null,"comment_count":null,"region_abbr":"CA","postal_code":"92071","going_count":null,"all_day":"0","latitude":"32.8482","groups":null,"url":"http://sandiego.eventful.com/events/early-childhood-music-/E0-001-064510428-3@2014012609?utm_source=apis&utm_medium=apim&utm_campaign=apic","id":"E0-001-064510428-3@2014012609","privacy":"1","city_name":"Santee","link_count":null,"longitude":"-116.992","country_name":"United States","country_abbr":"USA","region_name":"California","start_time":"2014-01-26 09:00:00","tz_id":null,"description":" ","modified":"2013-12-06 01:11:14","venue_display":"1","tz_country":null,"performers":null,"title":"Early Childhood Music","venue_address":"9530 Pathway St. #201","geocode_type":"Zip Code Based GeoCodes","tz_olson_path":null,"recur_string":"daily until March 1, 2014","calendars":null,"owner":"evdb","going":null,"country_abbr2":"US","image":null,"created":"2013-12-06 01:11:14","venue_id":"V0-001-007520469-4","tz_city":null,"stop_time":null,"venue_name":"Staump Music School","venue_url":"http://sandiego.eventful.com/venues/staump-music-school-/V0-001-007520469-4?utm_source=apis&utm_medium=apim&utm_campaign=apic"},{"watching_count":null,"calendar_count":null,"comment_count":null,"region_abbr":"CA","postal_code":"92093","going_count":null,"all_day":"0","latitude":"32.87785316904055","groups":null,"url":"http://sandiego.eventful.com/events/camera-lucida-presents-myriad-trio-ii-/E0-001-063056563-9?utm_source=apis&utm_medium=apim&utm_campaign=apic","id":"E0-001-063056563-9","privacy":"1","city_name":"La Jolla","link_count":null,"longitude":"-117.234994776799","country_name":"United States","country_abbr":"USA","region_name":"California","start_time":"2014-06-10 19:30:00","tz_id":null,"description":" Camera Lucida; Myriad Trio; San Diego Symphony; UCSD Music Department presents: Program TBA\n","modified":"2014-01-05 01:35:08","venue_display":"1","tz_country":null,"performers":null,"title":"CAMERA LUCIDA Presents Myriad Trio II","venue_address":"9500 Gilman Drive","geocode_type":"EVDB Geocoder","tz_olson_path":null,"recur_string":null,"calendars":null,"owner":"evdb","going":null,"country_abbr2":"US","image":{"small":{"width":"48","url":"http://s2.evcdn.com/images/small/I0-001/014/953/237-3.jpeg_/camera-lucida-presents-myriad-trio-ii-37.jpeg","height":"48"},"width":"48","caption":null,"medium":{"width":"128","url":"http://s2.evcdn.com/images/medium/I0-001/014/953/237-3.jpeg_/camera-lucida-presents-myriad-trio-ii-37.jpeg","height":"128"},"url":"http://s2.evcdn.com/images/small/I0-001/014/953/237-3.jpeg_/camera-lucida-presents-myriad-trio-ii-37.jpeg","thumb":{"width":"48","url":"http://s2.evcdn.com/images/thumb/I0-001/014/953/237-3.jpeg_/camera-lucida-presents-myriad-trio-ii-37.jpeg","height":"48"},"height":"48"},"created":"2013-11-01 02:28:21","venue_id":"V0-001-006031574-7","tz_city":null,"stop_time":null,"venue_name":"Conrad Prebys Music Center","venue_url":"http://sandiego.eventful.com/venues/conrad-prebys-music-center-/V0-001-006031574-7?utm_source=apis&utm_medium=apim&utm_campaign=apic"},{"watching_count":null,"calendar_count":null,"comment_count":null,"region_abbr":"CA","postal_code":null,"going_count":null,"all_day":"0","latitude":"32.7744363","groups":null,"url":"http://sandiego.eventful.com/events/music-lent-/E0-001-060700804-8?utm_source=apis&utm_medium=apim&utm_campaign=apic","id":"E0-001-060700804-8","privacy":"1","city_name":"San Diego","link_count":null,"longitude":"-117.1837880","country_name":"United States","country_abbr":"USA","region_name":"California","start_time":"2014-03-30 16:00:00","tz_id":null,"description":" Angelus Early Music Series presents: Program TBA\n","modified":"2013-09-29 03:16:16","venue_display":"1","tz_country":null,"performers":null,"title":"Music for Lent","venue_address":"Jenny Craig Pavilion","geocode_type":"EVDB Geocoder","tz_olson_path":null,"recur_string":null,"calendars":null,"owner":"evdb","going":null,"country_abbr2":"US","image":{"small":{"width":"48","url":"http://s3.evcdn.com/images/small/I0-001/014/610/090-6.jpeg_/music-lent-90.jpeg","height":"48"},"width":"48","caption":null,"medium":{"width":"128","url":"http://s3.evcdn.com/images/medium/I0-001/014/610/090-6.jpeg_/music-lent-90.jpeg","height":"128"},"url":"http://s3.evcdn.com/images/small/I0-001/014/610/090-6.jpeg_/music-lent-90.jpeg","thumb":{"width":"48","url":"http://s3.evcdn.com/images/thumb/I0-001/014/610/090-6.jpeg_/music-lent-90.jpeg","height":"48"},"height":"48"},"created":"2013-08-31 01:37:38","venue_id":"V0-001-006049978-4","tz_city":null,"stop_time":null,"venue_name":"University of San Diego","venue_url":"http://sandiego.eventful.com/venues/university-of-san-diego-/V0-001-006049978-4?utm_source=apis&utm_medium=apim&utm_campaign=apic"},{"watching_count":null,"calendar_count":null,"comment_count":null,"region_abbr":"CA","postal_code":"92093","going_count":null,"all_day":"0","latitude":"32.87785316904055","groups":null,"url":"http://sandiego.eventful.com/events/camera-lucida-mozart-brahms-/E0-001-063056554-1?utm_source=apis&utm_medium=apim&utm_campaign=apic","id":"E0-001-063056554-1","privacy":"1","city_name":"La Jolla","link_count":null,"longitude":"-117.234994776799","country_name":"United States","country_abbr":"USA","region_name":"California","start_time":"2014-02-03 19:30:00","tz_id":null,"description":" Camera Lucida; San Diego Symphony; UCSD Music Department presents: Mozart: Piano Trio No. 4 in E major, K. 542; Clarke: Sonata for Viola/Cello and Piano; Brahms: Trio for Clarinet, Cello and Piano ...\n","modified":"2013-11-04 01:41:31","venue_display":"1","tz_country":null,"performers":null,"title":"CAMERA LUCIDA / Mozart, Brahms","venue_address":"9500 Gilman Drive","geocode_type":"EVDB Geocoder","tz_olson_path":null,"recur_string":null,"calendars":null,"owner":"evdb","going":null,"country_abbr2":"US","image":{"small":{"width":"48","url":"http://s2.evcdn.com/images/small/I0-001/014/953/233-7.jpeg_/camera-lucida-mozart-brahms-33.jpeg","height":"48"},"width":"48","caption":null,"medium":{"width":"128","url":"http://s2.evcdn.com/images/medium/I0-001/014/953/233-7.jpeg_/camera-lucida-mozart-brahms-33.jpeg","height":"128"},"url":"http://s2.evcdn.com/images/small/I0-001/014/953/233-7.jpeg_/camera-lucida-mozart-brahms-33.jpeg","thumb":{"width":"48","url":"http://s2.evcdn.com/images/thumb/I0-001/014/953/233-7.jpeg_/camera-lucida-mozart-brahms-33.jpeg","height":"48"},"height":"48"},"created":"2013-11-01 02:28:01","venue_id":"V0-001-006031574-7","tz_city":null,"stop_time":null,"venue_name":"Conrad Prebys Music Center","venue_url":"http://sandiego.eventful.com/venues/conrad-prebys-music-center-/V0-001-006031574-7?utm_source=apis&utm_medium=apim&utm_campaign=apic"},{"watching_count":null,"calendar_count":null,"comment_count":null,"region_abbr":"CA","postal_code":"92093","going_count":null,"all_day":"0","latitude":"32.87785316904055","groups":null,"url":"http://sandiego.eventful.com/events/camera-lucida-dvork-sibelius-/E0-001-063056559-6?utm_source=apis&utm_medium=apim&utm_campaign=apic","id":"E0-001-063056559-6","privacy":"1","city_name":"La Jolla","link_count":null,"longitude":"-117.234994776799","country_name":"United States","country_abbr":"USA","region_name":"California","start_time":"2014-06-02 19:30:00","tz_id":null,"description":" Camera Lucida; San Diego Symphony; UCSD Music Department presents: Kodly: Serenade for Two Violins and Viola; Dvorak: Trio for Piano and Strings no 3 in F minor, Op. 65/B 130; Sibelius: Quartet fo...\n","modified":"2013-11-04 01:41:37","venue_display":"1","tz_country":null,"performers":null,"title":"CAMERA LUCIDA / Dvork, Sibelius","venue_address":"9500 Gilman Drive","geocode_type":"EVDB Geocoder","tz_olson_path":null,"recur_string":null,"calendars":null,"owner":"evdb","going":null,"country_abbr2":"US","image":{"small":{"width":"48","url":"http://s1.evcdn.com/images/small/I0-001/014/953/236-4.jpeg_/camera-lucida-dvork-sibelius-36.jpeg","height":"48"},"width":"48","caption":null,"medium":{"width":"128","url":"http://s1.evcdn.com/images/medium/I0-001/014/953/236-4.jpeg_/camera-lucida-dvork-sibelius-36.jpeg","height":"128"},"url":"http://s1.evcdn.com/images/small/I0-001/014/953/236-4.jpeg_/camera-lucida-dvork-sibelius-36.jpeg","thumb":{"width":"48","url":"http://s1.evcdn.com/images/thumb/I0-001/014/953/236-4.jpeg_/camera-lucida-dvork-sibelius-36.jpeg","height":"48"},"height":"48"},"created":"2013-11-01 02:28:18","venue_id":"V0-001-006031574-7","tz_city":null,"stop_time":null,"venue_name":"Conrad Prebys Music Center","venue_url":"http://sandiego.eventful.com/venues/conrad-prebys-music-center-/V0-001-006031574-7?utm_source=apis&utm_medium=apim&utm_campaign=apic"}]}} diff --git a/assignments/session03/.cache/api.eventful.com,json,events,search,q=running&l=Seattle&app_key=test_key,44b43d8d27c899b633db930a9d0fb1d6 b/assignments/session03/.cache/api.eventful.com,json,events,search,q=running&l=Seattle&app_key=test_key,44b43d8d27c899b633db930a9d0fb1d6 new file mode 100644 index 00000000..85b3be38 --- /dev/null +++ b/assignments/session03/.cache/api.eventful.com,json,events,search,q=running&l=Seattle&app_key=test_key,44b43d8d27c899b633db930a9d0fb1d6 @@ -0,0 +1,8 @@ +status: 200 +content-length: 11930 +content-location: http://api.eventful.com/json//events/search?q=running&l=Seattle&app_key=test_key +server: lighttpd/1.4.28 +date: Wed, 29 Jan 2014 01:47:19 GMT +content-type: text/javascript; charset=utf-8 + +{"last_item":null,"total_items":"213","first_item":null,"page_number":"1","page_size":"10","page_items":null,"search_time":"0.036","page_count":"22","events":{"event":[{"watching_count":null,"calendar_count":null,"comment_count":null,"region_abbr":"WA","postal_code":null,"going_count":null,"all_day":"2","latitude":"47.6064","groups":null,"url":"http://seattle.eventful.com/events/running-event-int-running-/E0-001-060455183-1?utm_source=apis&utm_medium=apim&utm_campaign=apic","id":"E0-001-060455183-1","privacy":"1","city_name":"Seattle","link_count":null,"longitude":"-122.331","country_name":"United States","country_abbr":"USA","region_name":"Washington","start_time":"2014-08-23 00:00:00","tz_id":null,"description":" ","modified":"2014-01-24 07:58:49","venue_display":"1","tz_country":null,"performers":null,"title":"Running Event - INT Running","venue_address":null,"geocode_type":"City Based GeoCodes","tz_olson_path":null,"recur_string":null,"calendars":null,"owner":"evdb","going":null,"country_abbr2":"US","image":null,"created":"2013-08-23 04:04:56","venue_id":"V0-001-007243812-0","tz_city":null,"stop_time":"2014-08-23 00:00:00","venue_name":"WA","venue_url":"http://seattle.eventful.com/venues/wa-/V0-001-007243812-0?utm_source=apis&utm_medium=apim&utm_campaign=apic"},{"watching_count":null,"calendar_count":null,"comment_count":null,"region_abbr":"WA","postal_code":"98208","going_count":null,"all_day":"0","latitude":"47.9015","groups":null,"url":"http://seattle.eventful.com/events/mill-creek-puddle-run-/E0-001-064399659-2?utm_source=apis&utm_medium=apim&utm_campaign=apic","id":"E0-001-064399659-2","privacy":"1","city_name":"Everett","link_count":null,"longitude":"-122.184","country_name":"United States","country_abbr":"USA","region_name":"Washington","start_time":"2014-02-02 08:30:00","tz_id":null,"description":" ","modified":"2013-12-19 13:55:35","venue_display":"1","tz_country":null,"performers":null,"title":"Mill Creek Puddle Run","venue_address":"13723 Puget Park Drive","geocode_type":"Zip Code Based GeoCodes","tz_olson_path":null,"recur_string":null,"calendars":null,"owner":"evdb","going":null,"country_abbr2":"US","image":null,"created":"2013-12-04 00:23:42","venue_id":"V0-001-007516927-6","tz_city":null,"stop_time":null,"venue_name":"Mill Creek Family YMCA","venue_url":"http://seattle.eventful.com/venues/mill-creek-family-ymca-/V0-001-007516927-6?utm_source=apis&utm_medium=apim&utm_campaign=apic"},{"watching_count":null,"calendar_count":null,"comment_count":null,"region_abbr":"WA","postal_code":"98103","going_count":null,"all_day":"2","latitude":"47.6798964","groups":null,"url":"http://seattle.eventful.com/events/superbowl-5k-runwalk-/E0-001-066202003-0?utm_source=apis&utm_medium=apim&utm_campaign=apic","id":"E0-001-066202003-0","privacy":"1","city_name":"Seattle","link_count":null,"longitude":"-122.3281102","country_name":"United States","country_abbr":"USA","region_name":"Washington","start_time":"2014-02-01 00:00:00","tz_id":null,"description":" ","modified":"2014-01-27 10:36:50","venue_display":"1","tz_country":null,"performers":null,"title":"SuperBowl 5k Run/Walk","venue_address":"7201 E Green Lake Drive N","geocode_type":"EVDB Geocoder","tz_olson_path":null,"recur_string":null,"calendars":null,"owner":"evdb","going":null,"country_abbr2":"US","image":null,"created":"2014-01-27 10:36:50","venue_id":"V0-001-000402996-9","tz_city":null,"stop_time":"2014-02-01 00:00:00","venue_name":"Evans Pool","venue_url":"http://seattle.eventful.com/venues/evans-pool-/V0-001-000402996-9?utm_source=apis&utm_medium=apim&utm_campaign=apic"},{"watching_count":null,"calendar_count":null,"comment_count":null,"region_abbr":"WA","postal_code":"98421","going_count":null,"all_day":"2","latitude":"47.2363400","groups":null,"url":"http://seattle.eventful.com/events/color-run-tacoma-/E0-001-065225697-3?utm_source=apis&utm_medium=apim&utm_campaign=apic","id":"E0-001-065225697-3","privacy":"1","city_name":"Tacoma","link_count":null,"longitude":"-122.4268340","country_name":"United States","country_abbr":"USA","region_name":"Washington","start_time":"2014-08-10 00:00:00","tz_id":null,"description":" ","modified":"2014-01-05 01:29:57","venue_display":"1","tz_country":null,"performers":null,"title":"THE COLOR RUN TACOMA","venue_address":"2727 East D Street","geocode_type":"EVDB Geocoder","tz_olson_path":null,"recur_string":null,"calendars":null,"owner":"evdb","going":null,"country_abbr2":"US","image":null,"created":"2013-12-27 12:24:00","venue_id":"V0-001-000144232-7","tz_city":null,"stop_time":"2014-08-10 00:00:00","venue_name":"Tacoma Dome","venue_url":"http://seattle.eventful.com/venues/tacoma-dome-/V0-001-000144232-7?utm_source=apis&utm_medium=apim&utm_campaign=apic"},{"watching_count":null,"calendar_count":null,"comment_count":null,"region_abbr":"WA","postal_code":"98373","going_count":null,"all_day":"0","latitude":"47.1402691","groups":null,"url":"http://seattle.eventful.com/events/rogers-reindeer-fun-run-/E0-001-064892349-4?utm_source=apis&utm_medium=apim&utm_campaign=apic","id":"E0-001-064892349-4","privacy":"1","city_name":"Puyallup","link_count":null,"longitude":"-122.3091746","country_name":"United States","country_abbr":"USA","region_name":"Washington","start_time":"2014-12-13 09:00:00","tz_id":null,"description":" ","modified":"2014-01-05 00:29:28","venue_display":"1","tz_country":null,"performers":null,"title":"Rogers Reindeer Fun Run","venue_address":"9010 128th Street E","geocode_type":"EVDB Geocoder","tz_olson_path":null,"recur_string":null,"calendars":null,"owner":"evdb","going":null,"country_abbr2":"US","image":null,"created":"2013-12-15 12:17:53","venue_id":"V0-001-000549441-6","tz_city":null,"stop_time":"2014-12-13 00:00:00","venue_name":"Heritage Recreation Center","venue_url":"http://seattle.eventful.com/venues/heritage-recreation-center-/V0-001-000549441-6?utm_source=apis&utm_medium=apim&utm_campaign=apic"},{"watching_count":null,"calendar_count":null,"comment_count":null,"region_abbr":"WA","postal_code":"98103","going_count":null,"all_day":"2","latitude":"47.6468650","groups":null,"url":"http://seattle.eventful.com/events/emerald-city-run-/E0-001-061648024-4?utm_source=apis&utm_medium=apim&utm_campaign=apic","id":"E0-001-061648024-4","privacy":"1","city_name":"Seattle","link_count":null,"longitude":"-122.3339155","country_name":"United States","country_abbr":"USA","region_name":"Washington","start_time":"2014-05-25 00:00:00","tz_id":null,"description":" ","modified":"2014-01-04 13:20:49","venue_display":"1","tz_country":null,"performers":null,"title":"Emerald City Run","venue_address":"2101 N Northlake Way","geocode_type":"EVDB Geocoder","tz_olson_path":null,"recur_string":null,"calendars":null,"owner":"evdb","going":null,"country_abbr2":"US","image":null,"created":"2013-09-24 13:12:40","venue_id":"V0-001-000256560-7","tz_city":null,"stop_time":"2014-05-25 00:00:00","venue_name":"Gas Works Park","venue_url":"http://seattle.eventful.com/venues/gas-works-park-/V0-001-000256560-7?utm_source=apis&utm_medium=apim&utm_campaign=apic"},{"watching_count":null,"calendar_count":null,"comment_count":null,"region_abbr":"WA","postal_code":"98106","going_count":null,"all_day":"2","latitude":"47.5498873","groups":null,"url":"http://seattle.eventful.com/events/seattle-run-series-revolution-run-2-3race-serie-/E0-001-064763538-9?utm_source=apis&utm_medium=apim&utm_campaign=apic","id":"E0-001-064763538-9","privacy":"1","city_name":"Seattle","link_count":null,"longitude":"-122.2576880","country_name":"United States","country_abbr":"USA","region_name":"Washington","start_time":"2014-02-23 00:00:00","tz_id":null,"description":" ","modified":"2014-01-09 01:42:49","venue_display":"1","tz_country":null,"performers":null,"title":"Seattle Run Series - Revolution Run (#2 of 3-Race Series)","venue_address":"5895 Lake Washington Blvd. S","geocode_type":"EVDB Geocoder","tz_olson_path":null,"recur_string":null,"calendars":null,"owner":"evdb","going":null,"country_abbr2":"US","image":null,"created":"2013-12-12 02:27:25","venue_id":"V0-001-005947639-8","tz_city":null,"stop_time":"2014-02-23 00:00:00","venue_name":"Seward Park, Seattle, Shelter #2","venue_url":"http://seattle.eventful.com/venues/seward-park-seattle-shelter-2-/V0-001-005947639-8?utm_source=apis&utm_medium=apim&utm_campaign=apic"},{"watching_count":null,"calendar_count":null,"comment_count":null,"region_abbr":"WA","postal_code":"98106","going_count":null,"all_day":"2","latitude":"47.5498873","groups":null,"url":"http://seattle.eventful.com/events/seattle-run-series-evolution-run-3-3race-series-/E0-001-064763541-3?utm_source=apis&utm_medium=apim&utm_campaign=apic","id":"E0-001-064763541-3","privacy":"1","city_name":"Seattle","link_count":null,"longitude":"-122.2576880","country_name":"United States","country_abbr":"USA","region_name":"Washington","start_time":"2014-03-30 00:00:00","tz_id":null,"description":" ","modified":"2014-01-09 01:42:49","venue_display":"1","tz_country":null,"performers":null,"title":"Seattle Run Series - Evolution Run (#3 of 3-Race Series)","venue_address":"5895 Lake Washington Blvd. S","geocode_type":"EVDB Geocoder","tz_olson_path":null,"recur_string":null,"calendars":null,"owner":"evdb","going":null,"country_abbr2":"US","image":null,"created":"2013-12-12 02:27:29","venue_id":"V0-001-005947639-8","tz_city":null,"stop_time":"2014-03-30 00:00:00","venue_name":"Seward Park, Seattle, Shelter #2","venue_url":"http://seattle.eventful.com/venues/seward-park-seattle-shelter-2-/V0-001-005947639-8?utm_source=apis&utm_medium=apim&utm_campaign=apic"},{"watching_count":null,"calendar_count":null,"comment_count":null,"region_abbr":"WA","postal_code":"98275","going_count":null,"all_day":"0","latitude":"47.8983820","groups":null,"url":"http://seattle.eventful.com/events/inspiring-hope-runwalk-2014-/E0-001-057746292-3?utm_source=apis&utm_medium=apim&utm_campaign=apic","id":"E0-001-057746292-3","privacy":"1","city_name":"Mukilteo","link_count":null,"longitude":"-122.3003070","country_name":"United States","country_abbr":"USA","region_name":"Washington","start_time":"2014-05-10 09:00:00","tz_id":null,"description":null,"modified":"2013-06-23 15:43:48","venue_display":"1","tz_country":null,"performers":null,"title":"Inspiring Hope Run/Walk 2014","venue_address":"10801 HARBOUR POINTE BLVD","geocode_type":"EVDB Geocoder","tz_olson_path":null,"recur_string":null,"calendars":null,"owner":"evdb","going":null,"country_abbr2":"US","image":null,"created":"2013-05-27 01:10:56","venue_id":"V0-001-004573067-9","tz_city":null,"stop_time":null,"venue_name":"Kamiak High School","venue_url":"http://seattle.eventful.com/venues/kamiak-high-school-/V0-001-004573067-9?utm_source=apis&utm_medium=apim&utm_campaign=apic"},{"watching_count":null,"calendar_count":null,"comment_count":null,"region_abbr":"WA","postal_code":"98115","going_count":null,"all_day":"2","latitude":"47.6813531","groups":null,"url":"http://seattle.eventful.com/events/run-like-mother-seattle-wa-/E0-001-066165870-2?utm_source=apis&utm_medium=apim&utm_campaign=apic","id":"E0-001-066165870-2","privacy":"1","city_name":"Seattle","link_count":null,"longitude":"-122.2593355","country_name":"United States","country_abbr":"USA","region_name":"Washington","start_time":"2014-05-11 00:00:00","tz_id":null,"description":" ","modified":"2014-01-25 19:56:40","venue_display":"1","tz_country":null,"performers":null,"title":"Run Like A Mother - Seattle, WA","venue_address":"7400 Sand Point Way N.E.","geocode_type":"EVDB Geocoder","tz_olson_path":null,"recur_string":null,"calendars":null,"owner":"evdb","going":null,"country_abbr2":"US","image":null,"created":"2014-01-25 19:56:40","venue_id":"V0-001-000256403-3","tz_city":null,"stop_time":"2014-05-11 00:00:00","venue_name":"Warren G. Magnuson Park","venue_url":"http://seattle.eventful.com/venues/warren-g-magnuson-park-/V0-001-000256403-3?utm_source=apis&utm_medium=apim&utm_campaign=apic"}]}} diff --git a/assignments/session03/eventful.py b/assignments/session03/eventful.py new file mode 100644 index 00000000..5b98d618 --- /dev/null +++ b/assignments/session03/eventful.py @@ -0,0 +1,66 @@ +""" +eventful + +A Python interface to the Eventful API. + +""" + +__author__ = "Edward O'Connor " +__copyright__ = "Copyright 2005, 2006 Eventful Inc." +__license__ = "MIT" + +import md5 +import urllib + +import httplib2 +import simplejson + +__all__ = ['APIError', 'API'] + +class APIError(Exception): + pass + +class API: + def __init__(self, app_key, server='api.eventful.com', cache=None): + """Create a new Eventful API client instance. +If you don't have an application key, you can request one: + http://api.eventful.com/keys/""" + self.app_key = app_key + self.server = server + self.http = httplib2.Http(cache) + + def call(self, method, **args): + "Call the Eventful API's METHOD with ARGS." + # Build up the request + args['app_key'] = self.app_key + if hasattr(self, 'user_key'): + args['user'] = self.user + args['user_key'] = self.user_key + args = urllib.urlencode(args) + url = "http://%s/json/%s?%s" % (self.server, method, args) + + # Make the request + response, content = self.http.request(url, "GET") + + # Handle the response + status = int(response['status']) + if status == 200: + try: + return simplejson.loads(content) + except ValueError: + raise APIError("Unable to parse API response!") + elif status == 404: + raise APIError("Method not found: %s" % method) + else: + raise APIError("Non-200 HTTP response status: %s" % response['status']) + + def login(self, user, password): + "Login to the Eventful API as USER with PASSWORD." + nonce = self.call('/users/login')['nonce'] + response = md5.new(nonce + ':' + + md5.new(password).hexdigest()).hexdigest() + login = self.call('/users/login', user=user, nonce=nonce, + response=response) + self.user_key = login['user_key'] + self.user = user + return user diff --git a/assignments/session03/eventmap_mash.py b/assignments/session03/eventmap_mash.py new file mode 100644 index 00000000..3b7fd840 --- /dev/null +++ b/assignments/session03/eventmap_mash.py @@ -0,0 +1,60 @@ +__author__ = 'brianschmitz' + + + + +import eventful + +api = eventful.API('test_key', cache='.cache') +# api.login('username', 'password') +events = api.call('/events/search', q='running', l='Seattle', ) + +for event in events['events']['event']: + print "%s at %s" % (event['title'], event['venue_name'],) + print event['start_time'] + print event['description'] + +import requests + +URL = 'https://www.google.com/search?pz=1&cf=all&ned=us&hl=en&tbm=nws&gl=us&as_q={query}&as_occt=any&as_drrb=b&as_mindate={month}%2F%{from_day}%2F{year}&as_maxdate={month}%2F{to_day}%2F{year}&tbs=cdr%3A1%2Ccd_min%3A3%2F1%2F13%2Ccd_max%3A3%2F2%2F13&as_nsrc=Gulf%20Times&authuser=0' + + +def run(**params): + response = requests.get(URL.format(**params)) + print response.content, response.status_code + + +# run(query=event['description'], month=1, from_day=1, to_day=1, year=14) + +# -*- coding: utf-8 -*- +import urllib +import urllib2 +import json + +def main(event): + query = event + print bing_search(query, 'Web') + # print bing_search(query, 'Image') + +def bing_search(query, search_type): + #search_type: Web, Image, News, Video + key= 'fIXP2iI8QV2pPFpJBao3e5lfrMP8B27CtQ5c2UkKq3w' + query = urllib.quote(query) + # create credential for authentication + user_agent = 'Mozilla/4.0 (compatible; MSIE 7.0; Windows NT 5.1; Trident/4.0; FDM; .NET CLR 2.0.50727; InfoPath.2; .NET CLR 1.1.4322)' + credentials = (':%s' % key).encode('base64')[:-1] + auth = 'Basic %s' % credentials + url = 'https://api.datamarket.azure.com/Data.ashx/Bing/Search/'+search_type+'?Query=%27'+query+'%27&$top=5&$format=json' + request = urllib2.Request(url) + request.add_header('Authorization', auth) + request.add_header('User-Agent', user_agent) + request_opener = urllib2.build_opener() + response = request_opener.open(request) + response_data = response.read() + json_result = json.loads(response_data) + result_list = json_result['d']['results'] + print result_list + return result_list + +if __name__ == "__main__": + main(event['description']) \ No newline at end of file diff --git a/resources/session03/mashup.py b/resources/session03/mashup.py index 5ebfc490..c10aba24 100644 --- a/resources/session03/mashup.py +++ b/resources/session03/mashup.py @@ -20,6 +20,7 @@ def fetch_search_results( def parse_source(html, encoding='utf-8'): + html = open('craigslist_results.html', 'r') parsed = BeautifulSoup(html, from_encoding=encoding) return parsed @@ -82,11 +83,20 @@ def add_walkscore(listing): if __name__ == '__main__': - html, encoding = fetch_search_results( - minAsk=500, maxAsk=1000, bedrooms=2 - ) + + # html, encoding = fetch_search_results( + # minAsk=500, maxAsk=1000, bedrooms=2 + #) + html = '' + encoding = 'utf-8' + doc = parse_source(html, encoding) - for listing in extract_listings(doc): - listing = add_address(listing) - listing = add_walkscore(listing) - pprint.pprint(listing) + listings = extract_listings(doc) + + #for listings in listings + print listings + #for listing in extract_listings(doc): + # listing = add_address(listing) + # listing = add_walkscore(listing) + # pprint.pprint(listing) + print doc.prettify() \ No newline at end of file diff --git a/resources/session04/cgi/cgi-bin/cgi_1.py b/resources/session04/cgi/cgi-bin/cgi_1.py index b969de64..27936f82 100755 --- a/resources/session04/cgi/cgi-bin/cgi_1.py +++ b/resources/session04/cgi/cgi-bin/cgi_1.py @@ -1,5 +1,11 @@ #!/usr/bin/python import cgi +import cgitb + + +cgitb.enable + + cgi.test() diff --git a/resources/session04/cgi/cgi-bin/cgi_2.py b/resources/session04/cgi/cgi-bin/cgi_2.py index eb6f2702..8b9744c5 100755 --- a/resources/session04/cgi/cgi-bin/cgi_2.py +++ b/resources/session04/cgi/cgi-bin/cgi_2.py @@ -1,4 +1,4 @@ -#!/usr/bin/python +#!/usr/bin/env/python import cgi import cgitb cgitb.enable() diff --git a/resources/session04/wsgi/bookapp.py b/resources/session04/wsgi/bookapp.py index 809d0a0a..c2eeead5 100644 --- a/resources/session04/wsgi/bookapp.py +++ b/resources/session04/wsgi/bookapp.py @@ -5,19 +5,65 @@ DB = BookDB() -def book(book_id): - return "

a book with id %s

" % book_id +def book(book_id): + page = """ +

{title}

+ + + + +
Author{author}
Publisher{publisher}
ISBN{isbn}
+Back to the list +""" + book = DB.title_info(book_id) + if book is None: + raise NameError + return page.format(**book) def books(): - return "

a list of books

" + all_books = DB.titles() + body = ['

My Bookshelf

', '
    '] + item_template = '
  • {title}
  • ' + for book in all_books: + body.append(item_template.format(**book)) + body.append('
') + return '\n'.join(body) + + +def application(environ, start_response): + headers = [("Content-type", "text/html")] + try: + path = environ.get('PATH_INFO', None) + if path is None: + raise NameError + func, args = resolve_path(path) + body = func(*args) + status = "200 OK" + except NameError: + status = "404 Not Found" + body = "

Not Found

" + except Exception: + status = "500 Internal Server Error" + body = "

Internal Server Error

" + finally: + headers.append(('Content-length', str(len(body)))) + start_response(status, headers) + return [body] +def resolve_path(path): + urls = [(r'^$', books), + (r'^book/(id[\d]+)$', book)] + matchpath = path.lstrip('/') + for regexp, func in urls: + match = re.match(regexp, matchpath) + if match is None: + continue + args = match.groups([]) + return func, args + # we get here if no url matches + raise NameError -def application(environ, start_response): - status = "200 OK" - headers = [('Content-type', 'text/html')] - start_response(status, headers) - return ["

No Progress Yet

", ] if __name__ == '__main__': diff --git a/resources/session05/sql/books.db b/resources/session05/sql/books.db new file mode 100644 index 0000000000000000000000000000000000000000..3aaf9b71f39f658a4c7adeeeb5bdadf606c4ca57 GIT binary patch literal 4096 zcmeHKK~EDw6rP>8rE~=WYunU>WIPaP0F8PP6Qi{(w9=NcU7|giEgk5j(_Pt4K@S@7 ztTFxt5BvpB#;frMaPg$^WMaH{HF0(eXiLF()qTy(n|brzH}ieTWT)koJQI|xJ8shw z9nZA|Ri5HpDi0@gAUT|VX0=7#aStJWPh40w^xR_6gPZE4rHG*~=!Ra*=;i&& z{S{VAX{iz(NK8*F760U|O)js|y%ybUQ+ti}OreWU&*GGAHR+73Ou0%pkxVK(H+;y> zAv!(o0_em%Njjsy7RB4q*F;NscTPrU3P&53Iq!LqY4aSh$-G% zDy}JzR60)w&Ab0`d>O%K*n@ZQ26o{&Jb(=-!Bt4&ANU*oi1+YYyo+DrCz#1BMd$r+)~QyRP@`v5l=1_ME~WN16Ki!yjH&37ADp+`24O8?u$J5u zVxt~vmU7+_uG5@sku2MyI5MK5m@?nCDIPklqVdR*cS6GwL&M(8KgF8mo*PopT%<(Z z8ml>^EaZklI!nltjh{N1rgjX?NPn7xy)?u9Xbv1lGt{4^`imxX(ZpRemE&pt1O~21 AL;wH) literal 0 HcmV?d00001 diff --git a/resources/session05/sql/createdb.py b/resources/session05/sql/createdb.py index 429bbdbf..e9d72ee2 100644 --- a/resources/session05/sql/createdb.py +++ b/resources/session05/sql/createdb.py @@ -1,11 +1,30 @@ import os import sqlite3 +from utils import show_table_metadata DB_FILENAME = 'books.db' DB_IS_NEW = not os.path.exists(DB_FILENAME) +DB_FILENAME = 'books.db' +SCHEMA_FILENAME = 'ddl.sql' # <- this is new +DB_IS_NEW = not os.path.exists(DB_FILENAME) + def main(): - pass + with sqlite3.connect(DB_FILENAME) as conn: # <- context mgr + if DB_IS_NEW: # A whole new if clause: + print 'Creating schema' + with open(SCHEMA_FILENAME, 'rt') as f: + schema = f.read() + conn.executescript(schema) + else: + # in the else clause, replace the print statement with this: + print "Database exists, introspecting:" + tablenames = ['author', 'book'] + cursor = conn.cursor() + for name in tablenames: + print "\n" + show_table_metadata(cursor, name) + # delete the `conn.close()` that was here. if __name__ == '__main__': main() \ No newline at end of file diff --git a/resources/session05/sql/populatedb.py b/resources/session05/sql/populatedb.py index 92baff4d..acdcff91 100644 --- a/resources/session05/sql/populatedb.py +++ b/resources/session05/sql/populatedb.py @@ -35,10 +35,36 @@ def show_books(conn): query = book_query show_query_results(conn, query) +def populate_db(conn): + authors = ([author] for author in AUTHORS_BOOKS.keys()) + cur = conn.cursor() + cur.executemany(author_insert, authors) + + for author in AUTHORS_BOOKS.keys(): + params = ([book, author] for book in AUTHORS_BOOKS[author]) + cur.executemany(book_insert, params) if __name__ == '__main__': if DB_IS_NEW: print "Database does not yet exist, please import `createdb` first" sys.exit(1) - print "Do something cool here" + with sqlite3.connect(DB_FILENAME) as conn1: + with sqlite3.connect(DB_FILENAME) as conn2: + try: + populate_db(conn1) + print "\nauthors and books on conn2 before commit:" + show_authors(conn2) + show_books(conn2) + except sqlite3.Error: + conn1.rollback() + print "\nauthors and books on conn2 after rollback:" + show_authors(conn2) + show_books(conn2) + raise + else: + conn1.commit() + print "\nauthors and books on conn2 after commit:" + show_authors(conn2) + show_books(conn2) + diff --git a/resources/session05/sql/utils.py b/resources/session05/sql/utils.py index 750669b1..8192ee2c 100644 --- a/resources/session05/sql/utils.py +++ b/resources/session05/sql/utils.py @@ -26,6 +26,6 @@ def show_table_metadata(cursor, tablename): 'China Mieville': ["Perdido Street Station", "The Scar", "King Rat"], 'Frank Herbert': ["Dune", "Hellstrom's Hive"], 'J.R.R. Tolkien': ["The Hobbit", "The Silmarillion"], - 'Susan Cooper': ["The Dark is Rising", ["The Greenwitch"]], + 'Susan Cooper': ["The Dark is Rising", "The Greenwitch"], 'Madeline L\'Engle': ["A Wrinkle in Time", "A Swiftly Tilting Planet"] } From cddec04245304179457ef1155cea7654f4579ea9 Mon Sep 17 00:00:00 2001 From: brianschmitz Date: Sun, 2 Feb 2014 13:54:49 -0800 Subject: [PATCH 08/19] save --- .idea/workspace.xml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.idea/workspace.xml b/.idea/workspace.xml index 859abe62..6054efbc 100644 --- a/.idea/workspace.xml +++ b/.idea/workspace.xml @@ -663,11 +663,11 @@ - + - + From 493de9b9c4d14a987cc7d74ceca2d068f232b768 Mon Sep 17 00:00:00 2001 From: brianschmitz Date: Mon, 3 Feb 2014 15:37:51 -0800 Subject: [PATCH 09/19] update --- .idea/workspace.xml | 197 ++++++-------------------------------------- 1 file changed, 23 insertions(+), 174 deletions(-) diff --git a/.idea/workspace.xml b/.idea/workspace.xml index 6054efbc..7cbc73dd 100644 --- a/.idea/workspace.xml +++ b/.idea/workspace.xml @@ -2,16 +2,6 @@ - - - - - - - - - - @@ -51,7 +41,7 @@ - + @@ -104,8 +94,8 @@ - @@ -204,135 +194,7 @@
- + - - + + + - + - + - @@ -693,7 +541,8 @@ - @@ -782,7 +631,7 @@ - + From e75c28e8eb27f21c6f1498627afd1a578acfc390 Mon Sep 17 00:00:00 2001 From: brianschmitz Date: Mon, 10 Feb 2014 18:06:09 -0800 Subject: [PATCH 10/19] Merge branch 'master' of https://github.com/UWPCE-PythonCert/training.python_web Conflicts: resources/session04/wsgi/bookapp.py --- .idea/workspace.xml | 196 +++-- assignments/session05/microblog/.idea/.name | 1 + .../session05/microblog/.idea/encodings.xml | 5 + .../inspectionProfiles/Project_Default.xml | 7 + .../inspectionProfiles/profiles_settings.xml | 7 + .../session05/microblog/.idea/microblog.iml | 24 + .../session05/microblog/.idea/misc.xml | 5 + .../session05/microblog/.idea/modules.xml | 9 + .../microblog/.idea/scopes/scope_settings.xml | 5 + .../session05/microblog/.idea/sqldialects.xml | 7 + assignments/session05/microblog/.idea/vcs.xml | 7 + .../session05/microblog/.idea/workspace.xml | 746 ++++++++++++++++++ assignments/session05/microblog/microblog.cfg | 3 + assignments/session05/microblog/microblog.db | Bin 0 -> 3072 bytes assignments/session05/microblog/microblog.py | 44 +- .../session05/microblog/microblog_tests.py | 39 +- assignments/session05/microblog/schema.sql | 2 +- .../session05/microblog/static/style.css | 2 +- .../session05/microblog/templates/layout.html | 29 +- .../session05/microblog/templates/login.html | 20 + .../microblog/templates/show_entries.html | 4 +- resources/session06/microblog/.idea/.name | 1 + .../session06/microblog/.idea/encodings.xml | 5 + .../session06/microblog/.idea/microblog.iml | 17 + resources/session06/microblog/.idea/misc.xml | 27 + .../session06/microblog/.idea/modules.xml | 9 + .../microblog/.idea/scopes/scope_settings.xml | 5 + resources/session06/microblog/.idea/vcs.xml | 7 + .../session06/microblog/.idea/workspace.xml | 497 ++++++++++++ 29 files changed, 1658 insertions(+), 72 deletions(-) create mode 100644 assignments/session05/microblog/.idea/.name create mode 100644 assignments/session05/microblog/.idea/encodings.xml create mode 100644 assignments/session05/microblog/.idea/inspectionProfiles/Project_Default.xml create mode 100644 assignments/session05/microblog/.idea/inspectionProfiles/profiles_settings.xml create mode 100644 assignments/session05/microblog/.idea/microblog.iml create mode 100644 assignments/session05/microblog/.idea/misc.xml create mode 100644 assignments/session05/microblog/.idea/modules.xml create mode 100644 assignments/session05/microblog/.idea/scopes/scope_settings.xml create mode 100644 assignments/session05/microblog/.idea/sqldialects.xml create mode 100644 assignments/session05/microblog/.idea/vcs.xml create mode 100644 assignments/session05/microblog/.idea/workspace.xml create mode 100644 assignments/session05/microblog/microblog.db create mode 100644 assignments/session05/microblog/templates/login.html create mode 100644 resources/session06/microblog/.idea/.name create mode 100644 resources/session06/microblog/.idea/encodings.xml create mode 100644 resources/session06/microblog/.idea/microblog.iml create mode 100644 resources/session06/microblog/.idea/misc.xml create mode 100644 resources/session06/microblog/.idea/modules.xml create mode 100644 resources/session06/microblog/.idea/scopes/scope_settings.xml create mode 100644 resources/session06/microblog/.idea/vcs.xml create mode 100644 resources/session06/microblog/.idea/workspace.xml diff --git a/.idea/workspace.xml b/.idea/workspace.xml index 7cbc73dd..b3b3d162 100644 --- a/.idea/workspace.xml +++ b/.idea/workspace.xml @@ -1,7 +1,35 @@ - + + + + + + + + + + + + + + + + + + + + + + + + + + + + + @@ -29,35 +57,19 @@ - - + + - - - - - - - - - - + - + + + - - - - - - - - - @@ -94,8 +106,8 @@ - @@ -115,7 +127,7 @@ - + @@ -171,12 +183,52 @@ + @@ -382,6 +443,9 @@ - + - - + - + - + - + + - + + + + @@ -550,6 +616,29 @@ + + + + + + + + + + + + + + + + + + + + + + + @@ -610,30 +699,43 @@ - + - + + + + + + + + + + + + - + - + - + - + - + - + - + + + diff --git a/assignments/session05/microblog/.idea/.name b/assignments/session05/microblog/.idea/.name new file mode 100644 index 00000000..11ffb000 --- /dev/null +++ b/assignments/session05/microblog/.idea/.name @@ -0,0 +1 @@ +microblog \ No newline at end of file diff --git a/assignments/session05/microblog/.idea/encodings.xml b/assignments/session05/microblog/.idea/encodings.xml new file mode 100644 index 00000000..e206d70d --- /dev/null +++ b/assignments/session05/microblog/.idea/encodings.xml @@ -0,0 +1,5 @@ + + + + + diff --git a/assignments/session05/microblog/.idea/inspectionProfiles/Project_Default.xml b/assignments/session05/microblog/.idea/inspectionProfiles/Project_Default.xml new file mode 100644 index 00000000..4bb2e408 --- /dev/null +++ b/assignments/session05/microblog/.idea/inspectionProfiles/Project_Default.xml @@ -0,0 +1,7 @@ + + + + \ No newline at end of file diff --git a/assignments/session05/microblog/.idea/inspectionProfiles/profiles_settings.xml b/assignments/session05/microblog/.idea/inspectionProfiles/profiles_settings.xml new file mode 100644 index 00000000..3b312839 --- /dev/null +++ b/assignments/session05/microblog/.idea/inspectionProfiles/profiles_settings.xml @@ -0,0 +1,7 @@ + + + + \ No newline at end of file diff --git a/assignments/session05/microblog/.idea/microblog.iml b/assignments/session05/microblog/.idea/microblog.iml new file mode 100644 index 00000000..82d7c357 --- /dev/null +++ b/assignments/session05/microblog/.idea/microblog.iml @@ -0,0 +1,24 @@ + + + + + + + + + + + + + + + + diff --git a/assignments/session05/microblog/.idea/misc.xml b/assignments/session05/microblog/.idea/misc.xml new file mode 100644 index 00000000..39c829f6 --- /dev/null +++ b/assignments/session05/microblog/.idea/misc.xml @@ -0,0 +1,5 @@ + + + + + diff --git a/assignments/session05/microblog/.idea/modules.xml b/assignments/session05/microblog/.idea/modules.xml new file mode 100644 index 00000000..ad8d82bd --- /dev/null +++ b/assignments/session05/microblog/.idea/modules.xml @@ -0,0 +1,9 @@ + + + + + + + + + diff --git a/assignments/session05/microblog/.idea/scopes/scope_settings.xml b/assignments/session05/microblog/.idea/scopes/scope_settings.xml new file mode 100644 index 00000000..922003b8 --- /dev/null +++ b/assignments/session05/microblog/.idea/scopes/scope_settings.xml @@ -0,0 +1,5 @@ + + + + \ No newline at end of file diff --git a/assignments/session05/microblog/.idea/sqldialects.xml b/assignments/session05/microblog/.idea/sqldialects.xml new file mode 100644 index 00000000..a4ded715 --- /dev/null +++ b/assignments/session05/microblog/.idea/sqldialects.xml @@ -0,0 +1,7 @@ + + + + + + + diff --git a/assignments/session05/microblog/.idea/vcs.xml b/assignments/session05/microblog/.idea/vcs.xml new file mode 100644 index 00000000..c80f2198 --- /dev/null +++ b/assignments/session05/microblog/.idea/vcs.xml @@ -0,0 +1,7 @@ + + + + + + + diff --git a/assignments/session05/microblog/.idea/workspace.xml b/assignments/session05/microblog/.idea/workspace.xml new file mode 100644 index 00000000..b3182726 --- /dev/null +++ b/assignments/session05/microblog/.idea/workspace.xml @@ -0,0 +1,746 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 1391563782287 + 1391563782287 + + + 1392083636502 + 1392083636502 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/assignments/session05/microblog/microblog.cfg b/assignments/session05/microblog/microblog.cfg index fda11a39..22dbf988 100644 --- a/assignments/session05/microblog/microblog.cfg +++ b/assignments/session05/microblog/microblog.cfg @@ -1,2 +1,5 @@ # application configuration for a Flask microblog DATABASE = 'microblog.db' +SECRET_KEY = "sooperseekritvaluenooneshouldknow" +USERNAME = 'admin' +PASSWORD = 'default' diff --git a/assignments/session05/microblog/microblog.db b/assignments/session05/microblog/microblog.db new file mode 100644 index 0000000000000000000000000000000000000000..a5ee71983e5b126c28f29cd800c4a5206a607096 GIT binary patch literal 3072 zcmeHJu};G<5Vhk7q#_2UN@O_+6}4&+0}~qsg{cG3EKDe*N3n<(cKSRK**Zj#Vd-Q+}R6i4k%w3WjzLcaqRd0Y`qiL5)K&@`1cB&MltDKPO+%u3{v}! z)Y&W7V4JQ4f~XXNarI7Pa&msll{Vm>lx>=0xcaB;i`W(r6bK6ZeFY9EOQ`=~MBh)` BbnXBE literal 0 HcmV?d00001 diff --git a/assignments/session05/microblog/microblog.py b/assignments/session05/microblog/microblog.py index fae4888a..02d7df00 100644 --- a/assignments/session05/microblog/microblog.py +++ b/assignments/session05/microblog/microblog.py @@ -1,62 +1,63 @@ from flask import Flask +import sqlite3 +from contextlib import closing from flask import g from flask import render_template from flask import abort from flask import request from flask import url_for from flask import redirect -import sqlite3 -from contextlib import closing +from flask import session +from flask import flash app = Flask(__name__) app.config.from_pyfile('microblog.cfg') - def connect_db(): return sqlite3.connect(app.config['DATABASE']) - def init_db(): with closing(connect_db()) as db: with app.open_resource('schema.sql') as f: db.cursor().executescript(f.read()) db.commit() - def get_database_connection(): db = getattr(g, 'db', None) if db is None: g.db = db = connect_db() return db - @app.teardown_request def teardown_request(exception): db = getattr(g, 'db', None) if db is not None: db.close() - def write_entry(title, text): con = get_database_connection() - con.execute('insert into entries (title, text) values (?, ?)', - [title, text]) + con.execute('insert into entries (title, text) values (?, ?)', [title, text]) con.commit() - def get_all_entries(): con = get_database_connection() cur = con.execute('SELECT title, text FROM entries ORDER BY id DESC') return [dict(title=row[0], text=row[1]) for row in cur.fetchall()] +def do_login(usr, pwd): + if usr != app.config['USERNAME']: + raise ValueError + elif pwd != app.config['PASSWORD']: + raise ValueError + else: + session['logged_in'] = True @app.route('/') def show_entries(): entries = get_all_entries() return render_template('show_entries.html', entries=entries) - @app.route('/add', methods=['POST']) def add_entry(): try: @@ -65,6 +66,27 @@ def add_entry(): abort(500) return redirect(url_for('show_entries')) +@app.route('/login', methods=['GET', 'POST']) +def login(): + error = None + if request.method == 'POST': + try: + do_login(request.form['username'], + request.form['password']) + except ValueError: + error = "Invalid Login" + else: + flash('You were logged in') + return redirect(url_for('show_entries')) + return render_template('login.html', error=error) + + +@app.route('/logout') +def logout(): + session.pop('logged_in', None) + flash('You were logged out') + return redirect(url_for('show_entries')) + if __name__ == '__main__': app.run(debug=True) diff --git a/assignments/session05/microblog/microblog_tests.py b/assignments/session05/microblog/microblog_tests.py index 57a64f37..20983e3c 100644 --- a/assignments/session05/microblog/microblog_tests.py +++ b/assignments/session05/microblog/microblog_tests.py @@ -1,8 +1,10 @@ import os import tempfile import unittest -import microblog +from flask import session + +import microblog class MicroblogTestCase(unittest.TestCase): @@ -14,16 +16,27 @@ def setUp(self): self.app = microblog.app microblog.init_db() + def tearDown(self): os.close(self.db_fd) os.unlink(microblog.app.config['DATABASE']) + def test_database_setup(self): con = microblog.connect_db() cur = con.execute('PRAGMA table_info(entries);') rows = cur.fetchall() self.assertEquals(len(rows), 3) + def login(self, username, password): + return self.client.post('/login', data=dict( + username=username, + password=password + ), follow_redirects=True) + + def logout(self): + return self.client.get('/logout', follow_redirects=True) + def test_write_entry(self): expected = ("My Title", "My Text") with self.app.test_request_context('/'): @@ -72,6 +85,28 @@ def test_add_entries(self): self.assertTrue('Hello' in actual) self.assertTrue('This is a post' in actual) + def test_login_passes(self): + with self.app.test_request_context('/'): + microblog.do_login(microblog.app.config['USERNAME'], + microblog.app.config['PASSWORD']) + self.assertTrue(session.get('logged_in', False)) + + def test_login_fails(self): + with self.app.test_request_context('/'): + self.assertRaises(ValueError, + microblog.do_login, + microblog.app.config['USERNAME'], + 'incorrectpassword') + + def test_login_logout(self): + response = self.login('admin', 'default') + assert 'You were logged in' in response.data + response = self.logout() + assert 'You were logged out' in response.data + response = self.login('adminx', 'default') + assert 'Invalid username' in response.data + response = self.login('admin', 'defaultx') + assert 'Invalid password' in response.data if __name__ == '__main__': - unittest.main() + unittest.main() \ No newline at end of file diff --git a/assignments/session05/microblog/schema.sql b/assignments/session05/microblog/schema.sql index 71fe0588..81bce6ec 100644 --- a/assignments/session05/microblog/schema.sql +++ b/assignments/session05/microblog/schema.sql @@ -3,4 +3,4 @@ create table entries ( id integer primary key autoincrement, title string not null, text string not null -); +); \ No newline at end of file diff --git a/assignments/session05/microblog/static/style.css b/assignments/session05/microblog/static/style.css index 80218c4f..3c24310b 100644 --- a/assignments/session05/microblog/static/style.css +++ b/assignments/session05/microblog/static/style.css @@ -17,4 +17,4 @@ h2 { font-size: 1.4em; } margin-bottom: 1em; background: #fafafa; border: 1px solid #1E727F} .flash { width: 30%; background: #00B0CC; padding: 1em; border: 1px solid #1E727F; margin-bottom: 1em;} -.error { background: #F0D6D6; padding: 0.5em; } +.error { background: #F0D6D6; padding: 0.5em; } \ No newline at end of file diff --git a/assignments/session05/microblog/templates/layout.html b/assignments/session05/microblog/templates/layout.html index e13b1287..37fbbacb 100644 --- a/assignments/session05/microblog/templates/layout.html +++ b/assignments/session05/microblog/templates/layout.html @@ -1,13 +1,24 @@ - - Microblog! - - - -

My Microblog

-
- {% block body %}{% endblock %} + + Flaskr + + + +

My Microblog

+
+ {% if not session.logged_in %} + log in + {% else %} + log_out + {% endif %}
- + {% for message in get_flashed_messages() %} +
{{ message }}
+ {% endfor %} +
+ {% block body %}{% endblock %} +
+ + diff --git a/assignments/session05/microblog/templates/login.html b/assignments/session05/microblog/templates/login.html new file mode 100644 index 00000000..86de3647 --- /dev/null +++ b/assignments/session05/microblog/templates/login.html @@ -0,0 +1,20 @@ +{% extends "layout.html" %} +{% block body %} +

Login

+ {% if error -%} +

Error {{ error }} + {%- endif %} +

+
+ + +
+
+ + +
+
+ +
+
+{% endblock %} \ No newline at end of file diff --git a/assignments/session05/microblog/templates/show_entries.html b/assignments/session05/microblog/templates/show_entries.html index 07738258..f44fd92b 100644 --- a/assignments/session05/microblog/templates/show_entries.html +++ b/assignments/session05/microblog/templates/show_entries.html @@ -1,5 +1,6 @@ {% extends "layout.html" %} {% block body %} + {% if session.logged_in %}
@@ -13,6 +14,7 @@
+ {% endif %}

Posts

    {% for entry in entries %} @@ -26,4 +28,4 @@

    {{ entry.title }}

  • No entries here so far
  • {% endfor %}
-{% endblock %} +{% endblock %} \ No newline at end of file diff --git a/resources/session06/microblog/.idea/.name b/resources/session06/microblog/.idea/.name new file mode 100644 index 00000000..11ffb000 --- /dev/null +++ b/resources/session06/microblog/.idea/.name @@ -0,0 +1 @@ +microblog \ No newline at end of file diff --git a/resources/session06/microblog/.idea/encodings.xml b/resources/session06/microblog/.idea/encodings.xml new file mode 100644 index 00000000..e206d70d --- /dev/null +++ b/resources/session06/microblog/.idea/encodings.xml @@ -0,0 +1,5 @@ + + + + + diff --git a/resources/session06/microblog/.idea/microblog.iml b/resources/session06/microblog/.idea/microblog.iml new file mode 100644 index 00000000..496ca957 --- /dev/null +++ b/resources/session06/microblog/.idea/microblog.iml @@ -0,0 +1,17 @@ + + + + + + + + + + + + diff --git a/resources/session06/microblog/.idea/misc.xml b/resources/session06/microblog/.idea/misc.xml new file mode 100644 index 00000000..480c2642 --- /dev/null +++ b/resources/session06/microblog/.idea/misc.xml @@ -0,0 +1,27 @@ + + + + + + + + + + diff --git a/resources/session06/microblog/.idea/modules.xml b/resources/session06/microblog/.idea/modules.xml new file mode 100644 index 00000000..ad8d82bd --- /dev/null +++ b/resources/session06/microblog/.idea/modules.xml @@ -0,0 +1,9 @@ + + + + + + + + + diff --git a/resources/session06/microblog/.idea/scopes/scope_settings.xml b/resources/session06/microblog/.idea/scopes/scope_settings.xml new file mode 100644 index 00000000..922003b8 --- /dev/null +++ b/resources/session06/microblog/.idea/scopes/scope_settings.xml @@ -0,0 +1,5 @@ + + + + \ No newline at end of file diff --git a/resources/session06/microblog/.idea/vcs.xml b/resources/session06/microblog/.idea/vcs.xml new file mode 100644 index 00000000..def6a6a1 --- /dev/null +++ b/resources/session06/microblog/.idea/vcs.xml @@ -0,0 +1,7 @@ + + + + + + + diff --git a/resources/session06/microblog/.idea/workspace.xml b/resources/session06/microblog/.idea/workspace.xml new file mode 100644 index 00000000..ec706091 --- /dev/null +++ b/resources/session06/microblog/.idea/workspace.xml @@ -0,0 +1,497 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 1391967870977 + 1391967870977 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + From 7f540525dea9114d08b9a71c6162098b2663a651 Mon Sep 17 00:00:00 2001 From: brianschmitz Date: Tue, 11 Feb 2014 15:31:37 -0800 Subject: [PATCH 11/19] commit --- .idea/workspace.xml | 46 +++++++++++---------------------------------- 1 file changed, 11 insertions(+), 35 deletions(-) diff --git a/.idea/workspace.xml b/.idea/workspace.xml index b3b3d162..3b6c3614 100644 --- a/.idea/workspace.xml +++ b/.idea/workspace.xml @@ -1,35 +1,7 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - + @@ -107,7 +79,7 @@ @@ -564,19 +536,24 @@ 1391470598118 1391470598118 - - @@ -211,41 +219,11 @@ From 5a8d7fc06862e3bbbfe6439619b127f8239c3156 Mon Sep 17 00:00:00 2001 From: brianschmitz Date: Thu, 20 Feb 2014 19:09:50 -0800 Subject: [PATCH 14/19] commit --- .idea/workspace.xml | 14 +++++++++----- 1 file changed, 9 insertions(+), 5 deletions(-) diff --git a/.idea/workspace.xml b/.idea/workspace.xml index cda70c25..c17e06ce 100644 --- a/.idea/workspace.xml +++ b/.idea/workspace.xml @@ -84,7 +84,7 @@ - + @@ -541,15 +541,20 @@ 1392584650845 1392584650845 - - + From fcac766c22259fa41905d929566efef6251d9906 Mon Sep 17 00:00:00 2001 From: brianschmitz Date: Sat, 22 Feb 2014 10:10:33 -0800 Subject: [PATCH 15/19] Merge branch 'master' of https://github.com/UWPCE-PythonCert/training.python_web Conflicts: resources/session04/wsgi/bookapp.py --- .idea/workspace.xml | 596 ++++++++++++++---- assignments/session07/mysite/myblog/admin.py | 9 +- assignments/session07/mysite/myblog/models.py | 46 +- assignments/session07/mysite/mysite.db | Bin 155648 -> 155648 bytes 4 files changed, 517 insertions(+), 134 deletions(-) diff --git a/.idea/workspace.xml b/.idea/workspace.xml index c17e06ce..cd96b0f1 100644 --- a/.idea/workspace.xml +++ b/.idea/workspace.xml @@ -2,6 +2,9 @@ + + + @@ -14,7 +17,7 @@ - + @@ -29,62 +32,97 @@ - - + + - + - - + + - + - + - - + + - + - - + + - + - - + - - + + - + + + + + + + + + + - + - - + + + + + + + + + + + + + + + + + + + + - + + + + + + + + + + @@ -123,14 +161,16 @@ - @@ -204,10 +244,244 @@ - + - + - - + + @@ -597,18 +921,11 @@ - - - - - - - - + @@ -624,8 +941,8 @@ - - + + @@ -633,61 +950,10 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - @@ -706,7 +972,7 @@ - + @@ -722,8 +988,8 @@ - - + + @@ -731,9 +997,7 @@ - - - + @@ -748,7 +1012,7 @@ - + @@ -764,8 +1028,8 @@ - - + + @@ -773,9 +1037,7 @@ - - - + @@ -790,8 +1052,8 @@ - - + + @@ -804,9 +1066,7 @@ - - - + @@ -887,15 +1147,30 @@ - + - + - + + + + + + + + + + + + + + + + @@ -903,32 +1178,107 @@ - + - + - - + - + + + + + + + + + + + + + + + + + + + + + + + + + + + + + - + - + - + - + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/assignments/session07/mysite/myblog/admin.py b/assignments/session07/mysite/myblog/admin.py index 67aec2d6..e2b5e8de 100644 --- a/assignments/session07/mysite/myblog/admin.py +++ b/assignments/session07/mysite/myblog/admin.py @@ -1,6 +1,11 @@ from django.contrib import admin from myblog.models import Post from myblog.models import Category +from myblog.models import PostAdmin +from myblog.models import CategoryAdmin +from myblog.models import CategoryInline + +admin.site.register(Post, PostAdmin, ) +admin.site.register(Category, CategoryAdmin) +# admin.site.register(CategoryInline, ) -admin.site.register(Post) -admin.site.register(Category) diff --git a/assignments/session07/mysite/myblog/models.py b/assignments/session07/mysite/myblog/models.py index 29b851c7..2180b049 100644 --- a/assignments/session07/mysite/myblog/models.py +++ b/assignments/session07/mysite/myblog/models.py @@ -1,16 +1,19 @@ from django.db import models from django.contrib.auth.models import User +from django.contrib import admin + class Post(models.Model): - title = models.CharField(max_length=128) - text = models.TextField(blank=True) - author = models.ForeignKey(User) - created_date = models.DateTimeField(auto_now_add=True) - modified_date = models.DateTimeField(auto_now=True) - published_date = models.DateTimeField(blank=True, null=True) + title = models.CharField(max_length=128) + text = models.TextField(blank=True) + author = models.ForeignKey(User) + created_date = models.DateTimeField(auto_now_add=True) + modified_date = models.DateTimeField(auto_now=True) + published_date = models.DateTimeField(blank=True, null=True) + + def __unicode__(self): + return self.title - def __unicode__(self): - return self.title class Category(models.Model): name = models.CharField(max_length=128) @@ -19,4 +22,29 @@ class Category(models.Model): related_name='categories') def __unicode__(self): - return self.name \ No newline at end of file + return self.name + + +class CategoryAdmin(admin.ModelAdmin): + + list_display = ('name', 'description') + exclude = ('posts', ) + + def __unicode__(self): + return self.name + + +class CategoryInline(admin.TabularInline): + model = Category + + +class PostAdmin(admin.ModelAdmin): + + list_display = ('title', 'author', 'created_date', ) + inlines = [CategoryInline, ] + + def __unicode__(self): + return self.name + + + diff --git a/assignments/session07/mysite/mysite.db b/assignments/session07/mysite/mysite.db index 63c9e9a57dbf40bdfacafb2a0d046cc8f04f22df..33c439403971b59eb73dcd942533c6470bcf0cd9 100644 GIT binary patch delta 330 zcmZoTz}awsbAmLZ*F+g-Mz4(tQRfAX6b#L+Of9U84D>9FEG%0~Z&NHnpsd))(ljNj($F-^u(ZG|%_6Cy zu+lJNx*b2`MnMZC8;p&NjV-5(@iV^RnZ&@vpUc3X%fFp}`({Chcz!<>W?x3Q9XO0+ z;lIP6YHV7Nn^aL{l#-ulW?`Ogk)C0hW|Eg^R-9r{RAgkF#|$!Qx*R{F!uH$pjG7y` znD`Gd@IT}~#J?D5(+qxVJ0k-_6I}yiT?1st8JQZGS+K}4J2GOG2D_bQ`@{Q;@(lnL C1YN=a delta 155 zcmZoTz}awsbAmLZ%S0JxMwg8VQRf8>6bvn`jLfZ!jP)!GO^qzfHlIFkX~4nAFUG(x z#?Q7{P~a~g@2^Hy$13BhilX$=l8otM{ETn7?l3U&Z)f1&&cA)Lpu=i@78Pb+#_4kW yj0)Rt%QI?j02=U+f&U@@VW8|Tera1H149#C17lqSGi3V=EX@tJKfKQ<-v9v6p)8yL From 68e9ddc7a414947b6ec2165b317347a21a165874 Mon Sep 17 00:00:00 2001 From: brianschmitz Date: Sat, 22 Feb 2014 10:14:26 -0800 Subject: [PATCH 16/19] Update Session07 --- .idea/workspace.xml | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/.idea/workspace.xml b/.idea/workspace.xml index cd96b0f1..a1983ac9 100644 --- a/.idea/workspace.xml +++ b/.idea/workspace.xml @@ -2,9 +2,6 @@ - - - @@ -869,7 +866,11 @@ 1392952139382 1392952139382 - From 003ce5abb8bbd30cf96f8f8eda7762e8ab570436 Mon Sep 17 00:00:00 2001 From: brianschmitz Date: Sat, 22 Feb 2014 19:13:08 -0800 Subject: [PATCH 17/19] Merge branch 'master' of https://github.com/UWPCE-PythonCert/training.python_web Conflicts: resources/session04/wsgi/bookapp.py --- .idea/workspace.xml | 329 ++++++------------ assignments/session07/mysite/myblog/admin.py | 5 +- assignments/session07/mysite/myblog/models.py | 3 +- assignments/session07/mysite/mysite.db | Bin 155648 -> 155648 bytes 4 files changed, 112 insertions(+), 225 deletions(-) diff --git a/.idea/workspace.xml b/.idea/workspace.xml index a1983ac9..9c63598e 100644 --- a/.idea/workspace.xml +++ b/.idea/workspace.xml @@ -2,6 +2,9 @@ + + + @@ -29,86 +32,86 @@ - - + + - - + + + + - - + + - + - + - - + + - + - - + + - - - - + + - - + + - + - - + + - - - - + + - - + + - - + + + + - - + + - + - - + + @@ -116,11 +119,13 @@ - - + + - - + + + + @@ -424,118 +429,6 @@ + @@ -877,22 +767,22 @@ - - - + - - + + - + + + + + - - @@ -922,46 +812,6 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - @@ -1202,13 +1052,6 @@ - - - - - - - @@ -1225,29 +1068,43 @@ - + - + - + - + + + + + + + + - + + + + + + + + @@ -1255,31 +1112,61 @@ - + - + - + - + + + + + + + + - + + + + + + + + + + + + + + + - + + + + + + + + + + diff --git a/assignments/session07/mysite/myblog/admin.py b/assignments/session07/mysite/myblog/admin.py index e2b5e8de..b92aeb3d 100644 --- a/assignments/session07/mysite/myblog/admin.py +++ b/assignments/session07/mysite/myblog/admin.py @@ -3,9 +3,8 @@ from myblog.models import Category from myblog.models import PostAdmin from myblog.models import CategoryAdmin -from myblog.models import CategoryInline admin.site.register(Post, PostAdmin, ) -admin.site.register(Category, CategoryAdmin) -# admin.site.register(CategoryInline, ) +admin.site.register(Category, CategoryAdmin, ) + diff --git a/assignments/session07/mysite/myblog/models.py b/assignments/session07/mysite/myblog/models.py index 2180b049..d3f97bd1 100644 --- a/assignments/session07/mysite/myblog/models.py +++ b/assignments/session07/mysite/myblog/models.py @@ -3,6 +3,7 @@ from django.contrib import admin + class Post(models.Model): title = models.CharField(max_length=128) text = models.TextField(blank=True) @@ -40,7 +41,7 @@ class CategoryInline(admin.TabularInline): class PostAdmin(admin.ModelAdmin): - list_display = ('title', 'author', 'created_date', ) + list_display = ('title', 'author', 'created_date', 'modified_date', ) inlines = [CategoryInline, ] def __unicode__(self): diff --git a/assignments/session07/mysite/mysite.db b/assignments/session07/mysite/mysite.db index 33c439403971b59eb73dcd942533c6470bcf0cd9..ae54a03752ff1328f14efd1a6a23516cdc58c2a9 100644 GIT binary patch delta 552 zcmZoTz}awsbAmKu&_o$$#-NP}QRfAX6%3563=OP|4D^i53{4G;H=jOlX~4(AbCiK! zj8BJmJFv~A5XiR5k^=*np2qY$D8JQKN85NlnB^Ozg zXH}KumXw-iPPgM{+*ogkY>Tm(sYx{}t1r+vBa_PHva005M8m4eVpFqB%Z#kDQlqT= zL`&0xlp+fw|B#HVs1Q%1s4S;UKOT3`->OJc-;l7J$gHSrKbJsb zzpAKAU-!UD-;e_Hv_M;1BLhPdT?1oX14{*dh#w6N^~{V7jLi(T>+msNV-)aUVBuG0 z;Ge{=%%97@oqs#fn}YmaD$Kr&aBt%96+8bO2G!(}Vxt`M0t*w1| ySH8(M`WS3)hWW*|M1`2KL((vG51?isthmTQe`-A(83Jm~enwwex delta 213 zcmZoTz}awsbAmLZ*F+g-Mz4(tQRfAX6b#L+Of9U84D>9FEGy$cLDkr_AUCO^$|xm2(agd;-6B21GR-6}(X2SdqNvEoIFDI{*_Uy;96zJN_S^D| znj5&7_zyAgKjc5ezj(8t!wh}}J0k-_6I}yiT>}eb_n8`)S+K}4J2FoH!^bGK{lR@k Gg$4kvx;kP2 From cfeafa56ef34a7af14064af8db2f573629e2c97d Mon Sep 17 00:00:00 2001 From: brianschmitz Date: Sat, 22 Feb 2014 19:17:08 -0800 Subject: [PATCH 18/19] update Added additional tasks --- .idea/workspace.xml | 13 +++++++------ 1 file changed, 7 insertions(+), 6 deletions(-) diff --git a/.idea/workspace.xml b/.idea/workspace.xml index 9c63598e..cdeaea52 100644 --- a/.idea/workspace.xml +++ b/.idea/workspace.xml @@ -2,9 +2,6 @@ - - - @@ -760,7 +757,11 @@ 1393092633097 1393092633097 - @@ -768,7 +769,7 @@ - + @@ -778,7 +779,7 @@ - + From b6427b8a4a7d9db29810105407798f26dae4498c Mon Sep 17 00:00:00 2001 From: brianschmitz Date: Sun, 16 Mar 2014 20:10:51 -0700 Subject: [PATCH 19/19] commit --- .idea/workspace.xml | 419 +++++++++++++----- resources/session10/wikitutorial/Data.fs | Bin 0 -> 691 bytes .../session10/wikitutorial/Data.fs.index | Bin 0 -> 46 bytes resources/session10/wikitutorial/Data.fs.lock | 1 + resources/session10/wikitutorial/Data.fs.tmp | 0 .../wikitutorial/templates/edit.pt | 4 +- 6 files changed, 309 insertions(+), 115 deletions(-) create mode 100644 resources/session10/wikitutorial/Data.fs create mode 100644 resources/session10/wikitutorial/Data.fs.index create mode 100644 resources/session10/wikitutorial/Data.fs.lock create mode 100644 resources/session10/wikitutorial/Data.fs.tmp diff --git a/.idea/workspace.xml b/.idea/workspace.xml index de71df99..9712306f 100644 --- a/.idea/workspace.xml +++ b/.idea/workspace.xml @@ -2,30 +2,7 @@ - - - - - - - - - - - - - - - - - - - - - - - - + @@ -47,27 +24,72 @@ + + + + + + + + + + + + + + + + + + + - - + + - + - + + + + + + + - + + + + + + + + + + + + + + + + + + + + + - + @@ -76,41 +98,63 @@ - + + + + + + + + + + - + - + - + - + - - + + + + - - + + - + + + + + + + + + + + + @@ -152,13 +196,14 @@ - @@ -278,6 +323,122 @@ - + - - + - + @@ -642,6 +802,7 @@ + @@ -672,61 +833,6 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - @@ -899,50 +1005,137 @@ - + + + + + + + + + + + - + - + - + - + - + - + - + - + - + - + + + + + + + + + + + + + + + + + + + + + + + - + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/resources/session10/wikitutorial/Data.fs b/resources/session10/wikitutorial/Data.fs new file mode 100644 index 0000000000000000000000000000000000000000..5a0f422c61219fa8c5ad3060e648331704f94784 GIT binary patch literal 691 zcma))y-ve05XYUbHpv4Zv3ab76a->q?nc!LB1X%kZfmu%} zoDrhDv_<6G2Mp4Ks|DBCY*;WntB`R~G56A#kb;)xKbYcvd!pgqw)I3Kn5^xGaH9`E C7qwUb literal 0 HcmV?d00001 diff --git a/resources/session10/wikitutorial/Data.fs.index b/resources/session10/wikitutorial/Data.fs.index new file mode 100644 index 0000000000000000000000000000000000000000..3f4e73a58c3ff88efa3671c9b4cca422c5994633 GIT binary patch literal 46 ncmeYPage Name Goes Here - - + +