prompt
large_stringlengths
70
991k
completion
large_stringlengths
0
1.02k
<|file_name|>test_serializers.py<|end_file_name|><|fim▁begin|># -*- coding: utf-8 -*- import mock from rest_framework import serializers from waffle.testutils import override_switch from olympia.amo.tests import ( BaseTestCase, addon_factory, collection_factory, TestCase, user_factory) from olympia.bandwagon.model...
<|file_name|>__init__.py<|end_file_name|><|fim▁begin|># -*- coding: utf-8 -*- from __future__ import absolute_import, unicode_literals, division from ._version import __version__, __version_info__ # noqa from .decorators import route, resource, asynchronous from .helpers import use from .relationship import Relationsh...
'asynchronous', 'use', 'Relationship'
<|file_name|>PiskvorkCommand.java<|end_file_name|><|fim▁begin|>package piskvork; /** * Root interface for a Piskvork command. A command must provide a string to * send to the AI, and a method to validate the response. */ public interface PiskvorkCommand { /** * Get the string for this command to send to t...
}
<|file_name|>trace.rs<|end_file_name|><|fim▁begin|>/* 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/. */ //! Utilities for tracing JS-managed values. //! //! The lifeti...
#[inline] fn trace(&self, trc: *mut JSTracer) { let (ref a, ref b) = *self; a.trace(trc);
<|file_name|>__init__.py<|end_file_name|><|fim▁begin|># Copyright (c) 2007 The Hewlett-Packard Development Company # All rights reserved. # # The license below extends only to copyright in the software and shall # not be construed as granting a license to any other intellectual # property including but not limited to i...
# LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR # A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT # OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, # SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
<|file_name|>LoginDeconnectionServlet.java<|end_file_name|><|fim▁begin|>package coop.ekologia.presentation.controller.user; import java.io.IOException; import javax.inject.Inject; import javax.servlet.ServletException; import javax.servlet.annotation.WebServlet; import javax.servlet.http.HttpServlet; import javax.ser...
*/
<|file_name|>GoodFETatmel128.py<|end_file_name|><|fim▁begin|># GoodFETclient to interface zigduino/atmel128 radio # forked by bx from code by neighbor Travis Goodspeed from GoodFETAVR import GoodFETAVR import sys, binascii, os, array, time, glob, struct fmt = ("B", "<H", None, "<L") class GoodFETatmel128rfa1(GoodFETA...
<|file_name|>driver.rs<|end_file_name|><|fim▁begin|>use std::collections::HashSet; use mio; use mio::{Token, Handler, EventSet, PollOpt}; use mio::tcp::TcpStream; use slab::Slab; use config::RootConfig; use connection::{TokenType, ListenerToken, IncomingToken, OutgoingToken, Connection}; use driver_state::DriverStat...
let frontend_addr: SocketAddr = FromStr::from_str(&config.frontends["in"].listen_addr) .unwrap();
<|file_name|>router.go<|end_file_name|><|fim▁begin|>package router import ( "github.com/Unknwon/macaron" "github.com/macaron-contrib/binding" "github.com/containerops/crew/handler" ) func SetRouters(m *macaron.Macaron) { m.Group("/v1", func() { //Session Router m.Group("/token", func() { m.Post("/", hand...
m.Group("/:team/user", func() { m.Get("/list", handler.W1GetTeamUsers) m.Put("/:user", handler.W1PutTeamUser)
<|file_name|>q_sigma.rs<|end_file_name|><|fim▁begin|>use crate::{ domains::Transition, fa::StateActionUpdate, policies::EnumerablePolicy, utils::argmaxima, Enumerable, Function, Handler, Parameterised, }; use rand::thread_rng; use std::{collections::VecDeque, ops::Index}; struct BackupE...
/// - Sutton, R. S. and Barto, A. G. (2017). Reinforcement Learning: An /// Introduction (2nd ed.). Manuscript in preparation. /// - De Asis, K., Hernandez-Garcia, J. F., Holland, G. Z., & Sutton, R. S. /// (2017). Multi-step Reinforcement Learning: A Unifying Algorithm. arXiv
<|file_name|>fundrawtransaction.py<|end_file_name|><|fim▁begin|>#!/usr/bin/env python3 # Copyright (c) 2014-2017 The Bitcoin Core developers # Distributed under the MIT software license, see the accompanying # file COPYING or http://www.opensource.org/licenses/mit-license.php. """Test the fundrawtransaction RPC.""" fr...
# the other 3 outputs are smaller as a result of subtractFeeFromOutputs assert_greater_than(share[0], 0) assert_greater_than(share[2], 0)
<|file_name|>TestBreakpointOptions.py<|end_file_name|><|fim▁begin|>""" Test breakpoint command for different options. """ from __future__ import print_function import lldb from lldbsuite.test.lldbtest import * import lldbsuite.test.lldbutil as lldbutil class BreakpointOptionsTestCase(TestBase): mydir = TestBa...
# Continue the program, there should be another stop. self.runCmd("process continue")
<|file_name|>reload.py<|end_file_name|><|fim▁begin|><|fim▁hole|># # This source code is licensed under the OSL-3.0 license found in the # LICENSE file in the root directory of this source tree. from __future__ import unicode_literals import time from django import forms from django.conf import settings from django.co...
# -*- coding: utf-8 -*- # This file is part of Shuup. # # Copyright (c) 2012-2017, Shoop Commerce Ltd. All rights reserved.
<|file_name|>Diamond.py<|end_file_name|><|fim▁begin|>import numpy as np from bokeh.models import ColumnDataSource, Plot, LinearAxis, Grid from bokeh.models.markers import Diamond from bokeh.io import curdoc, show N = 9 x = np.linspace(-2, 2, N) y = x**2 sizes = np.linspace(10, 20, N) source = ColumnDataSource(dict(x...
h_symmetry=False, v_symmetry=False, min_border=0, toolbar_location=None)
<|file_name|>worldedit.js<|end_file_name|><|fim▁begin|>var async = require('async'); Array.prototype.count = function() { var amount = 0; this.forEach(function(n) { if( typeof n !== 'number' ) { return; } amount += n; }); return amount; }; module.exports = function ...
weMax = {
<|file_name|>generator.py<|end_file_name|><|fim▁begin|>""" generator.py: Contains the Generator class. """ import random import copy import graphics from helpers import * # Just to check we have generated the correct number of polyominoes # {order: number of omiones} counts = {1: 1, 2: 1, 3: 2, 4: 7, 5: 18, 6: 60}...
# Check to see if generated polyomino is a repeat, and continue # till we've generated enough.
<|file_name|>escprober.py<|end_file_name|><|fim▁begin|>######################## BEGIN LICENSE BLOCK ######################## # The Original Code is mozilla.org code. # # The Initial Developer of the Original Code is # Netscape Communications Corporation. # Portions created by the Initial Developer are Copyright (C) 199...
CharSetProber.__init__(self) self._mCodingSM = [ \
<|file_name|>pyunit_te_deprecated_params.py<|end_file_name|><|fim▁begin|>from __future__ import print_function import os import sys import warnings sys.path.insert(1, os.path.join("..","..","..","..")) import h2o from h2o.estimators import H2OTargetEncoderEstimator from h2o.exceptions import H2ODeprecationWarning fro...
train = fr[0] test = fr[1] if incl_foldc: train["foldc"] = train.kfold_column(3, seed)
<|file_name|>test_troubleshooter_views_ping.py<|end_file_name|><|fim▁begin|>import pytest from postix.core.models import Ping<|fim▁hole|> from ..factories import cashdesk_factory, ping_factory @pytest.mark.django_db def test_troubleshooter_ping_view(troubleshooter_client): [ping_factory(ponged=(index % 3 != 0)) ...
<|file_name|>BDDiskFile.cpp<|end_file_name|><|fim▁begin|>/* ** Blue Dust - File code (cut-down, read only) */ #include <stdio.h> #include <stdlib.h> #include "BDDiskFile.h" #include "BDTypes.h" CBDDiskFile::CBDDiskFile() { m_fp = 0; } CBDDiskFile::~CBDDiskFile() { Close(); } int CBDDiskFile::Open(const char *pFile...
break;
<|file_name|>document.py<|end_file_name|><|fim▁begin|>#!/usr/bin/env python # -*- coding: utf-8 -*- import logging from functools import partialmethod from pymongo.operations import UpdateOne, InsertOne from .cache import CachedModel from .errors import ConfigError, ArgumentError from .metatype import DocumentType, ...
<|file_name|>cargo_output_metadata.rs<|end_file_name|><|fim▁begin|>use crate::core::compiler::{CompileKind, CompileTarget, RustcTargetData}; use crate::core::dependency::DepKind; use crate::core::resolver::{HasDevUnits, Resolve, ResolveOpts}; use crate::core::{Dependency, InternedString, Package, PackageId, Workspace};...
&package_map, &target_data, requested_kind, );
<|file_name|>StoreCommandResponse.java<|end_file_name|><|fim▁begin|>/** * Copyright 2014 Groupon.com * * 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/licen...
}
<|file_name|>search.go<|end_file_name|><|fim▁begin|><|fim▁hole|>// 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, sublicense, and/or sell // copies of the S...
// Copyright © 2016 Benjamin Martensson <benjamin.martensson@nrk.no> // // Permission is hereby granted, free of charge, to any person obtaining a copy
<|file_name|>application.rs<|end_file_name|><|fim▁begin|>use crate::{ errors::*, ToParams, }; use std::str::FromStr; #[derive(Debug, Clone, PartialEq)] pub struct AppId(String); #[derive(Debug, Clone, PartialEq)] pub struct AppKey(String); #[derive(Debug, Clone, PartialEq)] pub struct UserKey(String); #[deriv...
<|file_name|>OsgWidget.cpp<|end_file_name|><|fim▁begin|>/* * Rvzware based in CAPAWARE 3D * * Rvzware 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.1 of the License, or (at your op...
void OsgIWidget::UpdateTransformationMatrix(osg::Matrix *mp) {
<|file_name|>describe-clusters.rs<|end_file_name|><|fim▁begin|>/* * Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. * SPDX-License-Identifier: Apache-2.0. */ use aws_config::meta::region::RegionProviderChain; use aws_sdk_ecs::{Error, Region, PKG_VERSION}; use structopt::StructOpt; #[derive(Debug...
<|file_name|>NullAssignmentRule.java<|end_file_name|><|fim▁begin|>/** * BSD-style license; for more info see http://pmd.sourceforge.net/license.html<|fim▁hole|>import net.sourceforge.pmd.ast.ASTAssignmentOperator; import net.sourceforge.pmd.ast.ASTConditionalExpression; import net.sourceforge.pmd.ast.ASTEqualityExpres...
*/ package net.sourceforge.pmd.rules.design; import net.sourceforge.pmd.AbstractRule;
<|file_name|>RolesOperationsV1.js<|end_file_name|><|fim▁begin|>"use strict"; Object.defineProperty(exports, "__esModule", { value: true }); let _ = require('lodash'); let async = require('async'); const pip_services3_commons_node_1 = require("pip-services3-commons-node"); const pip_services3_facade_node_1 = require("pi...
}; }
<|file_name|>core.py<|end_file_name|><|fim▁begin|>"""Core functions used by the Thunder streaming feeder scripts, including asynchronous checking for new files. """ import errno import os import time from thunder_streaming.feeder.utils.filenames import getFilenamePostfix, getFilenamePrefix from thunder_streaming.feede...
def build_filecheck_generators(source_dir_or_dirs, mod_buffer_time, max_files=-1, filename_predicate=None):
<|file_name|>signverifymessagedialog.cpp<|end_file_name|><|fim▁begin|>// Copyright (c) 2011-2013 The Bitcoin developers // Distributed under the MIT/X11 software license, see the accompanying // file COPYING or http://www.opensource.org/licenses/mit-license.php. #include "signverifymessagedialog.h" #include "ui_signve...
CDataStream ss(SER_GETHASH, 0); ss << strMessageMagic;
<|file_name|>pycolbert.py<|end_file_name|><|fim▁begin|>import os import sys import subprocess testP = { "2005": [ { "date": "2005-10-17", "videos": [ "http://thecolbertreport.cc.com/videos/61f6xj/intro---10-17-05", "http://thecolbertreport.cc.com/videos/w9dr6d/first-show", "ht...
"http://thecolbertreport.cc.com/videos/9rlemm/intro---3-14-06", "http://thecolbertreport.cc.com/videos/i3ouk4/trusting-the-media", "http://thecolbertreport.cc.com/videos/i5bwzw/the-word---scapegoat",
<|file_name|>crop.js<|end_file_name|><|fim▁begin|>var gm = require('gm'); var request = require('request'); var cors = require('cors'); var upload = require('./s3-upload'); function crop(req, res) { try { var q = req.query; var image = gm(request(q.image), 'tempImage');<|fim▁hole|> } var fileObj ...
image.crop(q.width, q.height, q.left, q.top).toBuffer(function(err, buffer) { if (err) { throw err;
<|file_name|>format.rs<|end_file_name|><|fim▁begin|>#[derive(Debug, Clone, Copy, Eq, PartialEq)] pub struct Format(pub ChannelFormat, pub NumericFormat); #[derive(Debug, Clone, Copy, Eq, PartialEq)] pub enum ChannelFormat { R4G4, R4G4B4A4, R5G6B5, B5G6R5, R5G5B5A1, R8, R8G8, R8G8B8A8, ...
} #[derive(Debug, Clone, Copy, Eq, PartialEq)]
<|file_name|>resource.rs<|end_file_name|><|fim▁begin|>//! Configure the process resource limits. use cfg_if::cfg_if; use crate::errno::Errno; use crate::Result; pub use libc::rlim_t; use std::mem; cfg_if! { if #[cfg(all(target_os = "linux", any(target_env = "gnu", target_env = "uclibc")))]{ use libc::{__r...
/// let (soft_limit, hard_limit) = getrlimit(Resource::RLIMIT_NOFILE).unwrap(); /// println!("current soft_limit: {:?}", soft_limit);
<|file_name|>channel_numeric_operations.hpp<|end_file_name|><|fim▁begin|>/* Copyright 2005-2007 Adobe Systems Incorporated Distributed under the MIT License (see accompanying file LICENSE_1_0_0.txt or a copy at http://opensource.adobe.com/licenses.html) */ /*******************************************...
<|file_name|>lib.rs<|end_file_name|><|fim▁begin|>/* 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/. */ //! This module contains shared types and messages for use by dev...
pub isDocumentElement: bool, pub shortValue: String,
<|file_name|>runbr.py<|end_file_name|><|fim▁begin|>#!/usr/bin/env python3 # coding=utf-8 """Executa o servidor de nomes ".br"."""<|fim▁hole|>def main(): logging.basicConfig( format='[%(levelname)s]%(threadName)s %(message)s', level=logging.INFO) brNS = dns.NameServer('.br', 2, '127.0.0.1', 10001...
import logging import dns
<|file_name|>SimpleToadletServer.java<|end_file_name|><|fim▁begin|>/* This code is part of Freenet. It is distributed under the GNU General * Public License, version 2 (or at your option any later version). See * http://www.gnu.org/ for further details of the GPL. */ package freenet.clients.http; ////import org.tanu...
<|file_name|>__init__.py<|end_file_name|><|fim▁begin|>#! /usr/bin/env python<|fim▁hole|># __author__ = 'CwT' from .global_state import State Global = State()<|fim▁end|>
# -*- coding: utf-8 -*-
<|file_name|>Trumpet.java<|end_file_name|><|fim▁begin|>package vshevel.goit.module3.task3; public class Trumpet extends MusicalInstrument { <|fim▁hole|> System.out.println("It's sound not like Piano or Guitar"); } }<|fim▁end|>
@Override public void howDoesThisSound() {
<|file_name|>music.rs<|end_file_name|><|fim▁begin|>//! This module provides the music struct, which allows to play and control a music from a file. use libc; use mpv; use std::rc::Rc; use std::cell::RefCell; /// The music struct. pub struct Music { /// Indicates wether the music is playing, paused or stopped. ...
}, Some(_) => { },
<|file_name|>factory.py<|end_file_name|><|fim▁begin|>import logging from boto3.resources.factory import ResourceFactory from boto3.resources.model import ResourceModel from boto3.resources.base import ResourceMeta from boto3.docs import docstring from boto3.exceptions import ResourceLoadException from boto3.resources....
# Attributes that get auto-loaded
<|file_name|>ipaddress.py<|end_file_name|><|fim▁begin|>#!/usr/bin/python """nrvr.util.ipaddress - Utilities regarding IP addresses Class provided by this module is IPAddress. Works in Linux and Windows. Idea and first implementation - Leo Baschy <srguiwiz12 AT nrvr DOT com> Contributor - Nora Baschy Public reposi...
ipaddress = cls.asList(ipaddress)
<|file_name|>provider-specification-test.js<|end_file_name|><|fim▁begin|>import {ProviderSpecification} from 'dxref-core/system/provider/provider-specification'; import { module, test } from 'qunit'; module('Unit | dxref-core | system | provider | provider-specification'); test('provider-specification', function(ass...
assert.equal(providerSpec.getOutputType(), 'VALUE$Date');
<|file_name|>build.rs<|end_file_name|><|fim▁begin|>extern crate capnpc; extern crate cc; extern crate cmake; fn main() { // Compile RPC schema file into rust code capnpc::CompilerCommand::new() .src_prefix("schema") .file("schema/pung.capnp") .run().expect("schema compiler command"); ...
<|file_name|>insert_only.rs<|end_file_name|><|fim▁begin|>use std::borrow::Borrow; use std::boxed::Box; use std::cell::{Cell, UnsafeCell}; use std::cmp::Eq; use std::collections::hash_map::{self, Entry}; use std::collections::HashMap as Interior; use std::hash::{BuildHasher, Hash}; #[derive(Debug)] pub struct HashMap<K...
} impl<K, V> Iterator for IntoIter<K, V> { type Item = (K, V);
<|file_name|>mso_schema_site_vrf_region.py<|end_file_name|><|fim▁begin|>#!/usr/bin/python # -*- coding: utf-8 -*- # Copyright: (c) 2019, Dag Wieers (@dagwieers) <dag@wieers.com> # GNU General Public License v3.0+ (see COPYING or https://www.gnu.org/licenses/gpl-3.0.txt) from __future__ import absolute_import, divisio...
seealso: - module: mso_schema_site_vrf - module: mso_schema_template_vrf
<|file_name|>index.tsx<|end_file_name|><|fim▁begin|>import React from 'react'; import intersection from 'lodash/intersection'; import uniq from 'lodash/uniq'; import xor from 'lodash/xor'; import BulkNotice from './bulkNotice'; type RenderProps = { /** * Are all rows on current page selected? */ isPageSelec...
<|file_name|>tasks.py<|end_file_name|><|fim▁begin|>from celery import shared_task <|fim▁hole|> @shared_task def auto_sync_app_models_task(): sync.auto_sync_app_models()<|fim▁end|>
import sync
<|file_name|>mod.rs<|end_file_name|><|fim▁begin|>//! Shadowsocks Local Server #[cfg(feature = "local-flow-stat")] use std::path::PathBuf; use std::{ io::{self, ErrorKind}, sync::Arc, time::Duration, }; use futures::{ future::BoxFuture, stream::{FuturesUnordered, StreamExt}, FutureExt, }; use l...
bind_local_addr: config.outbound_bind_addr, ..Default::default()
<|file_name|>mmdd.py<|end_file_name|><|fim▁begin|># -*- coding: utf-8 -*- from dp_tornado.engine.controller import Controller class MmddController(Controller): def get(self): self.model.tests.helper_test.datetime.switch_timezone('Asia/Seoul') <|fim▁hole|> ms = ts * 1000 dt = self.helper.d...
ts = 1451671445
<|file_name|>ImageDescription.js<|end_file_name|><|fim▁begin|>import React, { PropTypes } from 'react'; export default function ImageDesciption({desc, price}) { return ( <div className="text"> <h3>{desc}</h3> <p className="price">{price}</p> </div><|fim▁hole|>}<|fim▁end|>
);
<|file_name|>client.py<|end_file_name|><|fim▁begin|>from tasks import func <|fim▁hole|>func.delay(1, 2)<|fim▁end|>
<|file_name|>docker.py<|end_file_name|><|fim▁begin|>#!/usr/bin/env python3 # -*- coding: utf-8 -*- """Tests for the Docker JSON parser.""" import unittest from plaso.lib import definitions from plaso.parsers import docker from tests.parsers import test_lib class DockerJSONUnitTest(test_lib.ParserTestCase): """Te...
self.assertEqual(storage_writer.number_of_events, 1) self.assertEqual(storage_writer.number_of_extraction_warnings, 0) self.assertEqual(storage_writer.number_of_recovery_warnings, 0)
<|file_name|>interface.py<|end_file_name|><|fim▁begin|># Copyright 2012 OpenStack Foundation # 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:/...
'attached-mac': mac_address})] if internal: attrs.insert(0, ('type', 'internal'))
<|file_name|>QuickMenu.py<|end_file_name|><|fim▁begin|>from enigma import eListboxPythonMultiContent, gFont, eEnv, getBoxType from boxbranding import getMachineBrand, getMachineName from Components.ActionMap import ActionMap from Components.Label import Label from Components.Pixmap import Pixmap from Components.MenuLi...
else: VIDEOENH = False
<|file_name|>baseSpec.js<|end_file_name|><|fim▁begin|>'use strict'; /* jasmine specs for services go here */ describe('base', function() { beforeEach(function(){ module('d3-uml-modeler.base'); module('d3-uml-modeler.uml-abstract-factory'); module('d3-uml-modeler.constants'); module('d3-uml-modeler.notificati...
//remove a child by passing its GUID to removeElement model.removeElement(child3.GUID);
<|file_name|>base.py<|end_file_name|><|fim▁begin|>from django.utils.encoding import python_2_unicode_compatible from allauth.socialaccount import app_settings from allauth.account.models import EmailAddress from ..models import SocialApp, SocialAccount, SocialLogin from ..adapter import get_adapter class AuthProces...
CONNECT = 'connect'
<|file_name|>input.component.exp.ts<|end_file_name|><|fim▁begin|>import { experimentOn } from '@islavi/ng2-component-lab'; const valueChange = (value: any): void => { console.log('The value was changed! >>>>', value); };<|fim▁hole|>export default experimentOn('Input') .group("Input",[ { id: 'normal...
<|file_name|>reactor.go<|end_file_name|><|fim▁begin|>package consensus import ( "context" "errors" "fmt" "runtime/debug" "sync" "time" cstypes "github.com/tendermint/tendermint/internal/consensus/types" "github.com/tendermint/tendermint/internal/eventbus" "github.com/tendermint/tendermint/internal/p2p" sm "...
// // NOTE: For now, it is just a hard-coded string to avoid accessing unprotected // shared variables.
<|file_name|>fake_connection.go<|end_file_name|><|fim▁begin|>// Code generated by counterfeiter. DO NOT EDIT. package routerfakes import ( "sync" "code.cloudfoundry.org/cli/api/router" ) type FakeConnection struct { MakeStub func(*router.Request, *router.Response) error makeMutex sync.RWMutex makeA...
<|file_name|>util.py<|end_file_name|><|fim▁begin|>#!/usr/bin/env python # Copyright 2020 the V8 project 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 heapq import os import platform import random import signal import subproces...
# We want to avoid comparisons on the last element of the tuple # since those elements might not be comparable. self.discriminator += 1
<|file_name|>profitcoin_it.ts<|end_file_name|><|fim▁begin|><?xml version="1.0" ?><!DOCTYPE TS><TS language="it" version="2.1"> <context> <name>AboutDialog</name> <message> <location filename="../forms/aboutdialog.ui" line="+14"/> <source>About profitcoin</source> <translation type="unfin...
<translation type="unfinished"/> </message> <message> <location line="+140"/>
<|file_name|>test_parser.py<|end_file_name|><|fim▁begin|>#! /usr/bin/env python # (Force the script to use the latest build.) # # test_parser.py import parser, traceback _numFailed = 0 def testChunk(t, fileName): global _numFailed print '----', fileName, try: ast = parser.suite(t) tup =...
testChunk(t, fileName)
<|file_name|>continuous.rs<|end_file_name|><|fim▁begin|>use std::collections::{HashSet, VecDeque}; use std::hash::{Hash, Hasher}; use std::iter::{FromIterator, Iterator}; use std::marker::PhantomData; use std::sync::{Arc, RwLock, Weak}; use uuid::Uuid; use super::{Continuous, DType}; use super::{Node, Observation, Va...
} dists
<|file_name|>views.py<|end_file_name|><|fim▁begin|>from braces.views import LoginRequiredMixin from django.contrib.auth.models import User, Group from django.shortcuts import render # Create your views here.<|fim▁hole|>from django.views.generic import ListView, DetailView, CreateView, UpdateView from rest_framework im...
<|file_name|>__init__.py<|end_file_name|><|fim▁begin|># -*- coding: utf-8 -*- # ---------------------------------------------------------------------------- # Copyright © 2016, Continuum Analytics, Inc. All rights reserved.<|fim▁hole|><|fim▁end|>
# # The full license is in the file LICENSE.txt, distributed with this software. # ----------------------------------------------------------------------------
<|file_name|>__init__.py<|end_file_name|><|fim▁begin|>""" Provides functionality to emulate keyboard presses on host machine. For more details about this component, please refer to the documentation at https://home-assistant.io/components/keyboard/ """ import voluptuous as vol from homeassistant.const import ( SE...
hass.services.register(DOMAIN, SERVICE_MEDIA_PLAY_PAUSE, lambda service:
<|file_name|>const.js<|end_file_name|><|fim▁begin|>// Copyright (c) 2020 Uber Technologies, Inc. // // 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 l...
model[this.name] = this.value; } } return this;
<|file_name|>Combine.js<|end_file_name|><|fim▁begin|>/*! * ${copyright} */ // Provides class sap.ui.rta.plugin.Combine. sap.ui.define([ 'sap/ui/rta/plugin/Plugin', 'sap/ui/dt/Selection', 'sap/ui/dt/OverlayRegistry', 'sap/ui/rta/Utils' ], function( Plugin, Selection, OverlayRegistry, Utils ) { "use strict"; ...
metadata: {
<|file_name|>isize.rs<|end_file_name|><|fim▁begin|>// Copyright 2012-2015 The Rust Project Developers. See the COPYRIGHT // file at the top-level directory of this distribution and at // http://rust-lang.org/COPYRIGHT. // // Licensed under the Apache License, Version 2.0 <LICENSE-APACHE or // http://www.apache.org/lice...
pub use core::isize::{BITS, BYTES, MIN, MAX};
<|file_name|>trial_of_the_champion.cpp<|end_file_name|><|fim▁begin|>/* * Copyright (C) 2008-2012 TrinityCore <http://www.trinitycore.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; ...
uiVehicle3GUID = pBoss->GetGUID(); uint64 uiGrandChampionBoss3 = 0; if (Vehicle* pVehicle = pBoss->GetVehicleKit()) if (Unit* unit = pVehicle->GetPassenger(0))
<|file_name|>einj.py<|end_file_name|><|fim▁begin|># Copyright (c) 2015, Intel Corporation # 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 a...
def _write_register(entry, value=None):
<|file_name|>authorize.js<|end_file_name|><|fim▁begin|><|fim▁hole|> */ module.exports = function(kbox) { // Npm modules var inquirer = require('inquirer'); // Kbox modules var Promise = require('bluebird'); /* * Make sure the user wants to proceed with the install/update */ return function(state) ...
'use strict'; /** * This contains a promisified confirmation question
<|file_name|>environment.py<|end_file_name|><|fim▁begin|>import functools import operator class Env(dict): """ Computational environment for some expression. Implemented with recursive composition - each environment has the outer environment. Every lookup for a name N in the environment E wit...
'list?': lambda term: isinstance(term, list), 'atom?': lambda term: isinstance(term, (int, float, str)), 'number?': lambda term: isinstance(term, (int, float)), 'symbol?': lambda term: isinstance(term, str),
<|file_name|>OptionHandler.java<|end_file_name|><|fim▁begin|>/* * Copyright to the original author or 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....
public interface OptionHandler { /** * Process the option.
<|file_name|>up-to-date.py<|end_file_name|><|fim▁begin|>#!/usr/bin/env python # # Copyright (c) 2001 - 2016 The SCons Foundation # # 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 rest...
<|file_name|>basic.py<|end_file_name|><|fim▁begin|>"""Implementation of basic magic functions.""" import argparse import textwrap import io import sys from pprint import pformat from IPython.core import magic_arguments, page from IPython.core.error import UsageError from IPython.core.magic import Magics, magics_clas...
"""
<|file_name|>prune_test.py<|end_file_name|><|fim▁begin|>#!/usr/bin/python # Copyright (c) 2012 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. """Tests that a set of symbols are truly pruned from the translator. Comp...
# That should still match the regexes later. if is_local(t): key = bin_name + '$' + sym_name else:
<|file_name|>test_view_list_all_medications.py<|end_file_name|><|fim▁begin|>from django.test import TestCase from medicine.models import Medicine from medicine.views import ListAllMedicines from user.models import HealthProfessional class TestListAllMedicines(TestCase): def setUp(self): # Making a Healt...
<|file_name|>RadioInput.spec.js<|end_file_name|><|fim▁begin|>import React from 'react'; import { shallow } from 'enzyme'; import { expect } from 'chai'; import sinon from 'sinon'; import RadioInput from './'; describe('RadioInput', () => { let wrapper; let value; let style;<|fim▁hole|> style = { backgroundCo...
let onChange; beforeEach(() => { value = 'test';
<|file_name|>FastqFileFactory.py<|end_file_name|><|fim▁begin|>import os,re,fnmatch from ehive.runnable.IGFBaseJobFactory import IGFBaseJobFactory class FastqFileFactory(IGFBaseJobFactory): ''' A job factory class for creating fan jobs for demultilexed fastq files ''' def param_defaults(self): params_dict=s...
<|file_name|>angular-touch.min.js<|end_file_name|><|fim▁begin|>version https://git-lfs.github.com/spec/v1<|fim▁hole|><|fim▁end|>
oid sha256:6f71532f9445b6d65fbaecee3fa6944aa804f3a8f7364028a6d8c71261adc0e5 size 3643
<|file_name|>api_v2.py<|end_file_name|><|fim▁begin|>""" The MIT License (MIT) Copyright (c) 2015 Robert Hodgen 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 witho...
project_key = utilities.key_for_urlsafe_id(project_id) request_object = json.loads(self.request.body) milestone = model.Milestone.for_number(project_key, int(milestone_id))
<|file_name|>__openerp__.py<|end_file_name|><|fim▁begin|># -*- coding: utf-8 -*- ############################################################################## # # Copyright (C) 2012+ BREMSKERL-REIBBELAGWERKE EMMERLING GmbH & Co. KG # Author Marco Dieckhoff # Copyright (C) 2013 Agile Business Group sagl (<http...
# This program is distributed in the hope that it will be useful, # but WITHOUT ANY WARRANTY; without even the implied warranty of
<|file_name|>app.js<|end_file_name|><|fim▁begin|>(function () { 'use strict'; angular.module('UserSearch') .controller('UserSearchController', ['searchService', UserSearchController]); function UserSearchController(searchService) { var self = this; self.user = {}; self.sea...
return searchService.getAllUserData().then(function (response) { if (response.data !== null) {
<|file_name|>commands.py<|end_file_name|><|fim▁begin|>"""Execute shell commands via os.popen() and return status, output.<|fim▁hole|> import commands outtext = commands.getoutput(cmd) (exitstatus, outtext) = commands.getstatusoutput(cmd) outtext = commands.getstatus(file) # returns output o...
Interface summary:
<|file_name|>li2_.py<|end_file_name|><|fim▁begin|># -*- coding: utf-8 -*- # # Copyright (C) 2016 Taifxx # # 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 Li...
# (at your option) any later version. #
<|file_name|>example.js<|end_file_name|><|fim▁begin|><|fim▁hole|> * Author: Brendan Le Foll <brendan.le.foll@intel.com> * Copyright (c) 2014 Intel Corporation. * * Permission is hereby granted, free of charge, to any person obtaining * a copy of this software and associated documentation files (the * "Software"), ...
/*
<|file_name|>UIGraphicsRotatorButton.cpp<|end_file_name|><|fim▁begin|>/* $Id: UIGraphicsRotatorButton.cpp $ */ /** @file * VBox Qt GUI - UIGraphicsRotatorButton class definition. */ /* * Copyright (C) 2012 Oracle Corporation * * This file is part of VirtualBox Open Source Edition (OSE), as * available from http:...
m_pForwardButtonAnimation->setDuration(m_iAnimationDuration);
<|file_name|>video-creator.py<|end_file_name|><|fim▁begin|>#! /usr/bin/env python import sys, cv, cv2, os import numpy as np import subprocess, signal import math import atexit import cPickle as pickle from sklearn.cluster import DBSCAN from sklearn import metrics, preprocessing import pymeanshift as pms from optparse...
video = None
<|file_name|>backup_only.py<|end_file_name|><|fim▁begin|>#!/usr/bin/env python # Copyright 2017 The Vitess 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.apach...
tablet_master.remove_tree() tablet_replica1.remove_tree() tablet_replica2.remove_tree()
<|file_name|>cs.ts<|end_file_name|><|fim▁begin|><?xml version="1.0" encoding="utf-8"?> <!DOCTYPE TS> <TS version="2.0" language="cs_CZ"> <context> <name>AboutDialog</name> <message> <source>About iTALC</source> <translation type="unfinished">O iTALC</translation> </message> <message> ...
<source>Date:</source> <translation type="unfinished">Datum:</translation> </message>
<|file_name|>trait-safety-fn-body.rs<|end_file_name|><|fim▁begin|>// Copyright 2014 The Rust Project Developers. See the COPYRIGHT // file at the top-level directory of this distribution and at // http://rust-lang.org/COPYRIGHT. // // Licensed under the Apache License, Version 2.0 <LICENSE-APACHE or // http://www.apach...
} unsafe impl UnsafeTrait for *mut isize { fn foo(self) {
<|file_name|>retry_interceptor.go<|end_file_name|><|fim▁begin|>// Copyright 2016 The etcd 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/...
} }
<|file_name|>application_key.go<|end_file_name|><|fim▁begin|>// Copyright 2021 Google Inc. // // Licensed under the Apache License, Version 2.0 (the "License"); you may not // use this file except in compliance with the License. You may obtain a copy of // the License at // // http://www.apache.org/licenses/LICENSE...
<|file_name|>RFCParameters.py<|end_file_name|><|fim▁begin|>""" This module provides vCard parameters that are defined by the vCard 4.0 RFC. """ from vcard4.parameters import BaseParameter class Language(BaseParameter): """ A LANGUAGE parameter. Example: ROLE;LANGUAGE=tr:hoca """<|fim▁hole|> ...
<|file_name|>__init__.py<|end_file_name|><|fim▁begin|>"""Support for monitoring OctoPrint 3D printers.""" from datetime import timedelta import logging from typing import cast from pyoctoprintapi import ApiError, OctoprintClient, PrinterOffline import voluptuous as vol from yarl import URL from homeassistant.config_e...
<|file_name|>test_compressed_int_list.py<|end_file_name|><|fim▁begin|># -*- coding: utf-8 -*- # Copyright 2017 GIG Technology NV # # 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:/...