code
stringlengths
1
1.49M
vector
listlengths
0
7.38k
snippet
listlengths
0
7.38k
#!/usr/bin/env python # -*- coding: utf-8 -*- """ Usage: python setup.py py2exe """ from distutils.core import setup import py2exe from gluon.import_all import base_modules, contributed_modules import os import fnmatch class reglob: def __init__(self, directory, pattern="*"): self.stack = [directory]...
[ [ 8, 0, 0.0965, 0.0702, 0, 0.66, 0, 0, 1, 0, 0, 0, 0, 0, 0 ], [ 1, 0, 0.1579, 0.0175, 0, 0.66, 0.1429, 152, 0, 1, 0, 0, 152, 0, 0 ], [ 1, 0, 0.1754, 0.0175, 0, 0.66...
[ "\"\"\"\nUsage:\n python setup.py py2exe\n\"\"\"", "from distutils.core import setup", "import py2exe", "from gluon.import_all import base_modules, contributed_modules", "import os", "import fnmatch", "class reglob:\n def __init__(self, directory, pattern=\"*\"):\n self.stack = [directory]\...
#!/usr/bin/env python # -*- coding: utf-8 -*- # portalocker.py - Cross-platform (posix/nt) API for flock-style file locking. # Requires python 1.5.2 or better. """ Cross-platform (posix/nt) API for flock-style file locking. Synopsis: import portalocker file = open(\"somefile\", \"r+\") port...
[ [ 8, 0, 0.1926, 0.2951, 0, 0.66, 0, 0, 1, 0, 0, 0, 0, 0, 0 ], [ 1, 0, 0.3525, 0.0082, 0, 0.66, 0.1111, 688, 0, 1, 0, 0, 688, 0, 0 ], [ 1, 0, 0.3607, 0.0082, 0, 0.66...
[ "\"\"\"\nCross-platform (posix/nt) API for flock-style file locking.\n\nSynopsis:\n\n import portalocker\n file = open(\\\"somefile\\\", \\\"r+\\\")\n portalocker.lock(file, portalocker.LOCK_EX)", "import os", "import logging", "import platform", "logger = logging.getLogger(\"web2py\")", "os_locking...
""" This file is part of the web2py Web Framework Copyrighted by Massimo Di Pierro <mdipierro@cs.depaul.edu> License: LGPLv3 (http://www.gnu.org/licenses/lgpl.html) """ from storage import Storage global_settings = Storage() settings = global_settings # legacy compatibility
[ [ 8, 0, 0.3, 0.5, 0, 0.66, 0, 0, 1, 0, 0, 0, 0, 0, 0 ], [ 1, 0, 0.7, 0.1, 0, 0.66, 0.3333, 864, 0, 1, 0, 0, 864, 0, 0 ], [ 14, 0, 0.9, 0.1, 0, 0.66, 0.6667, ...
[ "\"\"\"\nThis file is part of the web2py Web Framework\nCopyrighted by Massimo Di Pierro <mdipierro@cs.depaul.edu>\nLicense: LGPLv3 (http://www.gnu.org/licenses/lgpl.html)\n\"\"\"", "from storage import Storage", "global_settings = Storage()", "settings = global_settings # legacy compatibility" ]
#!/usr/bin/env python # -*- coding: utf-8 -*- """ This file is part of the web2py Web Framework Copyrighted by Massimo Di Pierro <mdipierro@cs.depaul.edu> License: LGPLv3 (http://www.gnu.org/licenses/lgpl.html) """ __all__ = ['HTTP', 'redirect'] defined_status = { 200: 'OK', 201: 'CREATED', 202: 'ACCEPTE...
[ [ 8, 0, 0.0577, 0.0481, 0, 0.66, 0, 0, 1, 0, 0, 0, 0, 0, 0 ], [ 14, 0, 0.0962, 0.0096, 0, 0.66, 0.2, 272, 0, 0, 0, 0, 0, 5, 0 ], [ 14, 0, 0.2933, 0.3654, 0, 0.66, ...
[ "\"\"\"\nThis file is part of the web2py Web Framework\nCopyrighted by Massimo Di Pierro <mdipierro@cs.depaul.edu>\nLicense: LGPLv3 (http://www.gnu.org/licenses/lgpl.html)\n\"\"\"", "__all__ = ['HTTP', 'redirect']", "defined_status = {\n 200: 'OK',\n 201: 'CREATED',\n 202: 'ACCEPTED',\n 203: 'NON-AU...
#!/usr/bin/env python # -*- coding: utf-8 -*- """ This file is part of the web2py Web Framework Copyrighted by Massimo Di Pierro <mdipierro@cs.depaul.edu> License: LGPLv3 (http://www.gnu.org/licenses/lgpl.html) """ import hashlib import uuid import random import os import thread import time def md5_hash(text): "...
[ [ 8, 0, 0.0822, 0.0685, 0, 0.66, 0, 0, 1, 0, 0, 0, 0, 0, 0 ], [ 1, 0, 0.137, 0.0137, 0, 0.66, 0.0714, 154, 0, 1, 0, 0, 154, 0, 0 ], [ 1, 0, 0.1507, 0.0137, 0, 0.66,...
[ "\"\"\"\nThis file is part of the web2py Web Framework\nCopyrighted by Massimo Di Pierro <mdipierro@cs.depaul.edu>\nLicense: LGPLv3 (http://www.gnu.org/licenses/lgpl.html)\n\"\"\"", "import hashlib", "import uuid", "import random", "import os", "import thread", "import time", "def md5_hash(text):\n ...
#!/usr/bin/env python # -*- coding: utf-8 -*- """ This file is part of the web2py Web Framework Copyrighted by Massimo Di Pierro <mdipierro@cs.depaul.edu> License: LGPLv3 (http://www.gnu.org/licenses/lgpl.html) """ import re # pattern to find defined tables regex_tables = re.compile(\ """^[\w]+\.define_table\(\...
[ [ 8, 0, 0.2143, 0.1786, 0, 0.66, 0, 0, 1, 0, 0, 0, 0, 0, 0 ], [ 1, 0, 0.3571, 0.0357, 0, 0.66, 0.2, 540, 0, 1, 0, 0, 540, 0, 0 ], [ 14, 0, 0.5357, 0.1071, 0, 0.66, ...
[ "\"\"\"\nThis file is part of the web2py Web Framework\nCopyrighted by Massimo Di Pierro <mdipierro@cs.depaul.edu>\nLicense: LGPLv3 (http://www.gnu.org/licenses/lgpl.html)\n\"\"\"", "import re", "regex_tables = re.compile(\\\n \"\"\"^[\\w]+\\.define_table\\(\\s*[\\'\\\"](?P<name>[\\w_]+)[\\'\\\"]\"\"\",\n ...
# this file exists for backward compatibility __all__ = ['DAL','Field','drivers'] from dal import DAL, Field, Table, Query, Set, Expression, Row, Rows, drivers, BaseAdapter, SQLField, SQLTable, SQLXorable, SQLQuery, SQLSet, SQLRows, SQLStorage, SQLDB, GQLDB, SQLALL, SQLCustomType
[ [ 14, 0, 0.6, 0.2, 0, 0.66, 0, 272, 0, 0, 0, 0, 0, 5, 0 ], [ 1, 0, 1, 0.2, 0, 0.66, 1, 4, 0, 21, 0, 0, 4, 0, 0 ] ]
[ "__all__ = ['DAL','Field','drivers']", "from dal import DAL, Field, Table, Query, Set, Expression, Row, Rows, drivers, BaseAdapter, SQLField, SQLTable, SQLXorable, SQLQuery, SQLSet, SQLRows, SQLStorage, SQLDB, GQLDB, SQLALL, SQLCustomType" ]
#!/usr/bin/env python # -*- coding: utf-8 -*- """ :: # from http://aspn.activestate.com/ASPN/Cookbook/Python/Recipe/496942 # Title: Cross-site scripting (XSS) defense # Submitter: Josh Goldfoot (other recipes) # Last Updated: 2006/08/05 # Version no: 1.0 """ from htmllib import HTMLParser from ...
[ [ 8, 0, 0.0395, 0.0465, 0, 0.66, 0, 0, 1, 0, 0, 0, 0, 0, 0 ], [ 1, 0, 0.0744, 0.0047, 0, 0.66, 0.1, 193, 0, 1, 0, 0, 193, 0, 0 ], [ 1, 0, 0.0791, 0.0047, 0, 0.66, ...
[ "\"\"\"\n::\n\n # from http://aspn.activestate.com/ASPN/Cookbook/Python/Recipe/496942\n # Title: Cross-site scripting (XSS) defense\n # Submitter: Josh Goldfoot (other recipes)\n # Last Updated: 2006/08/05\n # Version no: 1.0", "from htmllib import HTMLParser", "from cgi import escape", "from u...
import codecs, encodings """Caller will hand this library a buffer and ask it to either convert it or auto-detect the type. Based on http://code.activestate.com/recipes/52257/ Licensed under the PSF License """ # None represents a potentially variable byte. "##" in the XML spec... autodetect_dict={ # bytepattern ...
[ [ 1, 0, 0.0135, 0.0135, 0, 0.66, 0, 220, 0, 2, 0, 0, 220, 0, 0 ], [ 8, 0, 0.0811, 0.0946, 0, 0.66, 0.25, 0, 1, 0, 0, 0, 0, 0, 0 ], [ 14, 0, 0.223, 0.1351, 0, 0.66, ...
[ "import codecs, encodings", "\"\"\"Caller will hand this library a buffer and ask it to either convert\nit or auto-detect the type.\n\nBased on http://code.activestate.com/recipes/52257/\n\nLicensed under the PSF License\n\"\"\"", "autodetect_dict={ # bytepattern : (\"name\",\n (0x00, 0x00, 0...
# encoding utf-8 __author__ = "Thadeus Burgess <thadeusb@thadeusb.com>" # we classify as "non-reserved" those key words that are explicitly known # to the parser but are allowed as column or table names. Some key words # that are otherwise non-reserved cannot be used as function or data type n # ames and ...
[ [ 14, 0, 0.0014, 0.0005, 0, 0.66, 0, 777, 1, 0, 0, 0, 0, 3, 0 ], [ 14, 0, 0.0211, 0.0189, 0, 0.66, 0.0909, 63, 0, 0, 0, 0, 0, 8, 0 ], [ 14, 0, 0.1565, 0.2462, 0, 0....
[ "__author__ = \"Thadeus Burgess <thadeusb@thadeusb.com>\"", "COMMON = (\n 'SELECT',\n 'INSERT',\n 'DELETE',\n 'UPDATE',\n 'DROP',\n 'CREATE',\n 'ALTER',", "ALL = (\n 'ABORT',\n 'ABS',\n 'ABSOLUTE',\n 'ACCESS',\n 'ADA',\n 'ADD',\n 'ADMIN',", "POSTGRESQL = (\n 'FALSE...
# -*- coding: utf-8 -*- # This file is part of the Rocket Web Server # Copyright (c) 2010 Timothy Farrell # Import System Modules import sys import errno import socket import logging import platform # Define Constants VERSION = '1.2.2' SERVER_NAME = socket.gethostname() SERVER_SOFTWARE = 'Rocket %s' % VERSION HTTP_S...
[ [ 1, 0, 0.0043, 0.0006, 0, 0.66, 0, 509, 0, 1, 0, 0, 509, 0, 0 ], [ 1, 0, 0.0049, 0.0006, 0, 0.66, 0.0114, 546, 0, 1, 0, 0, 546, 0, 0 ], [ 1, 0, 0.0056, 0.0006, 0, ...
[ "import sys", "import errno", "import socket", "import logging", "import platform", "VERSION = '1.2.2'", "SERVER_NAME = socket.gethostname()", "SERVER_SOFTWARE = 'Rocket %s' % VERSION", "HTTP_SERVER_SOFTWARE = '%s Python/%s' % (SERVER_SOFTWARE, sys.version.split(' ')[0])", "BUF_SIZE = 16384", "S...
#!/usr/bin/env python # -*- coding: utf-8 -*- """ This file is part of the web2py Web Framework Copyrighted by Massimo Di Pierro <mdipierro@cs.depaul.edu> License: LGPLv3 (http://www.gnu.org/licenses/lgpl.html) Functions required to execute app components ============================================ FOR INTERNAL USE...
[ [ 8, 0, 0.1667, 0.1961, 0, 0.66, 0, 0, 1, 0, 0, 0, 0, 0, 0 ], [ 1, 0, 0.2941, 0.0196, 0, 0.66, 0.1667, 688, 0, 1, 0, 0, 688, 0, 0 ], [ 1, 0, 0.3137, 0.0196, 0, 0.66...
[ "\"\"\"\nThis file is part of the web2py Web Framework\nCopyrighted by Massimo Di Pierro <mdipierro@cs.depaul.edu>\nLicense: LGPLv3 (http://www.gnu.org/licenses/lgpl.html)\n\nFunctions required to execute app components\n============================================", "import os", "import stat", "import thread...
#!/usr/bin/env python # -*- coding: utf-8 -*- """ This file is part of the web2py Web Framework Copyrighted by Massimo Di Pierro <mdipierro@cs.depaul.edu> License: LGPLv3 (http://www.gnu.org/licenses/lgpl.html) CONTENT_TYPE dictionary created against freedesktop.org' shared mime info database version 0.70. """ __all...
[ [ 8, 0, 0.0105, 0.0112, 0, 0.66, 0, 0, 1, 0, 0, 0, 0, 0, 0 ], [ 14, 0, 0.0182, 0.0014, 0, 0.66, 0.3333, 272, 0, 0, 0, 0, 0, 5, 0 ], [ 14, 0, 0.4993, 0.9581, 0, 0.66...
[ "\"\"\"\nThis file is part of the web2py Web Framework\nCopyrighted by Massimo Di Pierro <mdipierro@cs.depaul.edu>\nLicense: LGPLv3 (http://www.gnu.org/licenses/lgpl.html)\n\nCONTENT_TYPE dictionary created against freedesktop.org' shared mime info\ndatabase version 0.70.\n\"\"\"", "__all__ = ['contenttype']", ...
import threading class Singleton(dict): """ This class makes a thread local Singleton (i.e. every threads sees a differnt singleton) It also makes a different singleton for each derived class. The objects behave like dictionaries and attributes/values are mapped into keys/values. But, while...
[ [ 1, 0, 0.0114, 0.0114, 0, 0.66, 0, 83, 0, 1, 0, 0, 83, 0, 0 ], [ 3, 0, 0.5114, 0.9659, 0, 0.66, 1, 222, 0, 29, 0, 0, 827, 0, 74 ], [ 8, 1, 0.1761, 0.2727, 1, 0.85,...
[ "import threading", "class Singleton(dict):\n \"\"\"\n This class makes a thread local Singleton\n (i.e. every threads sees a differnt singleton)\n It also makes a different singleton for each derived class.\n The objects behave like dictionaries and attributes/values\n are mapped into keys/valu...
#!/usr/bin/env python # -*- coding: utf-8 -*- """ This file is part of the web2py Web Framework Copyrighted by Massimo Di Pierro <mdipierro@cs.depaul.edu> License: LGPLv3 (http://www.gnu.org/licenses/lgpl.html) """ from SimpleXMLRPCServer import SimpleXMLRPCDispatcher def handler(request, response, methods): re...
[ [ 8, 0, 0.2857, 0.2381, 0, 0.66, 0, 0, 1, 0, 0, 0, 0, 0, 0 ], [ 1, 0, 0.4762, 0.0476, 0, 0.66, 0.5, 73, 0, 1, 0, 0, 73, 0, 0 ], [ 2, 0, 0.8095, 0.4286, 0, 0.66, ...
[ "\"\"\"\nThis file is part of the web2py Web Framework\nCopyrighted by Massimo Di Pierro <mdipierro@cs.depaul.edu>\nLicense: LGPLv3 (http://www.gnu.org/licenses/lgpl.html)\n\"\"\"", "from SimpleXMLRPCServer import SimpleXMLRPCDispatcher", "def handler(request, response, methods):\n response.session_id = None...
#!/usr/bin/env python # -*- coding: utf-8 -*- """ This file is part of the web2py Web Framework Developed by Massimo Di Pierro <mdipierro@cs.depaul.edu> and Limodou <limodou@gmail.com>. License: LGPLv3 (http://www.gnu.org/licenses/lgpl.html) This makes uses of the pywin32 package (http://sourceforge.net/projects/pywin...
[ [ 8, 0, 0.0541, 0.0764, 0, 0.66, 0, 0, 1, 0, 0, 0, 0, 0, 0 ], [ 1, 0, 0.1019, 0.0064, 0, 0.66, 0.0667, 654, 0, 1, 0, 0, 654, 0, 0 ], [ 1, 0, 0.1083, 0.0064, 0, 0.66...
[ "\"\"\"\nThis file is part of the web2py Web Framework\nDeveloped by Massimo Di Pierro <mdipierro@cs.depaul.edu> and\nLimodou <limodou@gmail.com>.\nLicense: LGPLv3 (http://www.gnu.org/licenses/lgpl.html)\n\nThis makes uses of the pywin32 package\n(http://sourceforge.net/projects/pywin32/).", "import time", "imp...
#!/usr/bin/env python # coding: utf8 """ RPX Authentication for web2py Developed by Nathan Freeze (Copyright © 2009) Email <nathan@freezable.com> Modified by Massimo Di Pierro This file contains code to allow using RPXNow.com (now Jainrain.com) services with web2py """ import re import urllib from ...
[ [ 8, 0, 0.0708, 0.0796, 0, 0.66, 0, 0, 1, 0, 0, 0, 0, 0, 0 ], [ 1, 0, 0.1239, 0.0088, 0, 0.66, 0.1429, 540, 0, 1, 0, 0, 540, 0, 0 ], [ 1, 0, 0.1327, 0.0088, 0, 0.66...
[ "\"\"\"\n RPX Authentication for web2py\n Developed by Nathan Freeze (Copyright © 2009)\n Email <nathan@freezable.com>\n Modified by Massimo Di Pierro\n\n This file contains code to allow using RPXNow.com (now Jainrain.com)\n services with web2py", "import re", "import urllib", "from gluon.html im...
#!/usr/bin/env python # -*- coding: utf-8 -*- """ This file is part of web2py Web Framework (Copyrighted, 2007-2009). Developed by Massimo Di Pierro <mdipierro@cs.depaul.edu>. License: GPL v2 Thanks to Hans Donner <hans.donner@pobox.com> for GaeGoogleAccount. """ from google.appengine.api import users class GaeGoog...
[ [ 8, 0, 0.1892, 0.1892, 0, 0.66, 0, 0, 1, 0, 0, 0, 0, 0, 0 ], [ 1, 0, 0.3243, 0.027, 0, 0.66, 0.5, 279, 0, 1, 0, 0, 279, 0, 0 ], [ 3, 0, 0.6892, 0.6486, 0, 0.66, ...
[ "\"\"\"\nThis file is part of web2py Web Framework (Copyrighted, 2007-2009).\nDeveloped by Massimo Di Pierro <mdipierro@cs.depaul.edu>.\nLicense: GPL v2\n\nThanks to Hans Donner <hans.donner@pobox.com> for GaeGoogleAccount.\n\"\"\"", "from google.appengine.api import users", "class GaeGoogleAccount(object):\n ...
#!/usr/bin/env python # -*- coding: utf-8 -*- """ This file is part of web2py Web Framework (Copyrighted, 2007-2009). Developed by Massimo Di Pierro <mdipierro@cs.depaul.edu>. License: GPL v2 Thanks to Hans Donner <hans.donner@pobox.com> for GaeGoogleAccount. """ from gluon.http import HTTP try: import linkedin...
[ [ 8, 0, 0.16, 0.14, 0, 0.66, 0, 0, 1, 0, 0, 0, 0, 0, 0 ], [ 1, 0, 0.26, 0.02, 0, 0.66, 0.3333, 453, 0, 1, 0, 0, 453, 0, 0 ], [ 7, 0, 0.31, 0.08, 0, 0.66, 0.6667...
[ "\"\"\"\nThis file is part of web2py Web Framework (Copyrighted, 2007-2009).\nDeveloped by Massimo Di Pierro <mdipierro@cs.depaul.edu>.\nLicense: GPL v2\n\nThanks to Hans Donner <hans.donner@pobox.com> for GaeGoogleAccount.\n\"\"\"", "from gluon.http import HTTP", "try:\n import linkedin\nexcept ImportError:...
#!/usr/bin/env python # coding: utf8 """ ExtendedLoginForm is used to extend normal login form in web2py with one more login method. So user can choose the built-in login or extended login methods. """ from gluon.html import DIV class ExtendedLoginForm(object): """ Put extended_login_form under web2py/gluon/...
[ [ 8, 0, 0.0539, 0.0392, 0, 0.66, 0, 0, 1, 0, 0, 0, 0, 0, 0 ], [ 1, 0, 0.0882, 0.0098, 0, 0.66, 0.5, 373, 0, 1, 0, 0, 373, 0, 0 ], [ 3, 0, 0.5539, 0.902, 0, 0.66, ...
[ "\"\"\"\nExtendedLoginForm is used to extend normal login form in web2py with one more login method.\nSo user can choose the built-in login or extended login methods.\n\"\"\"", "from gluon.html import DIV", "class ExtendedLoginForm(object):\n \"\"\"\n Put extended_login_form under web2py/gluon/contrib/log...
import urllib import urllib2 import base64 def basic_auth(server="http://127.0.0.1"): """ to use basic login with a different server from gluon.contrib.login_methods.basic_auth import basic_auth auth.settings.login_methods.append(basic_auth('http://server')) """ def basic_login_aux(username, ...
[ [ 1, 0, 0.0417, 0.0417, 0, 0.66, 0, 614, 0, 1, 0, 0, 614, 0, 0 ], [ 1, 0, 0.0833, 0.0417, 0, 0.66, 0.3333, 345, 0, 1, 0, 0, 345, 0, 0 ], [ 1, 0, 0.125, 0.0417, 0, 0...
[ "import urllib", "import urllib2", "import base64", "def basic_auth(server=\"http://127.0.0.1\"):\n \"\"\"\n to use basic login with a different server\n from gluon.contrib.login_methods.basic_auth import basic_auth\n auth.settings.login_methods.append(basic_auth('http://server'))\n \"\"\"\n\n ...
from gluon.contrib.pam import authenticate def pam_auth(): """ to use pam_login: from gluon.contrib.login_methods.pam_auth import pam_auth auth.settings.login_methods.append(pam_auth()) """ def pam_auth_aux(username, password): return authenticate(username, password) return pam_au...
[ [ 1, 0, 0.0769, 0.0769, 0, 0.66, 0, 109, 0, 1, 0, 0, 109, 0, 0 ], [ 2, 0, 0.6154, 0.8462, 0, 0.66, 1, 1, 0, 0, 1, 0, 0, 0, 1 ], [ 8, 1, 0.4615, 0.3846, 1, 0.33, ...
[ "from gluon.contrib.pam import authenticate", "def pam_auth():\n \"\"\"\n to use pam_login:\n from gluon.contrib.login_methods.pam_auth import pam_auth\n auth.settings.login_methods.append(pam_auth())\n \"\"\"\n\n def pam_auth_aux(username, password):", " \"\"\"\n to use pam_login:\n ...
import smtplib def email_auth(server="smtp.gmail.com:587", domain="@gmail.com"): """ to use email_login: from gluon.contrib.login_methods.email_auth import email_auth auth.settings.login_methods.append(email_auth("smtp.gmail.com:587", "@...
[ [ 1, 0, 0.0303, 0.0303, 0, 0.66, 0, 389, 0, 1, 0, 0, 389, 0, 0 ], [ 2, 0, 0.5606, 0.9091, 0, 0.66, 1, 699, 0, 2, 1, 0, 0, 0, 9 ], [ 8, 1, 0.2576, 0.1818, 1, 0.92, ...
[ "import smtplib", "def email_auth(server=\"smtp.gmail.com:587\",\n domain=\"@gmail.com\"):\n \"\"\"\n to use email_login:\n from gluon.contrib.login_methods.email_auth import email_auth\n auth.settings.login_methods.append(email_auth(\"smtp.gmail.com:587\",\n ...
#!/usr/bin/env python # -*- coding: utf-8 -*- """ This file is part of web2py Web Framework (Copyrighted, 2007-2009). Developed by Massimo Di Pierro <mdipierro@cs.depaul.edu>. License: GPL v2 Tinkered by Szabolcs Gyuris < szimszo n @ o regpreshaz dot eu> """ class CasAuth( object ): """ Login will be done vi...
[ [ 8, 0, 0.0609, 0.0609, 0, 0.66, 0, 0, 1, 0, 0, 0, 0, 0, 0 ], [ 3, 0, 0.5522, 0.9043, 0, 0.66, 1, 195, 0, 6, 0, 0, 186, 0, 16 ], [ 8, 1, 0.2348, 0.2522, 1, 0.31, ...
[ "\"\"\"\nThis file is part of web2py Web Framework (Copyrighted, 2007-2009).\nDeveloped by Massimo Di Pierro <mdipierro@cs.depaul.edu>.\nLicense: GPL v2\n\nTinkered by Szabolcs Gyuris < szimszo n @ o regpreshaz dot eu>\n\"\"\"", "class CasAuth( object ):\n \"\"\"\n Login will be done via Web2py's CAS applic...
#!/usr/bin/env python # -*- coding: utf-8 -*- """ Written by Michele Comitini <mcm@glisco.it> License: GPL v3 Adds support for OAuth1.0a authentication to web2py. Dependencies: - python-oauth2 (http://github.com/simplegeo/python-oauth2) """ import oauth2 as oauth import cgi from urllib2 import urlopen import ur...
[ [ 8, 0, 0.0452, 0.0532, 0, 0.66, 0, 0, 1, 0, 0, 0, 0, 0, 0 ], [ 1, 0, 0.0798, 0.0053, 0, 0.66, 0.1667, 311, 0, 1, 0, 0, 311, 0, 0 ], [ 1, 0, 0.0851, 0.0053, 0, 0.66...
[ "\"\"\"\nWritten by Michele Comitini <mcm@glisco.it>\nLicense: GPL v3\n\nAdds support for OAuth1.0a authentication to web2py.\n\nDependencies:\n - python-oauth2 (http://github.com/simplegeo/python-oauth2)", "import oauth2 as oauth", "import cgi", "from urllib2 import urlopen", "import urllib2", "from url...
SMSCODES = { 'Aliant':'@chat.wirefree.ca', 'Alltel':'@message.alltel.com', 'Ameritech':'@paging.acswireless.com', 'AT&T':'@txt.att.net', 'AU by KDDI':'@ezweb.ne.jp', 'BeeLine GSM':'@sms.beemail.ru', 'Bell Mobility Canada':'@txt.bellmobility.ca', 'Bellsouth':'@bellsouth.cl', 'BellSout...
[ [ 14, 0, 0.4509, 0.8929, 0, 0.66, 0, 606, 0, 0, 0, 0, 0, 6, 0 ], [ 2, 0, 0.9554, 0.0982, 0, 0.66, 1, 988, 0, 2, 1, 0, 0, 0, 1 ], [ 8, 1, 0.933, 0.0357, 1, 0.64, ...
[ "SMSCODES = {\n 'Aliant':'@chat.wirefree.ca',\n 'Alltel':'@message.alltel.com',\n 'Ameritech':'@paging.acswireless.com',\n 'AT&T':'@txt.att.net',\n 'AU by KDDI':'@ezweb.ne.jp',\n 'BeeLine GSM':'@sms.beemail.ru',\n 'Bell Mobility Canada':'@txt.bellmobility.ca',", "def sms_email(number,provider...
# -*- coding: iso-8859-1 -*- "PDF Template Helper for FPDF.py" __author__ = "Mariano Reingart <reingart@gmail.com>" __copyright__ = "Copyright (C) 2010 Mariano Reingart" __license__ = "LGPL 3.0" import sys,os,csv from fpdf import FPDF def rgb(col): return (col // 65536), (col // 256 % 256), (col% 256) class Te...
[ [ 8, 0, 0.0116, 0.0039, 0, 0.66, 0, 0, 1, 0, 0, 0, 0, 0, 0 ], [ 14, 0, 0.0194, 0.0039, 0, 0.66, 0.125, 777, 1, 0, 0, 0, 0, 3, 0 ], [ 14, 0, 0.0233, 0.0039, 0, 0.66,...
[ "\"PDF Template Helper for FPDF.py\"", "__author__ = \"Mariano Reingart <reingart@gmail.com>\"", "__copyright__ = \"Copyright (C) 2010 Mariano Reingart\"", "__license__ = \"LGPL 3.0\"", "import sys,os,csv", "from fpdf import FPDF", "def rgb(col):\n return (col // 65536), (col // 256 % 256), (col% 256...
from fpdf import FPDF from html import HTMLMixin from template import Template
[ [ 1, 0, 0.3333, 0.3333, 0, 0.66, 0, 957, 0, 1, 0, 0, 957, 0, 0 ], [ 1, 0, 0.6667, 0.3333, 0, 0.66, 0.5, 271, 0, 1, 0, 0, 271, 0, 0 ], [ 1, 0, 1, 0.3333, 0, 0.66, ...
[ "from fpdf import FPDF", "from html import HTMLMixin", "from template import Template" ]
#!/usr/bin/env python # -*- coding: utf-8 -*- # # Creates a taskbar icon for web2py # # Author: Mark Larsen, mostly stolen from Mark Hammond's # # C:\Python25\Lib\site-packages\win32\Demos\win32gui_taskbar.py # # 11/7/08 import os import sys import base64 import win32con import win32api import win32gui class TaskB...
[ [ 1, 0, 0.0331, 0.0041, 0, 0.66, 0, 688, 0, 1, 0, 0, 688, 0, 0 ], [ 1, 0, 0.0372, 0.0041, 0, 0.66, 0.1667, 509, 0, 1, 0, 0, 509, 0, 0 ], [ 1, 0, 0.0413, 0.0041, 0, ...
[ "import os", "import sys", "import base64", "import win32con", "import win32api", "import win32gui", "class TaskBarIcon:\n\n def __init__(self, iconPath=None):\n\n self.iconPath = iconPath\n self.status = []\n\n msg_TaskbarRestart = \\", " def __init__(self, iconPath=None):\...
#!/usr/bin/env python # -*- coding: utf-8 -*- """PyRSS2Gen - A Python library for generating RSS 2.0 feeds.""" __name__ = 'PyRSS2Gen' __version__ = (1, 0, 0) __author__ = 'Andrew Dalke <dalke@dalkescientific.com>' _generator_name = __name__ + '-' + '.'.join(map(str, __version__)) import datetime import cStringIO #...
[ [ 8, 0, 0.0068, 0.0017, 0, 0.66, 0, 0, 1, 0, 0, 0, 0, 0, 0 ], [ 14, 0, 0.0102, 0.0017, 0, 0.66, 0.0385, 136, 1, 0, 0, 0, 0, 3, 0 ], [ 14, 0, 0.0119, 0.0017, 0, 0.66...
[ "\"\"\"PyRSS2Gen - A Python library for generating RSS 2.0 feeds.\"\"\"", "__name__ = 'PyRSS2Gen'", "__version__ = (1, 0, 0)", "__author__ = 'Andrew Dalke <dalke@dalkescientific.com>'", "_generator_name = __name__ + '-' + '.'.join(map(str, __version__))", "import datetime", "import cStringIO", "class ...
#!/usr/bin/env python # -*- coding: utf-8 -*- "Contributed modules"
[ [ 8, 0, 1, 0.3333, 0, 0.66, 0, 0, 1, 0, 0, 0, 0, 0, 0 ] ]
[ "\"Contributed modules\"" ]
#!/usr/bin/env python # created my Massimo Di Pierro # license MIT/BSD/GPL import re import cgi __all__ = ['render', 'markmin2html'] __doc__ = """ # Markmin markup language ## About This is a new markup language t...
[ [ 1, 0, 0.0067, 0.0022, 0, 0.66, 0, 540, 0, 1, 0, 0, 540, 0, 0 ], [ 1, 0, 0.009, 0.0022, 0, 0.66, 0.05, 934, 0, 1, 0, 0, 934, 0, 0 ], [ 14, 0, 0.0135, 0.0022, 0, 0....
[ "import re", "import cgi", "__all__ = ['render', 'markmin2html']", "__doc__ = \"\"\"\n# Markmin markup language\n\n## About\n\nThis is a new markup language that we call markmin designed to produce high quality scientific papers and books and also put them online. We provide serializers for html, latex and pd...
#!/usr/bin/env python # created my Massimo Di Pierro # license MIT/BSD/GPL import re import cgi import sys import doctest from optparse import OptionParser __all__ = ['render','markmin2latex'] META = 'META' regex_newlines = re.compile('(\n\r)|(\r\n)') regex_dd=re.compile('\$\$(?P<latex>.*?)\$\$') regex_code = re.comp...
[ [ 1, 0, 0.0147, 0.0037, 0, 0.66, 0, 540, 0, 1, 0, 0, 540, 0, 0 ], [ 1, 0, 0.0184, 0.0037, 0, 0.66, 0.037, 934, 0, 1, 0, 0, 934, 0, 0 ], [ 1, 0, 0.0221, 0.0037, 0, 0...
[ "import re", "import cgi", "import sys", "import doctest", "from optparse import OptionParser", "__all__ = ['render','markmin2latex']", "META = 'META'", "regex_newlines = re.compile('(\\n\\r)|(\\r\\n)')", "regex_dd=re.compile('\\$\\$(?P<latex>.*?)\\$\\$')", "regex_code = re.compile('('+META+')|(``...
# this file exists for backward compatibility __all__ = ['DAL','Field','drivers','gae'] from gluon.dal import DAL, Field, Table, Query, Set, Expression, Row, Rows, drivers, BaseAdapter, SQLField, SQLTable, SQLXorable, SQLQuery, SQLSet, SQLRows, SQLStorage, SQLDB, GQLDB, SQLALL, SQLCustomType, gae
[ [ 14, 0, 0.6, 0.2, 0, 0.66, 0, 272, 0, 0, 0, 0, 0, 5, 0 ], [ 1, 0, 1, 0.2, 0, 0.66, 1, 169, 0, 22, 0, 0, 169, 0, 0 ] ]
[ "__all__ = ['DAL','Field','drivers','gae']", "from gluon.dal import DAL, Field, Table, Query, Set, Expression, Row, Rows, drivers, BaseAdapter, SQLField, SQLTable, SQLXorable, SQLQuery, SQLSet, SQLRows, SQLStorage, SQLDB, GQLDB, SQLALL, SQLCustomType, gae" ]
import struct import re from err import Warning, Error, InterfaceError, DataError, \ DatabaseError, OperationalError, IntegrityError, InternalError, \ NotSupportedError, ProgrammingError insert_values = re.compile(r'\svalues\s*(\(.+\))', re.IGNORECASE) class Cursor(object): ''' This ...
[ [ 1, 0, 0.0048, 0.0048, 0, 0.66, 0, 399, 0, 1, 0, 0, 399, 0, 0 ], [ 1, 0, 0.0096, 0.0048, 0, 0.66, 0.25, 540, 0, 1, 0, 0, 540, 0, 0 ], [ 1, 0, 0.024, 0.0144, 0, 0.6...
[ "import struct", "import re", "from err import Warning, Error, InterfaceError, DataError, \\\n DatabaseError, OperationalError, IntegrityError, InternalError, \\\n NotSupportedError, ProgrammingError", "insert_values = re.compile(r'\\svalues\\s*(\\(.+\\))', re.IGNORECASE)", "class Cur...
import re import datetime import time import array import struct from times import Date, Time, TimeDelta, Timestamp from constants import FIELD_TYPE try: set except NameError: try: from sets import BaseSet as set except ImportError: from sets import Set as set ESCAPE_REGEX = re.compile(r"...
[ [ 1, 0, 0.0033, 0.0033, 0, 0.66, 0, 540, 0, 1, 0, 0, 540, 0, 0 ], [ 1, 0, 0.0065, 0.0033, 0, 0.66, 0.027, 426, 0, 1, 0, 0, 426, 0, 0 ], [ 1, 0, 0.0098, 0.0033, 0, 0...
[ "import re", "import datetime", "import time", "import array", "import struct", "from times import Date, Time, TimeDelta, Timestamp", "from constants import FIELD_TYPE", "try:\n set\nexcept NameError:\n try:\n from sets import BaseSet as set\n except ImportError:\n from sets imp...
from time import localtime from datetime import date, datetime, time, timedelta Date = date Time = time TimeDelta = timedelta Timestamp = datetime def DateFromTicks(ticks): return date(*localtime(ticks)[:3]) def TimeFromTicks(ticks): return time(*localtime(ticks)[3:6]) def TimestampFromTicks(ticks): ret...
[ [ 1, 0, 0.0625, 0.0625, 0, 0.66, 0, 654, 0, 1, 0, 0, 654, 0, 0 ], [ 1, 0, 0.125, 0.0625, 0, 0.66, 0.125, 426, 0, 4, 0, 0, 426, 0, 0 ], [ 14, 0, 0.25, 0.0625, 0, 0.6...
[ "from time import localtime", "from datetime import date, datetime, time, timedelta", "Date = date", "Time = time", "TimeDelta = timedelta", "Timestamp = datetime", "def DateFromTicks(ticks):\n return date(*localtime(ticks)[:3])", " return date(*localtime(ticks)[:3])", "def TimeFromTicks(ticks...
MBLENGTH = { 8:1, 33:3, 88:2, 91:2 }
[ [ 14, 0, 0.55, 0.6, 0, 0.66, 0, 757, 0, 0, 0, 0, 0, 6, 0 ] ]
[ "MBLENGTH = {\n 8:1,\n 33:3,\n 88:2,\n 91:2\n }" ]
import pymysql import unittest class PyMySQLTestCase(unittest.TestCase): databases = [ {"host":"localhost","user":"root","passwd":"","db":"test_pymysql"}, {"host":"localhost","user":"root","passwd":"","db":"test_pymysql2"}] def setUp(self): self.connections = [] for params in ...
[ [ 1, 0, 0.0556, 0.0556, 0, 0.66, 0, 244, 0, 1, 0, 0, 244, 0, 0 ], [ 1, 0, 0.1111, 0.0556, 0, 0.66, 0.5, 88, 0, 1, 0, 0, 88, 0, 0 ], [ 3, 0, 0.5833, 0.7778, 0, 0.66,...
[ "import pymysql", "import unittest", "class PyMySQLTestCase(unittest.TestCase):\n databases = [\n {\"host\":\"localhost\",\"user\":\"root\",\"passwd\":\"\",\"db\":\"test_pymysql\"},\n {\"host\":\"localhost\",\"user\":\"root\",\"passwd\":\"\",\"db\":\"test_pymysql2\"}]\n\n def setUp(self):\n ...
from pymysql.tests.test_issues import * from pymysql.tests.test_example import * from pymysql.tests.test_basic import * if __name__ == "__main__": import unittest unittest.main()
[ [ 1, 0, 0.1429, 0.1429, 0, 0.66, 0, 897, 0, 1, 0, 0, 897, 0, 0 ], [ 1, 0, 0.2857, 0.1429, 0, 0.66, 0.3333, 138, 0, 1, 0, 0, 138, 0, 0 ], [ 1, 0, 0.4286, 0.1429, 0, ...
[ "from pymysql.tests.test_issues import *", "from pymysql.tests.test_example import *", "from pymysql.tests.test_basic import *", "if __name__ == \"__main__\":\n import unittest\n unittest.main()", " import unittest", " unittest.main()" ]
''' PyMySQL: A pure-Python drop-in replacement for MySQLdb. Copyright (c) 2010 PyMySQL contributors 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 limitati...
[ [ 8, 0, 0.0954, 0.1832, 0, 0.66, 0, 0, 1, 0, 0, 0, 0, 0, 0 ], [ 14, 0, 0.1985, 0.0076, 0, 0.66, 0.0345, 557, 0, 0, 0, 0, 0, 8, 0 ], [ 1, 0, 0.2137, 0.0076, 0, 0.66,...
[ "'''\nPyMySQL: A pure-Python drop-in replacement for MySQLdb.\n\nCopyright (c) 2010 PyMySQL contributors\n\nPermission is hereby granted, free of charge, to any person obtaining a copy\nof this software and associated documentation files (the \"Software\"), to deal\nin the Software without restriction, including wi...
COM_SLEEP = "\x00" COM_QUIT = "\x01" COM_INIT_DB = "\x02" COM_QUERY = "\x03" COM_FIELD_LIST = "\x04" COM_CREATE_DB = "\x05" COM_DROP_DB = "\x06" COM_REFRESH = "\x07" COM_SHUTDOWN = "\x08" COM_STATISTICS = "\x09" COM_PROCESS_INFO = "\x0a" COM_CONNECT = "\x0b" COM_PROCESS_KILL = "\x0c" COM_DEBUG = "\x0d" COM_PING = "\x0...
[ [ 14, 0, 0.087, 0.0435, 0, 0.66, 0, 19, 1, 0, 0, 0, 0, 3, 0 ], [ 14, 0, 0.1304, 0.0435, 0, 0.66, 0.0476, 408, 1, 0, 0, 0, 0, 3, 0 ], [ 14, 0, 0.1739, 0.0435, 0, 0.6...
[ "COM_SLEEP = \"\\x00\"", "COM_QUIT = \"\\x01\"", "COM_INIT_DB = \"\\x02\"", "COM_QUERY = \"\\x03\"", "COM_FIELD_LIST = \"\\x04\"", "COM_CREATE_DB = \"\\x05\"", "COM_DROP_DB = \"\\x06\"", "COM_REFRESH = \"\\x07\"", "COM_SHUTDOWN = \"\\x08\"", "COM_STATISTICS = \"\\x09\"", "COM_PROCESS_INFO = \"\\...
DECIMAL = 0 TINY = 1 SHORT = 2 LONG = 3 FLOAT = 4 DOUBLE = 5 NULL = 6 TIMESTAMP = 7 LONGLONG = 8 INT24 = 9 DATE = 10 TIME = 11 DATETIME = 12 YEAR = 13 NEWDATE = 14 VARCHAR = 15 BIT = 16 NEWDECIMAL = 246 ENUM = 247 SET = 248 TINY_BLOB = 249 MEDIUM_BLOB = 250 LONG_BLOB = 251 BLOB = 252 VAR_STRING = 253 STRING = 254 GEO...
[ [ 14, 0, 0.0938, 0.0312, 0, 0.66, 0, 22, 1, 0, 0, 0, 0, 1, 0 ], [ 14, 0, 0.125, 0.0312, 0, 0.66, 0.0357, 474, 1, 0, 0, 0, 0, 1, 0 ], [ 14, 0, 0.1562, 0.0312, 0, 0.6...
[ "DECIMAL = 0", "TINY = 1", "SHORT = 2", "LONG = 3", "FLOAT = 4", "DOUBLE = 5", "NULL = 6", "TIMESTAMP = 7", "LONGLONG = 8", "INT24 = 9", "DATE = 10", "TIME = 11", "DATETIME = 12", "YEAR = 13", "NEWDATE = 14", "VARCHAR = 15", "BIT = 16", "NEWDECIMAL = 246", "ENUM = 247", "SET = ...
NOT_NULL = 1 PRI_KEY = 2 UNIQUE_KEY = 4 MULTIPLE_KEY = 8 BLOB = 16 UNSIGNED = 32 ZEROFILL = 64 BINARY = 128 ENUM = 256 AUTO_INCREMENT = 512 TIMESTAMP = 1024 SET = 2048 PART_KEY = 16384 GROUP = 32767 UNIQUE = 65536
[ [ 14, 0, 0.0667, 0.0667, 0, 0.66, 0, 79, 1, 0, 0, 0, 0, 1, 0 ], [ 14, 0, 0.1333, 0.0667, 0, 0.66, 0.0714, 978, 1, 0, 0, 0, 0, 1, 0 ], [ 14, 0, 0.2, 0.0667, 0, 0.66,...
[ "NOT_NULL = 1", "PRI_KEY = 2", "UNIQUE_KEY = 4", "MULTIPLE_KEY = 8", "BLOB = 16", "UNSIGNED = 32", "ZEROFILL = 64", "BINARY = 128", "ENUM = 256", "AUTO_INCREMENT = 512", "TIMESTAMP = 1024", "SET = 2048", "PART_KEY = 16384", "GROUP = 32767", "UNIQUE = 65536" ]
ERROR_FIRST = 1000 HASHCHK = 1000 NISAMCHK = 1001 NO = 1002 YES = 1003 CANT_CREATE_FILE = 1004 CANT_CREATE_TABLE = 1005 CANT_CREATE_DB = 1006 DB_CREATE_EXISTS = 1007 DB_DROP_EXISTS = 1008 DB_DROP_DELETE = 1009 DB_DROP_RMDIR = 1010 CANT_DELETE_FILE = 1011 CANT_FIND_SYSTEM_REC = 1012 CANT_GET_STAT = 1013 CANT_GET_WD = 1...
[ [ 14, 0, 0.0042, 0.0021, 0, 0.66, 0, 135, 1, 0, 0, 0, 0, 1, 0 ], [ 14, 0, 0.0064, 0.0021, 0, 0.66, 0.0021, 316, 1, 0, 0, 0, 0, 1, 0 ], [ 14, 0, 0.0085, 0.0021, 0, 0...
[ "ERROR_FIRST = 1000", "HASHCHK = 1000", "NISAMCHK = 1001", "NO = 1002", "YES = 1003", "CANT_CREATE_FILE = 1004", "CANT_CREATE_TABLE = 1005", "CANT_CREATE_DB = 1006", "DB_CREATE_EXISTS = 1007", "DB_DROP_EXISTS = 1008", "DB_DROP_DELETE = 1009", "DB_DROP_RMDIR = 1010", "CANT_DELETE_FILE = 1011"...
SERVER_STATUS_IN_TRANS = 1 SERVER_STATUS_AUTOCOMMIT = 2 SERVER_MORE_RESULTS_EXISTS = 8 SERVER_QUERY_NO_GOOD_INDEX_USED = 16 SERVER_QUERY_NO_INDEX_USED = 32 SERVER_STATUS_CURSOR_EXISTS = 64 SERVER_STATUS_LAST_ROW_SENT = 128 SERVER_STATUS_DB_DROPPED = 256 SERVER_STATUS_NO_BACKSLASH_ESCAPES = 512 SERVER_STATUS_METADATA_C...
[ [ 14, 0, 0.1667, 0.0833, 0, 0.66, 0, 869, 1, 0, 0, 0, 0, 1, 0 ], [ 14, 0, 0.25, 0.0833, 0, 0.66, 0.1111, 540, 1, 0, 0, 0, 0, 1, 0 ], [ 14, 0, 0.3333, 0.0833, 0, 0.6...
[ "SERVER_STATUS_IN_TRANS = 1", "SERVER_STATUS_AUTOCOMMIT = 2", "SERVER_MORE_RESULTS_EXISTS = 8", "SERVER_QUERY_NO_GOOD_INDEX_USED = 16", "SERVER_QUERY_NO_INDEX_USED = 32", "SERVER_STATUS_CURSOR_EXISTS = 64", "SERVER_STATUS_LAST_ROW_SENT = 128", "SERVER_STATUS_DB_DROPPED = 256", "SERVER_STATUS_NO_BACK...
LONG_PASSWORD = 1 FOUND_ROWS = 1 << 1 LONG_FLAG = 1 << 2 CONNECT_WITH_DB = 1 << 3 NO_SCHEMA = 1 << 4 COMPRESS = 1 << 5 ODBC = 1 << 6 LOCAL_FILES = 1 << 7 IGNORE_SPACE = 1 << 8 PROTOCOL_41 = 1 << 9 INTERACTIVE = 1 << 10 SSL = 1 << 11 IGNORE_SIGPIPE = 1 << 12 TRANSACTIONS = 1 << 13 SECURE_CONNECTION = 1 << 15 MULTI_STA...
[ [ 14, 0, 0.1, 0.05, 0, 0.66, 0, 65, 1, 0, 0, 0, 0, 1, 0 ], [ 14, 0, 0.15, 0.05, 0, 0.66, 0.0588, 129, 4, 0, 0, 0, 0, 0, 0 ], [ 14, 0, 0.2, 0.05, 0, 0.66, 0.1176...
[ "LONG_PASSWORD = 1", "FOUND_ROWS = 1 << 1", "LONG_FLAG = 1 << 2", "CONNECT_WITH_DB = 1 << 3", "NO_SCHEMA = 1 << 4", "COMPRESS = 1 << 5", "ODBC = 1 << 6", "LOCAL_FILES = 1 << 7", "IGNORE_SPACE = 1 << 8", "PROTOCOL_41 = 1 << 9", "INTERACTIVE = 1 << 10", "SSL = 1 << 11", "IGNORE_SIGPIPE = 1 << ...
from gluon.contrib.memcache.memcache import Client from gluon.cache import CacheAbstract import time """ examle of usage: cache.memcache = MemcacheClient(request,[127.0.0.1:11211],debug=true) """ import cPickle as pickle import thread locker = thread.allocate_lock() def MemcacheClient(*a, **b): locker.acquire(...
[ [ 1, 0, 0.0116, 0.0116, 0, 0.66, 0, 698, 0, 1, 0, 0, 698, 0, 0 ], [ 1, 0, 0.0233, 0.0116, 0, 0.66, 0.125, 38, 0, 1, 0, 0, 38, 0, 0 ], [ 1, 0, 0.0349, 0.0116, 0, 0.6...
[ "from gluon.contrib.memcache.memcache import Client", "from gluon.cache import CacheAbstract", "import time", "\"\"\"\nexamle of usage:\n\ncache.memcache = MemcacheClient(request,[127.0.0.1:11211],debug=true)\n\"\"\"", "import cPickle as pickle", "import thread", "locker = thread.allocate_lock()", "de...
# (c) 2007 Chris AtLee <chris@atlee.ca> # Licensed under the MIT license: # http://www.opensource.org/licenses/mit-license.php """ PAM module for python Provides an authenticate function that will allow the caller to authenticate a user against the Pluggable Authentication Modules (PAM) on the system. Implemented usi...
[ [ 8, 0, 0.061, 0.065, 0, 0.66, 0, 0, 1, 0, 0, 0, 0, 0, 0 ], [ 14, 0, 0.0976, 0.0081, 0, 0.66, 0.0345, 272, 0, 0, 0, 0, 0, 5, 0 ], [ 1, 0, 0.1138, 0.0081, 0, 0.66, ...
[ "\"\"\"\nPAM module for python\n\nProvides an authenticate function that will allow the caller to authenticate\na user against the Pluggable Authentication Modules (PAM) on the system.\n\nImplemented using ctypes, so no compilation is necessary.\n\"\"\"", "__all__ = ['authenticate']", "from ctypes import CDLL, ...
#!/usr/bin/python # # Copyright 2007 Google Inc. # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or a...
[ [ 8, 0, 0.1163, 0.0116, 0, 0.66, 0, 0, 1, 0, 0, 0, 0, 0, 0 ], [ 1, 0, 0.1279, 0.0039, 0, 0.66, 0.0556, 715, 0, 1, 0, 0, 715, 0, 0 ], [ 1, 0, 0.1318, 0.0039, 0, 0.66...
[ "\"\"\"\nAn interactive, stateful AJAX shell that runs Python code on the server.\n\"\"\"", "import logging", "import new", "import os", "import pickle", "import sys", "import traceback", "import types", "import wsgiref.handlers", "import StringIO", "import threading", "locker = threading.RLoc...
from types import StringType, ListType, TupleType from copy import deepcopy from Elements import * DEFAULT_TAB_WIDTH = 720 ParagraphAlignmentMap = { ParagraphPropertySet.LEFT : 'ql', ParagraphPropertySet.RIGHT : 'qr', ParagraphPropertySet.CENTER : 'qc...
[ [ 1, 0, 0.0016, 0.0016, 0, 0.66, 0, 209, 0, 3, 0, 0, 209, 0, 0 ], [ 1, 0, 0.0031, 0.0016, 0, 0.66, 0.0714, 739, 0, 1, 0, 0, 739, 0, 0 ], [ 1, 0, 0.0047, 0.0016, 0, ...
[ "from types import StringType, ListType, TupleType", "from copy import deepcopy", "from Elements import *", "DEFAULT_TAB_WIDTH = 720", "ParagraphAlignmentMap = { ParagraphPropertySet.LEFT : 'ql',\n ParagraphPropertySet.RIGHT : 'qr',\n ParagraphPro...
from types import IntType, FloatType, LongType, StringTypes from copy import deepcopy from binascii import hexlify from Constants import * from Styles import * class UnhandledParamError( Exception ) : def __init__( self, param ) : Exception.__init__( self, "Don't...
[ [ 1, 0, 0.0013, 0.0013, 0, 0.66, 0, 209, 0, 4, 0, 0, 209, 0, 0 ], [ 1, 0, 0.0026, 0.0013, 0, 0.66, 0.0083, 739, 0, 1, 0, 0, 739, 0, 0 ], [ 1, 0, 0.004, 0.0013, 0, 0...
[ "from types import IntType, FloatType, LongType, StringTypes", "from copy import deepcopy", "from binascii import hexlify", "from Constants import *", "from Styles import *", "class UnhandledParamError( Exception ) :\n def __init__( self, param ) :\n Ex...
""" A Styles is a collection of PropertySets that can be applied to a particular RTF element. At present there are only two, Text and Paragraph but ListStyles will be added soon too. """ from PropertySets import * class TextStyle : def __init__( self, text_props, name=None, shading_props=None ) : self....
[ [ 8, 0, 0.043, 0.0753, 0, 0.66, 0, 0, 1, 0, 0, 0, 0, 0, 0 ], [ 1, 0, 0.0968, 0.0108, 0, 0.66, 0.3333, 611, 0, 1, 0, 0, 611, 0, 0 ], [ 3, 0, 0.2312, 0.2366, 0, 0.66,...
[ "\"\"\"\nA Styles is a collection of PropertySets that can be applied to a particular RTF element.\n\nAt present there are only two, Text and Paragraph but ListStyles will be added soon too.\n\n\n\"\"\"", "from PropertySets import *", "class TextStyle :\n def __init__( self, text_props, name=None, shading_pr...
""" PropertySets group common attributes together, each property set is used to control a specific part of the rendering. PropertySets can be used in different elements of the document. For example the FramePropertySet is used in paragraphs, tables, cells, etc. The TextPropertySet can be used for text or in a Paragr...
[ [ 8, 0, 0.0113, 0.0205, 0, 0.66, 0, 0, 1, 0, 0, 0, 0, 0, 0 ], [ 1, 0, 0.0246, 0.002, 0, 0.66, 0.0417, 209, 0, 1, 0, 0, 209, 0, 0 ], [ 1, 0, 0.0266, 0.002, 0, 0.66, ...
[ "\"\"\"\nPropertySets group common attributes together, each property set is used to control a specific part of the rendering.\n\nPropertySets can be used in different elements of the document.\n\nFor example the FramePropertySet is used in paragraphs, tables, cells, etc.\n\nThe TextPropertySet can be used for text...
from PropertySets import * from Elements import * from Styles import * from Renderer import * def dumps(doc): import cStringIO s=cStringIO.StringIO() r=Renderer() r.Write(doc,s) return s.getvalue()
[ [ 1, 0, 0.0909, 0.0909, 0, 0.66, 0, 611, 0, 1, 0, 0, 611, 0, 0 ], [ 1, 0, 0.1818, 0.0909, 0, 0.66, 0.25, 413, 0, 1, 0, 0, 413, 0, 0 ], [ 1, 0, 0.2727, 0.0909, 0, 0....
[ "from PropertySets import *", "from Elements import *", "from Styles import *", "from Renderer import *", "def dumps(doc):\n import cStringIO\n s=cStringIO.StringIO()\n r=Renderer()\n r.Write(doc,s)\n return s.getvalue()", " import cStringIO", " s=cStri...
class ViewKind : """An integer (0-5) that represents the view mode of the document.""" NONE = 0 PageLayout = 1 Outline = 2 MasterDocument = 3 Normal = 4 OnlineLayout = 5 DEFAULT = PageLayout def _IsValid( cls, value ) : return value in [ 0, 1...
[ [ 3, 0, 0.051, 0.0955, 0, 0.66, 0, 480, 0, 1, 0, 0, 0, 0, 1 ], [ 8, 1, 0.0127, 0.0064, 1, 0.49, 0, 0, 1, 0, 0, 0, 0, 0, 0 ], [ 14, 1, 0.0255, 0.0064, 1, 0.49, 0...
[ "class ViewKind :\n \"\"\"An integer (0-5) that represents the view mode of the document.\"\"\"\n\n NONE = 0\n PageLayout = 1\n Outline = 2\n MasterDocument = 3\n Normal = 4", " \"\"\"An integer (0-5) that represents the view mode of the document.\"\"\"", " N...
#!/usr/bin/env python # -*- coding: utf-8 -*- """ Developed by Robin Bhattacharyya (memecache for GAE) from gluon.contrib.gae_memcache import MemcacheClient cache.ram=cache.disk=MemcacheClient(request) """ import time from google.appengine.api.memcache import Client class MemcacheClient(Client): def __init__(...
[ [ 8, 0, 0.1383, 0.1277, 0, 0.66, 0, 0, 1, 0, 0, 0, 0, 0, 0 ], [ 1, 0, 0.234, 0.0213, 0, 0.66, 0.3333, 654, 0, 1, 0, 0, 654, 0, 0 ], [ 1, 0, 0.2553, 0.0213, 0, 0.66,...
[ "\"\"\"\nDeveloped by Robin Bhattacharyya (memecache for GAE)\n\nfrom gluon.contrib.gae_memcache import MemcacheClient\ncache.ram=cache.disk=MemcacheClient(request)\n\"\"\"", "import time", "from google.appengine.api.memcache import Client", "class MemcacheClient(Client):\n\n def __init__(self, request):\n...
"""Drop-in replacement for collections.OrderedDict by Raymond Hettinger http://code.activestate.com/recipes/576693/ """ from UserDict import DictMixin # Modified from original to support Python 2.4, see # http://code.google.com/p/simplejson/issues/detail?id=53 try: all except NameError: def all(seq): ...
[ [ 8, 0, 0.0252, 0.042, 0, 0.66, 0, 0, 1, 0, 0, 0, 0, 0, 0 ], [ 1, 0, 0.0504, 0.0084, 0, 0.66, 0.3333, 351, 0, 1, 0, 0, 351, 0, 0 ], [ 7, 0, 0.1134, 0.0672, 0, 0.66,...
[ "\"\"\"Drop-in replacement for collections.OrderedDict by Raymond Hettinger\n\nhttp://code.activestate.com/recipes/576693/\n\n\"\"\"", "from UserDict import DictMixin", "try:\n all\nexcept NameError:\n def all(seq):\n for elem in seq:\n if not elem:\n return False\n ...
"""JSON token scanner """ import re def _import_c_make_scanner(): try: raise ImportError # not not import this because conflict with python 2.6 from simplejson._speedups import make_scanner return make_scanner except ImportError: return None c_make_scanner = _import_c_make_scanne...
[ [ 8, 0, 0.0192, 0.0256, 0, 0.66, 0, 0, 1, 0, 0, 0, 0, 0, 0 ], [ 1, 0, 0.0385, 0.0128, 0, 0.66, 0.1429, 540, 0, 1, 0, 0, 540, 0, 0 ], [ 2, 0, 0.0897, 0.0897, 0, 0.66...
[ "\"\"\"JSON token scanner\n\"\"\"", "import re", "def _import_c_make_scanner():\n try:\n raise ImportError # not not import this because conflict with python 2.6\n from simplejson._speedups import make_scanner\n return make_scanner\n except ImportError:\n return None", " t...
"""Implementation of JSONEncoder Modified by Massimo Di Pierro to handle datetime """ import re import datetime from decimal import Decimal def _import_speedups(): try: raise ImportError # not not import this because conflict with python 2.6 from simplejson import _speedups return _speedups...
[ [ 8, 0, 0.0039, 0.0058, 0, 0.66, 0, 0, 1, 0, 0, 0, 0, 0, 0 ], [ 1, 0, 0.0078, 0.0019, 0, 0.66, 0.0556, 540, 0, 1, 0, 0, 540, 0, 0 ], [ 1, 0, 0.0097, 0.0019, 0, 0.66...
[ "\"\"\"Implementation of JSONEncoder\nModified by Massimo Di Pierro to handle datetime\n\"\"\"", "import re", "import datetime", "from decimal import Decimal", "def _import_speedups():\n try:\n raise ImportError # not not import this because conflict with python 2.6\n from simplejson import...
r"""JSON (JavaScript Object Notation) <http://json.org> is a subset of JavaScript syntax (ECMA-262 3rd edition) used as a lightweight data interchange format. :mod:`simplejson` exposes an API familiar to users of the standard library :mod:`marshal` and :mod:`pickle` modules. It is the externally maintained version of ...
[ [ 8, 0, 0.1582, 0.3133, 0, 0.66, 0, 0, 1, 0, 0, 0, 0, 0, 0 ], [ 14, 0, 0.3165, 0.0032, 0, 0.66, 0.1, 162, 1, 0, 0, 0, 0, 3, 0 ], [ 14, 0, 0.3244, 0.0127, 0, 0.66, ...
[ "r\"\"\"JSON (JavaScript Object Notation) <http://json.org> is a subset of\nJavaScript syntax (ECMA-262 3rd edition) used as a lightweight data\ninterchange format.\n\n:mod:`simplejson` exposes an API familiar to users of the standard library\n:mod:`marshal` and :mod:`pickle` modules. It is the externally maintaine...
from markdown2 import * from gluon.html import XML def WIKI(text, encoding="utf8", safe_mode='escape', html4tags=False, **attributes): if not text: test = '' if attributes.has_key('extras'): extras = attributes['extras'] del attributes['extras'] else: extras=None text = ...
[ [ 1, 0, 0.0625, 0.0625, 0, 0.66, 0, 623, 0, 1, 0, 0, 623, 0, 0 ], [ 1, 0, 0.125, 0.0625, 0, 0.66, 0.5, 373, 0, 1, 0, 0, 373, 0, 0 ], [ 2, 0, 0.625, 0.8125, 0, 0.66,...
[ "from markdown2 import *", "from gluon.html import XML", "def WIKI(text, encoding=\"utf8\", safe_mode='escape', html4tags=False, **attributes):\n if not text:\n test = ''\n if attributes.has_key('extras'):\n extras = attributes['extras']\n del attributes['extras']\n else:\n ...
#!/usr/bin/env python # coding: utf8 import re import unicodedata def urlify(s, max_length=80): s = s.lower() # string normalization, eg è => e, ñ => n s = unicodedata.normalize('NFKD', s.decode('utf-8')).encode('ASCII', 'ignore') # strip entities s = re.sub('&\w+;', '', s) # strip everything ...
[ [ 1, 0, 0.1739, 0.0435, 0, 0.66, 0, 540, 0, 1, 0, 0, 540, 0, 0 ], [ 1, 0, 0.2174, 0.0435, 0, 0.66, 0.5, 759, 0, 1, 0, 0, 759, 0, 0 ], [ 2, 0, 0.6522, 0.7391, 0, 0.6...
[ "import re", "import unicodedata", "def urlify(s, max_length=80):\n s = s.lower()\n # string normalization, eg è => e, ñ => n\n s = unicodedata.normalize('NFKD', s.decode('utf-8')).encode('ASCII', 'ignore')\n # strip entities\n s = re.sub('&\\w+;', '', s)\n # strip everything but letters, numb...
#!/usr/bin/python """ This file is part of the web2py Web Framework Copyrighted by Massimo Di Pierro <mdipierro@cs.depaul.edu> License: LGPLv3 (http://www.gnu.org/licenses/lgpl.html) 1) install tornado easy_install tornado 2) start this app: python gluon/contrib/comet_messaging.py -k mykey -p 8888 3) from an...
[ [ 8, 0, 0.2536, 0.4855, 0, 0.66, 0, 0, 1, 0, 0, 0, 0, 0, 0 ], [ 1, 0, 0.5072, 0.0072, 0, 0.66, 0.0714, 17, 0, 1, 0, 0, 17, 0, 0 ], [ 1, 0, 0.5145, 0.0072, 0, 0.66, ...
[ "\"\"\"\nThis file is part of the web2py Web Framework\nCopyrighted by Massimo Di Pierro <mdipierro@cs.depaul.edu>\nLicense: LGPLv3 (http://www.gnu.org/licenses/lgpl.html)\n\n1) install tornado\n\n easy_install tornado", "import tornado.httpserver", "import tornado.websocket", "import tornado.ioloop", "im...
import re, cPickle, random, datetime IUP = {'shoebill':{'a':1,'187':1},'trout-like':{'parr':1},'fig.':{'19':1},'mcintosh.':{'the':1,'illustration':1},'chiasmodon':{'niger':2},'yellow':{'and':4,'giant':1,'green':2,'red':1,'spots':1},'four':{'brightly':1,'hundred':1,'haunts':1,'feet':1,'solutions':2,'hours.':1,'things':...
[ [ 1, 0, 0.0062, 0.0062, 0, 0.66, 0, 540, 0, 4, 0, 0, 540, 0, 0 ], [ 14, 0, 0.0186, 0.0062, 0, 0.66, 0.2, 533, 0, 0, 0, 0, 0, 6, 0 ], [ 3, 0, 0.1739, 0.2919, 0, 0.66...
[ "import re, cPickle, random, datetime", "IUP = {'shoebill':{'a':1,'187':1},'trout-like':{'parr':1},'fig.':{'19':1},'mcintosh.':{'the':1,'illustration':1},'chiasmodon':{'niger':2},'yellow':{'and':4,'giant':1,'green':2,'red':1,'spots':1},'four':{'brightly':1,'hundred':1,'haunts':1,'feet':1,'solutions':2,'hours.':1,...
#!/usr/bin/env python # -*- coding: utf-8 -*- """ This file is part of the web2py Web Framework Copyrighted by Massimo Di Pierro <mdipierro@cs.depaul.edu> License: LGPLv3 (http://www.gnu.org/licenses/lgpl.html) """ import sys import cPickle import traceback import types import os import datetime import logging from ...
[ [ 8, 0, 0.0212, 0.0177, 0, 0.66, 0, 0, 1, 0, 0, 0, 0, 0, 0 ], [ 1, 0, 0.0353, 0.0035, 0, 0.66, 0.0588, 509, 0, 1, 0, 0, 509, 0, 0 ], [ 1, 0, 0.0389, 0.0035, 0, 0.66...
[ "\"\"\"\nThis file is part of the web2py Web Framework\nCopyrighted by Massimo Di Pierro <mdipierro@cs.depaul.edu>\nLicense: LGPLv3 (http://www.gnu.org/licenses/lgpl.html)\n\"\"\"", "import sys", "import cPickle", "import traceback", "import types", "import os", "import datetime", "import logging", ...
#!/usr/bin/env python # -*- coding: utf-8 -*- """ This file is part of the web2py Web Framework Copyrighted by Massimo Di Pierro <mdipierro@cs.depaul.edu> License: LGPLv3 (http://www.gnu.org/licenses/lgpl.html) Web2Py framework modules ======================== """
[ [ 8, 0, 0.6364, 0.8182, 0, 0.66, 0, 0, 1, 0, 0, 0, 0, 0, 0 ] ]
[ "\"\"\"\nThis file is part of the web2py Web Framework\nCopyrighted by Massimo Di Pierro <mdipierro@cs.depaul.edu>\nLicense: LGPLv3 (http://www.gnu.org/licenses/lgpl.html)\n\n\nWeb2Py framework modules\n========================" ]
""" This file is part of the web2py Web Framework Copyrighted by Massimo Di Pierro <mdipierro@cs.depaul.edu> License: LGPLv3 (http://www.gnu.org/licenses/lgpl.html) """ import datetime from storage import Storage from html import TAG import contrib.simplejson as simplejson import contrib.rss2 as rss2 def xml_rec(valu...
[ [ 8, 0, 0.0545, 0.0909, 0, 0.66, 0, 0, 1, 0, 0, 0, 0, 0, 0 ], [ 1, 0, 0.1091, 0.0182, 0, 0.66, 0.1, 426, 0, 1, 0, 0, 426, 0, 0 ], [ 1, 0, 0.1273, 0.0182, 0, 0.66, ...
[ "\"\"\"\nThis file is part of the web2py Web Framework\nCopyrighted by Massimo Di Pierro <mdipierro@cs.depaul.edu>\nLicense: LGPLv3 (http://www.gnu.org/licenses/lgpl.html)\n\"\"\"", "import datetime", "from storage import Storage", "from html import TAG", "import contrib.simplejson as simplejson", "import...
#!/usr/bin/env python """ This file is part of the web2py Web Framework Copyrighted by Massimo Di Pierro <mdipierro@cs.depaul.edu> License: LGPLv3 (http://www.gnu.org/licenses/lgpl.html) This file is not strictly required by web2py. It is used for three purposes: 1) check that all required modules are installed prop...
[ [ 8, 0, 0.078, 0.1101, 0, 0.66, 0, 0, 1, 0, 0, 0, 0, 0, 0 ], [ 1, 0, 0.1468, 0.0092, 0, 0.66, 0.1, 688, 0, 1, 0, 0, 688, 0, 0 ], [ 1, 0, 0.156, 0.0092, 0, 0.66, ...
[ "\"\"\"\nThis file is part of the web2py Web Framework\nCopyrighted by Massimo Di Pierro <mdipierro@cs.depaul.edu>\nLicense: LGPLv3 (http://www.gnu.org/licenses/lgpl.html)\n\nThis file is not strictly required by web2py. It is used for three purposes:\n\n1) check that all required modules are installed properly", ...
#!/usr/bin/env python # -*- coding: utf-8 -*- from datetime import datetime from time import mktime from time import sleep from time import time DB_URI = 'sqlite://sessions.sqlite' EXPIRATION_MINUTES = 60 SLEEP_MINUTES = 5 while 1: # Infinite loop now = time() # get current Unix timestamp for row in db(...
[ [ 1, 0, 0.16, 0.04, 0, 0.66, 0, 426, 0, 1, 0, 0, 426, 0, 0 ], [ 1, 0, 0.2, 0.04, 0, 0.66, 0.1429, 654, 0, 1, 0, 0, 654, 0, 0 ], [ 1, 0, 0.24, 0.04, 0, 0.66, 0.2...
[ "from datetime import datetime", "from time import mktime", "from time import sleep", "from time import time", "DB_URI = 'sqlite://sessions.sqlite'", "EXPIRATION_MINUTES = 60", "SLEEP_MINUTES = 5", "while 1: # Infinite loop\n now = time() # get current Unix timestamp\n \n for row in db().sele...
#!/usr/bin/env python # -*- coding: utf-8 -*- import sys import os import time import stat import datetime from gluon.utils import md5_hash from gluon.restricted import RestrictedError SLEEP_MINUTES = 5 DB_URI = 'sqlite://tickets.db' ALLOW_DUPLICATES = True path = os.path.join(request.folder, 'errors') db = SQLDB(...
[ [ 1, 0, 0.0727, 0.0182, 0, 0.66, 0, 509, 0, 1, 0, 0, 509, 0, 0 ], [ 1, 0, 0.0909, 0.0182, 0, 0.66, 0.0714, 688, 0, 1, 0, 0, 688, 0, 0 ], [ 1, 0, 0.1091, 0.0182, 0, ...
[ "import sys", "import os", "import time", "import stat", "import datetime", "from gluon.utils import md5_hash", "from gluon.restricted import RestrictedError", "SLEEP_MINUTES = 5", "DB_URI = 'sqlite://tickets.db'", "ALLOW_DUPLICATES = True", "path = os.path.join(request.folder, 'errors')", "db...
import sys, glob, os, shutil name=sys.argv[1] app=sys.argv[2] dest=sys.argv[3] a=glob.glob('applications/%(app)s/*/plugin_%(name)s.*' % dict(app=app,name=name)) b=glob.glob('applications/%(app)s/*/plugin_%(name)s/*' % dict(app=app,name=name)) for f in a: print 'cp %s ...' % f, shutil.copyfile(f,os.path.join('a...
[ [ 1, 0, 0.04, 0.04, 0, 0.66, 0, 509, 0, 4, 0, 0, 509, 0, 0 ], [ 14, 0, 0.08, 0.04, 0, 0.66, 0.1429, 57, 6, 0, 0, 0, 0, 0, 0 ], [ 14, 0, 0.12, 0.04, 0, 0.66, 0.2...
[ "import sys, glob, os, shutil", "name=sys.argv[1]", "app=sys.argv[2]", "dest=sys.argv[3]", "a=glob.glob('applications/%(app)s/*/plugin_%(name)s.*' % dict(app=app,name=name))", "b=glob.glob('applications/%(app)s/*/plugin_%(name)s/*' % dict(app=app,name=name))", "for f in a:\n print('cp %s ...' % f,)\n...
#!/usr/bin/env python # -*- coding: utf-8 -*- import os import time import stat SLEEP_MINUTES = 5 EXPIRATION_MINUTES = 60 path = os.path.join(request.folder, 'sessions') while 1: now = time.time() for file in os.listdir(path): filename = os.path.join(path, file) t = os.stat(filename)[stat.S...
[ [ 1, 0, 0.1739, 0.0435, 0, 0.66, 0, 688, 0, 1, 0, 0, 688, 0, 0 ], [ 1, 0, 0.2174, 0.0435, 0, 0.66, 0.1667, 654, 0, 1, 0, 0, 654, 0, 0 ], [ 1, 0, 0.2609, 0.0435, 0, ...
[ "import os", "import time", "import stat", "SLEEP_MINUTES = 5", "EXPIRATION_MINUTES = 60", "path = os.path.join(request.folder, 'sessions')", "while 1:\n now = time.time()\n\n for file in os.listdir(path):\n filename = os.path.join(path, file)\n t = os.stat(filename)[stat.ST_MTIME]\n...
#!/usr/bin/env python # -*- coding: utf-8 -*- # TODO: Comment this code import sys import shutil import os from gluon.languages import findT sys.path.insert(0, '.') file = sys.argv[1] apps = sys.argv[2:] d = {} for app in apps: path = 'applications/%s/' % app findT(path, file) data = eval(open(os.path...
[ [ 1, 0, 0.1429, 0.0238, 0, 0.66, 0, 509, 0, 1, 0, 0, 509, 0, 0 ], [ 1, 0, 0.1667, 0.0238, 0, 0.66, 0.0526, 614, 0, 1, 0, 0, 614, 0, 0 ], [ 1, 0, 0.1905, 0.0238, 0, ...
[ "import sys", "import shutil", "import os", "from gluon.languages import findT", "sys.path.insert(0, '.')", "file = sys.argv[1]", "apps = sys.argv[2:]", "d = {}", "for app in apps:\n path = 'applications/%s/' % app\n findT(path, file)\n data = eval(open(os.path.join(path, 'languages', '%s.p...
import sys import re def cleancss(text): text=re.compile('\s+').sub(' ', text) text=re.compile('\s*(?P<a>,|:)\s*').sub('\g<a> ', text) text=re.compile('\s*;\s*').sub(';\n ', text) text=re.compile('\s*\{\s*').sub(' {\n ', text) text=re.compile('\s*\}\s*').sub('\n}\n\n', text) return text ...
[ [ 1, 0, 0.0189, 0.0189, 0, 0.66, 0, 509, 0, 1, 0, 0, 509, 0, 0 ], [ 1, 0, 0.0377, 0.0189, 0, 0.66, 0.1667, 540, 0, 1, 0, 0, 540, 0, 0 ], [ 2, 0, 0.1321, 0.1321, 0, ...
[ "import sys", "import re", "def cleancss(text):\n text=re.compile('\\s+').sub(' ', text)\n text=re.compile('\\s*(?P<a>,|:)\\s*').sub('\\g<a> ', text)\n text=re.compile('\\s*;\\s*').sub(';\\n ', text)\n text=re.compile('\\s*\\{\\s*').sub(' {\\n ', text)\n text=re.compile('\\s*\\}\\s*').sub('...
#!/usr/bin/env python # -*- coding: utf-8 -*- import sys import re filename = sys.argv[1] data = open(filename, 'r').read() data = re.compile('\s*{\s*').sub(' { ', data) data = re.compile('\s*;\s*').sub('; ', data) data = re.compile('\s*}\s*').sub(' }\n', data) data = re.compile('[ ]+').sub(' ', data) print data
[ [ 1, 0, 0.2667, 0.0667, 0, 0.66, 0, 509, 0, 1, 0, 0, 509, 0, 0 ], [ 1, 0, 0.3333, 0.0667, 0, 0.66, 0.125, 540, 0, 1, 0, 0, 540, 0, 0 ], [ 14, 0, 0.4667, 0.0667, 0, ...
[ "import sys", "import re", "filename = sys.argv[1]", "data = open(filename, 'r').read()", "data = re.compile('\\s*{\\s*').sub(' { ', data)", "data = re.compile('\\s*;\\s*').sub('; ', data)", "data = re.compile('\\s*}\\s*').sub(' }\\n', data)", "data = re.compile('[ ]+').sub(' ', data)", "print(data)...
''' Create the web2py code needed to access your mysql legacy db. To make this work all the legacy tables you want to access need to have an "id" field. This plugin needs: mysql mysqldump installed and globally available. Under Windows you will probably need to add the mysql executable directory to the PATH variable...
[ [ 8, 0, 0.1085, 0.2075, 0, 0.66, 0, 0, 1, 0, 0, 0, 0, 0, 0 ], [ 1, 0, 0.217, 0.0094, 0, 0.66, 0.1429, 394, 0, 1, 0, 0, 394, 0, 0 ], [ 1, 0, 0.2264, 0.0094, 0, 0.66,...
[ "'''\nCreate the web2py code needed to access your mysql legacy db.\n\nTo make this work all the legacy tables you want to access need to have an \"id\" field.\n\nThis plugin needs:\nmysql\nmysqldump", "import subprocess", "import re", "import sys", "data_type_map = dict(\n varchar = 'string',\n ...
#!/usr/bin/python # -*- coding: utf-8 -*- ''' autoroutes writes routes for you based on a simpler routing configuration file called routes.conf. Example: ----- BEGIN routes.conf------- 127.0.0.1 /examples/default domain1.com /app1/default domain2.com /app2/default domain3.com /app3/default ----- END ---------- It m...
[ [ 8, 0, 0.1333, 0.2296, 0, 0.66, 0, 0, 1, 0, 0, 0, 0, 0, 0 ], [ 14, 0, 0.2778, 0.0444, 0, 0.66, 0.125, 308, 1, 0, 0, 0, 0, 3, 0 ], [ 4, 0, 0.3185, 0.037, 0, 0.66, ...
[ "'''\nautoroutes writes routes for you based on a simpler routing\nconfiguration file called routes.conf. Example:\n\n----- BEGIN routes.conf-------\n127.0.0.1 /examples/default\ndomain1.com /app1/default\ndomain2.com /app2/default", "config = '''\n127.0.0.1 /examples/default\ndomain1.com /app1/default\ndomai...
#!/usr/bin/env python # -*- coding: utf-8 -*- import cStringIO import re import sys import tarfile import urllib import xml.parsers.expat as expat """ Update script for contenttype.py module. Usage: python contentupdate.py /path/to/contenttype.py If no path is specified, script will look for contenttype.py in curre...
[ [ 1, 0, 0.0312, 0.0312, 0, 0.66, 0, 764, 0, 1, 0, 0, 764, 0, 0 ], [ 1, 0, 0.0625, 0.0312, 0, 0.66, 0.1667, 540, 0, 1, 0, 0, 540, 0, 0 ], [ 1, 0, 0.0938, 0.0312, 0, ...
[ "import cStringIO", "import re", "import sys", "import tarfile", "import urllib", "import xml.parsers.expat as expat", "class MIMEParser(dict):\n\n def __start_element_handler(self, name, attrs):\n if name == 'mime-type':\n if self.type:\n for extension in self.extens...
#!/usr/bin/env python # -*- coding: utf-8 -*- import sys import os import time import stat import datetime from gluon.utils import md5_hash from gluon.restricted import RestrictedError from gluon.tools import Mail path = os.path.join(request.folder, 'errors') hashes = {} mail = Mail() ### CONFIGURE HERE SLEEP_MINU...
[ [ 1, 0, 0.087, 0.0217, 0, 0.66, 0, 509, 0, 1, 0, 0, 509, 0, 0 ], [ 1, 0, 0.1087, 0.0217, 0, 0.66, 0.0625, 688, 0, 1, 0, 0, 688, 0, 0 ], [ 1, 0, 0.1304, 0.0217, 0, 0...
[ "import sys", "import os", "import time", "import stat", "import datetime", "from gluon.utils import md5_hash", "from gluon.restricted import RestrictedError", "from gluon.tools import Mail", "path = os.path.join(request.folder, 'errors')", "hashes = {}", "mail = Mail()", "SLEEP_MINUTES = 5", ...
import sys, glob for filename in glob.glob(sys.argv[1]): data1=open(filename,'rb').read() open(filename+'.bak2','wb').write(data1) data2 = '\n'.join([line.rstrip() for line in open(filename,'rb')])+'\n' open(filename,'wb').write(data2) print filename, len(data1)-len(data2)
[ [ 1, 0, 0.1429, 0.1429, 0, 0.66, 0, 509, 0, 2, 0, 0, 509, 0, 0 ], [ 6, 0, 0.6429, 0.8571, 0, 0.66, 1, 275, 3, 0, 0, 0, 0, 0, 13 ], [ 14, 1, 0.4286, 0.1429, 1, 0.26,...
[ "import sys, glob", "for filename in glob.glob(sys.argv[1]):\n data1=open(filename,'rb').read()\n open(filename+'.bak2','wb').write(data1)\n data2 = '\\n'.join([line.rstrip() for line in open(filename,'rb')])+'\\n'\n open(filename,'wb').write(data2)\n print(filename, len(data1)-len(data2))", " ...
EXPIRATION_MINUTES=60 DIGITS=(str(x) for x in range(10)) import os, time, stat, logging path=os.path.join(request.folder,'sessions') if not os.path.exists(path): os.mkdir(path) now=time.time() for filename in os.listdir(path): fullpath=os.path.join(path,filename) try: if os.path.isfile(fullpath): ...
[ [ 1, 0, 1, 1, 0, 0.66, 0, 688, 0, 4, 0, 0, 688, 0, 0 ] ]
[ "import os, time, stat, logging" ]
# coding: utf8 { '"update" is an optional expression like "field1=\'newvalue\'". You cannot update or delete the results of a JOIN': '"Update" ist ein optionaler Ausdruck wie "Feld1 = \'newvalue". JOIN Ergebnisse können nicht aktualisiert oder gelöscht werden', '%Y-%m-%d': '%Y-%m-%d', '%Y-%m-%d %H:%M:%S': '%Y-%m-%d %H:...
[ [ 8, 0, 0.5029, 0.9971, 0, 0.66, 0, 0, 0, 0, 0, 0, 0, 0, 0 ] ]
[ "{\n'\"update\" is an optional expression like \"field1=\\'newvalue\\'\". You cannot update or delete the results of a JOIN': '\"Update\" ist ein optionaler Ausdruck wie \"Feld1 = \\'newvalue\". JOIN Ergebnisse können nicht aktualisiert oder gelöscht werden',\n'%Y-%m-%d': '%Y-%m-%d',\n'%Y-%m-%d %H:%M:%S': '%Y-%m-%d...
# coding: utf8 { '"update" is an optional expression like "field1=\'newvalue\'". You cannot update or delete the results of a JOIN': '"Uaktualnij" jest dodatkowym wyrażeniem postaci "pole1=\'nowawartość\'". Nie możesz uaktualnić lub usunąć wyników z JOIN:', '%Y-%m-%d': '%Y-%m-%d', '%Y-%m-%d %H:%M:%S': '%Y-%m-%d %H:%M:%...
[ [ 8, 0, 0.5038, 0.9962, 0, 0.66, 0, 0, 0, 0, 0, 0, 0, 0, 0 ] ]
[ "{\n'\"update\" is an optional expression like \"field1=\\'newvalue\\'\". You cannot update or delete the results of a JOIN': '\"Uaktualnij\" jest dodatkowym wyrażeniem postaci \"pole1=\\'nowawartość\\'\". Nie możesz uaktualnić lub usunąć wyników z JOIN:',\n'%Y-%m-%d': '%Y-%m-%d',\n'%Y-%m-%d %H:%M:%S': '%Y-%m-%d %H...
# coding: utf8 { '"update" is an optional expression like "field1=\'newvalue\'". You cannot update or delete the results of a JOIN': '"actualice" es una expresión opcional como "campo1=\'nuevo_valor\'". No se puede actualizar o eliminar resultados de un JOIN', '%Y-%m-%d': '%Y-%m-%d', '%Y-%m-%d %H:%M:%S': '%Y-%m-%d %H:%...
[ [ 8, 0, 0.5035, 0.9965, 0, 0.66, 0, 0, 0, 0, 0, 0, 0, 0, 0 ] ]
[ "{\n'\"update\" is an optional expression like \"field1=\\'newvalue\\'\". You cannot update or delete the results of a JOIN': '\"actualice\" es una expresión opcional como \"campo1=\\'nuevo_valor\\'\". No se puede actualizar o eliminar resultados de un JOIN',\n'%Y-%m-%d': '%Y-%m-%d',\n'%Y-%m-%d %H:%M:%S': '%Y-%m-%d...
# coding: utf8 { '"update" is an optional expression like "field1=\'newvalue\'". You cannot update or delete the results of a JOIN': '"update" è un\'espressione opzionale come "campo1=\'nuovo valore\'". Non si può fare "update" o "delete" dei risultati di un JOIN ', '%Y-%m-%d': '%d/%m/%Y', '%Y-%m-%d %H:%M:%S': '%d/%m/%...
[ [ 8, 0, 0.5038, 0.9962, 0, 0.66, 0, 0, 0, 0, 0, 0, 0, 0, 0 ] ]
[ "{\n'\"update\" is an optional expression like \"field1=\\'newvalue\\'\". You cannot update or delete the results of a JOIN': '\"update\" è un\\'espressione opzionale come \"campo1=\\'nuovo valore\\'\". Non si può fare \"update\" o \"delete\" dei risultati di un JOIN ',\n'%Y-%m-%d': '%d/%m/%Y',\n'%Y-%m-%d %H:%M:%S'...
# coding: utf8 { '"update" is an optional expression like "field1=\'newvalue\'". You cannot update or delete the results of a JOIN': '"update" is an optional expression like "field1=\'newvalue\'". You cannot update or delete the results of a JOIN', '%Y-%m-%d': '%Y-%m-%d', '%Y-%m-%d %H:%M:%S': '%Y-%m-%d %H:%M:%S', '%s r...
[ [ 8, 0, 0.5036, 0.9964, 0, 0.66, 0, 0, 0, 0, 0, 0, 0, 0, 0 ] ]
[ "{\n'\"update\" is an optional expression like \"field1=\\'newvalue\\'\". You cannot update or delete the results of a JOIN': '\"update\" is an optional expression like \"field1=\\'newvalue\\'\". You cannot update or delete the results of a JOIN',\n'%Y-%m-%d': '%Y-%m-%d',\n'%Y-%m-%d %H:%M:%S': '%Y-%m-%d %H:%M:%S',\...
# coding: utf8 { '"update" is an optional expression like "field1=\'newvalue\'". You cannot update or delete the results of a JOIN': '"Uaktualnij" jest dodatkowym wyrażeniem postaci "pole1=\'nowawartość\'". Nie możesz uaktualnić lub usunąć wyników z JOIN:', '%Y-%m-%d': '%Y-%m-%d', '%Y-%m-%d %H:%M:%S': '%Y-%m-%d %H:%M:%...
[ [ 8, 0, 0.5036, 0.9964, 0, 0.66, 0, 0, 0, 0, 0, 0, 0, 0, 0 ] ]
[ "{\n'\"update\" is an optional expression like \"field1=\\'newvalue\\'\". You cannot update or delete the results of a JOIN': '\"Uaktualnij\" jest dodatkowym wyrażeniem postaci \"pole1=\\'nowawartość\\'\". Nie możesz uaktualnić lub usunąć wyników z JOIN:',\n'%Y-%m-%d': '%Y-%m-%d',\n'%Y-%m-%d %H:%M:%S': '%Y-%m-%d %H...
# coding: utf8 { '"update" is an optional expression like "field1=\'newvalue\'". You cannot update or delete the results of a JOIN': '"update" è un\'espressione opzionale come "campo1=\'nuovo valore\'". Non si può fare "update" o "delete" dei risultati di un JOIN ', '%Y-%m-%d': '%d/%m/%Y', '%Y-%m-%d %H:%M:%S': '%d/%m/%...
[ [ 8, 0, 0.5038, 0.9962, 0, 0.66, 0, 0, 0, 0, 0, 0, 0, 0, 0 ] ]
[ "{\n'\"update\" is an optional expression like \"field1=\\'newvalue\\'\". You cannot update or delete the results of a JOIN': '\"update\" è un\\'espressione opzionale come \"campo1=\\'nuovo valore\\'\". Non si può fare \"update\" o \"delete\" dei risultati di un JOIN ',\n'%Y-%m-%d': '%d/%m/%Y',\n'%Y-%m-%d %H:%M:%S'...
# coding: utf8 { '"update" is an optional expression like "field1=\'newvalue\'". You cannot update or delete the results of a JOIN': '"update" est une expression en option tels que "field1 = \'newvalue\'". Vous ne pouvez pas mettre à jour ou supprimer les résultats d\'une jointure "a JOIN"', '%Y-%m-%d': '%d-%m-%Y', '%Y...
[ [ 8, 0, 0.5039, 0.9961, 0, 0.66, 0, 0, 0, 0, 0, 0, 0, 0, 0 ] ]
[ "{\n'\"update\" is an optional expression like \"field1=\\'newvalue\\'\". You cannot update or delete the results of a JOIN': '\"update\" est une expression en option tels que \"field1 = \\'newvalue\\'\". Vous ne pouvez pas mettre à jour ou supprimer les résultats d\\'une jointure \"a JOIN\"',\n'%Y-%m-%d': '%d-%m-%...
# coding: utf8 { '"update" is an optional expression like "field1=\'newvalue\'". You cannot update or delete the results of a JOIN': '"עדכן" הוא ביטוי אופציונאלי, כגון "field1=newvalue". אינך יוכל להשתמש בjoin, בעת שימוש ב"עדכן" או "מחק".', '%Y-%m-%d': '%Y-%m-%d', '%Y-%m-%d %H:%M:%S': '%Y-%m-%d %H:%M:%S', '%s rows dele...
[ [ 8, 0, 0.5037, 0.9963, 0, 0.66, 0, 0, 0, 0, 0, 0, 0, 0, 0 ] ]
[ "{\n'\"update\" is an optional expression like \"field1=\\'newvalue\\'\". You cannot update or delete the results of a JOIN': '\"עדכן\" הוא ביטוי אופציונאלי, כגון \"field1=newvalue\". אינך יוכל להשתמש בjoin, בעת שימוש ב\"עדכן\" או \"מחק\".',\n'%Y-%m-%d': '%Y-%m-%d',\n'%Y-%m-%d %H:%M:%S': '%Y-%m-%d %H:%M:%S',\n'%s r...
# coding: utf8 { '"update" is an optional expression like "field1=\'newvalue\'". You cannot update or delete the results of a JOIN': '"update" é uma expressão opcional como "campo1=\'novo_valor\'". Não é permitido atualizar ou apagar resultados de um JOIN', '%Y-%m-%d': '%d/%m/%Y', '%Y-%m-%d %H:%M:%S': '%d/%m/%Y %H:%M:%...
[ [ 8, 0, 0.5031, 0.9969, 0, 0.66, 0, 0, 0, 0, 0, 0, 0, 0, 0 ] ]
[ "{\n'\"update\" is an optional expression like \"field1=\\'newvalue\\'\". You cannot update or delete the results of a JOIN': '\"update\" é uma expressão opcional como \"campo1=\\'novo_valor\\'\". Não é permitido atualizar ou apagar resultados de um JOIN',\n'%Y-%m-%d': '%d/%m/%Y',\n'%Y-%m-%d %H:%M:%S': '%d/%m/%Y %H...
# coding: utf8 { '"update" is an optional expression like "field1=\'newvalue\'". You cannot update or delete the results of a JOIN': '"更新" 是選擇性的條件式, 格式就像 "欄位1=\'值\'". 但是 JOIN 的資料不可以使用 update 或是 delete"', '%Y-%m-%d': '%Y-%m-%d', '%Y-%m-%d %H:%M:%S': '%Y-%m-%d %H:%M:%S', '%s rows deleted': '已刪除 %s 筆', '%s rows updated': ...
[ [ 8, 0, 0.5033, 0.9967, 0, 0.66, 0, 0, 0, 0, 0, 0, 0, 0, 0 ] ]
[ "{\n'\"update\" is an optional expression like \"field1=\\'newvalue\\'\". You cannot update or delete the results of a JOIN': '\"更新\" 是選擇性的條件式, 格式就像 \"欄位1=\\'值\\'\". 但是 JOIN 的資料不可以使用 update 或是 delete\"',\n'%Y-%m-%d': '%Y-%m-%d',\n'%Y-%m-%d %H:%M:%S': '%Y-%m-%d %H:%M:%S',\n'%s rows deleted': '已刪除 %s 筆',\n'%s rows up...
# coding: utf8 { '"browse"': '游览', '"save"': '"保存"', '"submit"': '"提交"', '"update" is an optional expression like "field1=\'newvalue\'". You cannot update or delete the results of a JOIN': '"更新"是可配置项 如 "field1=\'newvalue\'",你无法在JOIN 中更新或删除', '%Y-%m-%d': '%Y-%m-%d', '%Y-%m-%d %H:%M:%S': '%Y-%m-%d %H:%M:%S', '%s rows del...
[ [ 8, 0, 0.5034, 0.9966, 0, 0.66, 0, 0, 0, 0, 0, 0, 0, 0, 0 ] ]
[ "{\n'\"browse\"': '游览',\n'\"save\"': '\"保存\"',\n'\"submit\"': '\"提交\"',\n'\"update\" is an optional expression like \"field1=\\'newvalue\\'\". You cannot update or delete the results of a JOIN': '\"更新\"是可配置项 如 \"field1=\\'newvalue\\'\",你无法在JOIN 中更新或删除',\n'%Y-%m-%d': '%Y-%m-%d',\n'%Y-%m-%d %H:%M:%S': '%Y-%m-%d %H:%M...
# ########################################################### # ## generate menu # ########################################################### _a = request.application _c = request.controller _f = request.function response.title = '%s %s' % (_f, '/'.join(request.args)) response.subtitle = 'admin' response.menu = [(T('...
[ [ 14, 0, 0.1562, 0.0312, 0, 0.66, 0, 635, 7, 0, 0, 0, 0, 0, 0 ], [ 14, 0, 0.1875, 0.0312, 0, 0.66, 0.125, 934, 7, 0, 0, 0, 0, 0, 0 ], [ 14, 0, 0.2188, 0.0312, 0, 0....
[ "_a = request.application", "_c = request.controller", "_f = request.function", "response.title = '%s %s' % (_f, '/'.join(request.args))", "response.subtitle = 'admin'", "response.menu = [(T('site'), _f == 'site', URL(_a,'default','site'))]", "if request.args:\n _t = request.args[0]\n response.men...
EXPIRATION = 60 * 60 # logout after 60 minutes of inactivity CHECK_VERSION = True WEB2PY_URL = 'http://web2py.com' WEB2PY_VERSION_URL = WEB2PY_URL+'/examples/default/version' ########################################################################### # Preferences for EditArea # the user-interface feature that allow...
[ [ 14, 0, 0.0164, 0.0164, 0, 0.66, 0, 631, 4, 0, 0, 0, 0, 0, 0 ], [ 14, 0, 0.0328, 0.0164, 0, 0.66, 0.0625, 762, 1, 0, 0, 0, 0, 4, 0 ], [ 14, 0, 0.0492, 0.0164, 0, 0...
[ "EXPIRATION = 60 * 60 # logout after 60 minutes of inactivity", "CHECK_VERSION = True", "WEB2PY_URL = 'http://web2py.com'", "WEB2PY_VERSION_URL = WEB2PY_URL+'/examples/default/version'", "TEXT_EDITOR = 'edit_area' or 'amy'", "FONT_SIZE = 10", "FULL_SCREEN = 'false'", "ALLOW_TOGGLE = 'true'", "REPLA...
from gluon.admin import apath # ########################################################### # ## make sure administrator is on localhost or https # ########################################################### http_host = request.env.http_host.split(':')[0] if request.env.web2py_runtime_gae: session_db = DAL('gae')...
[ [ 1, 0, 0.0106, 0.0106, 0, 0.66, 0, 158, 0, 1, 0, 0, 158, 0, 0 ], [ 14, 0, 0.0638, 0.0106, 0, 0.66, 0.1, 785, 6, 0, 0, 0, 0, 0, 1 ], [ 4, 0, 0.1223, 0.0851, 0, 0.66...
[ "from gluon.admin import apath", "http_host = request.env.http_host.split(':')[0]", "if request.env.web2py_runtime_gae:\n session_db = DAL('gae')\n session.connect(request, response, db=session_db)\n hosts = (http_host, )\nelse:\n hosts = (http_host, socket.gethostname(),\n socket.gethos...
# Template helpers import os def button(href, label): return A(SPAN(label),_class='button',_href=href) def sp_button(href, label): return A(SPAN(label),_class='button special',_href=href) def helpicon(): return IMG(_src=URL('static', 'images/help.png'), _alt='help') def searchbox(elementid): return TAG['']...
[ [ 1, 0, 0.2, 0.0667, 0, 0.66, 0, 688, 0, 1, 0, 0, 688, 0, 0 ], [ 2, 0, 0.3667, 0.1333, 0, 0.66, 0.25, 95, 0, 2, 1, 0, 0, 0, 2 ], [ 13, 1, 0.4, 0.0667, 1, 0.6, 0...
[ "import os", "def button(href, label):\n return A(SPAN(label),_class='button',_href=href)", " return A(SPAN(label),_class='button',_href=href)", "def sp_button(href, label):\n return A(SPAN(label),_class='button special',_href=href)", " return A(SPAN(label),_class='button special',_href=href)", "def h...
import time import os import sys import re import urllib import cgi import difflib import shutil import stat import socket from textwrap import dedent try: from mercurial import ui, hg, cmdutil have_mercurial = True except ImportError: have_mercurial = False from gluon.utils import md5_hash from gluon.fi...
[ [ 1, 0, 0.0385, 0.0385, 0, 0.66, 0, 654, 0, 1, 0, 0, 654, 0, 0 ], [ 1, 0, 0.0769, 0.0385, 0, 0.66, 0.0556, 688, 0, 1, 0, 0, 688, 0, 0 ], [ 1, 0, 0.1154, 0.0385, 0, ...
[ "import time", "import os", "import sys", "import re", "import urllib", "import cgi", "import difflib", "import shutil", "import stat", "import socket", "from textwrap import dedent", "try:\n from mercurial import ui, hg, cmdutil\n have_mercurial = True\nexcept ImportError:\n have_mer...
if DEMO_MODE: session.flash = T('disabled in demo mode') redirect(URL('default','site')) if not have_mercurial: session.flash=T("Sorry, could not find mercurial installed") redirect(URL('default','design',args=request.args(0))) _hgignore_content = """\ syntax: glob *~ *.pyc *.pyo *.bak cache/* database...
[ [ 4, 0, 0.0274, 0.0411, 0, 0.66, 0, 0, 2, 0, 0, 0, 0, 0, 3 ], [ 14, 1, 0.0274, 0.0137, 1, 0.39, 0, 837, 3, 1, 0, 0, 716, 10, 1 ], [ 8, 1, 0.0411, 0.0137, 1, 0.39, ...
[ "if DEMO_MODE:\n session.flash = T('disabled in demo mode')\n redirect(URL('default','site'))", " session.flash = T('disabled in demo mode')", " redirect(URL('default','site'))", "if not have_mercurial:\n session.flash=T(\"Sorry, could not find mercurial installed\")\n redirect(URL('default'...