code
stringlengths
1
199k
from __future__ import unicode_literals from django.db import migrations, models class Migration(migrations.Migration): dependencies = [ ('aggregator', '0031_dataset_order'), ] operations = [ migrations.AddField( model_name='dimension', name='dataType', fi...
import time import sys import _mysql import random import string import re import os import traceback from selenium import webdriver from selenium.webdriver.support.ui import Select from selenium.webdriver.common.keys import Keys import selenium.webdriver.chrome.service as service service = service.Service('D:\ChromeDr...
"""Add a new SSH key.""" from os import path import click import SoftLayer from SoftLayer.CLI import environment from SoftLayer.CLI import exceptions @click.command() @click.argument('label') @click.option('--in-file', '-f', type=click.Path(exists=True), help="The id_rsa.pub file to import f...
from __future__ import unicode_literals from django.db import models, migrations class Migration(migrations.Migration): dependencies = [ ('inventory', '0021_license_view'), ] operations = [ migrations.AddField( model_name='collaborator', name='license_id', ...
from swgpy.object import * def create(kernel): result = Tangible() result.template = "object/tangible/ship/components/droid_interface/shared_ddi_seinar_interface_mk4.iff" result.attribute_template_id = 8 result.stfName("space/space_item","ddi_seinar_interface_mk4") #### BEGIN MODIFICATIONS #### #### END MODIFICA...
import random def main(): """Main""" # Initialize frequency1 = 0 frequency2 = 0 frequency3 = 0 frequency4 = 0 frequency5 = 0 frequency6 = 0 for roll in range(1, 6001): # Rolls a die 6000 times face = random.randrange(1, 7) # Random number from 1 to 7 # Count...
from plugins.Plugin import Plugin import os import json import sqlite3 DB_PATH = "market_data/loan_history.sqlite3" class Charts(Plugin): def on_bot_init(self): super(Charts, self).on_bot_init() # If there's no history database, can't use this if not os.path.isfile(DB_PATH): self.l...
from datetime import datetime from ..extensions import db class Notification(db.Model): __tablename__ = "notifications" id = db.Column(db.Integer, primary_key=True) created_at = db.Column(db.DateTime(), default=datetime.now) message = db.Column(db.String(255), nullable=False) category = db.Column(db...
import json from aleph.tests.util import TestCase class ReconcileApiTestCase(TestCase): def setUp(self): super(ReconcileApiTestCase, self).setUp() def test_index(self): res = self.client.get('/api/freebase/reconcile') assert res.status_code == 200, res assert 'schemaSpace' in res...
import os os.system("sudo python setup.py install")
if __name__ == '__main__': from types import MappingProxyType d = {1: 'A'} d_proxy = MappingProxyType(d) print(repr(d_proxy)) print(d_proxy[1]) d[2] = 'B' print(d_proxy[2])
class SecurionPayException(Exception): def __init__(self, type, code, message, charge_id, blacklist_rule_id): self.type = type self.code = code self.message = message self.charge_id = charge_id self.blacklist_rule_id = blacklist_rule_id def __str__(self): return '...
"""Run regression test suite. This module calls down into individual test cases via subprocess. It will forward all unrecognized arguments onto the individual test scripts. Functional tests are disabled on Windows by default. Use --force to run them anyway. For a description of arguments recognized by test scripts, see...
import skimage.io # bug. need to import this before tensorflow import skimage.transform # bug. need to import this before tensorflow import tensorflow as tf from tensorflow.python.ops import control_flow_ops from tensorflow.python.training import moving_averages from config import Config import datetime import numpy ...
import warnings warnings.simplefilter(action='ignore', category=FutureWarning) import numpy as np import time, os import tvm import tvm.contrib.graph_runtime as runtime from tvm import relay import tensorflow as tf import tvm.relay.testing.tf as tf_testing from tensorflow import nn np.random.seed(0) """ Network par...
from util_graph import * if __name__ == '__main__': get_labeled_graph_for_CC('./data/graph/graph.dat', './data/graph/graph_labeled_CC.dat', './data/graph/nodes_hash_CC.dat')
from django.conf.urls import patterns, url from tour import api urlpatterns = patterns( '', url(r'^api/tour/$', api.TourApiView.as_view(), name='tour.tour_api'), )
from pprint import pprint from config_loader import try_load_from_file from hpOneView.exceptions import HPOneViewException from hpOneView.oneview_client import OneViewClient config = { "ip": "", "credentials": { "userName": "administrator", "password": "" } } fabric_id = '' config = try_load...
class Solution: # @return an integer def numTrees(self, n): solutions = [1, 1, 2] for i in range(3, n+1): solutions.append(sum([solutions[i] * solutions[-1-i] for i in range(len(solutions))])) return solutions[n] def main(): solver = Solution() tests = list(range(5)) ...
import gzip from pathlib import Path from typing import Mapping, Sequence from urllib.request import urlretrieve import os from declarative_parser.parser import Argument, Parser, action from models import Gene from utils import jit REMOTE = 'https://github.com/kn-bibs/pathways-data/raw/master/gsea/msigdb/' DATA_DIR = P...
import inspect import sys from minimock import Mock def mock_module(module_name): """ Replaces all of the functions of a module with mock versions of the same functions that don't do anything. Doesn't modify classes or the methods of classes, nor does it change any global data in the modules. Example usage: ...
""" Read a maf file and write out a new maf with only blocks having the required species, after dropping any other species and removing columns containing only gaps. usage: %prog species,species2,... input_maf output_maf allow_partial min_species_per_block """ from galaxy import eggs import pkg_resources; pkg_resources...
from __future__ import unicode_literals from django.apps import AppConfig class MainConfig(AppConfig): name = 'main'
from google.appengine.ext import ndb from consts.district_type import DistrictType from models.team import Team class DistrictTeam(ndb.Model): """ DistrictTeam represents the "home district" for a team in a year key_name is like <year><district_short>_<team_key> (e.g. 2015ne_frc1124) district_short is o...
from swgpy.object import * def create(kernel): result = Static() result.template = "object/static/structure/general/shared_poi_tato_farm_64x64_s02.iff" result.attribute_template_id = -1 result.stfName("obj_n","unknown_object") #### BEGIN MODIFICATIONS #### #### END MODIFICATIONS #### return result
class Allergies(object): _allergies = [ "eggs", "peanuts", "shellfish", "strawberries", "tomatoes", "chocolate", "pollen", "cats" ] def __init__(self, score): self.score = score def is_allergic_to(self, allergy): return bool...
from __future__ import absolute_import, division, print_function, unicode_literals from os import path import sys import nib default_config = path.join(nib.cwd, 'defaults.nib') def merge(dest, source): """In-place, recursive merge of two dictionaries.""" for key in source: if key in dest: if...
from sqlalchemy.testing import eq_ from sqlalchemy import * from sqlalchemy import types as sqltypes, exc, schema from sqlalchemy.sql import table, column from sqlalchemy.testing import fixtures, AssertsExecutionResults, AssertsCompiledSQL from sqlalchemy import testing from sqlalchemy.util import u, b from sqlalchemy ...
from swgpy.object import * def create(kernel): result = Creature() result.template = "object/mobile/shared_dressed_space_comm_chiss_assassin_m.iff" result.attribute_template_id = 9 result.stfName("npc_name","chiss_patron") #### BEGIN MODIFICATIONS #### #### END MODIFICATIONS #### return result
from django.db import migrations, models class Migration(migrations.Migration): dependencies = [ ('open_humans', '0005_userevent'), ] operations = [ migrations.AddField( model_name='userevent', name='event_type', field=models.CharField(default='', max_leng...
import re from pkg_resources import get_distribution, DistributionNotFound from setuptools import setup, find_packages long_description = """A library for image augmentation in machine learning experiments, particularly convolutional neural networks. Supports the augmentation of images, keypoints/landmarks, bounding bo...
import datetime import logging from apscheduler.schedulers.background import BackgroundScheduler from pajbot import utils log = logging.getLogger(__name__) class ScheduledJob: def __init__(self, job): self.job = job def pause(self, *args, **kwargs): if self.job: self.job.pause(*args,...
import datetime from order.models.order import Order, OrderProduct, OrderShop class OrderService(): def list(): result = Order.all() return dict(result) def create(shop, price, total): result = Order.create( price = price, total = total, created_at = d...
import question_template game_type = 'find_the_failure' source_language = 'python' parameter_list = [ ['$x1','int'],['$x2','int'] ] tuple_list = [ ['py_min_ff_', [1,None],[None,None],[None,7]] ] global_code_template = '''\ xX import sys xX d \'\'\' d purpose d return the smaller of a and b d precondition d ...
def pytest_addoption(parser): group = parser.getgroup("JIT options") group.addoption('--slow', action="store_true", default=False, dest="run_slow_tests", help="run all the compiled tests (instead of just a few)")
from .resource import Resource class LoadBalancer(Resource): """LoadBalancer resource. Variables are only populated by the server, and will be ignored when sending a request. :param id: Resource ID. :type id: str :ivar name: Resource name. :vartype name: str :ivar type: Resource type. ...
from django.utils.text import slugify from rest_framework import serializers from fragments.models import Post, Fragment class FragmentSerializer(serializers.ModelSerializer): """ Serializer for Fragment instances """ class Meta: model = Fragment fields = ( 'post', ...
from __future__ import unicode_literals from django.db import models, migrations class Migration(migrations.Migration): dependencies = [ ('constituencies', '0001_initial'), ] operations = [ migrations.AlterField( model_name='constituency', name='count', fi...
from haystack import indexes from dictionary.models import Word class WordIndex(indexes.SearchIndex, indexes.Indexable): text = indexes.CharField(document=True, use_template=True) finnish = indexes.CharField(model_attr='finnish') def get_model(self): return Word def index_queryset(self, using=No...
import time import bs4 import requests def get_news(page, entrant=1): while True: try: headers = { 'user-agent': 'Mozilla/5.0 (Macintosh; Intel Mac OS X 10_7_5)', 'accept': 'text/html,application/xhtml+xml,application/xml;q=0.9,*/*;q=0.8', 'accept-...
import platform import socket import os def autodetect(): """ Returns ------- bool True if current platform matches, otherwise False """ fqdn = socket.getfqdn() if not ".cheyenne" in fqdn: return False dirs = os.path.abspath(__file__).split('/') sweet_src_dirname = dirs[len...
""" Created on Fri Jul 11 11:07:07 2014 @author: Mark """ for x in range (56): max_a = x/6+1 max_b = x/9+1 max_c = x/20+1 for c in range (max_c): for b in range (max_b): for a in range (max_a): if 6*a+9*b+20*c-x == 0: print x,'=6*',a,'+9*',b,'+20*'...
def foo(a): if a: print("hit!") else: print("nothing!") def generator(): x = yield 42 print(x) x = yield print(x) x = 12 + (yield 42) print(x) x = 12 + (yield) print(x) foo((yield 42)) foo((yield)) gen = generator() a = next(gen) print(a) # 42 print("+++++...
from check import * import os import bitarray def opencode(dict): f=open("kodai","r") lines = f.readlines() praeita = '' for x in lines: if x!='\n': x = x.rstrip('\n') if "++" in x: dict["+"] = x[2:] elif praeita != '': dict[praeita]= x[1:] praeita = '' else: x = x.split("+") try: dict...
from neuron import Neuron from PIL import Image import os import sys import glob import pickle threshold = 1 width = 35 l_rate = 0.005 err_margin = 0.1 # does nothing so far a_func = "step" f_stretch = 1 def main(): print "==============" print "TRAINING PHASE" print "==============" neurons = l...
"""Page model for Automation/Anisble/Credentials""" import attr from navmazing import NavigateToAttribute from navmazing import NavigateToSibling from widgetastic.exceptions import NoSuchElementException from widgetastic.utils import ParametrizedLocator from widgetastic.widget import ConditionalSwitchableView from widg...
"""Integration tests for the pull_request event.""" from __future__ import absolute_import, unicode_literals import httpretty from flask import json from kwalitee.models import CommitStatus, Repository from kwalitee.tasks import push from hamcrest import (assert_that, equal_to, contains_string, has_length, ...
""" Plotting results of variable ring buffer experiment. Copyright (C) Sarah Mount, 2009. This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation; either version 2 of the License, or (at your option) any later...
import logging import sys class Utils(object): logpath = '/var/log/libvirt/libvirtwakeonlan.log' @staticmethod def SetupLogging(logpath=None): returnValue = True logformat = "%(asctime)s|%(levelname)s|%(message)s" dateformat = "%Y-%m-%d %H:%M:%S" if logpath is None: ...
__author__ = 'Aram Kananov <arcanan@flashmail.com>, Petr Vanek, <petr@yarpen.cz>' class OracleTypeSource(OraclePLSQLSource): """Source code of type""" pass
import os from jinja2 import Environment, PackageLoader environment = Environment(loader = PackageLoader('megaphysics', 'templates')) if 'MEGPHYS_ROOT' in os.environ: environment.globals['ROOT'] = os.environ['MEGPHYS_ROOT'] else: environment.globals['ROOT'] = "/" def generate_page(template, filepath, **kwargs):...
import ping, socket import os, time, json hosts = "/etc/hosts" timeout = 1500 #timeout in ms interval = 200 #ping interval in ms attempts = 10 tld = ".czf" domain = ".brevnov.czf" smokeping_prefix = "Klienti" smpater_prefix = "Backbone" smokeping_babble_length = 3 smpater_babble_length = 2 smokeping_html = "/var/www/ht...
import sys import os import argparse import shutil DESCRIPTION = "\n" \ "Update pyqt4-visual-graph with the most recent version of the library\n" EPILOG = "\n" \ "Examples:\n" + \ "\n" + \ "update_visual_graph.py\n" + \ "\tupdates the xilinx build with the files in ~/Projects/visual_graph\n" + \ "\n" + \ "update_visual...
from enum import Enum from .tools import matrix_to_list class DataType(Enum): float = "float" float2 = "float2" float3 = "float3" float4 = "float4" float16 = "float4x4" int = "int" int4 = "int4" bool = "bool" texture = "texture" data = "data" class DataEntry: name = "" ty...
from tkinter import mainloop from tkinter.messagebox import showinfo from tkinter102 import MyGui class CustomGui(MyGui): # inherit init def reply(self): # replace reply showinfo(title='popup', message='Ouch!') if __name__ == '__main__': CustomGui...
title = 'Pmw.Balloon demonstration' import sys sys.path[:0] = ['../../..'] import tkinter import Pmw class Demo: def __init__(self, parent): # Create the Balloon. self.balloon = Pmw.Balloon(parent) # Create some widgets and megawidgets with balloon help. frame = tkinter.Frame(parent)...
from . import historyentry from . import msgarea from . import statusbar import meld.linkmap import meld.diffmap import meld.util.sourceviewer
""" Created on Mon Dec 16 08:28:25 2013 @author: mel """ from beatle.model import TComponent from beatle import tran class Data(TComponent): """Implements data""" context_container = True # visual methods @tran.TransactionalMethod('move python variable {0}') def drop(self, to): """Drops data...
specification = { -2: #submodel_id [ "ln(urbansim.zone.average_income)", #"urbansim.household_x_zone.cost_to_income_ratio", #"ln(urbansim.zone.residential_units)", "urbansim.household_x_zone.income_and_ln_improvement_value_per_unit", ] ...
import os, sys import string import glob debug=0 ignored_files = { "trio": "too many non standard macros", "trio.c": "too many non standard macros", "trionan.c": "too many non standard macros", "triostr.c": "too many non standard macros", "acconfig.h": "generated portability layer", "config.h": "generated p...
NAME = "ZenPacks.OndrejJakubcik.OracleHwMonitoring" VERSION = "1.1" AUTHOR = "Ondrej Jakubcik" LICENSE = "LGPL" NAMESPACE_PACKAGES = ['ZenPacks', 'ZenPacks.OndrejJakubcik'] PACKAGES = ['ZenPacks', 'ZenPacks.OndrejJakubcik', 'ZenPacks.OndrejJakubcik.OracleHwMonitoring'] INSTALL_REQUIRES = [] COMPAT_ZENOSS_VERS = ">= 3.0...
import os import logging from virttest import virt_vm from virttest import libvirt_xml from virttest import virsh from virttest import utils_misc from virttest import utils_test from virttest import utils_config from virttest import utils_libvirtd from autotest.client import utils from autotest.client.shared import err...
""" Utilties for working with the event loop. """ from __future__ import absolute_import import logging log = logging.getLogger("storage.asyncutils") class LoopingCall(object): """ A simplified version of `twisted.internet.task.LoopingCall`. This class implements the common pattern of running a call every ...
__doc__="""IBMNetworkAdapterMap IBMNetworkAdapterMap maps the ibmSystemLogicalNetworkAdapterTable table to cards objects $Id: IBMNetworkAdapterMap.py,v 1.0 2009/07/21 23:36:53 egor Exp $""" __version__ = '$Revision: 1.0 $'[11:-2] from Products.DataCollector.plugins.CollectorPlugin import SnmpPlugin, GetTableMap from Pr...
import json import datetime class DatetimeEncoder(json.JSONEncoder): def default(self, obj): if (isinstance(obj, datetime.datetime) or isinstance(obj, datetime.date) or isinstance(obj, datetime.timedelta)): return repr(obj) else: return super(DateTimeE...
from openerp import api from openerp.tests import HttpCase from openerp.tests.common import TransactionCase from openerp.addons.base.ir.ir_qweb import AssetsBundle from openerp.modules.module import get_resource_path from collections import Counter from os import utime import time class TestJavascriptAssetsBundle(Trans...
import numpy as np from sverchok.utils.testing import * from sverchok.utils.logging import debug, info from sverchok.utils.geom import PlaneEquation, LineEquation, linear_approximation class PlaneTests(SverchokTestCase): def test_plane_from_three_points(self): p1 = (1, 0, 0) p2 = (0, 1, 0) p...
''' This __init__ file is present to help with certain non-standard uses of pubsub1: 1. so that sphinx's autodoc extension can find the pubsub1 documentation 2. so that py2exe can find the pub module when v1 API is used (pubsub1/pub.py gets included in the library only if pubsub1 is a package) Otherwise, the pubsub....
import bpy import mathutils def reset_transform(ob): m = mathutils.Matrix() ob.matrix_local = m def func_add_corrective_pose_shape_fast(source, target): result = "" reset_transform(target) # If target object doesn't have Basis shape key, create it. try: num_keys = len( target.data.shape_...
import os import json import math import time import sys, io import shutil import requests import re from UserDict import UserDict from urlparse import urlparse try: from html import escape # python 3.x except ImportError: from cgi import escape # python 2.x scriptpath=os.path.dirname(os.path.realpath(__file_...
from optparse import OptionParser from sys import exit from unittest import TestLoader, TestSuite, TextTestRunner from itools.core import get_abspath from itools.fs import lfs from ikaaro.server import create_server import test_database import test_metadata import test_server from junitxml import JUnitXmlResult test_mo...
from __future__ import with_statement import re from base64 import b64encode from pycurl import FORM_FILE, HTTPHEADER from time import sleep from module.common.json_layer import json_loads from module.network.HTTPRequest import BadHeader from module.network.RequestFactory import getRequest from module.plugins.Hook impo...
from django.db import models from xml.sax.saxutils import escape class Journal(models.Model): id = models.IntegerField(primary_key=True) name = models.CharField(max_length=225) def escaped_name(self): return escape(self.name) class Meta: db_table = u't_journals' class Ion(models.Model): ...
from mitmflib.impacket.dcerpc.v5.ndr import NDRSTRUCT, NDRUniConformantVaryingArray, NDRENUM from mitmflib.impacket.dcerpc.v5.dcomrt import DCOMCALL, DCOMANSWER, IRemUnknown2, PMInterfacePointer, INTERFACE from mitmflib.impacket.dcerpc.v5.dtypes import LPWSTR, ULONG, DWORD, SHORT, GUID from mitmflib.impacket.dcerpc.v5....
from django.core.checks import register, Warning from django.conf import settings @register() def deprecated_settings(app_configs, **kwargs): issues = [] if ('payment_statement' in settings.HOST): issues.append( Warning( "The setting HOST['payment_statement'] is no longer ren...
import os import sys import shutil as module import xml.sax as package correct_mod = os.path.join(sys.prefix, 'shutil.pyc') correct_pkg = os.path.join(sys.prefix, 'xml', 'sax', '__init__.pyc') print ' mod.__file__: %s' % module.__file__ print ' mod.__file__: %s' % correct_mod print ' pkg.__file__: %s' % package.__fi...
import time from task import BackgroundTask from settings import settings from utils import log class TaskQueue(BackgroundTask): """A queue of tasks. A task queue is a queue of other tasks. If you need, for example, to do simple tasks A, B, and C, you can create a TaskQueue and add the simple tasks to i...
from openerp import models, fields, api, _ from openerp.exceptions import except_orm from datetime import datetime import ast import logging _logger = logging.getLogger(__name__) class ClouderSaveRepository(models.Model): """ Define the save.repository object, which represent the repository where the saves ...
"""Navigation (back/forward) indicator displayed in the statusbar.""" from qutebrowser.mainwindow.statusbar import textbase class Backforward(textbase.TextBase): """Shows navigation indicator (if you can go backward and/or forward).""" def __init__(self, parent=None): super().__init__(parent) se...
import analysis_params from cellsim16popsParams_modified_spontan import multicompartment_params from plot_methods import plot_signal_sum, plot_signal_sum_colorplot import plotting_helpers as phlp import h5py import matplotlib.pyplot as plt import os import numpy as np import matplotlib.style matplotlib.style.use('class...
from cloudscape.portal.ui.core.template import PortalTemplate class AppController(PortalTemplate): """ Portal formulas application controller class. """ def __init__(self, parent): super(AppController, self).__init__(parent) # Construct the request map self.map = self._construct_...
import unittest, test.test_support import sys, cStringIO, os import struct class SysModuleTest(unittest.TestCase): def test_original_displayhook(self): import __builtin__ savestdout = sys.stdout out = cStringIO.StringIO() sys.stdout = out dh = sys.__displayhook__ self...
""" The :mod:`peregrine.iqgen.bits.doppler_factory` module contains classes and functions related to object factory for doppler control objects. """ from peregrine.iqgen.bits.doppler_poly import Doppler as PolyDoppler from peregrine.iqgen.bits.doppler_sine import Doppler as SineDoppler class ObjectFactory(object): ''...
__all__ = ['convert_language', 'list_languages', 'LANGUAGES'] def convert_language(language, to_iso, from_iso=None): """Convert a language into another format :param string language: language :param int to_iso: convert language to ISO-639-x :param int from_iso: convert language from ISO-639-x :retur...
import sys BLOCK_SIZE = 8000 number = "{0}: ".format(sys.argv[1]) if len(sys.argv) == 2 else "" stdin = sys.stdin.buffer.read() lines = stdin.decode("utf8", "ignore").splitlines() word = lines[0].rstrip() for filename in lines[1:]: filename = filename.rstrip() previous = "" try: with open(filename, ...
import logging import argparse import os import random import sys import traceback import yaml import numpy as np from numpy.linalg import norm from lerot.query import load_queries from lerot.utils import get_class def run(run_id, experimenter, args): logging.info("run %d starts" % run_id) # initialize log file...
from __future__ import absolute_import, division, print_function import getopt import os.path import inspect import six import configman as cm from configman import ConfigurationManager, Namespace from configman import ConfigFileFutureProxy, environment, command_line from configman.converters import class_converter def...
{ 'name': 'Migration for purchase payment', 'version': '8.0.1.0.0', 'category': 'Tools', 'author': 'Serv. Tecnol. Avanzados - Pedro M. Baeza, ' 'Antiun Ingeniería S.L.', 'website': 'http://www.antiun.com', 'depends': [ 'account_payment_extension', 'purchase', ],...
""" Unit tests for instructor_dashboard.py. """ import ddt import datetime from mock import patch from nose.plugins.attrib import attr from pytz import UTC from django.conf import settings from django.core.urlresolvers import reverse from django.test.client import RequestFactory from django.test.utils import override_s...
""" The Masked Ball """ from ..utils import * class TB_Pilot1: "Mystery Pilot" deathrattle = Summon(CONTROLLER, RandomMinion(cost=COST(SELF))) tags = {GameTag.DEATHRATTLE: True}
""" Template tags for displaying prices correctly. Prefer these filters for rendering prices of products and basket lines or total price of basket, since the will take price display options of current template context into account (see `PriceDisplayOptions`). Especially, they convert prices to correct taxness. There is...
""" This file is used to import class of files in model folder """ from . import model
""" Support executing map reduce tasks. """ from __future__ import absolute_import import gzip import logging import logging.config import os import StringIO from hashlib import md5 import luigi import luigi.contrib.hadoop import luigi.task from luigi import configuration from edx.analytics.tasks.util.manifest import c...
import unittest2 import test_term_count suite = [ test_term_count ]
from weboob.tools.backend import BaseBackend from weboob.capabilities.calendar import ICapCalendarEvent, BaseCalendarEvent, CATEGORIES, TRANSP, STATUS from datetime import datetime, time from .browser import ParisKiwiBrowser __all__ = ['ParisKiwiBackend'] class ParisKiwiBackend(BaseBackend, ICapCalendarEvent): NAME...
import subprocess import json from time import sleep import urllib import base64 import zlib import cPickle from alignak_test import unittest from alignak.http.generic_interface import GenericInterface from alignak.http.receiver_interface import ReceiverInterface from alignak.http.arbiter_interface import ArbiterInterf...
import pytz from openerp import SUPERUSER_ID, workflow from datetime import datetime from dateutil.relativedelta import relativedelta from operator import attrgetter from openerp.tools.safe_eval import safe_eval as eval from openerp.osv import fields, osv from openerp.tools.translate import _ import openerp.addons.deci...
from django.db import models from django.db.models import Count from django.conf import settings from django.utils.translation import ugettext_lazy as _ from django.utils import timezone from django.core.exceptions import ValidationError from django.utils.functional import cached_property from taiga.base.utils.slug imp...
from braces.views import CsrfExemptMixin from braces.views import JSONResponseMixin from django.contrib import messages from django.contrib.auth.decorators import login_required from django.shortcuts import redirect, render from django.utils.decorators import method_decorator from django.views import View from core.loc...
import sys, unittest, math, os import xml.etree.ElementTree as et from JSBSim_utils import CreateFDM, SandBox, CopyAircraftDef class TestAccelerometer(unittest.TestCase): def setUp(self): self.sandbox = SandBox() def tearDown(self): self.sandbox.erase() def AddAccelerometersToAircraft(self, ...