prompt
large_stringlengths
70
991k
completion
large_stringlengths
0
1.02k
<|file_name|>test_capi1.py<|end_file_name|><|fim▁begin|>import difflib import os import pytest from fusesoc.core import Core def compare_fileset(fileset, name, files): assert name == fileset.name for i in range(len(files)): assert files[i] == fileset.file[i].name def test_core_info(): tests_dir =...
"atlys.core") core = Core(filename)
<|file_name|>expected.rs<|end_file_name|><|fim▁begin|>// @generated automatically by Diesel CLI. diesel::table! { /// Representation of the `users2` table. /// /// (Automatically generated by Diesel.) users2 (id) { /// The `id` column of the `users2` table. /// /// Its SQL type ...
} }
<|file_name|>TestLogAppender.cpp<|end_file_name|><|fim▁begin|><|fim▁hole|> * Created on 7. Oktober 2011, 15:06 */ #include "TestLogAppender.h" namespace org { namespace esb { namespace hive { TestLogAppender::TestLogAppender(const log4cplus::helpers::Properties properties) { } TestLogAppende...
/* * File: TestLogAppender.cpp * Author: HoelscJ *
<|file_name|>app.module.ts<|end_file_name|><|fim▁begin|><|fim▁hole|>import {RouterModule} from '@angular/router'; import {HttpModule} from '@angular/http'; import { AppComponent } from './app.component'; import { HeroDetailComponent } from './hero-detail.component'; import {HeroesComponent} from './heroes.component'...
import { NgModule } from '@angular/core'; import { BrowserModule } from '@angular/platform-browser'; import {FormsModule} from '@angular/forms';
<|file_name|>puzzle-state.service.ts<|end_file_name|><|fim▁begin|>import {Injectable} from '@angular/core'; import 'rxjs/add/operator/share'; import { StateService, LocalStorageService } from '../../modules/puzzle/index'; @Injectable() export class PuzzleStateService extends StateService { constructor(databaseSe...
zero() { this.databaseService.zero(); }
<|file_name|>dmc_colors.py<|end_file_name|><|fim▁begin|>import csv import os import color def _GetDataDirPath(): return os.path.join(os.path.dirname(__file__), 'data') def _GetCsvPath(): return os.path.join(_GetDataDirPath(), 'dmccolors.csv') def _GetCsvString(): with open(_GetCsvPath()) as f: return f.rea...
def main(): for color in GetDMCColors(): print color
<|file_name|>tuple-struct.rs<|end_file_name|><|fim▁begin|><|fim▁hole|>// Copyright 2013-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://...
<|file_name|>sunburst.d.ts<|end_file_name|><|fim▁begin|>export * from "../.internal/plugins/sunburst/Sunburst"; <|fim▁hole|><|fim▁end|>
export * from "../.internal/plugins/sunburst/SunburstSeries";
<|file_name|>20.d.ts<|end_file_name|><|fim▁begin|><|fim▁hole|><|fim▁end|>
export { ColorSwitch20 as default } from "../../";
<|file_name|>TestDeadServerMetricRegionChore.java<|end_file_name|><|fim▁begin|>/* * 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 thi...
}
<|file_name|>nrf_matter_device_test.py<|end_file_name|><|fim▁begin|># Copyright 2022 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...
"serial_number": "FT2BSR6O",
<|file_name|>check_button.rs<|end_file_name|><|fim▁begin|>// This file was generated by gir (17af302) from gir-files (11e0e6d) // DO NOT EDIT use Actionable; use Bin; use Buildable; use Button; use Container; use ToggleButton; use Widget; use ffi; use glib::object::Downcast; use glib::object::IsA; use glib::translate:...
pub trait CheckButtonExt {} impl<O: IsA<CheckButton>> CheckButtonExt for O {}
<|file_name|>models.py<|end_file_name|><|fim▁begin|>from django.conf import settings<|fim▁hole|>from django.contrib.contenttypes.models import ContentType import jsonfield from .signals import event_logged class Log(models.Model): user = models.ForeignKey( getattr(settings, "AUTH_USER_MODEL", "auth.Use...
from django.db import models from django.utils import timezone from django.contrib.contenttypes.fields import GenericForeignKey
<|file_name|>dom_automation_controller.cc<|end_file_name|><|fim▁begin|>// Copyright (c) 2012 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. #include "content/renderer/dom_automation_controller.h" #include "base/bind.h"...
<|file_name|>chips-demo.ts<|end_file_name|><|fim▁begin|>import { Component } from '@angular/core'; @Component({ moduleId: module.id, selector: 'chips-demo', templateUrl: 'chips-demo.html', styleUrls: ['chips-demo.css'] }) export class ChipsDemoComponent {<|fim▁hole|><|fim▁end|>
}
<|file_name|>CustomListPreference.java<|end_file_name|><|fim▁begin|>package com.lpiem.apps.loupelec.utilities.customUiElement; import android.content.Context; import android.preference.ListPreference; import android.util.AttributeSet; /** * CustomListPreference Class */ public class CustomListPreference extends Lis...
<|file_name|>installed_application.py<|end_file_name|><|fim▁begin|># -*- coding: utf-8 -*- # Copyright (c) 2020, Frappe Technologies and contributors # For license information, please see license.txt from __future__ import unicode_literals<|fim▁hole|>class InstalledApplication(Document): pass<|fim▁end|>
# import frappe from frappe.model.document import Document
<|file_name|>workspacetreewidget.py<|end_file_name|><|fim▁begin|><|fim▁hole|># & Institut Laue - Langevin # SPDX - License - Identifier: GPL - 3.0 + # This file is part of the mantidqt package # # from __future__ import (absolute_import, unicode_literals) from mantidqt.utils.qt import import_qt WorkspaceTreeWidg...
# Mantid Repository : https://github.com/mantidproject/mantid # # Copyright &copy; 2017 ISIS Rutherford Appleton Laboratory UKRI, # NScD Oak Ridge National Laboratory, European Spallation Source
<|file_name|>ref_binding_to_reference.rs<|end_file_name|><|fim▁begin|>// edition:2018 // FIXME: run-rustfix waiting on multi-span suggestions #![warn(clippy::ref_binding_to_reference)] #![allow(clippy::needless_borrowed_reference)] fn f1(_: &str) {} macro_rules! m2 { ($e:expr) => { f1(*$e) }; } macro_...
let x = String::new(); // Ok, the pattern is from a macro
<|file_name|>PageItem.tsx<|end_file_name|><|fim▁begin|>import Link from "found/Link"; import * as React from "react"; import { flattenPermissions } from "../utils"; import { PermissionObject } from "../types"; import PermissionChips from "./PermissionChips"; import DateFromNow from "./DateFromNow"; type Props = { ...
</div> ); }
<|file_name|>task.py<|end_file_name|><|fim▁begin|># Copyright 2021 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 # # https://www.apache.org/licenses/LICENSE-2.0 # Unless requ...
<|file_name|>lg-thumbnail.js<|end_file_name|><|fim▁begin|>/*! lightgallery - v1.2.15 - 2016-03-10 * http://sachinchoolur.github.io/lightGallery/ * Copyright (c) 2016 Sachin N; Licensed Apache 2.0 */ (function($, window, document, undefined) { 'use strict'; var defaults = { thumbnail: true, ...
<|file_name|>ifaddrmsg.py<|end_file_name|><|fim▁begin|>import socket from pyroute2.common import map_namespace from pyroute2.netlink import nlmsg from pyroute2.netlink import nla # address attributes # # Important comment: # For IPv4, IFA_ADDRESS is a prefix address, not a local interface # address. It makes no differ...
unsigned char ifa_family; /* Address type */ unsigned char ifa_prefixlen; /* Prefixlength of address */ unsigned char ifa_flags; /* Address flags */ unsigned char ifa_scope; /* Address scope */
<|file_name|>mrp_bom.py<|end_file_name|><|fim▁begin|># -*- encoding: utf-8 -*- ############################################################################## # # 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 ...
<|file_name|>rocksdb-index.cc<|end_file_name|><|fim▁begin|>#include "RocksIndex.hh" #include <stdlib.h> #include <iostream> // Get command line arguments for array size (100M) and number of trials (1M) void arrayArgs(int argc, char* argv[], objectId_t& asize, int& reps) {<|fim▁hole|>} // Main program goes here int...
asize = (argc>1) ? strtoull(argv[1], 0, 0) : 100000000; reps = (argc>2) ? strtol(argv[2], 0, 0) : 1000000;
<|file_name|>issue-13352.rs<|end_file_name|><|fim▁begin|>// Copyright 2014 The Rust Project Developers. See the COPYRIGHT<|fim▁hole|>// Licensed under the Apache License, Version 2.0 <LICENSE-APACHE or // http://www.apache.org/licenses/LICENSE-2.0> or the MIT license // <LICENSE-MIT or http://opensource.org/licenses/MI...
// file at the top-level directory of this distribution and at // http://rust-lang.org/COPYRIGHT. //
<|file_name|>env-vars.rs<|end_file_name|><|fim▁begin|>// run-pass // ignore-wasm32-bare no env vars use std::env::*; fn main() { for (k, v) in vars_os() { // On Windows, the environment variable NUMBER_OF_PROCESSORS has special meaning.<|fim▁hole|> // Unfortunately, you can get different answers, d...
<|file_name|>Crypter.py<|end_file_name|><|fim▁begin|># -*- coding: utf-8 -*- from .Base import Base from .misc import parse_name, safename class Crypter(Base): __name__ = "Crypter" __type__ = "crypter" __version__ = "0.20" __status__ = "stable" __pattern__ = r'^unmatchable$' __config__ = [("...
folder = parse_name(name)
<|file_name|>test_all_nodes_recovery_with_one_cmd_create_vm.py<|end_file_name|><|fim▁begin|>''' Integration Test for creating KVM VM with all nodes shutdown and recovered. @author: Quarkonics ''' import zstackwoodpecker.test_util as test_util import zstackwoodpecker.test_state as test_state import zstackwoo...
vm.check() vm.destroy() test_util.test_pass('After Recover Node with One command, Create VM Test Success')
<|file_name|>BasicCanvasUsageExample01.js<|end_file_name|><|fim▁begin|><|fim▁hole|><|fim▁end|>
<canvas id="drawing" width="200" height="200">A drawing of something.</canvas>
<|file_name|>graph.py<|end_file_name|><|fim▁begin|># -*- coding: utf-8 -*- ############################################################################## # # OpenERP, Open Source Management Solution # Copyright (C) 2004-2009 Tiny SPRL (<http://tiny.be>). # Copyright (C) 2010-2011 OpenERP s.a. (<http://openerp....
inst = graph[name] else: inst = object.__new__(cls)
<|file_name|>locations.go<|end_file_name|><|fim▁begin|>// Copyright (C) 2014 Constantin Schomburg <me@cschomburg.com> // // Use of this source code is governed by an MIT-style // license that can be found in the LICENSE file. <|fim▁hole|> "time" ) type Location struct { Timestamp time.Time `json:"timestamp,omitempty"...
package schema import ( "fmt"
<|file_name|>InvalidPathException.java<|end_file_name|><|fim▁begin|>/** * This file is part of the CRISTAL-iSE kernel. * Copyright (c) 2001-2015 The CRISTAL Consortium. All rights reserved. * * This library is free software; you can redistribute it and/or modify it * under the terms of the GNU Lesser General ...
package org.cristalise.kernel.lookup; public class InvalidPathException extends Exception {
<|file_name|>comparison.py<|end_file_name|><|fim▁begin|>import sys import requests try: from .helper import * except SystemError: from helper import * def compareRequestsAndSelenium(url): html1 = str(requests.get(url).text) try: driver = webdriver.Firefox() driver.maximize_window() ...
finally: driver.close()
<|file_name|>SortAscIcon.tsx<|end_file_name|><|fim▁begin|><|fim▁hole|> * Copyright (C) 2009-2022 SonarSource SA * mailto:info AT sonarsource DOT com * * This program 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 Soft...
/* * SonarQube
<|file_name|>Exclamation.js<|end_file_name|><|fim▁begin|>import React from 'react'; import SvgExclamation from '../svg/Exclamation.js'; import styles from './InputArea.scss'; const exclamation = () => <div className={styles.suffix + ' ' + styles.exclamation}> <SvgExclamation width={2} height={11}/> </div>;<|f...
export default exclamation;
<|file_name|>forms.js<|end_file_name|><|fim▁begin|>/*------------------------------------------------------------------------ # Full Name of JSN UniForm # ------------------------------------------------------------------------ # author JoomlaShine.com Team # copyright Copyright (C) 2012 JoomlaShine.com. All Rig...
} JSNUniformForms.prototype = { //Create modal box email list select
<|file_name|>main.rs<|end_file_name|><|fim▁begin|>use std::collections::BinaryHeap; <|fim▁hole|> let mut heap = BinaryHeap::new(); heap.push(-1); let mut last = 0; loop { let i = heap.pop(); let x = match i { Some(n) => -n, None => 0, }; if x > las...
// Prints out numbers whose only prime factors are 2, 3, and 5. fn main() {
<|file_name|>ControllerFacade.java<|end_file_name|><|fim▁begin|>/* * 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 un...
// never include sensitive properties values in search results if (descriptor.isSensitive()) {
<|file_name|>PizzaDAO.java<|end_file_name|><|fim▁begin|>package com.aws.global.dao; import java.util.ArrayList; import com.aws.global.classes.Pizza; import com.aws.global.common.base.BaseDAO; import com.aws.global.mapper.PizzaRowMapper; public class PizzaDAO extends BaseDAO{ //SQL Statement when user adds a pizza...
<|file_name|>util_test.py<|end_file_name|><|fim▁begin|># _*_ coding: utf-8 _*_ import os try: from cStringIO import StringIO # python 2 except ImportError: from io import StringIO # python 3 from collections import OrderedDict import unittest from tornado.escape import to_unicode from tortik.util import mak...
<|file_name|>__init__.py<|end_file_name|><|fim▁begin|># -*- coding: utf-8 -*- from operator import attrgetter from pyangbind.lib.yangtypes import RestrictedPrecisionDecimalType from pyangbind.lib.yangtypes import RestrictedClassType from pyangbind.lib.yangtypes import TypedListType from pyangbind.lib.yangtypes import Y...
"levels", "level",
<|file_name|>stream.rs<|end_file_name|><|fim▁begin|>//! Convenience wrapper for streams to switch between plain TCP and TLS at runtime. //! //! There is no dependency on actual TLS implementations. Everything like //! `native_tls` or `openssl` will work as long as there is a TLS stream supporting standard //! `Read + ...
/// Encrypted socket stream using `native-tls`. #[cfg(feature = "native-tls")] NativeTls(tokio_native_tls::TlsStream<S>),
<|file_name|>spelling.py<|end_file_name|><|fim▁begin|># peppy Copyright (c) 2006-2010 Rob McMullen # Licenced under the GPLv2; see http://peppy.flipturn.org for more info """Spell checking provider """ import os, sys import wx from wx.lib.pubsub import Publisher from peppy.yapsy.plugins import * from peppy.lib.stcsp...
<|file_name|>test_model.py<|end_file_name|><|fim▁begin|>from nose.tools import * # noqa import mock from boto.s3.connection import * # noqa from tests.base import OsfTestCase, get_default_metaschema from tests.factories import ProjectFactory from framework.auth import Auth from website.addons.base.testing import mo...
def test_serialize_credentials(self):
<|file_name|>georss.py<|end_file_name|><|fim▁begin|># Support for the GeoRSS format # Copyright 2010-2015 Kurt McKee <contactme@kurtmckee.org> # Copyright 2002-2008 Mark Pilgrim # All rights reserved. # # This file is a part of feedparser. # # Redistribution and use in source and binary forms, with or without modificat...
# whitespace. There must be at least two pairs.
<|file_name|>MediaApiWebRtc2HttpTest.java<|end_file_name|><|fim▁begin|>/* * (C) Copyright 2014 Kurento (http://kurento.org/) * * All rights reserved. This program and the accompanying materials * are made available under the terms of the GNU Lesser General Public License * (LGPL) version 2.1 which accompanies this...
ExecutorService exec = Executors.newFixedThreadPool(NPLAYERS); List<Future<?>> results = new ArrayList<>();
<|file_name|>explicit_multisample.py<|end_file_name|><|fim▁begin|>from OpenGLCffi.GL import params @params(api='gl', prms=['pname', 'index', 'val']) def glGetMultisamplefvNV(pname, index, val): pass @params(api='gl', prms=['index', 'mask'])<|fim▁hole|>def glSampleMaskIndexedNV(index, mask): pass @params(api='gl',...
<|file_name|>winprocess.py<|end_file_name|><|fim▁begin|>""" Windows Process Control winprocess.run launches a child process and returns the exit code. Optionally, it can: redirect stdin, stdout & stderr to files run the command as another user limit the process's running time control the process window (locati...
xySize: window size (width, height) in pixels desktop: lpDesktop - name of desktop e.g. 'winsta0\\default'
<|file_name|>fixed.rs<|end_file_name|><|fim▁begin|>// Copyright 2013-2017, The Gtk-rs Project Developers. // See the COPYRIGHT file at the top-level directory of this distribution. // Licensed under the MIT license, see the LICENSE file or <http://opensource.org/licenses/MIT> use ffi; use glib_ffi; use glib::translate...
assert!(has_widget(self, item), "this item isn't in the Fixed's widget list"); let mut value = Value::from(&0); unsafe {
<|file_name|>test-runner-hides-main.rs<|end_file_name|><|fim▁begin|>// Copyright 2012-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://ww...
// Building as a test runner means that a synthetic main will be run,
<|file_name|>magnetostaticInteractions.py<|end_file_name|><|fim▁begin|># # Copyright (C) 2013,2014,2015,2016 The ESPResSo project # # This file is part of ESPResSo. # # ESPResSo 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 Soft...
# GNU General Public License for more details.
<|file_name|>function2promise.ts<|end_file_name|><|fim▁begin|>export = function test() { let output = add(10, 20); console.log(`output is ${output}`); let p1 = fn2promise(add, 10, 20); p1.then((value) => { console.log(`${value} received`); }); let p2 = fn2promise(add, 1, 2); p2.t...
return value + 5;
<|file_name|>app.js<|end_file_name|><|fim▁begin|>import express from 'express' import cors from 'cors' import bodyParser from 'body-parser' import helmet from 'helmet' import httpStatus from 'http-status' import path from 'path' import routes from './routes' import logger from './helpers/logger.js' const app = expres...
// API Routes app.use('/', routes)
<|file_name|>create.go<|end_file_name|><|fim▁begin|>package tccpnoutputs import (<|fim▁hole|> "github.com/giantswarm/microerror" "github.com/giantswarm/aws-operator/service/controller/controllercontext" "github.com/giantswarm/aws-operator/service/controller/key" "github.com/giantswarm/aws-operator/service/interna...
"context" "strconv"
<|file_name|>csum.cc<|end_file_name|><|fim▁begin|>/* Copyright (c) 2008 The Board of Trustees of The Leland Stanford * Junior University * * We are making the OpenFlow specification and associated documentation * (Software) available for public use and benefit with the expectation * that others will use, modify an...
<|file_name|>main.rs<|end_file_name|><|fim▁begin|>use std::collections::HashMap; use std::io::{self, BufRead}; use lazy_regex::regex; use regex::Regex; use structopt::StructOpt; type H = HashMap<Header, Vec<(String, String, String)>>; #[derive(Debug, Clone, PartialEq, Eq, Hash)] enum Header { Versioned { package...
component.to_owned(), )); }
<|file_name|>version.py<|end_file_name|><|fim▁begin|><|fim▁hole|><|fim▁end|>
# -*- coding: utf-8 -*- __version__ = (0, 1, 0, 'final', 0)
<|file_name|>ExtendedRandomIter.java<|end_file_name|><|fim▁begin|>/* * GeoTools - The Open Source Java GIS Toolkit * http://geotools.org * * (C) 2015, Open Source Geospatial Foundation (OSGeo) * * This library is free software; you can redistribute it and/or * modify it under the terms of the GNU ...
} ExtendedRandomIter(RandomIter delegate, RenderedOp op) { super();
<|file_name|>path.rs<|end_file_name|><|fim▁begin|>use std::fmt; use std::hash::{Hash, Hasher}; use std::slice::{Iter, IterMut}; #[derive(Clone, PartialEq, Hash, Debug)] pub enum Fragment { Index(usize), Name(String) } impl fmt::Display for Fragment { fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result { ...
<|file_name|>ReducedDelegateFunctionSymbol.java<|end_file_name|><|fim▁begin|>/* * Copyright 2014 Guidewire Software, Inc. */ package gw.internal.gosu.parser; import gw.lang.reflect.IMethodInfo; /** */ public class ReducedDelegateFunctionSymbol extends ReducedDynamicFunctionSymbol implements IReducedDelegateFuncti...
return _targetMethodInfo; } }
<|file_name|>scaleway_sshkey.py<|end_file_name|><|fim▁begin|>#!/usr/bin/python # # Scaleway SSH keys management module # # Copyright (C) 2018 Online SAS. # https://www.scaleway.com # # GNU General Public License v3.0+ (see COPYING or https://www.gnu.org/licenses/gpl-3.0.txt) from __future__ import absolute_import, div...
required: true timeout: description:
<|file_name|>index.js<|end_file_name|><|fim▁begin|>/** * React Starter Kit (https://www.reactstarterkit.com/) * * Copyright © 2014-present Kriasoft, LLC. All rights reserved. *<|fim▁hole|> */ import React from 'react'; // import Layout from '../../components/Layout'; const title = 'Admin Page'; const isAdmin = fa...
* This source code is licensed under the MIT license found in the * LICENSE.txt file in the root directory of this source tree.
<|file_name|>test_cli20_floatingips.py<|end_file_name|><|fim▁begin|>#!/usr/bin/env python # Copyright 2012 Red Hat # 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...
position_names = ['floating_network_id', 'port_id', 'fixed_ip_address']
<|file_name|>test_color.py<|end_file_name|><|fim▁begin|>import pytest from plumbum.colorlib.styles import ANSIStyle, Color, AttributeNotFound, ColorNotFound from plumbum.colorlib.names import color_html, FindNearest class TestNearestColor: def test_exact(self): assert FindNearest(0,0,0).all_fast() == 0 ...
assert FindNearest(0,255,0).only_basic() == 2
<|file_name|>same.rs<|end_file_name|><|fim▁begin|>extern crate iron_valid; extern crate params; use iron_valid::{Rule, validate}; use params::{Map, Value}; use std::collections::BTreeMap; #[test] fn test_same_valid_string() { let mut params = Map::new(); params.assign("same", Value::String("foo".to_owned()))....
assert!(result.is_ok()); assert_eq!(result.unwrap().find(&["same"]).unwrap(),
<|file_name|>DOUBLONnewBDD.py<|end_file_name|><|fim▁begin|>#!/usr/bin/python # -*- coding: utf-8 -*- import psycopg2 import psycopg2.extras import os import subprocess import sys sys.path.append("C:\\Program Files\\FME\\fmeobjects\\python27") import fmeobjects # ----------------------##### VARIABLES #####-...
<|file_name|>mc.py<|end_file_name|><|fim▁begin|>import PandaProd.Producer.opts PandaProd.Producer.opts.options.config = 'Autumn18'<|fim▁hole|><|fim▁end|>
from PandaProd.Producer.prod import process
<|file_name|>chebi2gene.py<|end_file_name|><|fim▁begin|>#!/usr/bin/python """ Small web application to retrieve information from uniprot and itag for a given compound. The idea is that for one compound we are able to find out in which reactions it is involved and what are the proteins involved in these reactions. For...
@APP.route('/chebi/<chebi_id>') def show_chebi(chebi_id): """ Shows the front page. All the content of this page is in the index.html file under the
<|file_name|>main.js<|end_file_name|><|fim▁begin|><|fim▁hole|><|fim▁end|>
// Insert your JS here
<|file_name|>function.py<|end_file_name|><|fim▁begin|># function.py - views for evaluating SQL functions on SQLAlchemy models # # Copyright 2011 Lincoln de Sousa <lincoln@comum.org>. # Copyright 2012, 2013, 2014, 2015, 2016 Jeffrey Finkelstein # <jeffrey.finkelstein@gmail.com> and contributors. # # This file ...
# Flask-Restless is distributed under both the GNU Affero General Public # License version 3 and under the 3-clause BSD license. For more
<|file_name|>saml.go<|end_file_name|><|fim▁begin|>package provider import ( "crypto/rand" "crypto/rsa" "crypto/tls" "crypto/x509" "encoding/base64" "encoding/pem" "encoding/xml" "errors" "fmt" "io/ioutil" "math/big" "net/http" "net/url" "strings" "time" "github.com/netlify/gotrue/models" "github.com/...
<|file_name|>gen_difficultytest.go<|end_file_name|><|fim▁begin|>// Code generated by github.com/fjl/gencodec. DO NOT EDIT.<|fim▁hole|> package tests import ( "encoding/json" "math/big" "github.com/okcoin/go-okcoin/common" "github.com/okcoin/go-okcoin/common/math" ) var _ = (*difficultyTestMarshaling)(nil) func ...
<|file_name|>BorderLayout.java<|end_file_name|><|fim▁begin|>/* * This file is part of lanterna (https://github.com/mabe02/lanterna). * * lanterna 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, eit...
} } }
<|file_name|>main.rs<|end_file_name|><|fim▁begin|>#![feature(slice_patterns, convert, vec_push_all)] extern crate md5; mod keys; use keys::*; fn main() { // capture arguments let key = match get_key_from_args() { Ok(k) => k, Err(why) => { handle_errors(why); return; }, }; // separate key into segment...
let _ = match check_segment3(segments.as_ref(), &mut mod_key) { Ok(_) => {}, Err(why) => {
<|file_name|>log.py<|end_file_name|><|fim▁begin|># -*- coding: utf-8 -*- import logging<|fim▁hole|>from . import constants logger = logging.getLogger(constants.NAME)<|fim▁end|>
<|file_name|>views.py<|end_file_name|><|fim▁begin|>from django.shortcuts import render from django.http import HttpResponseRedirect from django.core.urlresolvers import reverse import datetime, time, requests, re, os import bs4 from django.contrib.admin.views.decorators import staff_member_required from decimal import ...
c32 = Gas.objects.get(name='Fullerite-C32') c320 = Gas.objects.get(name='Fullerite-C320') c540 = Gas.objects.get(name='Fullerite-C540')
<|file_name|>solve_ph_array.py<|end_file_name|><|fim▁begin|>from fprops import * from pylab import * import sys #P = fluid('water','helmholtz'); #P = fluid('ammonia','pengrob'); P = fluid('carbondioxide','pengrob');<|fim▁hole|>print "SOLVING TRIPLE POINT..." print "Fluid: %s\nData source: %s" %(P.name, P.source) try...
<|file_name|>plugin.py<|end_file_name|><|fim▁begin|>from Plugins.Plugin import PluginDescriptor from Screens.Console import Console from Screens.ChoiceBox import ChoiceBox from Screens.MessageBox import MessageBox from Screens.Screen import Screen from Screens.Standby import TryQuitMainloop from Screens.Ipkg import Ipk...
self["status"] = StaticText("")
<|file_name|>scroll-tofixed-view.js<|end_file_name|><|fim▁begin|>var $ = require('jquery'); var CoreView = require('backbone/core-view'); var checkAndBuildOpts = require('builder/helpers/required-opts');<|fim▁hole|> module.exports = CoreView.extend({ events: { 'click .js-foo': '_fooHandler' }, initialize: f...
var REQUIRED_OPTS = [ 'el' ];
<|file_name|>test.py<|end_file_name|><|fim▁begin|>#!/usr/bin/env python # # Copyright 2008 the V8 project authors. 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...
<|file_name|>parser.py<|end_file_name|><|fim▁begin|>"""Parse ISI journal abbreviations website.""" # Copyright (c) 2012 Andrew Dawson # # 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 withou...
if self.parser_state == 'dt': self.journal_names.append(''.join(self.data_entities).strip())
<|file_name|>dependency.rs<|end_file_name|><|fim▁begin|>use std::fmt; use std::rc::Rc; use std::str::FromStr; use semver::VersionReq; use semver::ReqParseError; use serde::ser; use core::{SourceId, Summary, PackageId}; use util::{Cfg, CfgExpr, Config}; use util::errors::{CargoResult, CargoResultExt, CargoError}; ///...
<|file_name|>table.py<|end_file_name|><|fim▁begin|>""" PynamoDB Connection classes ~~~~~~~~~~~~~~~~~~~~~~~~~~~ """ from typing import Any, Dict, Mapping, Optional, Sequence from pynamodb.connection.base import Connection, MetaTable, OperationSettings from pynamodb.constants import DEFAULT_BILLING_MODE, KEY from pynam...
key: str = KEY,
<|file_name|>partitions.py<|end_file_name|><|fim▁begin|># -*- 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 # # https://www.apache.org/licenses...
# Unless required by applicable law or agreed to in writing, software # distributed under the License is distributed on an "AS IS" BASIS,
<|file_name|>Projection.cpp<|end_file_name|><|fim▁begin|>/* Copyright_License { XCSoar Glide Computer - http://www.xcsoar.org/ Copyright (C) 2000-2021 The XCSoar Project A detailed list of copyright holders can be found in the file "AUTHORS". This program is free software; you can redistribute it and/or mod...
scale = _scale; // Calculate earth radius in pixels draw_scale = FAISphere::REARTH * scale;
<|file_name|>ExportNamedDeclaration.js<|end_file_name|><|fim▁begin|>const AssignmentExpression = require('./AssignmentExpression'); const Class = require('./Class'); const DecoratorDescriptor = require('./DecoratorDescriptor'); const ExpressionStatement = require('./ExpressionStatement'); const Function = require('./Fu...
* @type {string} */ this.docblock = null;
<|file_name|>import-types.d.ts<|end_file_name|><|fim▁begin|>declare module '*.scss' { const content: {[className: string]: string}; export default content; } declare module '*.png' { const src: string; export default src; } <|fim▁hole|>declare module '*.svg' { import * as React from 'react'; export const R...
<|file_name|>conference.py<|end_file_name|><|fim▁begin|>#!/usr/bin/env python """ conference.py -- Udacity conference server-side Python App Engine API; uses Google Cloud Endpoints $Id: conference.py,v 1.25 2014/05/24 23:42:19 wesc Exp wesc $ created by wesc on 2014 apr 21 """ __author__ = 'wesc+api@google.com...
name='getConferenceSessionsByType') def getConferenceSessionsByType(self, request):
<|file_name|>urls.py<|end_file_name|><|fim▁begin|>from django.conf.urls import include, patterns, url from django.views.generic.base import RedirectView from mdn.urls import mdn_urlpatterns from webplatformcompat.routers import router from .views import RequestView, ViewFeature webplatformcompat_urlpatterns = patter...
template_name='webplatformcompat/browse.jinja2'),
<|file_name|>ibm3.py<|end_file_name|><|fim▁begin|># -*- coding: utf-8 -*- # Natural Language Toolkit: IBM Model 3 # # Copyright (C) 2001-2013 NLTK Project # Authors: Chin Yee Lee, Hengfeng Li, Ruxin Hou, Calvin Tanujaya Lim # URL: <http://nltk.org/> # For license information, see LICENSE.TXT """ Translation model that...
of Model 2.
<|file_name|>gen_server_objects.py<|end_file_name|><|fim▁begin|>#!/usr/bin/env python print("""# ******* WARNING - AUTO GENERATED CODE - DO NOT EDIT ******* module VimSdk module VmomiSupport """) <|fim▁hole|> print(""" end end """)<|fim▁end|>
import ServerObjects import PbmObjects import SmsObjects
<|file_name|>subst_output.rs<|end_file_name|><|fim▁begin|>// Test substitutions involving only the outputs of the function. extern crate crucible; use crucible::*; use crucible::method_spec::{MethodSpec, MethodSpecBuilder, clobber_globals}; fn f(x: u8) -> (u8, u8) { (x, x + 1) }<|fim▁hole|> let x = <u8>::symbol...
fn f_spec() -> MethodSpec {
<|file_name|>uxvismode.js<|end_file_name|><|fim▁begin|>Ext.namespace('Ext.ux.plugin'); Ext.onReady(function(){ /* This important rule solves many of the <object/iframe>.reInit issues encountered * when setting display:none on an upstream(parent) element (on all Browsers except IE). * This default ...
CSS.createStyleSheet('.x-hide-nosize{height:0px!important;width:0px!important;border:none!important;zoom:1;}.x-hide-nosize * {height:0px!important;width:0px!important;border:none!important;zoom:1;}'); CSS.refreshCache();
<|file_name|>setting.js<|end_file_name|><|fim▁begin|>// ---------------------------------------------------------------------------- // Module initialization var Config = require("config").config; var utils = require("utils"); var validators = require("validators"); // -------------------------------------------------...
}; // ---------------------------------------------------------------------------- // Create the object representing this particular setting
<|file_name|>on.js<|end_file_name|><|fim▁begin|>/** * Created by tkachenko on 14.04.15. */ ATF.invoke(['$directiveProvider', 'utils', 'jQuery'], function ($directiveProvider, utils, $) { $directiveProvider.register('$On', { link: function (name, $el, scope, args, vars) { var __vars = vars||{...
<|file_name|>Adlez.py<|end_file_name|><|fim▁begin|>import sys, pygame, math, random, time from Level import * from Player import * from Enemy import * from NPC import * from Menu import * from Item import * pygame.init() clock = pygame.time.Clock() width = 1000 height = 700 size = width, height bgColor = r,b,g = 255...
player.go("down") elif event.key == pygame.K_a or event.key == pygame.K_LEFT: player.go("left")
<|file_name|>GridClientConsistentHash.java<|end_file_name|><|fim▁begin|>/* * 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 t...
// Get first node hash in the circle clock-wise. return circle.get(tailEntry == null ? firstEntry.getKey() : tailEntry.getKey()).first(); } finally {
<|file_name|>urlsearchparams.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/. */ use dom::bindings::cell::DomRefCell; use dom::binding...
} }
<|file_name|>policy.go<|end_file_name|><|fim▁begin|>// Copyright 2014 Canonical Ltd. // Licensed under the AGPLv3, see LICENCE file for details. package state import ( "fmt" "launchpad.net/juju-core/constraints" "launchpad.net/juju-core/environs/config" "launchpad.net/juju-core/errors" ) // Policy is an interfa...
// PrecheckInstance performs a preflight check on the specified // series and constraints, ensuring that they are possibly valid for