code
stringlengths
1
25.8M
language
stringclasses
18 values
source
stringclasses
4 values
repo
stringclasses
78 values
path
stringlengths
0
268
#pragma once #include <ATen/core/DimVector.h> #include <ATen/core/TensorBody.h> #include <ATen/core/blob.h> #include <ATen/core/custom_class.h> #include <ATen/core/ivalue_to.h> #include <ATen/core/jit_type_base.h> #include <ATen/core/type_factory.h> #include <c10/core/SymBool.h> #include <c10/core/SymFloat.h> #include...
c
github
https://github.com/pytorch/pytorch
aten/src/ATen/core/ivalue.h
/* * 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 n...
java
github
https://github.com/apache/kafka
clients/src/test/java/org/apache/kafka/clients/producer/ProducerConfigTest.java
"""Module only used for the login part of the script""" # import built-in & third-party modules import pickle import socket import os import json import random from selenium.webdriver.common.action_chains import ActionChains from selenium.webdriver.common.keys import Keys # import InstaPy modules from .time_util impo...
unknown
codeparrot/codeparrot-clean
import { test } from '../../test'; export default test({ warnings: [ { code: 'css_unused_selector', message: 'Unused CSS selector "article + div"', start: { character: 45, column: 1, line: 5 }, end: { character: 58, column: 14, line: 5 } }, { code: 'css_unused_selector', message: 'Unused CSS s...
javascript
github
https://github.com/sveltejs/svelte
packages/svelte/tests/css/samples/siblings-combinator/_config.js
#!/usr/bin/env python # -*- coding: utf-8 -*- from rosettastone import RosettaStone from genome import Genome from chromosome import Chromosome from encodingtype import EncodingType class IntegerTestRosettaStone(RosettaStone): def __init__(self, name=None): super(IntegerTestRosettaStone, self).__init__(...
unknown
codeparrot/codeparrot-clean
/* * Copyright (C) 2008 The Guava 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 agre...
java
github
https://github.com/google/guava
android/guava-tests/test/com/google/common/io/MultiReaderTest.java
#file : InMoov2.minimalTorso.py # this will run with versions of MRL 1.0.107 # a very minimal script for InMoov # although this script is very short you can still # do voice control of a right Arm # for any command which you say - you will be required to say a confirmation # e.g. you say -> test stomach, InMoov will a...
unknown
codeparrot/codeparrot-clean
{ "kind": "Dashboard", "apiVersion": "dashboard.grafana.app/v2beta1", "metadata": { "name": "v0alpha1.timeseries-formats.v42" }, "spec": { "annotations": [ { "kind": "AnnotationQuery", "spec": { "query": { "kind": "DataQuery", "group": "grafana",...
json
github
https://github.com/grafana/grafana
apps/dashboard/pkg/migration/conversion/testdata/output/migrated_dev_dashboards/panel-timeseries/v0alpha1.timeseries-formats.v42.v2beta1.json
/** * -------------------------------------------------------------------------- * Bootstrap dom/data.js * Licensed under MIT (https://github.com/twbs/bootstrap/blob/main/LICENSE) * -------------------------------------------------------------------------- */ /** * Constants */ const elementMap = new Map() ex...
javascript
github
https://github.com/twbs/bootstrap
js/src/dom/data.js
def plot_crystal_sketch(v0_h,v0_v,vH_h ,vH_v ,H_h ,H_v): import matplotlib.pyplot as plt from matplotlib.path import Path import matplotlib.patches as patches hshift = 0.2 vshift = 0.0 plt.figure(1, figsize=(6,6)) ax = plt.subplot(111) ax.xaxis.set_ticks_position('none) ax.yaxis.s...
unknown
codeparrot/codeparrot-clean
# We intentionally define lots of variables that aren't used, and # want to import all variables from base settings files # pylint: disable=W0401, W0614 from ..dev import * CLASSES_TO_DBS = { 'BerkeleyX/CS169.1x/2012_Fall': "cs169.db", 'BerkeleyX/CS188.1x/2012_Fall': "cs188_1.db", 'HarvardX/CS50x/2012': "...
unknown
codeparrot/codeparrot-clean
<?php use Symfony\Bundle\FrameworkBundle\Tests\DependencyInjection\FrameworkExtensionTestCase; $container->loadFromExtension('framework', [ 'workflows' => [ 'article' => [ 'type' => 'workflow', 'supports' => [ FrameworkExtensionTestCase::class, ], ...
php
github
https://github.com/symfony/symfony
src/Symfony/Bundle/FrameworkBundle/Tests/DependencyInjection/Fixtures/php/workflow_with_complex_place_follow_by_simplistic_place_config.php
/** * \file cipher.h * * \brief This file contains an abstraction interface for use with the cipher * primitives provided by the library. It provides a common interface to all of * the available cipher operations. * * \author Adriaan de Jong <dejong@fox-it.com> */ /* * Copyright The Mbed TLS Contributors * ...
c
github
https://github.com/nodejs/node
deps/LIEF/third-party/mbedtls/include/mbedtls/cipher.h
#include "parts.h" #include "util.h" static PyObject * tuple_check(PyObject* Py_UNUSED(module), PyObject *obj) { NULLABLE(obj); return PyLong_FromLong(PyTuple_Check(obj)); } static PyObject * tuple_checkexact(PyObject* Py_UNUSED(module), PyObject *obj) { NULLABLE(obj); return PyLong_FromLong(PyTuple_C...
c
github
https://github.com/python/cpython
Modules/_testlimitedcapi/tuple.c
/* * Copyright (c) 2018-Present, Redis Ltd. * All rights reserved. * * Licensed under your choice of (a) the Redis Source Available License 2.0 * (RSALv2); or (b) the Server Side Public License v1 (SSPLv1); or (c) the * GNU Affero General Public License v3 (AGPLv3). * * -----------------------------------------...
c
github
https://github.com/redis/redis
src/lolwut5.c
import collections import ctypes import itertools import logging import multiprocessing import os import pickle import textwrap import unittest from importlib import import_module from django.conf import settings from django.core.exceptions import ImproperlyConfigured from django.db import DEFAULT_DB_ALIAS, connection...
unknown
codeparrot/codeparrot-clean
/* * Copyright 2025-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...
kotlin
github
https://github.com/spring-projects/spring-framework
framework-docs/src/main/kotlin/org/springframework/docs/testing/resttestclient/contextconfig/WebConfig.kt
// Copyright (c) HashiCorp, Inc. // SPDX-License-Identifier: BUSL-1.1 package command import ( "bytes" "path/filepath" "strings" "testing" "github.com/hashicorp/cli" "github.com/hashicorp/terraform/internal/addrs" "github.com/hashicorp/terraform/internal/providers" "github.com/hashicorp/terraform/internal/s...
go
github
https://github.com/hashicorp/terraform
internal/command/state_replace_provider_test.go
#!/usr/bin/python # # (c) 2016 Olaf Kilian <olaf.kilian@symanex.com> # Chris Houseknecht, <house@redhat.com> # James Tanner, <jtanner@redhat.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_func...
unknown
codeparrot/codeparrot-clean
/* * Copyright (C) 2012 The Guava 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 agre...
java
github
https://github.com/google/guava
android/guava-tests/test/com/google/common/io/TestCharSink.java
it("should pass package.json type to loader", function () { expect(require("esm/loader.js!")).toBe("module"); }); it("should pass 'module' type to loader for .mjs", function () { expect(require("cjs/loader.mjs!")).toBe("module"); expect(require("esm/loader.mjs!")).toBe("module"); expect(require("./loader.mjs!")).t...
javascript
github
https://github.com/webpack/webpack
test/cases/loaders/_esm-loader-type/index.js
//! For middleware documentation, see [`Logger`]. use std::{ borrow::Cow, collections::HashSet, env, fmt::{self, Display as _}, future::Future, marker::PhantomData, pin::Pin, rc::Rc, task::{Context, Poll}, }; use actix_service::{Service, Transform}; use actix_utils::future::{ready,...
rust
github
https://github.com/actix/actix-web
actix-web/src/middleware/logger.rs
// Copyright (c) HashiCorp, Inc. // SPDX-License-Identifier: BUSL-1.1 package ephemeral import ( "testing" "github.com/hashicorp/terraform/internal/lang/marks" "github.com/zclconf/go-cty/cty" ) func TestEphemeral_removeEphemeralValues(t *testing.T) { for name, tc := range map[string]struct { input cty.Value ...
go
github
https://github.com/hashicorp/terraform
internal/lang/ephemeral/marshal_test.go
import { registerRuntimeHelpers } from '@vue/compiler-core' export const V_MODEL_RADIO: unique symbol = Symbol(__DEV__ ? `vModelRadio` : ``) export const V_MODEL_CHECKBOX: unique symbol = Symbol( __DEV__ ? `vModelCheckbox` : ``, ) export const V_MODEL_TEXT: unique symbol = Symbol(__DEV__ ? `vModelText` : ``) export ...
typescript
github
https://github.com/vuejs/core
packages/compiler-dom/src/runtimeHelpers.ts
--- title: ServerRouter --- # ServerRouter <!-- ⚠️ ⚠️ IMPORTANT ⚠️ ⚠️ Thank you for helping improve our documentation! This file is auto-generated from the JSDoc comments in the source code, so please edit the JSDoc comments in the file below and this file will be re-generated once those changes are merged. https:...
unknown
github
https://github.com/remix-run/react-router
docs/api/framework-routers/ServerRouter.md
# Copyright 2021 Google Research and The HuggingFace Inc. team. 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 # # Unl...
python
github
https://github.com/huggingface/transformers
src/transformers/models/big_bird/configuration_big_bird.py
// Copyright 2015 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 main_test import ( "bytes" "debug/elf" "debug/macho" "debug/pe" "flag" "fmt" "go/format" "internal/godebug" "internal/platform" "internal/tes...
go
github
https://github.com/golang/go
src/cmd/go/go_test.go
# Copyright 2017 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
""" Models for configuration of the feature flags controlling persistent grades. """ from config_models.models import ConfigurationModel from django.conf import settings from django.db.models import BooleanField, IntegerField, TextField from opaque_keys.edx.django.models import CourseKeyField from six import text_type ...
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...
java
github
https://github.com/apache/hadoop
hadoop-cloud-storage-project/hadoop-cos/src/main/java/org/apache/hadoop/fs/cosn/CosNFileReadTask.java
# Copyright 2010-2015 MongoDB, 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 writin...
unknown
codeparrot/codeparrot-clean
""" Depth Spider Middleware See documentation in docs/topics/spider-middleware.rst """ from __future__ import annotations import logging from typing import TYPE_CHECKING, Any from scrapy.spidermiddlewares.base import BaseSpiderMiddleware from scrapy.utils.decorators import _warn_spider_arg if TYPE_CHECKING: fr...
python
github
https://github.com/scrapy/scrapy
scrapy/spidermiddlewares/depth.py
#!/usr/bin/env python """ @package mi.dataset.parser.test.test_cg_stc_eng_stc @file marine-integrations/mi/dataset/parser/test/test_cg_stc_eng_stc.py @author Mike Nicoletti @brief Test code for a Cg_stc_eng_stc data parser """ import os import re import ntplib from nose.plugins.attrib import attr from mi.core.except...
unknown
codeparrot/codeparrot-clean
# coding=utf-8 """Resources test. .. note:: 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 2 of the License, or (at your option) any later version. """ __author__ = '...
unknown
codeparrot/codeparrot-clean
#!/usr/bin/env python # -*- coding: utf-8 -*- def get_split_names( name ): split_name_list = name.split("/") for i in range(0, len(split_name_list)): split_name_list[i] = split_name_list[i].strip() return split_name_list def esc_char(name): if "'" in name: return "$$" + name + "$$" ...
unknown
codeparrot/codeparrot-clean
/** * @license * Copyright Google LLC All Rights Reserved. * * Use of this source code is governed by an MIT-style license that can be * found in the LICENSE file at https://angular.dev/license */ import {Route} from '../../../../../protocol'; import { findNodesByLabel, getRouteLabel, mapRoute, RouterTre...
typescript
github
https://github.com/angular/angular
devtools/projects/ng-devtools/src/lib/devtools-tabs/router-tree/router-tree-fns.spec.ts
""" Expressions ----------- Offer fast expression evaluation through numexpr """ from __future__ import annotations import operator from typing import TYPE_CHECKING import warnings import numpy as np from pandas._config import get_option from pandas.util._exceptions import find_stack_level from pandas.core impo...
python
github
https://github.com/pandas-dev/pandas
pandas/core/computation/expressions.py
# coding: utf-8 """ Copyright 2015 SmartBear Software 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 (c) 2012 Google Inc. All rights reserved. # Use of this source code is governed by a BSD-style license that can be # found in the LICENSE file. """ Verifies that list xcode_settings are flattened before being exported to the environment. """ from __future__ import print_function im...
unknown
codeparrot/codeparrot-clean
use super::*; use crate::loom::thread; use futures_test::task::{new_count_waker, AwokenCount}; #[cfg(loom)] const NUM_ITEMS: usize = 16; #[cfg(not(loom))] const NUM_ITEMS: usize = 64; fn new_handle() -> (EntryHandle, AwokenCount) { let (waker, count) = new_count_waker(); (EntryHandle::new(0, waker), count) ...
rust
github
https://github.com/tokio-rs/tokio
tokio/src/runtime/time_alt/tests.rs
"""Helper functions.""" import contextlib import random import re import sys import yaml from buildscripts.resmokelib import config as _config from buildscripts.resmokelib.utils import archival __all__ = ["archival"] @contextlib.contextmanager def open_or_use_stdout(filename): """Open the specified file for wr...
python
github
https://github.com/mongodb/mongo
buildscripts/resmokelib/utils/__init__.py
# -*- coding: utf-8 -*- from odoo import fields, models, api from odoo.exceptions import UserError READONLY_STATES = { 'done': [('readonly', True)], } change = [('time', u'计时'), ('piece', u'计件'), ('efficiency', u'计效')] class StaffWages(models.Model): _name = 'staff.wages' _description...
unknown
codeparrot/codeparrot-clean
#!/usr/bin/env python # -*- coding: utf-8 -*- # # (c) 2015, René Moser <mail@renemoser.net> # # This file is part of Ansible, # # Ansible 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...
unknown
codeparrot/codeparrot-clean
/* Copyright 2018 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
pkg/kubelet/lifecycle/predicate_test.go
#!/usr/bin/env bash # Copyright 2021 The Cockroach Authors. # # Use of this software is governed by the CockroachDB Software License # included in the /LICENSE file. set -xeuo pipefail bazel run //pkg/cmd/urlcheck --run_under="cd $PWD && "
unknown
github
https://github.com/cockroachdb/cockroach
build/teamcity/cockroach/nightlies/url_check_impl.sh
use std::sync::Arc; use rustc_ast::{self as ast, *}; use rustc_hir::def::{DefKind, PartialRes, PerNS, Res}; use rustc_hir::def_id::DefId; use rustc_hir::{self as hir, GenericArg}; use rustc_middle::{span_bug, ty}; use rustc_session::parse::add_feature_diagnostics; use rustc_span::{BytePos, DUMMY_SP, DesugaringKind, Id...
rust
github
https://github.com/rust-lang/rust
compiler/rustc_ast_lowering/src/path.rs
/* * 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 n...
java
github
https://github.com/apache/kafka
clients/src/main/java/org/apache/kafka/clients/consumer/internals/events/StreamsOnTasksRevokedCallbackNeededEvent.java
""" Classes to support XML for serial devices http://libvirt.org/formatdomain.html#elementCharSerial """ from virttest.libvirt_xml import base, accessors, xcepts from virttest.libvirt_xml.devices.character import CharacterBase class Serial(CharacterBase): __slots__ = ('protocol_type', 'target_port', 'target_typ...
unknown
codeparrot/codeparrot-clean
@import url('https://fonts.googleapis.com/icon?family=Material+Symbols+Outlined'); :host { display: flex; justify-content: center; font-family: 'Press Start 2P'; --retro-button-color: color-mix(in srgb, var(--vivid-pink) 80%, var(--gray-1000)); --retro-shadow-light: color-mix(in srgb, var(--retro-button-col...
css
github
https://github.com/angular/angular
adev/src/content/examples/aria/toolbar/src/basic/retro/app/app.css
# Copyright 2025 Google Inc. HuggingFace Inc. team. All rights reserved. # # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless requir...
python
github
https://github.com/huggingface/transformers
src/transformers/models/gemma3/convert_gemma3_weights.py
# -*- coding: cp1252 -*- ## # Support module for the xlrd package. # # <p>Portions copyright © 2005-2010 Stephen John Machin, Lingfo Pty Ltd</p> # <p>This module is part of the xlrd package, which is released under a BSD-style licence.</p> ## # 2010-03-01 SJM Reading SCL record # 2010-03-01 SJM Added more record IDs ...
unknown
codeparrot/codeparrot-clean
def unique_sublists(list1): result ={} for l in list1: result.setdefault(tuple(l), list()).append(1) for a, b in result.items(): result[a] = sum(b) return result
unknown
mbpp
<!--Copyright 2022 The HuggingFace Team. 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 agreed...
unknown
github
https://github.com/huggingface/transformers
docs/source/en/model_doc/switch_transformers.md
# 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/pythonw # -*- coding: UTF-8 -*- ''' MIT License Copyright (c) 2017 Tairan Liu 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 rig...
unknown
codeparrot/codeparrot-clean
#!/usr/bin/python # -*- coding: utf-8 -*- # (c) 2018, Ansible by Red Hat, inc # 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
# python3 # pylint: disable=g-bad-file-header # Copyright 2019 DeepMind Technologies Limited. 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...
unknown
codeparrot/codeparrot-clean
annotation class Annotation(vararg val values: Int) @Annotation(+<expr>1</expr>) class C
kotlin
github
https://github.com/JetBrains/kotlin
analysis/analysis-api/testData/components/compileTimeConstantProvider/evaluate/integerLiteral_plusOne_justOne.kt
import time import tables import artist from sapphire.analysis.core_reconstruction import CoreReconstruction, PlotCoreReconstruction from sapphire.utils import pbar X, Y = 65., 20.82 def get_tcc_values(data, force_new=False): if 'tcc' in data.root and not force_new: return data.root.tcc.read() else...
unknown
codeparrot/codeparrot-clean
## Input ```javascript async function Component(props) { const x = []; await populateData(props.id, x); return x; } ``` ## Code ```javascript import { c as _c } from "react/compiler-runtime"; async function Component(props) { const $ = _c(2); let x; if ($[0] !== props.id) { x = []; await populat...
unknown
github
https://github.com/facebook/react
compiler/packages/babel-plugin-react-compiler/src/__tests__/fixtures/compiler/await-side-effecting-promise.expect.md
# -*- coding: iso-8859-1 -*- """Parser for command line options. This module helps scripts to parse the command line arguments in sys.argv. It supports the same conventions as the Unix getopt() function (including the special meanings of arguments of the form `-' and `--'). Long options similar to those supported by...
unknown
codeparrot/codeparrot-clean
from __future__ import unicode_literals, division, absolute_import import logging import os import tempfile from flexget import plugin from flexget.event import event log = logging.getLogger('check_subtitles') class MetainfoSubs(object): """ Set 'subtitles' field for entries, if they are local video files wi...
unknown
codeparrot/codeparrot-clean
#!/usr/bin/env python # encoding: utf-8 # Thomas Nagy, 2006-2010 (ita) """ This tool is totally deprecated Try using: .pc.in files for .pc files the feature intltool_in - see demos/intltool make-like rules """ import shutil, re, os from waflib import TaskGen, Node, Task, Utils, Build, Errors from waflib.TaskGen i...
unknown
codeparrot/codeparrot-clean
/////////////////////////////////////////////////////////////////////////// // // Copyright (c) 2002-2012, Industrial Light & Magic, a division of Lucas // Digital Ltd. LLC // // All rights reserved. // // Redistribution and use in source and binary forms, with or without // modification, are permitted provided that th...
c
github
https://github.com/opencv/opencv
3rdparty/openexr/Imath/ImathFrame.h
--- applies_to: stack: serverless: mapped_pages: - https://www.elastic.co/guide/en/elasticsearch/reference/current/position-increment-gap.html --- # position_increment_gap [position-increment-gap] [Analyzed](/reference/elasticsearch/mapping-reference/mapping-index.md) text fields take term [positions](/referenc...
unknown
github
https://github.com/elastic/elasticsearch
docs/reference/elasticsearch/mapping-reference/position-increment-gap.md
#!/usr/bin/env python # This file is part of the Printrun suite. # # Printrun is free software: you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by # the Free Software Foundation, either version 3 of the License, or # (at your option) any later version. # # Prin...
unknown
codeparrot/codeparrot-clean
# Copyright (c) 2014 Mirantis Inc. # # Licensed under the Apache License, Version 2.0 (the License); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # Unless required by applicable law or agreed to in writing, so...
unknown
codeparrot/codeparrot-clean
# -*- coding: utf-8 -*- ######################################################################### # # Copyright (C) 2012 OpenPlans # # 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 versio...
unknown
codeparrot/codeparrot-clean
#!/usr/bin/python from __future__ import (absolute_import, division, print_function) # Copyright 2019 Fortinet, Inc. # # 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 Lic...
unknown
codeparrot/codeparrot-clean
#!/usr/bin/env python3 # Copyright (c) 2013-2019 GitHub Inc. # Copyright 2019 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. # This script reads the configurations of GN and outputs a config.gypi file that # will be use...
python
github
https://github.com/nodejs/node
tools/generate_config_gypi.py
from ..Qt import QtGui, QtCore, USE_PYSIDE import matplotlib if USE_PYSIDE: matplotlib.rcParams['backend.qt4']='PySide' from matplotlib.backends.backend_qt4agg import FigureCanvasQTAgg as FigureCanvas from matplotlib.backends.backend_qt4agg import NavigationToolbar2QTAgg as NavigationToolbar from matplotlib.figur...
unknown
codeparrot/codeparrot-clean
{ "format_version": "1.0", "terraform_version": "1.1.0-dev", "applyable": true, "complete": true, "planned_values": { "root_module": { "resources": [ { "address": "test_instance.test", "mode": "managed", "type": "test_instance", "name": "test", ...
json
github
https://github.com/hashicorp/terraform
internal/command/testdata/show-json/provider-aliasing-default/output.json
// Copyright IBM Corp. 2016, 2025 // SPDX-License-Identifier: BUSL-1.1 package vault import ( "bytes" "context" "crypto/ecdsa" "crypto/elliptic" "crypto/rand" "crypto/tls" "crypto/x509" "crypto/x509/pkix" "encoding/base64" "encoding/pem" "errors" "fmt" "io/ioutil" "math/big" mathrand "math/rand" "net"...
go
github
https://github.com/hashicorp/vault
vault/testing.go
# -*- coding: utf-8 -*- """ Acceptance tests for Video. """ import os from mock import patch from nose.plugins.attrib import attr from unittest import skipIf, skip from ..helpers import UniqueCourseTest, is_youtube_available, YouTubeStubConfig from ...pages.lms.video.video import VideoPage from ...pages.lms.tab_nav i...
unknown
codeparrot/codeparrot-clean
// // basic_serial_port.hpp // ~~~~~~~~~~~~~~~~~~~~~ // // Copyright (c) 2003-2024 Christopher M. Kohlhoff (chris at kohlhoff dot com) // Copyright (c) 2008 Rep Invariant Systems, Inc. (info@repinvariant.com) // // Distributed under the Boost Software License, Version 1.0. (See accompanying // file LICENSE_1_0.txt or c...
unknown
github
https://github.com/mysql/mysql-server
extra/boost/boost_1_87_0/boost/asio/basic_serial_port.hpp
antora: extensions: - require: '@springio/antora-extensions' root_component_name: 'framework' site: title: Spring Framework url: https://docs.spring.io/spring-framework/reference robots: allow git: ensure_git_suffix: false content: sources: - url: https://github.com/spring-projects/spring-framework ...
unknown
github
https://github.com/spring-projects/spring-framework
framework-docs/antora-playbook.yml
""" Test functions for stats module WRITTEN BY LOUIS LUANGKESORN <lluang@yahoo.com> FOR THE STATS MODULE BASED ON WILKINSON'S STATISTICS QUIZ http://www.stanford.edu/~clint/bench/wilk.txt Additional tests by a host of SciPy developers. """ from __future__ import division, print_function, absolute_impo...
unknown
codeparrot/codeparrot-clean
# -*- coding: utf-8 -*- """ *************************************************************************** AddTableField.py --------------------- Date : August 2012 Copyright : (C) 2012 by Victor Olaya Email : volayaf at gmail dot com *************************...
unknown
codeparrot/codeparrot-clean
// 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/LICENSE-2.0 // // Unless required by applicable law or agreed t...
go
github
https://github.com/etcd-io/etcd
client/v3/config.go
# frozen_string_literal: true class ChatMessage < ActiveRecord::Base end class ChatMessageCustomPk < ActiveRecord::Base self.table_name = "chat_messages_custom_pk" end
ruby
github
https://github.com/rails/rails
activerecord/test/models/chat_message.rb
# Copyright 2013 The Chromium Authors. All rights reserved. # Use of this source code is governed by a BSD-style license that can be # found in the LICENSE file. import threading class TestCollection(object): """A threadsafe collection of tests. Args: tests: List of tests to put in the collection. """ d...
unknown
codeparrot/codeparrot-clean
class CustomButton extends HTMLButtonElement {} customElements.define('custom-button', CustomButton, { extends: 'button' });
javascript
github
https://github.com/sveltejs/svelte
packages/svelte/tests/runtime-browser/custom-elements-samples/extended-builtin/custom-button.js
#!/usr/bin/env python # # Copyright 2013 Free Software Foundation, Inc. # # This file is part of GNU Radio # # GNU Radio 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, or (at your option) # ...
unknown
codeparrot/codeparrot-clean
function component(a) { let t = {a}; function x() { t.foo(); } x(t); return t; } export const FIXTURE_ENTRYPOINT = { fn: component, params: ['TodoAdd'], isComponent: 'TodoAdd', };
javascript
github
https://github.com/facebook/react
compiler/packages/babel-plugin-react-compiler/src/__tests__/fixtures/compiler/capturing-function-decl.js
#!/usr/bin/env python # -*- coding: iso-8859-1 -*- ''' retain - Command-line utility that removes all files except the ones specified on the command line. Usage: ------ retain [-fnrsv] [-d directory] filename [...] Options: -------- --directory <dir> The directory to operate on. Defaults to the current -...
unknown
codeparrot/codeparrot-clean
import json import uuid import sqlalchemy as sql from sqlalchemy import orm from keystone import config from keystone import exception CONF = config.CONF def upgrade(migrate_engine): meta = sql.MetaData() meta.bind = migrate_engine role_table = sql.Table('role', meta, autoload=True) # name should b...
unknown
codeparrot/codeparrot-clean
/* Copyright 2017 - 2025 R. Thomas * Copyright 2017 - 2025 Quarkslab * * 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 req...
unknown
github
https://github.com/nodejs/node
deps/LIEF/include/LIEF/MachO/ExportInfo.hpp
// Copyright IBM Corp. 2016, 2025 // SPDX-License-Identifier: BUSL-1.1 package builtinplugins import ( "context" credJWT "github.com/hashicorp/vault-plugin-auth-jwt" logicalKv "github.com/hashicorp/vault-plugin-secrets-kv" credAppRole "github.com/hashicorp/vault/builtin/credential/approle" credCert "github.com/...
go
github
https://github.com/hashicorp/vault
helper/builtinplugins/registry.go
""" General testing utilities. """ import sys from contextlib import contextmanager from django.dispatch import Signal from markupsafe import escape from mock import Mock, patch @contextmanager def nostderr(): """ ContextManager to suppress stderr messages http://stackoverflow.com/a/1810086/882918 """ ...
unknown
codeparrot/codeparrot-clean
"""Support for the sensors in a GreenEye Monitor.""" from homeassistant.const import ( CONF_NAME, CONF_SENSOR_TYPE, CONF_TEMPERATURE_UNIT, POWER_WATT, TIME_HOURS, TIME_MINUTES, TIME_SECONDS, VOLT, ) from homeassistant.helpers.entity import Entity from . import ( CONF_COUNTED_QUANTIT...
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");...
java
github
https://github.com/apache/hadoop
hadoop-common-project/hadoop-common/src/main/java/org/apache/hadoop/service/launcher/ServiceShutdownHook.java
import { parseISO, format } from "date-fns"; type DateProps = { dateString: string; }; const Date = (props: DateProps) => { const { dateString } = props; const date = parseISO(dateString); return <time dateTime={dateString}>{format(date, "LLLL d, yyyy")}</time>; }; export default Date;
typescript
github
https://github.com/vercel/next.js
examples/cms-cosmic/components/date.tsx
# -*- coding: utf-8 -*- """QGIS Unit tests for QgsRasterFileWriter. .. note:: 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 2 of the License, or (at your option) any later version. "...
unknown
codeparrot/codeparrot-clean
/* * Copyright (C) 2009 The Guava 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 agre...
java
github
https://github.com/google/guava
guava-gwt/src-super/com/google/common/collect/super/com/google/common/collect/ForwardingImmutableList.java
# 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
/*------------------------------------------------------------------------- * * nodeIndexonlyscan.c * Routines to support index-only scans * * Portions Copyright (c) 1996-2026, PostgreSQL Global Development Group * Portions Copyright (c) 1994, Regents of the University of California * * * IDENTIFICATION * ...
c
github
https://github.com/postgres/postgres
src/backend/executor/nodeIndexonlyscan.c
// Copyright 2012 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 runtime_test import ( "runtime" "testing" ) // arm soft division benchmarks adapted from // https://ridiculousfish.com/files/division_benchmarks.tar...
go
github
https://github.com/golang/go
src/runtime/vlop_arm_test.go
# Licensed under a 3-clause BSD style license - see LICENSE.rst import sys import pytest import numpy as np from astropy import table from astropy.table import Row from astropy import units as u from .conftest import MaskedTable def test_masked_row_with_object_col(): """ Numpy < 1.8 has a bug in masked arra...
unknown
codeparrot/codeparrot-clean
#!/usr/bin/env python from __future__ import with_statement import time from SocketServer import ThreadingMixIn, TCPServer, StreamRequestHandler #import pydysh from aupy2 import Utility class Master(object): def __init__(self): self.master_server = None super(Master, self).__init__() def startMonitor(self, ips...
unknown
codeparrot/codeparrot-clean
# -*- coding: utf-8 -*- ############################################################################################### # # MediaPortal for Dreambox OS # # Coded by MediaPortal Team (c) 2013-2017 # # This plugin is open source but it is NOT free software. # # This plugin may only be distributed to and executed...
unknown
codeparrot/codeparrot-clean