src stringlengths 721 1.04M |
|---|
import dbus
from twisted.words.xish import xpath
from servicetest import (assertEquals, EventPattern)
from gabbletest import exec_test, make_result_iq, sync_stream, make_presence
import constants as cs
from caps_helper import compute_caps_hash, \
text_fixed_properties, text_allowed_properties, \
stream_tube_... |
# borrowed most of this from: https://gist.github.com/aflaxman/287370
import xml.sax
import copy
import networkx as nx
from geojson import MultiPoint, Point, Polygon, MultiPolygon, GeometryCollection, LineString
def graph_to_geojson(g):
geoms = []
for node_id, node in g.node.iteritems():
geoms.append... |
#!/usr/bin/env python
#
# rpclib - Copyright (C) Rpclib contributors.
#
# This library is free software; you can redistribute it and/or
# modify it under the terms of the GNU Lesser General Public
# License as published by the Free Software Foundation; either
# version 2.1 of the License, or (at your option) any later ... |
import os
import sys
from setuptools import setup, find_packages
here = os.path.abspath(os.path.dirname(__file__))
README = open(os.path.join(here, 'README.md')).read()
CHANGES = open(os.path.join(here, 'CHANGES.rst')).read()
requires = [
'snovault',
'Pillow',
'PyBrowserID',
'SQLAlchemy>=1.0.0b1',
... |
#!/usr/bin/env python
"Check binaries configuration"
#
# Copyright (C) 2012-2017 ABINIT Group (Yann Pouillon)
#
# This file is part of the ABINIT software package. For license information,
# please see the COPYING file in the top-level directory of the ABINIT source
# distribution.
#
from __future__ import unicode_lite... |
import unittest
from Testing import ZopeTestCase as ztc
from Products.CMFCore.utils import getToolByName
from Products.UWOshSuccess.tests.base import UWOshSuccessFunctionalTestCase
from DateTime import DateTime
class TestReports(UWOshSuccessFunctionalTestCase):
def afterSetUp(self):
pass
def before... |
# Copyright (C) 2010-2011 Richard Lincoln
#
# Permission is hereby granted, free of charge, to any person obtaining a copy
# of this software and associated documentation files (the "Software"), to
# deal in the Software without restriction, including without limitation the
# rights to use, copy, modify, merge, publish... |
from __future__ import absolute_import
from time import time
from itertools import count
from celery import states
from celery.events import Event
from celery.events.state import State, Worker, Task, HEARTBEAT_EXPIRE_WINDOW
from celery.utils import uuid
from celery.tests.utils import Case
class replay(object):
... |
"""empty message
Revision ID: 8ce7926aa132
Revises: cfc5f3fd5efe
Create Date: 2018-06-07 18:53:47.656557
"""
from alembic import op
# revision identifiers, used by Alembic.
revision = '8ce7926aa132'
down_revision = 'cfc5f3fd5efe'
branch_labels = None
depends_on = None
def upgrade():
# ### commands auto genera... |
"""This module describes fully-functioning networks created from the pieces in `layer`.
"""
from __future__ import division, print_function
import collections
import inspect
import numpy as np
import six
import theano
import theano.tensor as T
from theano.tensor.shared_randomstreams import RandomStreams
from ..data ... |
"""@package OsmPlugin
This is the main module of the OSM Plugin.
It shows/hides all tool buttons, widgets and dialogs.
After closing dialogs it does all actions related with their return codes.
/***************************************************************************
* ... |
from resources.lib.abc_base import BaseForum
from BeautifulSoup import BeautifulSoup
import resources.lib.util as util
import HTMLParser
import resources.lib.structure as s
import resources.lib.hosts as hosts
class DesiRonakApi(BaseForum):
short_name = 'desironak'
long_name = 'Desi Ronak Forum'
local_thum... |
# Copyright Istio Authors
#
# 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... |
from js9 import j
import os
import capnp
# import msgpack
import base64
ModelBaseCollection = j.data.capnp.getModelBaseClassCollection()
ModelBase = j.data.capnp.getModelBaseClass()
# from JumpScale9.clients.tarantool.KVSInterface import KVSTarantool
class $NameModel(ModelBase):
'''
'''
def __init__(sel... |
import Gedi as gedi
import george
import numpy as np;
import matplotlib.pylab as pl; pl.close('all')
from time import time,sleep
import scipy.optimize as op
import sys
##### INITIAL DATA ###########################################################
nrep = 1
pontos=[]
temposQP=[]
temposmulti=[]
georgeQP=[]
sleept... |
##
# Copyright (c) 2005-2017 Apple 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 applicable l... |
from sympy.core.basic import Basic, S, C, sympify, Wild
from sympy.core.function import Lambda, Function, Function, expand_log
from sympy.core.cache import cacheit
from sympy.utilities.decorator import deprecated
from sympy.ntheory import multiplicity
from sympy.core.basic import Mul
class exp(Function):
nargs ... |
# -*- coding: utf-8 -*-
# Copyright (C) 2012-2013 Matthias Bolte <matthias@tinkerforge.com>
# Copyright (C) 2011-2012 Olaf Lüke <olaf@tinkerforge.com>
#
# Redistribution and use in source and binary forms of this file,
# with or without modification, are permitted.
from threading import Thread, Lock, Semaphore
# curr... |
from django.http import HttpRequest
from rest_framework import serializers
from requests.exceptions import HTTPError
from allauth.socialaccount.helpers import complete_social_login
class SocialLoginSerializer(serializers.Serializer):
access_token = serializers.CharField(required=False)
code = serializers.Cha... |
from eclcli.common import command
from eclcli.common import utils
from ..networkclient.common import utils as to_obj
class ListPubicIP(command.Lister):
def get_parser(self, prog_name):
parser = super(ListPubicIP, self).get_parser(prog_name)
parser.add_argument(
'--name',
m... |
#!/usr/bin/python
#! -*- encoding: utf-8 -*-
import json
import csv
import bisect
import copy
"""
File
Pipeline:
Input: CSV file with startups, CSV file with person and where they work.
Output: JSON file suitable for d3 consumption.
"""
STARTUPS_FILE = 'startups.csv'
PERSONS_FILE = 'persons.csv'
STARTUPS_PERSONS_J... |
import sys
import os
import logging
logger = logging.getLogger('snaptastic.cli')
path = os.path.abspath(__file__)
parent = os.path.join(path, '../', '../')
sys.path.append(parent)
from argh import command, ArghParser
from snaptastic import get_snapshotter
from snaptastic import settings
import json
def configure_sn... |
"Verifies that bounds are caught through monomials"
from gpkit import Model, parse_variables
from gpkit.exceptions import UnboundedGP, UnknownInfeasible
class BoundsChecking(Model):
"""Implements a crazy set of unbounded variables.
Variables
---------
Ap [-] d
D [-] e
F ... |
# Copyright (c) 2011 The Native Client Authors. All rights reserved.
# Use of this source code is governed by a BSD-style license that can be
# found in the LICENSE file.
#
# Config file for various nacl compilation scenarios
#
import os
import sys
TOOLCHAIN_CONFIGS = {}
class ToolchainConfig(object):
def __init_... |
import os
import sys
import numpy as np
import pygame
from pygame.constants import K_w
from .. import base
class BirdPlayer(pygame.sprite.Sprite):
def __init__(self,
SCREEN_WIDTH, SCREEN_HEIGHT, init_pos,
image_assets, rng, color="red", scale=1.0):
self.SCREEN_WIDTH = SCREEN_WI... |
import pickle
PA = 'A6'
def load(partId, caseId=1):
"""
This function returns the example test-cases for a specific part of an assignment.
Input:
partId (int) = part number of the assignment (1 for A*Part1, 2 for A*Part2 and so on)
caseId (int) = caseId = k to return the kth test case. Typically there are two ... |
#!/usr/bin/python
# We need the following two lines in order for matplotlib to work
# without access to an X server.
from __future__ import division
import matplotlib
matplotlib.use('Agg')
import pylab, numpy, sys
xmax = 2.5
xmin = -0.4
def plotit(dftdata, mcdata):
dft_len = len(dftdata[:,0])
dft_dr = dftda... |
import numpy as np
from phonopy import Phonopy, PhonopyGruneisen
from phonopy.interface.vasp import read_vasp
from phonopy.file_IO import parse_FORCE_SETS
def append_band(bands, q_start, q_end):
band = []
for i in range(51):
band.append(np.array(q_start) +
(np.array(q_end) - np.arra... |
#!/usr/bin/python
# -*- coding: utf-8 -*-
#
# Copyright 2013 The Plaso Project Authors.
# Please see the AUTHORS file for details on individual authors.
#
# 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 L... |
# Author: Martijn Pieters
# Contact: mjpieters@users.sourceforge.net
# Revision: $Revision: 21817 $
# Date: $Date: 2005-07-21 13:39:57 -0700 (Thu, 21 Jul 2005) $
# Copyright: This module has been placed in the public domain.
# New language mappings are welcome. Before doing a new translation, please
# read <http://do... |
from __future__ import print_function
import sys
from IPython.core.inputtransformer import InputTransformer
from . import util
class SolutionInputTransformer(InputTransformer):
"""IPython input transformer that renders jinja templates in cells,
allowing them to be run while the instructor is developing the
... |
#!python3.5
# For command aliases prior to 3.2 - https://bugs.python.org/issue25299
#
# https://pythonconquerstheuniverse.wordpress.com/2011/08/29/lambda_tutorial/
from __future__ import print_function
import sys
import re
import json
import requests
import errno
from velstor.restapi import Session
from functools im... |
# -*- coding: utf-8 -*-
#
# Copyright (C) 2009, 2012 UNINETT AS
#
# This file is part of Network Administration Visualized (NAV).
#
# NAV is free software: you can redistribute it and/or modify it under
# the terms of the GNU General Public License version 2 as published by
# the Free Software Foundation.
#
# This prog... |
# encoding: utf-8
'''
GDB - Contains functions directly used by GDB for crash processing
@author: Christian Holler (:decoder)
@license:
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://mozill... |
'''
videobee urlresolver plugin
Copyright (C) 2016 Gujal
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 3 of the License, or
(at your option) any later version.
This program is distr... |
# coding: utf-8
"""
MINDBODY Public API
No description provided (generated by Swagger Codegen https://github.com/swagger-api/swagger-codegen) # noqa: E501
OpenAPI spec version: v6
Generated by: https://github.com/swagger-api/swagger-codegen.git
"""
import pprint
import re # noqa: F401
impor... |
#!bin/python
# vim: set fileencoding=utf-8 :
# Elie Khoury <Elie.Khoury@idiap.ch>
# Fri Aug 30 11:44:33 CEST 2013
#
# Copyright (C) 2012-2013 Idiap Research Institute, Martigny, Switzerland
#
# This program is free software: you can redistribute it and/or modify
# it under the terms of the GNU General Public License as... |
#!/usr/bin/env python
#-------------------------------------------------------------------------
# Copyright (c) Microsoft Corporation. All rights reserved.
# Licensed under the MIT License. See License.txt in the project root for
# license information.
#----------------------------------------------------------------... |
#!/usr/bin/python
# -*- coding: utf-8 -*-
##
## (C) 2015 Muthiah Annamalai
## Licensed under GPL Version 3
##
## Interpreter for Ezhil language
from __future__ import print_function
import sys
PYTHON3 = (sys.version[0] == '3')
if PYTHON3:
unicode = str
## Tx
from .transform import Visitor, TransformVisitor
from .... |
"""
/***************************************************************************
QuickOSM QGIS plugin
OSM Overpass API frontend
-------------------
begin : 2017-11-11
copyright : (C) 2017 by Etienne Trimaille
email ... |
# Django settings for mytest project.
from os.path import normpath, join, dirname
#ROOT : the django project root
ROOT = lambda *base : normpath(join(dirname(__file__), *base)).replace('\\','/')
DEBUG = True
TEMPLATE_DEBUG = DEBUG
ADMINS = (
# ('Your Name', 'your_email@domain.com'),
)
MANAGERS = ADMINS
DATABAS... |
from unittest import TestCase
from src.Escuderia import Escuderia
from src.Piloto import Piloto
from src.Circuito import Circuito
from src.GranPremio import GranPremio
from mock import patch
__author__ = 'MAMISHO'
class TestGranPremio(TestCase):
def test_extraer_participantes_1(self):
"""
Test ex... |
#!/usr/bin/env python
# -*- coding: utf-8 -*-
"""Update encrypted deploy password in Travis config file
"""
from __future__ import print_function
import base64
import json
import os
from getpass import getpass
import yaml
from cryptography.hazmat.primitives.serialization import load_pem_public_key
from cryptography.h... |
import os
FILE_TEMPLATE = """extends ../../../path-feature-template.pug
block description
| """
def parseFeatureDescription(feature):
description = feature.description.replace('\n', '\n | ')
return FILE_TEMPLATE + description + '\n'
def getFeatureFileName(feature):
return feature.title.replace... |
#!/usr/bin/env python
## begin license ##
#
# "Weightless" is a High Performance Asynchronous Networking Library. See http://weightless.io
#
# Copyright (C) 2006-2011 Seek You Too (CQ2) http://www.cq2.nl
# Copyright (C) 2011-2012, 2015, 2020-2021 Seecr (Seek You Too B.V.) https://seecr.nl
#
# This file is part of "Weig... |
# -*- coding: utf-8 -*-
#
# Copyright © 2012 - 2014 Michal Čihař <michal@cihar.com>
#
# This file is part of Weblate <http://weblate.org/>
#
# 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, eithe... |
#!/usr/bin/python
import click
import os
import time
#import dns
import dns.resolver
import dns.query
import dns.zone
import sys
@click.command()
@click.option('--host', prompt="What host would you like to query?")
@click.option('--record-type', prompt="What type of record would you like to look-up?", type=click.Choic... |
'''
Copyright (C) 2021 Gitcoin Core
This program 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 your option) any later version.
This progra... |
# coding=utf-8
import unittest
"""60. Permutation Sequence
https://leetcode.com/problems/permutation-sequence/description/
The set `[1,2,3,..., _n_ ]` contains a total of _n_! unique permutations.
By listing and labeling all of the permutations in order, we get the following
sequence for _n_ = 3:
1. `"123"`
2. ... |
'''
Built-in web server using Flask. Should mirror functionality offered by the
cli.
'''
from flask import Flask
from flask import render_template, request, session
import tmw.config as config
import tmw.core as core
import json
from uuid import uuid4
from multiprocessing import Pool
app = Flask(__name__)
pool = ... |
#!/usr/bin/env python
# pylint: disable=C0116,W0613
# This program is dedicated to the public domain under the CC0 license.
"""
First, a few callback functions are defined. Then, those functions are passed to
the Dispatcher and registered at their respective places.
Then, the bot is started and runs until we press Ctr... |
from daisychain.step import Step
from daisychain.step_status import StepStatus
from daisychain.field import Field
from daisychain.reference import Reference,ReferenceList
from abc import abstractmethod
class MonitorStatus(StepStatus):
def __init__(self, *args, **kwargs):
super(MonitorStatus, self).__init__... |
# -*- coding: utf-8 -*-
import sys
import os
PYTHONPATH=os.getenv("PYTHONPATH","not_defined")
if "not_defined" in PYTHONPATH:
MSG("cannot acces to PYTHONPATH environment. It's required for accessing to brukerPARIO lib" )
EXIT()
#add the Library path for importing brukerPARIO
sys.path.append(PYTHONPATH)
import bruke... |
"""Creates a Graph data structure, featuring graph traversal and two shortest path algorithms."""
import timeit
import random
class Graph(object):
"""Define the Graph class structure."""
def __init__(self):
"""Make an empty dictionary."""
self.graph_dict = {}
def add_node(self, value):
... |
# -*- coding: utf-8 -*-
from __future__ import unicode_literals
from __future__ import print_function
from timeit import timeit
import tabulate
import asciitable
import prettytable
import texttable
import sys
import codecs
setup_code = r"""
from csv import writer
try: # Python 2
from StringIO import StringIO
excep... |
import os,sys,shutil
def choice():
ch = int(input("enter your choice \n1.open file \n 2.append file \n 3.create file \n 4.delete file \n 5.copy file \n 6.move file 7.rename_file \n 8. exit \n "))
if ch == 1:
open_file()
elif ch == 2:
append_file()
elif ch == 3:
create_f... |
# Copyright 2019 Google LLC. 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 law or a... |
# Copyright 2020 Pants project contributors (see CONTRIBUTORS.md).
# Licensed under the Apache License, Version 2.0 (see LICENSE).
from pants.backend.jvm.targets.java_library import JavaLibrary
from pants.backend.jvm.tasks.jvm_compile.compile_context import CompileContext
from pants.backend.jvm.tasks.jvm_compile.zinc... |
# encoding: utf-8
import datetime
from south.db import db
from south.v2 import SchemaMigration
from django.db import models
class Migration(SchemaMigration):
def forwards(self, orm):
# Adding field 'Membership.messages_generated'
db.add_column('sms_membership', 'messages_generated', self.... |
#! /usr/bin/env python
# -*- coding: utf-8 -*-
#
# Interpreter version: python 2.7
#
# Imports =====================================================================
# Functions & classes =========================================================
class URN_NBN(str):
"""
Class used to hold URN:NBN string and als... |
# Copyright (c) Facebook, Inc. and its affiliates.
#
# This source code is licensed under the MIT license found in the
# LICENSE file in the root directory of this source tree.
from __future__ import absolute_import, division, print_function, unicode_literals
import logging
import os
import re
import subprocess
###... |
# -*- coding: utf-8 -*-
"""
Geosearch master index
Create a master index that should be usable for all geosearches
With this master index we could do one search and find all items
within a specific radius or that contains some specific point
Current counts for different datasets:
kadastraal_object 582551
pand 183659... |
#!/usr/bin/env python3
# Copyright (c) 2010 ArtForz -- public domain half-a-node
# Copyright (c) 2012 Jeff Garzik
# Copyright (c) 2010-2016 The Bitcoin Core developers
# Distributed under the MIT software license, see the accompanying
# file COPYING or http://www.opensource.org/licenses/mit-license.php.
"""Bitcoin P2P ... |
"""
Generic mixins for classes.
"""
from functools import partial
from django.conf import settings
from django.core.exceptions import ImproperlyConfigured
class GetSettingsMixin(object):
"""
A generic class mixin which adds a _get_settings() method, which will
return a tuple of settings or throw appropri... |
# -*- encoding: utf-8 -*-
'''
:maintainer: HubbleStack
:maturity: 2016.7.0
:platform: Windows
:requires: SaltStack
'''
from __future__ import absolute_import
import copy
import fnmatch
import logging
import salt.utils
import salt.utils.platform
from salt.exceptions import CommandExecutionError
from distutils.version... |
import logging
from typing import List
import sqlalchemy
import uuid
import ujson
from datetime import datetime
from listenbrainz import db
from listenbrainz.db.exceptions import DatabaseException
from data.model.similar_user_model import SimilarUsers
from typing import Tuple, List
logger = logging.getLogger(__name... |
#!/usr/bin/env python
import sys
if sys.version_info[0] == 3:
unichr = chr
#A list of all icon-names with the codepoint (unicode-value) on the right
#You can use the names on the page http://fortawesome.github.io/Font-Awesome/design.html
_codepoints = [
("fa-adjust", 0xf042),
("fa-adn", 0xf170),
("fa-... |
import sys
import subprocess
import os
from numpy import asarray
#triangle_path = os.path.join( "C:\\Users\\Mai\\Dropbox\\Research\\Deformation\\src\\py\\triangle", "triangle.exe")
triangle_path = os.path.join( os.path.dirname( __file__ ), "triangle", "triangle" )
if not os.path.exists( triangle_path ):
raise Imp... |
#!/usr/bin/env python3
# Sequencer1 by Mike Cook August 2020
#Plays samples from a file
import time
from pygame import mixer
import board
import neopixel
from caltap import CalTap
def main():
global markTime, stepTime
init()
print("Sequencer - playing samples through the audio output")
print("Tap to a... |
import unittest
import hashlib
import os
import random
from StringIO import StringIO
from .. import Session, User, File, Directory
from .. import errors
USERNAME = os.environ.get('MEGA_USERNAME', None)
PASSWORD = os.environ.get('MEGA_PASSWORD', None)
def random_string(length):
return (('%0'+str(length)+'x') % rando... |
#! /usr/bin/env python
# FIXME: it has to be seen if this is any useful
# FIXME: to bring back to life
from DIRAC.Core.Base.Script import parseCommandLine
parseCommandLine()
from DIRAC.Resources.Catalog.FileCatalog import FileCatalog
from DIRAC.Core.Utilities.File ... |
"""
Test cases for the dircache module
Nick Mathewson
"""
import unittest
from test.test_support import run_unittest, TESTFN, import_module
dircache = import_module('dircache', deprecated=True)
import os, time, sys, tempfile
class DircacheTests(unittest.TestCase):
def setUp(self):
self.t... |
#!/usr/bin/env python
"""
PlexNMT
Sources:
PlexConnect: https://github.com/iBaa/PlexConnect/wiki
inter-process-communication (queue): http://pymotw.com/2/multiprocessing/communication.html
"""
import sys, time
from os import sep
import socket
from multiprocessing import Process, Pipe
import signal, errno
from Vers... |
import pandas as pd
import numpy as np
import csv
import os
import matplotlib.pyplot as plt
import cufflinks as cf
import plotly
import plotly.offline as py
from plotly.offline.offline import _plot_html
import plotly.graph_objs as go
from plotly.tools import FigureFactory as FF
cf.set_config_file(world_readable=False,... |
"""
Copyright (c) 2016 Gabriel Esteban
Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated
documentation files (the "Software"), to deal in the Software without restriction, including without limitation
the rights to use, copy, modify, merge, publish, distribute... |
# ENVISIoN
#
# Copyright (c) 2019-2021 Jesper Ericsson, Gabriel Anderberg, Didrik Axén,
# Adam Engman, Kristoffer Gubberud Maras, Joakim Stenborg
# All rights reserved.
#
# Redistribution and use in source and binary forms, with or without
# modification, are permitted provided that the following conditions are ... |
#!/usr/bin/env python3
# -*- coding: utf-8 -*-
#
# player.py
#
# This file is part of upodcatcher
#
# Copyright (C) 2017
# Lorenzo Carbonell Cerezo <lorenzo.carbonell.cerezo@gmail.com>
#
# This program is free software: you can redistribute it and/or modify
# it under the terms of the GNU General Public License as publ... |
#!/usr/bin/python
# -*- coding: utf8 -*-
from pprint import pprint
import sys,os
import random
import json
import gzip
import random
import boto3
s3 = boto3.resource('s3')
client = boto3.client('sqs')
QUEUE_ENDPOINT='https://eu-west-1.queue.amazonaws.com/888250974927/s3-copy-list'
DST_BUCKET='ireland-leo-test'
de... |
from datetime import datetime
from django.shortcuts import render, redirect, get_object_or_404
from django.contrib.auth.decorators import login_required
from django.core.urlresolvers import reverse
from django.contrib import messages
from estofadora.core.utils import MONTHS, last_day_of, month_before_of
from .forms ... |
# Python script to visualize rotation about a non-body axis.
# Let the lab frame be the inertial frame S.
# Let the origin of the rigid body be O, in the inertial frame S'.
# Let r_ss' be the vector from S to S'.
# Let the body frame relative to O be S''.
# Consider a fixed point on the body, r_s' in S', and r_s'' in... |
"""This file contains the test_yahoo module of the DJ Scrooge backtesting API.
Copyright (C) 2012 James Adam Cataldo
This file is part of Pengoe.
Pengoe 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 Found... |
# 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 2014: 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 b... |
# coding=utf-8
# Author: Guillaume Serre <guillaume.serre@gmail.com>
#
# URL: https://sickrage.github.io
#
# This file is part of SickRage.
#
# SickRage 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 v... |
#!/usr/bin/env python2
# -*- coding: utf-8 -*-
#
# Timetra is a time tracking application and library.
# Copyright © 2010-2014 Andrey Mikhaylenko
#
# This file is part of Timetra.
#
# Timetra is free software: you can redistribute it and/or modify
# it under the terms of the GNU Lesser General Public Li... |
#!/usr/bin/env python
# -*- coding: utf-8 -*-
# deb/controlfile.py - parse debian control files
#
# Copyright © 2008 Canonical Ltd.
# Author: Scott James Remnant <scott@ubuntu.com>.
#
# This program is free software: you can redistribute it and/or modify
# it under the terms of version 3 of the GNU General Public Licen... |
"""@author: Bryan Silverthorn <bcs@cargo-cult.org>"""
import os
import os.path
import shutil
import resource
import tempfile
import subprocess
import contextlib
import borg
from . import solvers
from . import features
logger = borg.get_logger(__name__, default_level = "INFO")
class LP2SAT_FailedException(Exception)... |
# -*- coding: utf-8 -*-
from bottle import run, get, request, template
from pymongo import MongoClient
from os import linesep
mongoclient = MongoClient()
db = mongoclient.giw
#Columnas para las tablas de los ejercicios 2, 3, 4, 5 y 7
all_table_data = ['Nombre de usuario', 'e-mail', 'Página web', 'Tarjeta de crédito'... |
# Copyright (c) 2014, Fundacion Dr. Manuel Sadosky
# All rights reserved.
# Redistribution and use in source and binary forms, with or without
# modification, are permitted provided that the following conditions are met:
# 1. Redistributions of source code must retain the above copyright notice, this
# list of condit... |
"""Test for certbot_apache.augeas_configurator."""
import os
import shutil
import unittest
import mock
from certbot import errors
from certbot_apache.tests import util
class AugeasConfiguratorTest(util.ApacheTest):
"""Test for Augeas Configurator base class."""
_multiprocess_can_split_ = True
def set... |
'''
Wrapper for GeoSteiner program
'''
from itertools import dropwhile, takewhile, ifilter
import os
from subprocess import Popen, PIPE
from geonet.network import SteinerTree
# TODO: check if GeoSteiner is available
def geosteiner(pos):
'''Call geosteiner to compute and return'''
def parse_ps(output):
... |
# 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 u... |
#!/bin/python
#https://python-packaging.readthedocs.io/en/latest/minimal.html
import os, glob, sys
import os.path
from shutil import copyfile
from setuptools import find_packages
from setuptools import setup
fenrirVersion = '1.9.7'
packageVersion = 'post1'
# handle flags for package manager like aurman and pacaur.
fo... |
# Copyright (C) 2014-2015 Andrey Antukh <niwi@niwi.be>
# Copyright (C) 2014-2015 Jesús Espino <jespinog@gmail.com>
# Copyright (C) 2014-2015 David Barragán <bameda@dbarragan.com>
# This program is free software: you can redistribute it and/or modify
# it under the terms of the GNU Affero General Public License as
# pub... |
# Copyright (C) 2010-2011 Richard Lincoln
#
# Permission is hereby granted, free of charge, to any person obtaining a copy
# of this software and associated documentation files (the "Software"), to
# deal in the Software without restriction, including without limitation the
# rights to use, copy, modify, merge, publish... |
# -*- coding: utf-8 -*-
from ethereum import tester
from ethereum.utils import decode_hex
from raiden.blockchain.abi import (
CHANNEL_MANAGER_ABI,
NETTING_CHANNEL_ABI,
HUMAN_TOKEN_ABI,
REGISTRY_ABI,
)
from raiden.channel import Channel, ChannelEndState
from raiden.utils import privatekey_to_address
c... |
# ---------------------------------------------------------------
# Imports
# ---------------------------------------------------------------
import sys
import socket
import select
import time
import os
sys.path.append(os.path.join(os.path.dirname(__file__), '..'))
from s12_chat import chat_settings
# ---------------... |
#! /usr/bin/env python
# encoding: utf-8
# WARNING! Do not edit! http://waf.googlecode.com/svn/docs/wafbook/single.html#_obtaining_the_waf_file
import os
from waflib import Task,Utils,Options,Errors,Logs
from waflib.TaskGen import taskgen_method,before_method,after_method,feature
def add_marshal_file(self,filename,pre... |
# -*- coding: utf-8 -*-
from __future__ import unicode_literals
from django.db import models, migrations
import datetime
from django.utils.timezone import utc
class Migration(migrations.Migration):
dependencies = [
('postings', '0002_auto_20141111_0540'),
]
operations = [
migrations.Alt... |
#!/usr/bin/python -tt
# Copyright 2010 Google Inc.
# Licensed under the Apache License, Version 2.0
# http://www.apache.org/licenses/LICENSE-2.0
# Google's Python Class
# http://code.google.com/edu/languages/google-python-class/
# Basic string exercises
# Fill in the code for the functions below. main() is already se... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.