gt
stringclasses
1 value
context
stringlengths
2.49k
119k
#!/usr/bin/env python # -*- coding: utf-8 -*- def connect_gridfs_mongodb(hostname=None,db_name=None): import pymongo, gridfs if not hostname: hostname='127.0.0.1' try: mongo = pymongo.MongoClient(hostname, waitQueueMultiple=10) except pymongo.errors.ConnectionFailure: hostname ...
# coding=utf-8 # -------------------------------------------------------------------------- # Copyright (c) Microsoft Corporation. All rights reserved. # Licensed under the MIT License. See License.txt in the project root for license information. # Code generated by Microsoft (R) AutoRest Code Generator. # Changes may ...
# commit.py # Copyright (C) 2008, 2009 Michael Trier ([email protected]) and contributors # # This module is part of GitPython and is released under # the BSD License: http://www.opensource.org/licenses/bsd-license.php from git.util import ( Actor, Iterable, Stats, ) from git.diff import Di...
import unittest import numpy as np from pycqed.instrument_drivers.meta_instrument import kernel_object as ko from pycqed.measurement import kernel_functions as kf from qcodes import station """ Kernel TODO's: - Rename distortions class - path for saving the kernels should not be the notebook directory - test sav...
# Licensed to the StackStorm, Inc ('StackStorm') under one or more # contributor license agreements. See the NOTICE file distributed with # this work for additional information regarding copyright ownership. # The ASF licenses this file to You under the Apache License, Version 2.0 # (the "License"); you may not use th...
# 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 agreed to in writing, software # distributed unde...
# (C) Datadog, Inc. 2010-2016 # (C) Luca Cipriani <[email protected]> 2013 # All rights reserved # Licensed under Simplified BSD License (see LICENSE) # stdlib from collections import defaultdict import time # 3p import psutil # project from checks import AgentCheck from config import _is_affirmative from utils.platform im...
""" These managers define helper methods for accessing the database from Comm system components. """ from __future__ import print_function from django.db.models import Q from evennia.typeclasses.managers import (TypedObjectManager, TypeclassManager) from evennia.utils import logger _GA = object.__getattribute__ _Acc...
from django.conf import settings from django.http import * from django.shortcuts import render_to_response from django.core.urlresolvers import reverse from django.contrib.auth import logout from django.core.context_processors import csrf from django.template import RequestContext from profile.models import * from po...
# -*- coding: utf-8 -*- # Copyright (c) 2015, Vispy Development Team. # Distributed under the (new) BSD License. See LICENSE.txt for more info. from __future__ import division import weakref from .. import gloo from .. import app from .node import Node from ..visuals.transforms import STTransform, TransformCache fro...
# Copyright 2017 Google LLC # # 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 agreed to in writing, s...
from __future__ import annotations import numbers import numpy as np from numpy.lib.mixins import NDArrayOperatorsMixin from pandas._libs import lib from pandas._typing import ( Dtype, NpDtype, Scalar, npt, ) from pandas.compat.numpy import function as nv from pandas.core.dtypes.cast import construc...
from __future__ import absolute_import, print_function import cython from .. import __version__ import re, os, sys, time from glob import iglob try: import gzip gzip_open = gzip.open gzip_ext = '.gz' except ImportError: gzip_open = open gzip_ext = '' import shutil import subprocess try: impo...
# This code is original from jsmin by Douglas Crockford, it was translated to # Python by Baruch Even. It was rewritten by Dave St.Germain for speed. # # The MIT License (MIT) # # Copyright (c) 2013 Dave St.Germain # # Permission is hereby granted, free of charge, to any person obtaining a copy # of this software and...
from __future__ import absolute_import import logging import os import re import shutil import sys import tempfile import traceback import warnings import zipfile from distutils import sysconfig from distutils.util import change_root from email.parser import FeedParser from pip._vendor import pkg_resources, six from...
""" Copyright 2017 Pani Networks 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 agreed to in writing, soft...
# Copyright (C) 2003, 2004 Nominum, Inc. # # Permission to use, copy, modify, and distribute this software and its # documentation for any purpose with or without fee is hereby granted, # provided that the above copyright notice and this permission notice # appear in all copies. # # THE SOFTWARE IS PROVIDED "AS IS" AND...
import ast from os import path from copy import deepcopy from operator import lt, gt from itertools import takewhile import fnmatch from .code_util import DocStringInheritor __all__ = ['keywords', 'EvaluateQueries', 'eval_queries', 'queries_syntax_check', 'queries_preprocess'] keywords = [ 'and', 'or', '...
import numpy as np from .base import _fit_liblinear, BaseSVC, BaseLibSVM from ..base import BaseEstimator, RegressorMixin from ..linear_model.base import LinearClassifierMixin, SparseCoefMixin, \ LinearModel from ..feature_selection.from_model import _LearntSelectorMixin from ..utils import check_X_y class Linea...
# Copyright 2015 The Chromium Authors. All rights reserved. # Use of this source code is governed by a BSD-style license that can be # found in the LICENSE file. """Miscellaneous utility functions.""" import contextlib import datetime import errno import json import os import shutil import subprocess import sys impo...
# -*- coding: utf-8 -* #py.test --cov remdups --cov-report term-missing #This succeeds on Windows with c:\msys64\usr\bin in %PATH% and #mv C:\Windows\System32\find.exe C:\Windows\System32\findw.exe #for .sh, .bat, .py #On linux .bat cannot be executed import os import tempfile import subprocess import shutil from it...
# vim: tabstop=4 shiftwidth=4 softtabstop=4 # Copyright 2011 United States Government as represented by the # Administrator of the National Aeronautics and Space Administration. # All Rights Reserved. # Copyright (c) 2011 Citrix Systems, Inc. # # Licensed under the Apache License, Version 2.0 (the "License"); you m...
# Copyright 2017 The Chromium Authors. All rights reserved. # Use of this source code is governed by a BSD-style license that can be # found in the LICENSE file. import logging class StoryExpectations(object): """An object that contains disabling expectations for benchmarks and stories. Example Usage: class F...
from netbox_api.api.protocol import RequestHandler from netbox_api.model import * class NetboxClient(object): def __init__(self, host, port, token, scheme, verify=None): # Request handling self._request_handler = RequestHandler(host, port, token, scheme, verify) # Client parts sel...
import json import copy import logging import os import sys from lxml import etree from xblock.core import XML_NAMESPACES from xblock.fields import Dict, Scope, ScopeIds from xblock.runtime import KvsFieldData from xmodule.x_module import XModuleDescriptor, DEPRECATION_VSCOMPAT_EVENT from xmodule.modulestore.inheritan...
import numpy as np import os import warnings import random import sys import logging import scipy from itertools import product, izip, chain, cycle from collections import defaultdict from functools import partial from pymaptools.iter import izip_with_cycles, isiterable, take from pymaptools.containers import labels_to...
from unittest import mock import pytest from opentrons.protocols.parse import parse from opentrons.protocols.execution.execute_json_v4 import ( dispatch_json, _engage_magnet, _disengage_magnet, load_modules_from_json, _temperature_module_set_temp, _temperature_module_deactivate, _temperature_module_awai...
""" Utilities for determining application-specific dirs. See <https://github.com/platformdirs/platformdirs> for details and usage. """ from __future__ import annotations import importlib import os import sys from pathlib import Path from typing import TYPE_CHECKING if TYPE_CHECKING: from pip._vendor.typing_extens...
# Copyright 2016 Cisco Systems, Inc. All rights reserved. # # 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 requir...
import ctypes import pymem.ressources.structure dll = ctypes.WinDLL('kernel32.dll') #: Opens an existing local process object. #: #: https://msdn.microsoft.com/en-us/library/windows/desktop/ms684320%28v=vs.85%29.aspx OpenProcess = dll.OpenProcess OpenProcess.restype = ctypes.c_ulonglong #: Terminates the specified ...
from __future__ import unicode_literals # encoding: utf-8 import datetime from south.db import db from south.v2 import SchemaMigration from django.db import models class Migration(SchemaMigration): depends_on = [ ("pages", "0001_initial"), ] def forwards(self, orm): # Adding model 'Produ...
# DExTer : Debugging Experience Tester # ~~~~~~ ~ ~~ ~ ~~ # # Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions. # See https://llvm.org/LICENSE.txt for license information. # SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception """Test tool.""" import math import os im...
#!/usr/bin/python # -*- coding: utf-8 -*- ################################################################################################## # module for the eigenvalue problem # Copyright 2013 Timo Hartmann (thartmann15 at gmail.com) # # todo: # - implement balancing # - agressive early deflation # ######...
# MySQL Connector/Python - MySQL driver written in Python. """Django database Backend using MySQL Connector/Python This Django database backend is heavily based on the MySQL backend coming with Django. Changes include: * Support for microseconds (MySQL 5.6.3 and later) * Using INFORMATION_SCHEMA where possible * Usi...
import logging import unittest from mock import MagicMock from crutch.core.runner import Runner, Runners from crutch.core.runtime import RuntimeEnvironment from crutch.core.features.basics import Feature, FeatureCategory def create_runtime(runner): return RuntimeEnvironment(Runners({'runner': runner})) def create...
#----------------------------------------------------------------------------- # Copyright (c) 2012 - 2022, Anaconda, Inc., and Bokeh Contributors. # All rights reserved. # # The full license is in the file LICENSE.txt, distributed with this software. #-------------------------------------------------------------------...
__author__ = 'matthi' import operator import copy from collections import deque from pyspeechgrammar import model from pyspeechgrammar.fst import model as fst_model class FSTPart: def __init__(self): self.input_arcs = [] self.output_arcs = [] self.is_optional = False class FSTSerial...
# 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 agreed to in writing, software # distributed unde...
# coding=utf-8 # -------------------------------------------------------------------------- # Copyright (c) Microsoft Corporation. All rights reserved. # Licensed under the MIT License. See License.txt in the project root for license information. # Code generated by Microsoft (R) AutoRest Code Generator. # Changes may ...
# Copyright (c) 2005-2010 Resolver Systems Ltd, PythonAnywhere LLP # See LICENSE.md # try: import unittest2 as unittest except ImportError: import unittest from sheet.parser.fl_cell_reference_parse_node import FLCellReferenceParseNode from sheet.parser.fl_cell_range_parse_node import FLCellRangeParseNode from...
# Copyright 2015 The TensorFlow Authors. All Rights Reserved. # # 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 applica...
from sfepy.base.base import * from sfepy.solvers.solvers import EigenvalueSolver ## # c: 03.03.2008, r: 03.03.2008 class SymeigEigenvalueSolver( EigenvalueSolver ): name = 'eig.symeig' ## # c: 03.03.2008, r: 03.03.2008 def __init__( self, conf, **kwargs ): EigenvalueSolver.__init__( self, ...
""" DontCamp.com Administrative Support System v. 1.3 written by: [email protected] Revision: $Revision: 1.30 $ Changelog: 1.1.2: * changed the ass class layout significantly to make better use of a branched object structure * broke logic into more functions to make extensions both easier to write and m...
from calendar import timegm from datetime import datetime, timedelta from requests import Session import pyfilemail as pm from pyfilemail import logger, login_required, load_config, get_configfile from urls import get_URL from transfer import Transfer from errors import hellraiser, FMBaseError class User(object): ...
"""Module with main classes related to Interfaces.""" import json import logging from enum import IntEnum from pyof.v0x01.common.phy_port import PortFeatures as PortFeatures01 from pyof.v0x04.common.port import PortFeatures as PortFeatures04 from kytos.core.common import GenericEntity from kytos.core.helpers import n...
#!/usr/bin/python # Copyright 2016 Tomas Karasek <[email protected]> # GNU General Public License v3.0+ (see COPYING or https://www.gnu.org/licenses/gpl-3.0.txt) from __future__ import absolute_import, division, print_function __metaclass__ = type ANSIBLE_METADATA = {'metadata_version': '1.1', ...
# Copyright 2016 The TensorFlow Authors. All Rights Reserved. # # 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 ...
#!/usr/bin/env python # encoding: utf-8 import os from modularodm import Q from modularodm.exceptions import ModularOdmException from framework.auth.core import User from website import settings from website.app import init_app from website.conferences.model import Conference def main(): init_app(set_backends...
from sympy import Symbol, exp, Integer, Real, sin, cos, log, Poly, Lambda, \ Function, I, S, sqrt, srepr, Rational from sympy.abc import x, y from sympy.core.sympify import sympify, _sympify, SympifyError from sympy.core.decorators import _sympifyit from sympy.utilities.pytest import raises def test_439(): ...
# Copyright (c) 2016 EMC Corporation. # All Rights Reserved. # # 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 applica...
# Copyright 2016 The TensorFlow Authors. All Rights Reserved. # # 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 applica...
import time import socket import gevent import numpy as np import sys import cv2 from load_config import LoadConfig import cvlib conf = LoadConfig("config.toml").config """ def match(): img = cv2.imread("box_in_scene2.png")#sys.argv[1]) temp = cv2.imread("box4.png")#sys.argv[2]) try: dist = ...
from typing import Optional, Union, Dict import os import os.path as osp import shutil from ogb.utils import smiles2graph from ogb.utils.url import decide_download, download_url, extract_zip import pandas as pd import numpy as np from tqdm import tqdm import torch class PCQM4MDataset(object): def __init__(self,...
# Copyright 2018 The TensorFlow Authors. All Rights Reserved. # # 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 applica...
# Licensed under a 3-clause BSD style license - see LICENSE.rst """ This module tests model set evaluation and fitting for some common use cases. """ # pylint: disable=invalid-name import pytest import numpy as np from numpy.testing import assert_allclose from astropy.modeling.models import (Polynomial1D, Polynomial2D...
from __future__ import print_function import os, sys, ctypes import re try: import urllib2 import Tkinter import tkFileDialog except ImportError: import urllib.request as urllib2 import tkinter as Tkinter import tkinter.filedialog as tkFileDialog default_folder = "~" class init: @staticme...
import keras.backend as K import logging import numpy as np from aes.layers import MeanOverTime from keras.layers import Activation, Dense, Dropout, Input from keras.layers.embeddings import Embedding from keras.models import Model logger = logging.getLogger(__name__) class Models: def __init__(self, prompt_id, ...
# This file is part of gorm, an object relational mapper for versioned graphs. # Copyright (C) 2014 Zachary Spector. from collections import MutableMapping, MutableSequence from json import dumps, loads from copy import deepcopy def enc_tuple(o): """Return the object, converted to a form that will preserve the ...
from copy import deepcopy import unittest from tests import common from romaine.parser.exceptions import UnclosedPythonishString class TestMultilineParser(unittest.TestCase): """ Test multi-line gherkin parser functionality of romaine's core. """ def setUp(self): """ Prepare t...
# -*- coding: utf-8 -*- # Copyright 2014 OpenMarket Ltd # # 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 la...
# -*- coding: utf-8 -*- """ werkzeug.utils ~~~~~~~~~~~~~~ This module implements various utilities for WSGI applications. Most of them are used by the request and response wrappers but especially for middleware development it makes sense to use them without the wrappers. :copyright: (c) 2013 ...
#!/usr/bin/env python3 # -*- coding: utf-8 -*- """ main_window The main window and system tray for the commotion_client pyqt GUI. Key componenets handled within: * exiting/hiding the application * Creating the main window and systemTray icon. """ #Standard Library Imports import logging #PyQt imports from PyQt4 ...
# General purpose utilities for PyBERT. # # Original author: David Banas <[email protected]> # Original date: September 27, 2014 (Copied from `pybert_cntrl.py'.) # # Copyright (c) 2014 David Banas; all rights reserved World wide. from numpy import sign, sin, pi, array, linspace, float, zeros, ones, repeat...
# (c) Copyright 2015 Hewlett Packard Enterprise Development LP # # 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 re...
from django.db import connections from django.db.models.query import QuerySet, ValuesQuerySet, ValuesListQuerySet from django.contrib.gis import memoryview from django.contrib.gis.db.models import aggregates from django.contrib.gis.db.models.fields import get_srid_info, PointField, LineStringField from django.contrib....
# -*- coding: utf-8 -*- """ Class for reading/writing analog signals in a text file. Each columns represents a AnalogSignal. All AnalogSignal have the same sampling rate. Covers many case when part of a file can be viewed as a CSV format. Supported : Read/Write Author: sgarcia """ import csv import os import numpy...
# TODO: Move this rules to model or be smarter import sys import inspect from models import TopologyParameterCustomValue from system.models import Configuration def configuration_factory(databaseinfra, memory_size): for name, obj in inspect.getmembers(sys.modules[__name__]): if inspect.isclass(obj) and '_...
# HTTP response (JSON) parser import json from application import * from http_req import * from url_gen import * from datetime import datetime class AbstractParser(object): def __init__(self, server): self.server = server self.url_gen = UrlGen() self.requester = HttpRequester() def pa...
#!/usr/bin/env python # -*- encoding: utf-8 -*- # CREATED:2015-02-02 10:09:43 by Brian McFee <[email protected]> '''Time stretching deformations''' import jams import librosa import pyrubberband as pyrb import numpy as np import pandas as pd from ..base import BaseTransformer __all__ = ['TimeStretch', '...
""" OOBHandler - Out Of Band Handler The OOBHandler.execute_cmd is called by the sessionhandler when it detects an `oob` keyword in the outgoing data (usually called via `msg(oob=...)` How this works is that the handler executes an oobfunction, which is defined in a user-supplied module. This function can then make u...
#!/usr/bin/python # Copyright 2008, Google Inc. # All rights reserved. # # Redistribution and use in source and binary forms, with or without # modification, are permitted provided that the following conditions are # met: # # * Redistributions of source code must retain the above copyright # notice, this list of co...
"""Tests for acme.challenges.""" import unittest import mock import OpenSSL import requests from six.moves.urllib import parse as urllib_parse # pylint: disable=import-error from acme import errors from acme import jose from acme import other from acme import test_util CERT = test_util.load_comparable_cert('cert....
# Copyright 2020 The StackStorm Authors. # Copyright 2019 Extreme Networks, 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 ...
from __future__ import unicode_literals from django.test import TestCase from django.utils import six from .models import Person, FunPerson, Book, Car, PersonManager, PublishedBookManager class CustomManagerTests(TestCase): def setUp(self): self.b1 = Book.published_objects.create( title="How...
# Copyright (c) 2010-2012 OpenStack Foundation # # 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 agree...
# -*- coding: utf-8 -*- from ast import literal_eval from warnings import warn from typing import ( Tuple, List, Set ) from PyQt5.QtCore import ( QPointF, QRectF, Qt ) from PyQt5.QtGui import ( QKeyEvent ) from PyQt5.QtWidgets import ( QGraphicsItem, QGraphicsLineItem, QGraphics...
# needs access to libtcc and math.h # TODO: *get tcc errors (currently something like 'Unknown error 3217941984', # this makes debugging painful) # *currently the compiled function accepts too many arguments silently # *implement multi-dimensional functions for frange # *list co...
""" This module implements the base model class. All model things inherit from this class. """ from . import H2OFrame from . import H2OConnection import h2o import imp class ModelBase(object): def __init__(self): self._id = None self._model_json = None self._metrics_class = None self._is_xvalidat...
# -*- coding: utf-8 -*- # Copyright 2020 Google LLC # # 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...
import pickle import unittest import numpy as np import six import chainer from chainer import functions as F from chainer import optimizers from chainer import testing _all_optimizers = [ 'AdaDelta', 'AdaGrad', 'Adam', 'AdamW', 'AMSGrad', 'AdaBound', 'AMSBound', 'CorrectedMomentumSG...
import os import os.path import tempfile import shutil import json from nose.tools import eq_ from nose.tools import with_setup from build_pack_utils import utils from common.integration import ErrorHelper from common.components import BuildPackAssertHelper from common.components import HttpdAssertHelper from common.co...
from smimeX509validation import TrustStore, LoadDirChainOfTrust,smimeX509validation, smimeX509ValidationError from hepixvmitrust.vmitrustlib import time_format_definition as time_format_definition import logging import vmcatcher.databaseDefinition as model import json trustAnchorMap = ['None','Browser','IGTF'] clas...
# # Licensed to the Apache Software Foundation (ASF) under one or more # contributor license agreements. See the NOTICE file distributed with # this work for additional information regarding copyright ownership. # The ASF licenses this file to You under the Apache License, Version 2.0 # (the "License"); you may not us...
""" Django settings for winthrop project. Generated by 'django-admin startproject' using Django 1.10.4. For more information on this file, see https://docs.djangoproject.com/en/1.10/topics/settings/ For the full list of settings and their values, see https://docs.djangoproject.com/en/1.10/ref/settings/ """ import o...
import math import numpy as np from scipy import ndimage from ..transform import resize from ..util import img_as_float def _smooth(image, sigma, mode, cval): """Return image with each channel smoothed by the Gaussian filter.""" smoothed = np.empty(image.shape, dtype=np.double) # apply Gaussian filter t...
#!/usr/bin/env python # -- Content-Encoding: UTF-8 -- """ Pelix remote services: Abstract RPC implementation :author: Thomas Calmant :copyright: Copyright 2014, isandlaTech :license: Apache License 2.0 :version: 0.5.8 :status: Beta .. Copyright 2014 isandlaTech Licensed under the Apache License, Version 2.0...
# Copyright (c) 2016 IBM # 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 agreed to in writing, softwar...
# Copyright 2018 The TensorFlow Authors. All Rights Reserved. # # 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 applica...
from functools import wraps from flask import Blueprint, current_app, render_template, redirect, request, url_for, flash, session, abort, jsonify from flask_login import current_user, login_required from sqlalchemy import or_, and_ from preston.xmlapi import Preston as XMLAPI from auth.shared import db, eveapi from a...
#!/bin/env python # This Source Code Form is subject to the terms of the Mozilla Public # License, v. 2.0. If a copy of the MPL was not distributed with this # file, You can obtain one at http://mozilla.org/MPL/2.0/. # # Usage: symbolstore.py <params> <dump_syms path> <symbol store path> # ...
import os import sys import unittest import warnings from types import ModuleType from django.conf import ENVIRONMENT_VARIABLE, LazySettings, Settings, settings from django.core.exceptions import ImproperlyConfigured from django.http import HttpRequest from django.test import ( SimpleTestCase, TestCase, Transactio...
# Copyright 2017 Mirantis Inc. # All Rights Reserved. # # 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...
""" sentry.plugins.base.v2 ~~~~~~~~~~~~~~~~~~~~~~ :copyright: (c) 2010-2013 by the Sentry Team, see AUTHORS for more details. :license: BSD, see LICENSE for more details. """ from __future__ import absolute_import, print_function __all__ = ('Plugin2',) import logging from django.http import HttpResponseRedirect fro...
# Copyright (C) 2009 Google Inc. All rights reserved. # # Redistribution and use in source and binary forms, with or without # modification, are permitted provided that the following conditions are # met: # # * Redistributions of source code must retain the above copyright # notice, this list of conditions and the f...
# Copyright (c) 2009, Rotem Yaari <[email protected]> # All rights reserved. # # Redistribution and use in source and binary forms, with or without # modification, are permitted provided that the following conditions are met: # * Redistributions of source code must retain the above copyright # notice, this li...
# encoding: utf-8 import logging import os import signal from time import time from functools import wraps from inspect import isgeneratorfunction from collections import defaultdict from multiprocessing import RLock from tornado.gen import Return, sleep from tornado.ioloop import IOLoop from tornado.locks import Lock ...
############################################################################### ## ## Copyright (C) 2006-2011, University of Utah. ## All rights reserved. ## Contact: [email protected] ## ## This file is part of VisTrails. ## ## "Redistribution and use in source and binary forms, with or without ## modification, ...
# -*- coding: utf-8 -*- """ Organize pictures file into directory tree with year and month. Use perl exiftool to get creation date and filename from file metadata. Strongly inspired from the project: https://github.com/OneLogicalMyth/Random-Scripts.git Created on 27/12/16 15:53 @author: vpistis """ import date...
# -*- coding: utf-8 -*- # # pydicom documentation build configuration file, created by # sphinx-quickstart on Sat Feb 20 23:28:19 2010. # # This file is execfile()d with the current # directory set to its containing dir. # # Note that not all possible configuration # values are present in this # autogenerated file. # ...
""" These system tests are testing the release of groovy+ catkin projects. """ from __future__ import print_function import os import sys try: from vcstools.vcs_abstraction import get_vcs_client except ImportError: print("vcstools was not detected, please install it.", file=sys.stderr) sys.exit(1) from ...