This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env python | |
# coding: utf-8 | |
# | |
# Copyright (c) 2017, Roman Miroshnychenko <[email protected]> | |
# Permission is hereby granted, free of charge, to any person obtaining a copy | |
# of this software and associated documentation files (the "Software"), to deal | |
# in the Software without restriction, including without limitation the rights | |
# to use, copy, modify, merge, publish, distribute, sublicense, and/or sell | |
# copies of the Software, and to permit persons to whom the Software is |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
from wsgiref.simple_server import WSGIServer, WSGIRequestHandler, make_server | |
from socketserver import ThreadingMixIn | |
import xbmc | |
from bottle import route, default_app | |
class SilentWSGIRequestHandler(WSGIRequestHandler): | |
"""Custom WSGI Request Handler with logging disabled""" | |
protocol_version = 'HTTP/1.1' |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
-- Create the table | |
CREATE TABLE IF NOT EXISTS `StateBoundaries` ( | |
`State` varchar(10) DEFAULT NULL, | |
`Name` varchar(255) DEFAULT NULL, | |
`MinLat` varchar(50) DEFAULT NULL, | |
`MaxLat` varchar(50) DEFAULT NULL, | |
`MinLon` varchar(50) DEFAULT NULL, | |
`MaxLon` varchar(50) DEFAULT NULL | |
) ENGINE=InnoDB DEFAULT CHARSET=utf8; |