code
stringlengths
1
199k
import shlex import sys import notify2 import os import gi gi.require_version("AppIndicator3", "0.1") from gi.repository import AppIndicator3 gi.require_version("Gtk", "3.0") from gi.repository import Gtk _VERSION = "1.0" _SETTINGS_FILE = os.getenv("HOME") + "/.sshplus" _ABOUT_TXT = """A simple application starter as a...
from __future__ import unicode_literals import django.contrib.postgres.fields.jsonb from django.db import migrations, models import django.db.models.deletion class Migration(migrations.Migration): initial = True dependencies = [ ] operations = [ migrations.CreateModel( name='Company'...
from threading import Thread from time import sleep import random from adapt.intent import IntentBuilder from mycroft.messagebus.message import Message from mycroft.skills.LILACS_core.question_parser import LILACSQuestionParser from mycroft.skills.LILACS_knowledge.knowledgeservice import KnowledgeService from mycroft.s...
from __future__ import unicode_literals from __future__ import print_function from builtins import str as text import traceback import subprocess import wx import wx.lib.filebrowsebutton from ooffice import * class DocumentDialog(wx.Dialog): def __init__(self, parent, modifications): self.modifications = mo...
from ..rerequest import TemplateRequest init_req = TemplateRequest( re = r'(http://)?(www\.)?(?P<domain>ur(play)?)\.se/(?P<req_url>.+)', encode_vars = lambda v: { 'req_url': 'http://%(domain)s.se/%(req_url)s' % v } ) hls = { 'title': 'UR-play', 'url': 'http://urplay.se/', 'feed_url': 'http://urplay.se/rss', ...
class Object: def __init__(self, name): self._name = name @property def name(self): return self._name
from planarprocess import * from gds_helpers import * from itertools import cycle xmin, xmax = -5, 5 layers = gds_cross_section('mypmos.gds', [(0,xmin), (0, xmax)], 'gdsmap.map') ['P-Active-Well', 'Active-Cut', 'N-Well', 'Metal-2', 'Metal-1', 'P-Select', 'N-Select', 'Transistor-Poly', 'Via1'] wafer = Wafer(1., 5., 0, x...
from setuptools import setup, find_packages setup( name = "CyprjToMakefile", version = "0.1", author = "Simon Marchi", author_email = "simon.marchi@polymtl.ca", description = "Generate Makefiles from Cypress cyprj files.", license = "GPLv3", url = "https://github.com/simark/cyprj-to-makefile...
from .submaker import Submaker from inception.tools.signapk import SignApk import shutil import os from inception.constants import InceptionConstants class UpdatezipSubmaker(Submaker): def make(self, updatePkgDir): keys_name = self.getValue("keys") signingKeys = self.getMaker().getConfig().getKeyCon...
PYS_SERVICE_MOD_PRE='pys_' # 模块名称的前缀 PYS_HEAD_LEN=12 # 报文头长度 PYS_MAX_BODY_LEN=10485760 # 最大报文长度
import hashlib, time from django import forms from django.contrib.auth.models import User, Group from django.contrib.auth.forms import UserCreationForm, AuthenticationForm from poetry.models import Poem, Theme from user.models import Contributor my_default_errors = { 'required': 'Еңгізуге міндетті параметр' } error...
from __future__ import unicode_literals from django.db import migrations, models class Migration(migrations.Migration): dependencies = [ ('app', '0054_add_field_user_to_productionform'), ] operations = [ migrations.AddField( model_name='applicationform', name='require...
__all__ = ["speedtest_exceptions", "speedtest"] from . import sendtest
import os import re import sys """ * Perform initial configuration to ensure that the server is set up to work with Burton's format sudo chown -R ubuntu:ubuntu /var/www mkdir -p /var/www/default/public_html mv /var/www/html/index.html /var/www/default/public_html # Ubuntu >=14.04 mv /var/www/index.html ...
from django.conf.urls.defaults import * urlpatterns = patterns('', (r'^(\d+)/$', 'onpsx.gallery.views.index'), (r'^$', 'onpsx.gallery.views.index'), )
import io import os import six import pytest from pytest_pootle.factories import ( LanguageDBFactory, ProjectDBFactory, StoreDBFactory, TranslationProjectFactory) from pytest_pootle.utils import update_store from translate.storage.factory import getclass from django.db.models import Max from django.core.excepti...
import pilas import json from pilas.escena import Base from general import General from individual import Individual class jugadores(Base): def __init__(self): Base.__init__(self) def fondo(self): pilas.fondos.Fondo("data/img/fondos/aplicacion.jpg") def general(self): self.sonido_boton.reproducir() pilas.alm...
import logging logging.basicConfig() from enum import Enum logger = logging.getLogger('loopabull') logger.setLevel(logging.INFO) class Result(Enum): runfinished = 1 runerrored = 2 unrouted = 3 error = 4
from __future__ import absolute_import, division, print_function __metaclass__ = type import traceback REQUESTS_IMP_ERR = None try: import requests HAS_REQUESTS = True except ImportError: REQUESTS_IMP_ERR = traceback.format_exc() HAS_REQUESTS = False PYVMOMI_IMP_ERR = None try: from pyVim import con...
class CachedProperty(object): """ A property that is only computed once per instance and then stores the result in _cached_properties of the object. Source: https://github.com/bottlepy/bottle/commit/fa7733e075da0d790d809aa3d2f53071897e6f76 """ def __init__(self, func): self.__doc__ =...
from vsg.rules import token_prefix from vsg import token lTokens = [] lTokens.append(token.signal_declaration.identifier) class rule_008(token_prefix): ''' This rule checks for valid prefixes on signal identifiers. Default signal prefix is *s\_*. |configuring_prefix_and_suffix_rules_link| **Violatio...
import urllib2, json, os, sys, re def download_asset(path, url): asset_path = None try: file_name = os.path.basename(url) asset_path = os.path.join(path, file_name) if os.path.exists(asset_path): # Skip downloading asset_path = None else: if no...
from setuptools import setup def readme(): with open('README.rst') as f: return f.read() setup(name='MapperTools', packages=['MapperTools'], version='0.1', description='A python 2.7 implementation of Mapper algorithm for Topological Data Analysis', keywords='mapper TDA python', ...
from .meta import classproperty class AtomData(object): # Maximum ASA for each residue # from Miller et al. 1987, JMB 196: 641-656 total_asa = { 'A': 113.0, 'R': 241.0, 'N': 158.0, 'D': 151.0, 'C': 140.0, 'Q': 189.0, 'E': 183.0, 'G': 85.0, ...
import sys import subprocess result = subprocess.Popen('sh test.sh', shell=True) text = result.communicate()[0] sys.exit(result.returncode)
__requires__ = 'setuptools==0.6c11' import sys from pkg_resources import load_entry_point sys.exit( load_entry_point('setuptools==0.6c11', 'console_scripts', 'easy_install')() )
import urllib.request from bs4 import BeautifulSoup import time req_header = {'User-Agent':'Mozilla/5.0 (Windows NT 6.1) AppleWebKit/537.11 (KHTML, like Gecko) Chrome/23.0.1271.64 Safari/537.11', 'Accept':'text/html,application/xhtml+xml,application/xml;q=0.9,*/*;q=0.8', #'Accept-Language': 'en-US,en;q=0.8,zh-Hans-...
import tensorflow as tf import matplotlib.pyplot as plt import math x_node = tf.random_uniform([1], minval=-1, maxval=1, dtype=tf.float32, name='x_node') y_node = tf.random_uniform([1], minval=-1, maxval=1, dtype=tf.float32, name='y_node') times = 5000 hits = 0 pis = [] with tf.Session() as session: ...
import sys import os import configparser import logging log = logging.getLogger(__name__) class gcfg(object): datapath = None cfgpath = None defaults = {'bind_address': '127.0.0.1', 'port': '4242', 'data_dir': '~/.gazee', 'temp_dir': '', 'comic...
import pytest from mathmaker.lib.core.root_calculus import Value from mathmaker.lib.core.base_geometry import Point from mathmaker.lib.core.geometry import Polygon @pytest.fixture def p1(): p1 = Polygon([Point('A', 0.5, 0.5), Point('B', 3, 1), Point('C', 3.2, 4), ...
from __future__ import absolute_import import re import abc class AddressbookError(Exception): pass class AddressBook(object): """can look up email addresses and realnames for contacts. .. note:: This is an abstract class that leaves :meth:`get_contacts` unspecified. See :class:`AbookAddress...
import numpy as np from scipy.signal import medfilt import manager.operations.method as method from manager.operations.methodsteps.confirmation import Confirmation from manager.exceptions import VoltPyNotAllowed class MedianFilter(method.ProcessingMethod): can_be_applied = True _steps = [ { ...
""" Django settings for lwc project. Generated by 'django-admin startproject' using Django 1.9.7. For more information on this file, see https://docs.djangoproject.com/en/1.9/topics/settings/ For the full list of settings and their values, see https://docs.djangoproject.com/en/1.9/ref/settings/ """ import os BASE_DIR =...
import os import sys if __name__ == "__main__": os.environ.setdefault("DJANGO_SETTINGS_MODULE", "MyGarden.settings") try: from django.core.management import execute_from_command_line except ImportError: # The above import may fail for some other reason. Ensure that the # issue is rea...
from osweb.projects.ManageProject import ManageProject from osweb.projects.projects_data import ProjectsData
def test_generators(): import os import tempfile from fusesoc.config import Config from fusesoc.coremanager import CoreManager from fusesoc.edalizer import Edalizer from fusesoc.librarymanager import Library from fusesoc.vlnv import Vlnv tests_dir = os.path.dirname(__file__) cores_di...
from bollinger import bands, plot, strategies import argparse parser = argparse.ArgumentParser(description="plots bollinger bands or suggests investments", epilog="example: bolly.py plot AMZN FB") parser.add_argument("action", metavar="ACTION", choices=["plot", "suggest"], help="either plot or suggest") parser.add_argu...
import sys import csv from itertools import izip VERSION = (0, 9, 4) __version__ = ".".join(map(str, VERSION)) pass_throughs = [ 'register_dialect', 'unregister_dialect', 'get_dialect', 'list_dialects', 'field_size_limit', 'Dialect', 'excel', 'excel_tab', 'Sniffer', 'QUOTE_ALL', ...
import os,re,sys,pprint,shutil from pathlib import Path PACKAGES_DIR = "../packages" def errorExit(msg): print(msg) sys.exit(1) def isPathDisabled(path): for part in path.parts: if part.lower().startswith("_disabled"): return True return False depsFolder = Path("_deps_split") prodFolder = Path("_prods_split") ...
from unittest import mock from configman.dotdict import DotDict from socorro.lib.task_manager import TaskManager, default_task_func class TestTaskManager: def test_constuctor1(self): config = DotDict() config.quit_on_empty_queue = False tm = TaskManager(config) assert tm.config == co...
import argparse import datetime import os import re def version_str(args): return str(args.major) + "." + str(args.minor) + "." + str(args.maintenance) def file_process(name, rule, args): print("--- Processing " + os.path.basename(name)) with open(name) as source: data = rule(source.read(), args) ...
import json import mock from django.test import TestCase from django.core.urlresolvers import reverse class TestAPI(TestCase): @mock.patch('ldap.initialize') def test_exists(self, mocked_initialize): connection = mock.MagicMock() mocked_initialize.return_value = connection url = reverse(...
""" Monitor the WR31 door enclosure """ import time import sys import sarcli import idigidata def millisecond_timestamp(): """ Return a timestamp, in milliseconds :return ms_timestamp: int, Timestamp in milliseconds """ ms_timestamp = int(time.time() * 1000) return ms_timestamp def cli_command(c...
import copy import logging import os import time from datetime import datetime from hashlib import sha1 import newrelic.agent from django.core.exceptions import ObjectDoesNotExist from django.db.utils import IntegrityError from past.builtins import long from treeherder.etl.artifact import (serialize_artifact_json_blobs...
import os import re import shutil import zipfile from . import Collection from .hooks import runHook from .lang import _ from .utils import ids2str, json, splitFields class Exporter(object): def __init__(self, col, did=None): self.col = col self.did = did def exportInto(self, path): self...
from . import res_partner
{ 'name': "MIS Builder Cost Center Filter", 'version': '8.0.1.0.0', 'category': 'Reporting', 'summary': """ Add Cost Center filters to MIS Reports """, 'author': 'ICTSTUDIO,' 'ACSONE SA/NV,' 'Odoo Community Association (OCA)', 'website': "http://www.ictstudio....
__license__ = "GNU Affero General Public License, Ver.3" __author__ = "Pablo Alvarez de Sotomayor Posadillo" import os import os.path import subprocess import httplib from datetime import datetime from django import forms from django.http import HttpResponse, HttpResponseRedirect from django.template import RequestCont...
from pts.modeling.core.environment import load_modeling_environment_cwd from pts.modeling.config.component import definition environment = load_modeling_environment_cwd() runs = environment.fitting_runs properties = ["representation", "filters", "ranges", "genetic", "grid", "units", "types"] definition = definition.cop...
import os from importlib import import_module from django.core.management.base import BaseCommand from django.utils import translation from django.conf import settings def get_modules(): path = os.path.join(settings.BASE_DIR, 'utils', 'upgrade') root, dirs, files = next(os.walk(path)) return files class Com...
from .naive import StratNaive import random import numpy as np class BetaDecreaseStrat(StratNaive): def __init__(self, vu_cfg, time_scale=0.9, **strat_cfg2): StratNaive.__init__(self,vu_cfg=vu_cfg, **strat_cfg2) self.time_scale = time_scale def update_speaker(self, ms, w, mh, voc, mem, bool_succ, context=[]): s...
from django.db import connection from django.conf import settings from django.utils import timezone from taiga.projects.history import services as history_service from taiga.projects.history.choices import HistoryType from . import tasks def _get_project_webhooks(project): webhooks = [] for webhook in project.w...
''' ''' import unittest, copy from testRoot import RootClass from noink.user_db import UserDB from noink.entry_db import EntryDB class AddEntry(RootClass): def test_AddEntry(self): userDB = UserDB() entryDB = EntryDB() u = userDB.add("jontest", "pass", "Jon Q. Testuser") title = 'Lit...
from unittest import TestCase from micall.drivers.run_info import RunInfo from micall.drivers.sample import Sample from micall.drivers.sample_group import SampleGroup class RunInfoTest(TestCase): def test_get_all_samples(self): expected_fastq_paths = ['1a_R1_001.fastq', '1b_R...
import os import arrow import magic import hashlib import logging import requests from io import BytesIO from PIL import Image from flask import json from .image import get_meta from .video import get_meta as video_meta import base64 from superdesk.errors import SuperdeskApiError logger = logging.getLogger(__name__) de...
""" Copyright 2012 Paul Willworth <ioscode@gmail.com> This file is part of Galaxy Harvester. Galaxy Harvester is free software: you can redistribute it and/or modify it under the terms of the GNU Affero General Public License as published by the Free Software Foundation, either version 3 of the License, or (at yo...
import os import sys import nose from subprocess import CalledProcessError, check_output as run from functools import partial GJSLINT_COMMAND = 'gjslint' GJSLINT_OPTIONS = ['--strict'] JS_BASE_FOLDER = os.path.join('skylines', 'public', 'js') JS_FILES = [ 'baro.js', 'fix-table.js', 'flight.js', 'general...
from . import sale_order from . import purchase_order
""" Learning Tools Interoperability (LTI) module. Resources --------- Theoretical background and detailed specifications of LTI can be found on: http://www.imsglobal.org/LTI/v1p1p1/ltiIMGv1p1p1.html This module is based on the version 1.1.1 of the LTI specifications by the IMS Global authority. For authentication, ...
from datetime import datetime, date import pytest from pytz import UTC from uber.config import c from uber.models import Attendee, Session from uber.site_sections import summary @pytest.fixture def birthdays(): dates = [ date(1964, 12, 30), date(1964, 12, 31), date(1964, 1, 1), date(...
from django.template import Library, Node, TemplateSyntaxError, Variable from django.conf import settings from django.core import urlresolvers import hashlib import re register = Library() class ViewNode(Node): def __init__(self, parser, token): self.args = [] self.kwargs = {} tokens = token...
import errno import os import signal import socket import StringIO import sys def grim_reaper(signum, frame): while True: try: pid, status = os.waitpid( -1, # Wait for any child process os.WNOHANG # Do not block and return EWOULDBLOCK error ...
from . import models from . import wizards
{ 'name': "Better validation for Attendance", 'summary': """ Short (1 phrase/line) summary of the module's purpose, used as subtitle on modules listing or apps.openerp.com""", 'description': """ Long description of module's purpose """, 'author': "Jörn Mankiewicz", 'websi...
import os import time import sys FOLDERPATH = sys.argv[1] walk = os.walk(FOLDERPATH) FSEVENT = "delete" for item in walk: FILEPATHPREFIX = item[0] + "\\" for song in item[2]: if song.endswith(".mp3"): FILEPATH = "%s%s" % (FILEPATHPREFIX, song) os.system('python script.py "' + so...
from tests.mock_navitia import navitia_response response = navitia_response.NavitiaResponse() response.queries = [ "vehicle_journeys/?filter=vehicle_journey.has_code(source, Code-orders)&since=20120615T120000Z&until=20120615T190000Z&data_freshness=base_schedule&depth=2" # resquest time is UTC -> 12:00 is 8:00 l...
import argparse import socket import time import yarp EMSG_YARP_NOT_FOUND = "Could not connect to the yarp server. Try running 'yarp detect'." EMSG_ROBOT_NOT_FOUND = 'Could not connect to the robot at %s:%s' class EZModule(yarp.RFModule): """ The EZBModule class provides a base class for developing modules for the...
import os from xbrowse_server import xbrowse_controls from django.core.management.base import BaseCommand from xbrowse_server.base.models import Project, Individual, VCFFile from xbrowse_server import sample_management class Command(BaseCommand): def add_arguments(self, parser): parser.add_argument('args', ...
from __future__ import print_function import time from flask import Flask, session, url_for from flask_debugtoolbar import DebugToolbarExtension from weblablib import WebLab, requires_active, weblab_user, poll app = Flask(__name__) app.config['SECRET_KEY'] = 'something random' # e.g., run: os.urandom(32) and put the ou...
""" Class_LabExperimBased provides functionalities for data handling of data obtained in lab experiments in the field of (waste)water treatment. Copyright (C) 2016 Chaim De Mulder This program is free software: you can redistribute it and/or modify it under the terms of the GNU Affero General Public License as publishe...
import source_navigation_steps import functional_test class TestSourceInterfaceNotFound( functional_test.FunctionalTest, source_navigation_steps.SourceNavigationStepsMixin): def test_not_found(self): self._source_not_found()
from common.log import logUtils as log from constants import clientPackets from constants import serverPackets def handle(userToken, packetData): # get token data username = userToken.username # Read packet data packetData = clientPackets.setAwayMessage(packetData) # Set token away message userToken.awayMessage =...
""" WSGI config for tumuli project. It exposes the WSGI callable as a module-level variable named ``application``. For more information on this file, see https://docs.djangoproject.com/en/2.0/howto/deployment/wsgi/ """ import os from django.core.wsgi import get_wsgi_application os.environ.setdefault("DJANGO_SETTINGS_MO...
"""course_discovery URL Configuration The `urlpatterns` list routes URLs to views. For more information please see: https://docs.djangoproject.com/en/1.8/topics/http/urls/ Examples: Function views 1. Add an import: from my_app import views 2. Add a URL to urlpatterns: url(r'^$', views.home, name='home') C...
from odoo.tests.common import TransactionCase class TestProjectDuplicateSubtask(TransactionCase): def setUp(self): super().setUp() self.project1 = self.env["project.project"].create({"name": "Project 1"}) self.task1 = self.env["project.task"].create( {"name": "name1", "project_id...
from django.conf.urls import url from .decorators import captcha_required from captcha import views urlpatterns = [ url(r'^new/', views.new_captcha, name='new_captcha'), ]
{ "name": "Romania - Invoice Report ", "summary": "Localizare Terrabit", "version": "14.0.3.0.3", "author": "Dorin Hongu," "Odoo Community Association (OCA)", "website": "https://github.com/OCA/l10n-romania", "license": "AGPL-3", "category": "Generic Modules", "depends": [ "base"...
from odoo import fields, models, api from datetime import datetime class OutletLoss(models.Model): _name = 'outlet.loss' @api.multi @api.depends('qty', 'price_outlet', 'price_unit') def _get_outlet_loss(self): for loss in self: loss.total_lost = loss.qty*(loss.price_outlet-loss.price...
import tempfile from datetime import datetime import flask_testing from flask import url_for import iis from iis.models import User from iis.extensions import db class BaseTestCase(flask_testing.TestCase): DB_FILE = tempfile.mkstemp() SQLALCHEMY_DATABASE_URI = "sqlite:///" + DB_FILE[1] LOGGING = {"version":...
import os from setuptools import setup README = open(os.path.join(os.path.dirname(__file__), 'README.rst')).read() os.chdir(os.path.normpath(os.path.join(os.path.abspath(__file__), os.pardir))) setup( name='django-isegory', version='0.1', packages=['isegory'], include_package_data=True, license='AGP...
import uuid from bottle import Bottle, request, response, abort import bcrypt from recall.data import whitelist, blacklist from recall import convenience as c from recall import plugins, jobs, messages app = Bottle() app.install(plugins.exceptions) app.install(plugins.ppjson) app.install(plugins.auth) app.install(plugi...
from collections import defaultdict from fs.errors import ResourceNotFoundError import logging import inspect import re from path import path from django.http import Http404 from django.conf import settings from .module_render import get_module from xmodule.course_module import CourseDescriptor from xmodule.modulestore...
import io import pytest import databot import pandas as pd from databot.db.utils import Row from databot.exporters.utils import flatten_nested_lists, flatten_nested_dicts, get_level_keys, flatten, sort_fields from databot.exporters import jsonl from databot.exporters import pandas @pytest.fixture def data(): return...
from django.contrib.auth.decorators import login_required from django.core.exceptions import PermissionDenied from django.shortcuts import get_object_or_404, render from base.models.person import Person from base.views.learning_units.common import get_learning_unit_identification_context @login_required def learning_un...
""" Views for contract feature """ import logging from edxmako.shortcuts import render_to_response from django.contrib.auth.models import User from django.contrib.auth import authenticate, login from django.shortcuts import redirect from django.core.urlresolvers import reverse from biz.djangoapps.ga_manager.models impo...
import os @VOLT.Command(description = 'Build the Voter application and catalog.', options = VOLT.BooleanOption('-C', '--conditional', 'conditional', 'only build when the catalog file is missing')) def build(runner): if not runner.opts.conditional or not os.pa...
from openerp import fields, models, api, _ from openerp.exceptions import Warning import logging _logger = logging.getLogger(__name__) class afip_incoterm(models.Model): _name = 'afip.incoterm' _description = 'Afip Incoterm' afip_code = fields.Char( 'Code', required=True) name = fields.Char( ...
"""Add is_loud and pronouns columns to PanelApplicant Revision ID: bba880ef5bbd Revises: 8f8419ebcf27 Create Date: 2019-07-20 02:57:17.794469 """ revision = 'bba880ef5bbd' down_revision = '8f8419ebcf27' branch_labels = None depends_on = None from alembic import op import sqlalchemy as sa try: is_sqlite = op.get_con...
def keysetter(key): if not isinstance(key, str): raise TypeError('key name must be a string') resolve = key.split('.') head, last = tuple(resolve[:-1]), resolve[-1] def g(obj,value): for key in head : obj = obj[key] obj[last] = value return g def keygetter(key): ...
from odoo import api, fields, models class EventType(models.Model): _inherit = "event.type" community_menu = fields.Boolean( "Community Menu", compute="_compute_community_menu", readonly=False, store=True, help="Display community tab on website") @api.depends('website_menu') def ...
import pytest import json from django.urls import reverse from .. import factories as f pytestmark = pytest.mark.django_db def test_watch_task(client): user = f.UserFactory.create() task = f.create_task(owner=user, milestone=None) f.MembershipFactory.create(project=task.project, user=user, is_admin=True) ...
import subprocess def release(): subprocess.call(["python3", "setup.py", "sdist", "upload"])
from . import BaseWordChoice class WordPreference(BaseWordChoice): def pick_w(self,m,voc,mem,context=[]): if m in voc.get_known_meanings(): if m in list(mem['prefered words'].keys()): w = mem['prefered words'][m] if w not in voc.get_known_words(m=m): w = voc.get_random_known_w(m=m) else: w = v...
from __future__ import unicode_literals from django.db import migrations, models class Migration(migrations.Migration): dependencies = [ ('maposmatic', '0004_maprenderingjob_track'), ] operations = [ migrations.AlterField( model_name='maprenderingjob', name='track', ...
""" Base test case for the course API views. """ from django.core.urlresolvers import reverse from rest_framework.test import APITestCase from lms.djangoapps.courseware.tests.factories import StaffFactory from student.tests.factories import UserFactory from xmodule.modulestore.tests.django_utils import TEST_DATA_SPLIT_...
from django.contrib.auth.models import User, UserManager from django.utils.translation import ugettext_lazy as _ from django.db import models from django.db.models import signals, Avg, Q from datetime import date import os from django.conf import settings def create_profile_for_user(sender, **kwargs): ''' This ...
{ 'name': 'Products Management Group', 'version': '13.0.1.0.0', 'category': 'base.module_category_knowledge_management', 'author': 'ADHOC SA', 'website': 'www.adhoc.com.ar', 'license': 'AGPL-3', 'depends': [ 'sale', ], 'data': [ 'security/product_management_security.x...
from __future__ import absolute_import from math import isinf, isnan from warnings import warn NOT_MASS_BALANCED_TERMS = {"SBO:0000627", # EXCHANGE "SBO:0000628", # DEMAND "SBO:0000629", # BIOMASS "SBO:0000631", # PSEUDOREACTION ...
import math, os from bup import _helpers, helpers from bup.helpers import sc_page_size _fmincore = getattr(helpers, 'fmincore', None) BLOB_MAX = 8192*4 # 8192 is the "typical" blob size for bupsplit BLOB_READ_SIZE = 1024*1024 MAX_PER_TREE = 256 progress_callback = None fanout = 16 GIT_MODE_FILE = 0100644 GIT_MODE_TRE...
"""Test of ARIA horizontal sliders using Firefox.""" from macaroon.playback import * import utils sequence = MacroSequence() sequence.append(PauseAction(10000)) sequence.append(KeyComboAction("Tab")) sequence.append(KeyComboAction("Tab")) sequence.append(utils.StartRecordingAction()) sequence.append(KeyComboAction("Tab...