code
stringlengths
1
25.8M
language
stringclasses
18 values
source
stringclasses
4 values
repo
stringclasses
78 values
path
stringlengths
0
268
# This is equivalent to the core suite, but runs with CBR with histogram CE enabled. test_kind: js_test selector: roots: - jstests/core/**/*.js - jstests/core_standalone/**/*.js exclude_files: # Transactions are not supported on MongoDB standalone nodes, so we do not run these tests in the # 'core' ...
unknown
github
https://github.com/mongodb/mongo
buildscripts/resmokeconfig/suites/query_cbr_histogram_jscore_passthrough.yml
/* Copyright 2024 The Kubernetes 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, ...
go
github
https://github.com/kubernetes/kubernetes
cmd/kubeadm/app/cmd/phases/upgrade/apply/bootstraptoken.go
from test.test_json import PyTest, CTest import re # 2007-10-05 JSONDOCS = [ # http://json.org/JSON_checker/test/fail1.json '"A JSON payload should be an object or array, not a string."', # http://json.org/JSON_checker/test/fail2.json '["Unclosed array"', # http://json.org/JSON_checker/test/fail3.j...
unknown
codeparrot/codeparrot-clean
import argparse import logging from neutronclient.neutron.v2_0 import CreateCommand from neutronclient.neutron.v2_0 import DeleteCommand from neutronclient.neutron.v2_0 import ListCommand from neutronclient.neutron.v2_0 import UpdateCommand from neutronclient.neutron.v2_0 import ShowCommand class ListPolicy(ListComma...
unknown
codeparrot/codeparrot-clean
#!/usr/bin/env python # Licensed to Cloudera, Inc. under one # or more contributor license agreements. See the NOTICE file # distributed with this work for additional information # regarding copyright ownership. Cloudera, Inc. licenses this file # to you under the Apache License, Version 2.0 (the # "License"); you ma...
unknown
codeparrot/codeparrot-clean
import {createHookWrapper, CONST_STRING0, CONST_STRING1} from 'shared-runtime'; function useHook({value}) { return { getValue() { return identity(value); }, } ? CONST_STRING0 : CONST_STRING1; } export const FIXTURE_ENTRYPOINT = { fn: createHookWrapper(useHook), params: [{value: 0}], };
javascript
github
https://github.com/facebook/react
compiler/packages/babel-plugin-react-compiler/src/__tests__/fixtures/compiler/object-literal-method-in-ternary-test.js
#if defined __AVX512__ || defined __AVX512F__ #include <immintrin.h> void test() { __m512i a, b, c; a = _mm512_popcnt_epi8(a); // BITALG a = _mm512_shrdv_epi64(a, b, c); // VBMI2 a = _mm512_popcnt_epi64(a); // VPOPCNTDQ a = _mm512_dpwssd_epi32(a, b, c);...
cpp
github
https://github.com/opencv/opencv
cmake/checks/cpu_avx512icl.cpp
# Copyright (C) 2001-2007 Python Software Foundation # Author: Anthony Baxter # Contact: email-sig@python.org """Class representing audio/* type MIME documents.""" __all__ = ['MIMEAudio'] import sndhdr from io import BytesIO from email import encoders from email.mime.nonmultipart import MIMENonMultipart _sndhdr_MI...
unknown
codeparrot/codeparrot-clean
""" Fantasm: A taskqueue-based Finite State Machine for App Engine Python Docs and examples: http://code.google.com/p/fantasm/ Copyright 2010 VendAsta Technologies 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 ob...
unknown
codeparrot/codeparrot-clean
#!/usr/bin/python # -*- coding: utf-8 -*- # (c) 2015, Joseph Callen <jcallen () csc.com> # GNU General Public License v3.0+ (see COPYING or https://www.gnu.org/licenses/gpl-3.0.txt) from __future__ import absolute_import, division, print_function __metaclass__ = type ANSIBLE_METADATA = {'metadata_version': '1.1', ...
unknown
codeparrot/codeparrot-clean
// @enableNewMutationAliasingModel:false import {makeArray, mutate} from 'shared-runtime'; /** * Bug repro: * Found differences in evaluator results * Non-forget (expected): * (kind: ok) * {"bar":4,"x":{"foo":3,"wat0":"joe"}} * {"bar":5,"x":{"foo":3,"wat0":"joe"}} * Forget: * (kind: ok) * {"bar"...
typescript
github
https://github.com/facebook/react
compiler/packages/babel-plugin-react-compiler/src/__tests__/fixtures/compiler/bug-capturing-func-maybealias-captured-mutate.ts
// This file is part of OpenCV project. // It is subject to the license terms in the LICENSE file found in the top-level directory // of this distribution and at http://opencv.org/license.html #include "precomp.hpp" #include "opencl_kernels_core.hpp" #include "split.simd.hpp" #include "split.simd_declarations.hpp" //...
cpp
github
https://github.com/opencv/opencv
modules/core/src/split.dispatch.cpp
import types from requests.exceptions import HTTPError from herodb.client import StoreClient from herodb.test.util import run_server, stop_server from nose import tools as nt import time client = None def setup_hero(): global client run_server() time.sleep(1) client = StoreClient('http://localhost:808...
unknown
codeparrot/codeparrot-clean
# -*- coding: utf-8 -*- from __future__ import unicode_literals from django.conf import settings # import default models from shop to materialize them from shop.models.defaults.address import ShippingAddress, BillingAddress from shop.models.defaults.cart import Cart from shop.models.defaults.cart_item import CartItem...
unknown
codeparrot/codeparrot-clean
# encoding: utf-8 """ Style object hierarchy. """ from __future__ import ( absolute_import, division, print_function, unicode_literals ) from . import BabelFish from ..enum.style import WD_STYLE_TYPE from ..shared import ElementProxy from ..text.font import Font from ..text.parfmt import ParagraphFormat def Sty...
unknown
codeparrot/codeparrot-clean
#include <gtest/gtest.h> #include <ATen/core/boxing/impl/test_helpers.h> #include <ATen/core/op_registration/op_registration.h> #include <ATen/core/Tensor.h> #include <torch/csrc/jit/frontend/function_schema_parser.h> #include <torch/library.h> #include <ATen/core/LegacyTypeDispatch.h> using c10::RegisterOperators; ...
cpp
github
https://github.com/pytorch/pytorch
aten/src/ATen/core/boxing/impl/make_boxed_from_unboxed_functor_test.cpp
#!/usr/bin/env python from distutils.core import setup import OSC setup(name='pyOSC', version="%s.%s-%s" % OSC.version, description='Simple OpenSoundControl module in Pure Python', long_description="""Simple OpenSoundControl module in Pure Python. Replaces the 'SimpleOSC' module. This implementation is intended...
unknown
codeparrot/codeparrot-clean
from __future__ import unicode_literals import os from django.template import Context, Engine, TemplateSyntaxError from django.template.base import Node from django.template.library import InvalidTemplateLibrary from django.test import SimpleTestCase, ignore_warnings from django.test.utils import extend_sys_path from...
unknown
codeparrot/codeparrot-clean
# Copyright (c) 2013, Web Notes Technologies Pvt. Ltd. and Contributors # License: GNU General Public License v3. See license.txt from __future__ import unicode_literals import frappe def execute(): frappe.reload_doc("accounts", "doctype", "tax_rule") customers = frappe.db.sql("""select name, default_taxes_and_cha...
unknown
codeparrot/codeparrot-clean
# -*- coding: utf-8 -*- ############################################################################## # # OpenERP, Open Source Management Solution # Copyright (C) 2004-2010 Tiny SPRL (<http://tiny.be>). # # This program is free software: you can redistribute it and/or modify # it under the terms of the GNU...
unknown
codeparrot/codeparrot-clean
// Copyright 2024 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/LICENSE-2.0 // // Unless required by applicable law or agreed t...
go
github
https://github.com/etcd-io/etcd
server/embed/etcd_test.go
# -*- coding: utf-8 -*- # # Horizon documentation build configuration file, created by # sphinx-quickstart on Thu Oct 27 11:38:59 2011. # # This file is execfile()d with the current directory set to its # containing dir. # # Note that not all possible configuration values are present in this # autogenerated file. # # A...
unknown
codeparrot/codeparrot-clean
# -*- coding: utf-8 -*- # # This file is part of Invenio. # Copyright (C) 2010, 2011, 2013, 2014, 2015 CERN. # # Invenio 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 of the # License, or (a...
unknown
codeparrot/codeparrot-clean
#!/usr/bin/env python """Script to split a large mediawiki file into multiple files, by header.""" import sys import re import os ADD_TOC = True # Add TOC everywhere? def usage(): print "Usage: [scriptname] [infilename]" if len(sys.argv) != 2: usage() exit() filename_in = sys.argv[1] if '.' in filename...
unknown
codeparrot/codeparrot-clean
# Copyright 2016 The TensorFlow Authors. All Rights Reserved. # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applica...
unknown
codeparrot/codeparrot-clean
"""Support for Yeelight Sunflower color bulbs (not Yeelight Blue or WiFi).""" import logging import voluptuous as vol import yeelightsunflower from homeassistant.components.light import ( ATTR_BRIGHTNESS, ATTR_HS_COLOR, PLATFORM_SCHEMA, SUPPORT_BRIGHTNESS, SUPPORT_COLOR, LightEntity, ) from ho...
unknown
codeparrot/codeparrot-clean
/* * Copyright 2010-2024 JetBrains s.r.o. and Kotlin Programming Language contributors. * Use of this source code is governed by the Apache 2.0 license that can be found in the license/LICENSE.txt file. */ package org.jetbrains.kotlin.analysis.api.standalone.fir.test.cases.generated.cases.components.typeCreator; i...
java
github
https://github.com/JetBrains/kotlin
analysis/analysis-api-standalone/tests-gen/org/jetbrains/kotlin/analysis/api/standalone/fir/test/cases/generated/cases/components/typeCreator/FirStandaloneNormalAnalysisSourceModuleTypeParameterTypeTestGenerated.java
# vim: tabstop=4 shiftwidth=4 softtabstop=4 # 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...
unknown
codeparrot/codeparrot-clean
import asyncio,gzip from random import shuffle from .FDB import FDB from .TerminalWrapper import TerminalWrapper from .ProgressBar import ProgressBar from .Common import print_error class FDBController(object): def __init__(self,limit=5,lineno=0,loop=None,pterminal = None,wordlist=None,extensions=None): se...
unknown
codeparrot/codeparrot-clean
# -*- coding: 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): # Deleting field 'Gloss.comp' db.delete_column('dictionary_gloss', 'comp') # Changing field 'Gloss.i...
unknown
codeparrot/codeparrot-clean
#!/usr/bin/python # -*- coding: utf-8 -*- # Copyright: (c) 2015, Joseph Callen <jcallen () csc.com> # Copyright: (c) 2018, Ansible Project # GNU General Public License v3.0+ (see COPYING or https://www.gnu.org/licenses/gpl-3.0.txt) from __future__ import absolute_import, division, print_function __metaclass__ = type ...
unknown
codeparrot/codeparrot-clean
# Copyright (c) 2013, Web Notes Technologies Pvt. Ltd. and Contributors # License: GNU General Public License v3. See license.txt from __future__ import unicode_literals import webnotes from webnotes.utils import flt, getdate from webnotes.model.bean import getlist class DocType: def __init__(self,d,dl): self.doc,...
unknown
codeparrot/codeparrot-clean
<script setup> import * as Plot from "@observablehq/plot"; import * as d3 from "d3"; import {ref} from "vue"; import PlotRender from "../components/PlotRender.js"; const domain = ref("a,b,c,d,e,f"); const padding = ref(0.1); const paddingOuter = ref(0.1); const paddingInner = ref(0.1); const align = ref(0.5); const r...
unknown
github
https://github.com/d3/d3
docs/d3-scale/band.md
# -*- coding: iso-8859-1 -*- """ MoinMoin - DocBook Formatter @copyright: 2005,2008 by Mikko Virkkilä <mvirkkil@cc.hut.fi> @copyright: 2005 by MoinMoin:AlexanderSchremmer (small modifications) @copyright: 2005 by MoinMoin:Petr Pytelka <pyta@lightcomp.com> (small modifications) @copyright: 2009 by M...
unknown
codeparrot/codeparrot-clean
#!/usr/bin/env python import os import tornado.web from baseHandler import BaseHandler from traffic_cloud_utils.app_config import get_project_path, get_project_video_path from traffic_cloud_utils.video import save_video_frame from traffic_cloud_utils.plotting.visualization import road_user_traj, turn_icon_counts from ...
unknown
codeparrot/codeparrot-clean
from django.core.urlresolvers import reverse from django.views.generic import CreateView, ListView from django.views.generic.dates import timezone_today from .forms import CorporateMemberSignUpForm from .models import CorporateMember, DeveloperMember class DeveloperMemberListView(ListView): model = DeveloperMembe...
unknown
codeparrot/codeparrot-clean
{ "kind": "Dashboard", "apiVersion": "dashboard.grafana.app/v2beta1", "metadata": { "name": "v0alpha1.shared_queries.v42" }, "spec": { "annotations": [ { "kind": "AnnotationQuery", "spec": { "query": { "kind": "DataQuery", "group": "datasource", ...
json
github
https://github.com/grafana/grafana
apps/dashboard/pkg/migration/conversion/testdata/output/migrated_dev_dashboards/panel-common/v0alpha1.shared_queries.v42.v2beta1.json
# Copyright 2013 Google Inc. All Rights Reserved. """A git credential helper that provides Google git repository passwords. Reads a session from stdin that looks a lot like: protocol=https host=code.google.com And writes out a session to stdout that looks a lot like: username=me password=secret Errors will b...
unknown
codeparrot/codeparrot-clean
# 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 'Order.transaction_id' db.add_column('shop_order', 'transaction_id', self.gf('django.db.models.fiel...
unknown
codeparrot/codeparrot-clean
/* * Copyright (c) 2007 Mockito contributors * This program is made available under the terms of the MIT License. */ package org.mockito.internal.reporting; import static org.junit.Assert.assertEquals; import org.junit.Test; import org.mockitoutil.TestBase; public class PluralizerTest extends TestBase { @Tes...
java
github
https://github.com/mockito/mockito
mockito-core/src/test/java/org/mockito/internal/reporting/PluralizerTest.java
# Copyright 2015, Rackspace US, Inc. # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or agreed to in w...
unknown
codeparrot/codeparrot-clean
package versions import ( "strconv" "strings" ) // compare compares two version strings // returns -1 if v1 < v2, 1 if v1 > v2, 0 otherwise. func compare(v1, v2 string) int { if v1 == v2 { return 0 } var ( currTab = strings.Split(v1, ".") otherTab = strings.Split(v2, ".") ) maxVer := len(currTab) if l...
go
github
https://github.com/moby/moby
client/pkg/versions/compare.go
from __future__ import unicode_literals import re import warnings from django.core.exceptions import ImproperlyConfigured from django.core.mail import send_mail from django.core import validators from django.db import models from django.db.models.manager import EmptyManager from django.utils.crypto import get_random_s...
unknown
codeparrot/codeparrot-clean
// Copyright IBM Corp. 2016, 2025 // SPDX-License-Identifier: MPL-2.0 //go:build !enterprise package dbplugin import ( "github.com/hashicorp/vault/sdk/database/dbplugin/v5/proto" "github.com/hashicorp/vault/sdk/helper/pluginutil" ) type entGRPCClient struct{} func (c gRPCClient) Close() error { ctx, cancel := g...
go
github
https://github.com/hashicorp/vault
sdk/database/dbplugin/v5/grpc_client_oss.go
--- description: Learn to use the built-in network debugger to debug overlay networking problems keywords: network, troubleshooting, debug title: Debug overlay or swarm networking issues --- **WARNING** This tool can change the internal state of the libnetwork API, be really mindful on its use and read carefully the f...
unknown
github
https://github.com/moby/moby
daemon/libnetwork/cmd/diagnostic/README.md
name: BASERUBY Check on: push: paths-ignore: - 'doc/**' - '**/man/*' - '**.md' - '**.rdoc' - '**/.document' - '.*.yml' pull_request: paths-ignore: - 'doc/**' - '**/man/*' - '**.md' - '**.rdoc' - '**/.document' - '.*.yml' merge_group:...
unknown
github
https://github.com/ruby/ruby
.github/workflows/baseruby.yml
#!/usr/bin/env bash # Copyright 2014 The Kubernetes 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 applica...
unknown
github
https://github.com/kubernetes/kubernetes
hack/generate-docs.sh
#!/bin/bash set -eu ./mvnw \ --projects '!guava-testlib,!guava-tests,!guava-bom,!guava-gwt' \ -Dmaven.test.skip=true \ -Dmaven.javadoc.skip=true \ -ntp \ clean install ./mvnw \ -f android \ --projects '!guava-testlib,!guava-tests,!guava-bom' \ -Dmaven.test.skip=true \ -Dmaven.javadoc.skip=true \ -...
unknown
github
https://github.com/google/guava
util/gradle_integration_tests.sh
# Licensed under the Apache License, Version 2.0 (the "License"); you may # not use this file except in compliance with the License. You may obtain # a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or agreed to in writing, software # distributed under t...
unknown
codeparrot/codeparrot-clean
#! /usr/bin/env python # Selectively preprocess #ifdef / #ifndef statements. # Usage: # ifdef [-Dname] ... [-Uname] ... [file] ... # # This scans the file(s), looking for #ifdef and #ifndef preprocessor # commands that test for one of the names mentioned in the -D and -U # options. On standard output it writes a copy...
unknown
codeparrot/codeparrot-clean
#!/usr/bin/python # -*- coding: utf-8 -*- # (c) 2016 Michael Gruener <michael.gruener@chaosmoon.net> # GNU General Public License v3.0+ (see COPYING or https://www.gnu.org/licenses/gpl-3.0.txt) from __future__ import absolute_import, division, print_function __metaclass__ = type ANSIBLE_METADATA = {'metadata_version...
unknown
codeparrot/codeparrot-clean
/* Copyright 2024 The TensorFlow Authors. All Rights Reserved. Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or a...
c
github
https://github.com/tensorflow/tensorflow
tensorflow/compiler/mlir/lite/transforms/pass_options_setter.h
var foo = "foo"; export default foo;
javascript
github
https://github.com/webpack/webpack
examples/code-splitting-native-import-context-filter/templates/foo.js
"""Basic checks for HomeKitclimate.""" from aiohomekit.model.characteristics import CharacteristicsTypes from aiohomekit.model.services import ServicesTypes from homeassistant.components.climate.const import ( DOMAIN, HVAC_MODE_COOL, HVAC_MODE_HEAT, HVAC_MODE_HEAT_COOL, HVAC_MODE_OFF, SERVICE_S...
unknown
codeparrot/codeparrot-clean
# Actix Ecosystem Dependency Graphs See rendered versions of these dot graphs [on the wiki](https://github.com/actix/actix-web/wiki/Dependency-Graph). ## Rendering Dot graphs were rendered using the `dot` command from [GraphViz](https://www.graphviz.org/doc/info/command.html): ```sh for f in $(ls docs/graphs/*.dot ...
unknown
github
https://github.com/actix/actix-web
docs/graphs/README.md
from __future__ import unicode_literals from django.contrib.syndication.views import Feed as BaseFeed from django.utils.feedgenerator import Atom1Feed, Rss201rev2Feed class GeoFeedMixin(object): """ This mixin provides the necessary routines for SyndicationFeed subclasses to produce simple GeoRSS or W3C G...
unknown
codeparrot/codeparrot-clean
// Copyright 2011 The Go Authors. All rights reserved. // Use of this source code is governed by a BSD-style // license that can be found in the LICENSE file. package math // Export internal functions for testing. var ExpGo = exp var Exp2Go = exp2 var HypotGo = hypot var SqrtGo = sqrt var TrigReduce = trigReduce con...
go
github
https://github.com/golang/go
src/math/export_test.go
// Copyright IBM Corp. 2016, 2025 // SPDX-License-Identifier: BUSL-1.1 package command import ( "fmt" "strings" "github.com/hashicorp/cli" "github.com/posener/complete" ) var ( _ cli.Command = (*PolicyReadCommand)(nil) _ cli.CommandAutocomplete = (*PolicyReadCommand)(nil) ) type PolicyReadCommand...
go
github
https://github.com/hashicorp/vault
command/policy_read.go
# -*- coding: utf-8 -*- import xmpp import threading import Agent import Envelope import FIPAMessage import AID import Behaviour import ACLParser import socket import SocketServer SIMBAPORT = 20001 class SIMBA(Agent.PlatformAgent): class OutboxBehaviour(Behaviour.Behaviour): ''' Behaviour that rou...
unknown
codeparrot/codeparrot-clean
# Copyright 2015, Rackspace US, Inc. # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or agreed to in w...
unknown
codeparrot/codeparrot-clean
# -*- coding: utf-8 -*- """ A series of tests to establish that the command-line managment tools work as advertised - especially with regards to the handling of the DJANGO_SETTINGS_MODULE and default settings.py files. """ from __future__ import unicode_literals import os import re import shutil import socket import s...
unknown
codeparrot/codeparrot-clean
# frozen_string_literal: true module Arel module TreeManagerBehavior extend ActiveSupport::Concern class MyEngine class << self def type_caster; end def with_connection yield MyConnection.new end end class MyConnection def quote_table_name(name) ...
ruby
github
https://github.com/rails/rails
activerecord/test/cases/arel/support/tree_manager_behavior.rb
# Copyright (c) 2010 Chris Moyer http://coredumped.org/ # # 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, ...
unknown
codeparrot/codeparrot-clean
#!/usr/bin/env python # Copyright (C) 2009 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-2.0 # # Unless required by applicable l...
unknown
codeparrot/codeparrot-clean
# frozen_string_literal: true =begin = Info 'OpenSSL for Ruby 2' project Copyright (C) 2001 GOTOU YUUZOU <gotoyuzo@notwork.org> All rights reserved. = Licence This program is licensed under the same licence as Ruby. (See the file 'COPYING'.) =end require "openssl/buffering" if defined?(OpenSSL::SSL) requi...
ruby
github
https://github.com/ruby/ruby
ext/openssl/lib/openssl/ssl.rb
/* * Copyright 2002-present 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 * * https://www.apache.org/licenses/LICENSE-2.0 * * Unless required b...
java
github
https://github.com/spring-projects/spring-framework
spring-context/src/test/java/org/springframework/validation/DataBinderTests.java
from sphinx.domains import Domain, ObjType from sphinx.roles import XRefRole from sphinx.domains.std import GenericObject, StandardDomain from sphinx.directives import ObjectDescription from sphinx.util.nodes import clean_astext, make_refnode from sphinx.util import ws_re from sphinx import addnodes from sphinx.util.do...
unknown
codeparrot/codeparrot-clean
//===--- SILArgumentConvention.h --------------------------------*- C++ -*-===// // // This source file is part of the Swift.org open source project // // Copyright (c) 2014 - 2017 Apple Inc. and the Swift project authors // Licensed under Apache License v2.0 with Runtime Library Exception // // See https://swift.org/L...
c
github
https://github.com/apple/swift
include/swift/SIL/SILArgumentConvention.h
############################################################################## # # OpenERP, Open Source Management Solution # Copyright (C) 2004-2009 Tiny SPRL (<http://tiny.be>). # # This program is free software: you can redistribute it and/or modify # it under the terms of the GNU Affero General Public L...
unknown
codeparrot/codeparrot-clean
{ "DESTROY": { "summary": "Destroys a consumer group.", "complexity": "O(N) where N is the number of entries in the group's pending entries list (PEL).", "group": "stream", "since": "5.0.0", "arity": 4, "container": "XGROUP", "function": "xgroupCommand", ...
json
github
https://github.com/redis/redis
src/commands/xgroup-destroy.json
# utils.py # # Copyright (c) 2017, Franco Masotti # # 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,...
unknown
codeparrot/codeparrot-clean
"""Creates new network subsystem with virtual eth device.""" from __future__ import absolute_import from __future__ import division from __future__ import print_function from __future__ import unicode_literals import errno import os import logging import multiprocessing from . import utils from . import iptables fr...
unknown
codeparrot/codeparrot-clean
/* * Copyright 2014-2021 JetBrains s.r.o and contributors. Use of this source code is governed by the Apache 2.0 license. */ package io.ktor.server.application /** * An exception that is thrown when the current body in the HTTP pipeline is invalid. * * [Report a problem](https://ktor.io/feedback/?fqname=io.ktor....
kotlin
github
https://github.com/ktorio/ktor
ktor-server/ktor-server-core/common/src/io/ktor/server/application/PluginExceptions.kt
########################################################################## # # Copyright (c) 2011-2012, John Haddon. All rights reserved. # Copyright (c) 2013-2014, Image Engine Design Inc. All rights reserved. # # Redistribution and use in source and binary forms, with or without # modification, are permitted prov...
unknown
codeparrot/codeparrot-clean
#!/usr/bin/env python import threading import dns from dnsdisttests import DNSDistTest class TestAXFR(DNSDistTest): # this test suite uses a different responder port # because, contrary to the other ones, its # TCP responder allows multiple responses and we don't want # to mix things up. _testServ...
unknown
codeparrot/codeparrot-clean
import traceback from submissions.Conklin import music class DataFrame: data = [] feature_names = [] target = [] target_names = [] musicECHP = DataFrame() musicECHP.data = [] targetInfo = [] list_of_songs = music.get_songs() for song in list_of_songs: try: tempo = float(song['song']["tem...
unknown
codeparrot/codeparrot-clean
""" Initial configuration. """ from __future__ import unicode_literals __all__ = ( 'STARTUP_COMMANDS' ) STARTUP_COMMANDS = """ bind-key '"' split-window -v bind-key % split-window -h bind-key c new-window bind-key Right select-pane -R bind-key Left select-pane -L bind-key Up select-pane -U bind-key Down select-pa...
unknown
codeparrot/codeparrot-clean
# 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...
python
github
https://github.com/apache/airflow
airflow-core/tests/unit/utils/test_docs.py
## Input ```javascript // @compilationMode:"infer" function useDiv(props) { return <div />; } ``` ## Code ```javascript import { c as _c } from "react/compiler-runtime"; // @compilationMode:"infer" function useDiv(props) { const $ = _c(1); let t0; if ($[0] === Symbol.for("react.memo_cache_sentinel")) { ...
unknown
github
https://github.com/facebook/react
compiler/packages/babel-plugin-react-compiler/src/__tests__/fixtures/compiler/infer-functions-hook-with-jsx.expect.md
''' Guns for HTTP/2 ''' import logging from collections import namedtuple from hyper import HTTP20Connection, tls import ssl from hyper.http20.exceptions import ConnectionError from .base import GunBase Http2Ammo = namedtuple("Http2Ammo", "method,uri,headers,body") logger = logging.getLogger(__name__) class HttpMult...
unknown
codeparrot/codeparrot-clean
/* * Copyright (c) 2007 Mockito contributors * This program is made available under the terms of the MIT License. */ package org.mockito.internal.invocation; import static org.mockito.internal.invocation.MatcherApplicationStrategy.getMatcherApplicationStrategyFor; import static org.mockito.internal.invocation.TypeS...
java
github
https://github.com/mockito/mockito
mockito-core/src/main/java/org/mockito/internal/invocation/InvocationMatcher.java
# Copyright (c) 2013, Mark Peek <mark@peek.org> # All rights reserved. # # See LICENSE file for full license. from . import AWSObject, Ref, GetAtt from .validators import boolean, integer, network_port class CacheCluster(AWSObject): resource_type = "AWS::ElastiCache::CacheCluster" props = { 'AutoMino...
unknown
codeparrot/codeparrot-clean
# Licensed to the Software Freedom Conservancy (SFC) under one # or more contributor license agreements. See the NOTICE file # distributed with this work for additional information # regarding copyright ownership. The SFC licenses this file # to you under the Apache License, Version 2.0 (the # "License"); you may not...
unknown
codeparrot/codeparrot-clean
# -*- coding: UTF-8 -*- ## Copyright 2011-2013 Luc Saffre ## This file is part of the Lino project. ## Lino 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 opt...
unknown
codeparrot/codeparrot-clean
""" Benchmarks of sklearn SAGA vs lightning SAGA vs Liblinear. Shows the gain in using multinomial logistic regression in term of learning time. """ # Authors: The scikit-learn developers # SPDX-License-Identifier: BSD-3-Clause import json import os import time import matplotlib.pyplot as plt import numpy as np fro...
python
github
https://github.com/scikit-learn/scikit-learn
benchmarks/bench_saga.py
//// [tests/cases/conformance/async/es2017/asyncAwait_es2017.ts] //// //// [asyncAwait_es2017.ts] type MyPromise<T> = Promise<T>; declare var MyPromise: typeof Promise; declare var p: Promise<number>; declare var mp: MyPromise<number>; async function f0() { } async function f1(): Promise<void> { } async function f3()...
javascript
github
https://github.com/microsoft/TypeScript
tests/baselines/reference/asyncAwait_es2017.js
# -*- coding: utf-8 -*- # Copyright (C) 2014-2016 Andrey Antukh <niwi@niwi.nz> # Copyright (C) 2014-2016 Jesús Espino <jespinog@gmail.com> # Copyright (C) 2014-2016 David Barragán <bameda@dbarragan.com> # Copyright (C) 2014-2016 Alejandro Alonso <alejandro.alonso@kaleidos.net> # This program is free software: you can r...
unknown
codeparrot/codeparrot-clean
#!/usr/bin/env python """ Use the AppVeyor API to download Windows artifacts. Taken from: https://bitbucket.org/ned/coveragepy/src/tip/ci/download_appveyor.py # Licensed under the Apache License: http://www.apache.org/licenses/LICENSE-2.0 # For details: https://bitbucket.org/ned/coveragepy/src/default/NOTICE.txt """ f...
unknown
codeparrot/codeparrot-clean
//===----------------------------------------------------------------------===// // // Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions. // See https://llvm.org/LICENSE.txt for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // //===---------------------------...
c
github
https://github.com/llvm/llvm-project
clang-tools-extra/clang-tidy/bugprone/RawMemoryCallOnNonTrivialTypeCheck.h
""" To run this, you'll need to have installed. * scikit-learn Does two benchmarks First, we fix a training set, increase the number of samples to classify and plot number of classified samples as a function of time. In the second benchmark, we increase the number of dimensions of the training set, classify a sam...
unknown
codeparrot/codeparrot-clean
# coding: utf-8 from __future__ import unicode_literals import re from .common import InfoExtractor from ..utils import ( xpath_text, xpath_element, int_or_none, parse_duration, ) class HBOBaseIE(InfoExtractor): _FORMATS_INFO = { '1920': { 'width': 1280, 'height': ...
unknown
codeparrot/codeparrot-clean
#!/usr/bin/env python from tests.unit import unittest from tests.compat import mock from boto.ec2.elb import ELBConnection from boto.ec2.elb import LoadBalancer DISABLE_RESPONSE = b"""<?xml version="1.0" encoding="UTF-8"?> <DisableAvailabilityZonesForLoadBalancerResult xmlns="http://ec2.amazonaws.com/doc/2013-02-01/...
unknown
codeparrot/codeparrot-clean
# 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 ...
unknown
codeparrot/codeparrot-clean
from datetime import datetime from functools import partialmethod from io import StringIO from unittest import mock, skipIf from django.core import serializers from django.core.serializers import SerializerDoesNotExist from django.core.serializers.base import ProgressBar from django.db import connection, transaction f...
python
github
https://github.com/django/django
tests/serializers/tests.py
# Copyright 2004-2005 Elemental Security, Inc. All Rights Reserved. # Licensed to PSF under a Contributor Agreement. # Pgen imports from . import grammar, token, tokenize class PgenGrammar(grammar.Grammar): pass class ParserGenerator(object): def __init__(self, filename, stream=None): close_stream =...
unknown
codeparrot/codeparrot-clean
use crate::de::{deserialize_seq, has_flatten, Parameters, TupleForm}; #[cfg(feature = "deserialize_in_place")] use crate::de::{deserialize_seq_in_place, place_lifetime}; use crate::fragment::{Fragment, Stmts}; use crate::internals::ast::Field; use crate::internals::attr; use crate::private; use proc_macro2::TokenStream...
rust
github
https://github.com/serde-rs/serde
serde_derive/src/de/tuple.rs
""" This module contains fixups for using nose under different versions of Python. """ import sys import os import traceback import types import inspect import nose.util __all__ = ['make_instancemethod', 'cmp_to_key', 'sort_list', 'ClassType', 'TypeType', 'UNICODE_STRINGS', 'unbound_method', 'ismethod', ...
unknown
codeparrot/codeparrot-clean
# -*- coding: utf-8 -*- import sys import re if __name__ == '__main__': if len(sys.argv) < 4: print("Usage: python bond_html.py hoge.html -o hoge_out.html") sys.exit() target_file = open(sys.argv[1], 'r', encoding='utf-8') target_txt = target_file.read() target_file.close() outpu...
unknown
codeparrot/codeparrot-clean
# Copyright 2015 The TensorFlow Authors. All Rights Reserved. # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applica...
unknown
codeparrot/codeparrot-clean
#!/usr/bin/env python # Copyright 2015 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 argparse import operator import os import re from sets import Set from subprocess import Popen, PIPE import sys def search_al...
unknown
codeparrot/codeparrot-clean