code
stringlengths
1
25.8M
language
stringclasses
18 values
source
stringclasses
4 values
repo
stringclasses
78 values
path
stringlengths
0
268
import { createApp } from 'vue' import { renderToString } from '../src/renderToString' describe('ssr: compiler options', () => { test('config.isCustomElement (deprecated)', async () => { const app = createApp({ template: `<div><x-button/></div>`, }) app.config.isCustomElement = tag => tag.startsWit...
typescript
github
https://github.com/vuejs/core
packages/server-renderer/__tests__/ssrCompilerOptions.spec.ts
#!/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 the user can override the compiler and linker using CC/CXX/NM/READELF environment variables. """ import TestGyp import os i...
unknown
codeparrot/codeparrot-clean
This is an {{ author }}.
html
github
https://github.com/django/django
tests/generic_views/templates/generic_views/author_detail.html
# rbx & bulma-pro example This example shows how to use Next.js along with [rbx](https://github.com/dfee/rbx)(Bulma UI Framework for react) and [Bulma Pro](https://mubaidr.js.org/bulma-pro/). ## Deploy your own [![Deploy with Vercel](https://vercel.com/button)](https://vercel.com/new/clone?repository-url=https://git...
unknown
github
https://github.com/vercel/next.js
examples/with-rbx-bulma-pro/README.md
# zerotrie [![crates.io](https://img.shields.io/crates/v/zerotrie)](https://crates.io/crates/zerotrie) <!-- cargo-rdme start --> A data structure offering zero-copy storage and retrieval of byte strings, with a focus on the efficient storage of ASCII strings. Strings are mapped to `usize` values. [`ZeroTrie`] does n...
unknown
github
https://github.com/nodejs/node
deps/crates/vendor/zerotrie/README.md
#!/usr/bin/env python #coding:utf-8 from toughradius.tools.secret import gen_secret def echo_radiusd_cnf(): return '''[DEFAULT] debug = 0 tz = CST-8 secret = %s ssl = 1 privatekey = /var/toughradius/privkey.pem certificate = /var/toughradius/cacert.pem [database] dbtype = mysql dburl = mysql://radiusd:root@127.0....
unknown
codeparrot/codeparrot-clean
#include <ruby.h> static size_t usr_size(const void *ptr) { return sizeof(int); } static const rb_data_type_t usrmarshal_type = { "UsrMarshal", {0, RUBY_DEFAULT_FREE, usr_size,}, 0, 0, RUBY_TYPED_FREE_IMMEDIATELY|RUBY_TYPED_WB_PROTECTED, }; static VALUE usr_alloc(VALUE klass) { int *p; re...
c
github
https://github.com/ruby/ruby
ext/-test-/marshal/usr/usrmarshal.c
# -*- coding: utf-8 -*- import numpy as np from ..Qt import QtGui, QtCore from ..python2_3 import asUnicode, basestring from .. import metaarray __all__ = ['TableWidget'] def _defersort(fn): def defersort(self, *args, **kwds): # may be called recursively; only the first call needs to block sorting ...
unknown
codeparrot/codeparrot-clean
# Django settings for pdfmergeWEB project. import os DEBUG = True TEMPLATE_DEBUG = DEBUG ADMINS = ( # ('Your Name', 'your_email@example.com'), ) MANAGERS = ADMINS DATABASES = { 'default': { 'ENGINE': 'django.db.backends.', # Add 'postgresql_psycopg2', 'mysql', 'sqlite3' or 'oracle'. 'NAME': ...
unknown
codeparrot/codeparrot-clean
/* date_core.c: Coded by Tadayoshi Funaba 2010-2014 */ #include "ruby.h" #include "ruby/encoding.h" #include "ruby/util.h" #include <math.h> #include <time.h> #if defined(HAVE_SYS_TIME_H) #include <sys/time.h> #endif #undef NDEBUG #define NDEBUG #include <assert.h> #ifdef RUBY_EXTCONF_H #include RUBY_EXTCONF_H #en...
c
github
https://github.com/ruby/ruby
ext/date/date_core.c
# -*- coding: utf-8 -*- # # This file is part of Invenio. # Copyright (C) 2007, 2008, 2009, 2010, 2011, 2014 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,...
unknown
codeparrot/codeparrot-clean
apiVersion: v1 kind: Service metadata: name: a spec: selector: app: test clusterIP: 10.0.0.12 ports: - port: 80
unknown
github
https://github.com/kubernetes/kubernetes
hack/testdata/service-revision2.yaml
// Copyright (c) HashiCorp, Inc. // SPDX-License-Identifier: BUSL-1.1 package remoteexec import ( "bytes" "context" "errors" "fmt" "io" "io/ioutil" "log" "os" "strings" "github.com/hashicorp/terraform/internal/communicator" "github.com/hashicorp/terraform/internal/communicator/remote" "github.com/hashico...
go
github
https://github.com/hashicorp/terraform
internal/builtin/provisioners/remote-exec/resource_provisioner.go
// ignore-tidy-filelength use core::mem; use core::ops::{Bound, ControlFlow}; use ast::mut_visit::{self, MutVisitor}; use ast::token::IdentIsRaw; use ast::{CoroutineKind, ForLoopKind, GenBlockKind, MatchKind, Pat, Path, PathSegment, Recovered}; use rustc_ast::token::{self, Delimiter, InvisibleOrigin, MetaVarKind, Tok...
rust
github
https://github.com/rust-lang/rust
compiler/rustc_parse/src/parser/expr.rs
doctests = """ Test simple loop with conditional >>> sum(i*i for i in range(100) if i&1 == 1) 166650 Test simple nesting >>> list((i,j) for i in range(3) for j in range(4) ) [(0, 0), (0, 1), (0, 2), (0, 3), (1, 0), (1, 1), (1, 2), (1, 3), (2, 0), (2, 1), (2, 2), (2, 3)] Test nesting with the inner ...
unknown
codeparrot/codeparrot-clean
#!/usr/bin/env python import os import re import sys import pickle import time import traceback import yahoo.search from yahoo.search.web import WebSearch APP_ID = 'P5ihFKzV34G69QolFfb3nN7p0rSsYfC9tPGq.IUS.NLWEeJ14SG9Lei0rwFtgwL8cDBrA6Egdw--' QUERY_MODIFIERS = '-site:txdns.net -site:sitedossier.com -mx -site:dataopedi...
unknown
codeparrot/codeparrot-clean
//! This module manages how the incremental compilation cache is represented in //! the file system. //! //! Incremental compilation caches are managed according to a copy-on-write //! strategy: Once a complete, consistent cache version is finalized, it is //! never modified. Instead, when a subsequent compilation sess...
rust
github
https://github.com/rust-lang/rust
compiler/rustc_incremental/src/persist/fs.rs
""" Django settings for istelemarketer project. For more information on this file, see https://docs.djangoproject.com/en/1.6/topics/settings/ For the full list of settings and their values, see https://docs.djangoproject.com/en/1.6/ref/settings/ """ # Build paths inside the project like this: os.path.join(BASE_DIR, ...
unknown
codeparrot/codeparrot-clean
######################################################################### # # # # # copyright 2002 Paul Henry Tremblay # # ...
unknown
codeparrot/codeparrot-clean
// Copyright 2013 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 import "unsafe" // adjust Gobuf as if it executed a call to fn with context ctxt // and then did an immediate Gosave. func gostartcall(buf *go...
go
github
https://github.com/golang/go
src/runtime/sys_arm64.go
# TODO: (FEAT) support additional apache formats (http://ossec-docs.readthedocs.org/en/latest/log_samples/apache/apache.html) # NOQA # TODO: (FEAT) maybe consolidate Json and Custom formatters to the same class, to let other custom formatters use them both for each type implemented # NOQA # TODO: (FEAT) implement Tom...
unknown
codeparrot/codeparrot-clean
# Copyright 2016 Pants project contributors (see CONTRIBUTORS.md). # Licensed under the Apache License, Version 2.0 (see LICENSE). import importlib import logging import os import re import sys import sysconfig import traceback from contextlib import closing from types import CoroutineType from typing import Any, Iter...
unknown
codeparrot/codeparrot-clean
# Copyright (C) 2010 Jim Washington # # 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 wr...
unknown
codeparrot/codeparrot-clean
/* * Copyright 2014-2025 JetBrains s.r.o and contributors. Use of this source code is governed by the Apache 2.0 license. */ package io.ktor.network.sockets.tests import io.ktor.network.sockets.* import io.ktor.util.* import kotlin.test.BeforeTest import kotlin.test.Test import kotlin.test.assertContentEquals clas...
kotlin
github
https://github.com/ktorio/ktor
ktor-network/common/test/io/ktor/network/sockets/tests/InetSocketAddressTest.kt
import agents as ag import envgui as gui import random # ______________________________________________________________________________ loc_A, loc_B = (1, 1), (2, 1) # The two locations for the Vacuum world def RandomVacuumAgent(): "Randomly choose one of the actions from the vacuum environment." p = ag.Ran...
unknown
codeparrot/codeparrot-clean
""" Import geometry from various formats ('import' is python keyword, hence the name 'ymport'). """ from yade.wrapper import * from yade import utils from minieigen import * def textExt(fileName,format='x_y_z_r',shift=Vector3.Zero,scale=1.0,attrs=[],**kw): """Load sphere coordinates from file in specific format, re...
unknown
codeparrot/codeparrot-clean
# META: timeout=long import pytest import time from tests.actions.support.keys import ALL_EVENTS, Keys from tests.actions.support.refine import filter_dict, get_keys, get_events @pytest.mark.parametrize("name,expected", ALL_EVENTS.items()) def test_webdriver_special_key_sends_keydown(session, ...
unknown
codeparrot/codeparrot-clean
# -*- coding: utf-8 -*- ############################################################################## # # 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...
unknown
codeparrot/codeparrot-clean
# Contributing ## Requirements Before getting started, ensure your system has access to the following tools: - [Node.js](https://nodejs.org/) - [Rustup](https://rustup.rs/) - [pnpm](https://pnpm.io/) ## Getting started ```sh # Install dependencies pnpm install # Install Rust toolchain and WASM targets rustup defa...
unknown
github
https://github.com/tailwindlabs/tailwindcss
.github/CONTRIBUTING.md
# Module for interacting with CloudFlare # updated for v4 of cloudflare API import requests import json baseurl = "https://api.cloudflare.com/client/v4" def validate_response(req, logger): ''' General response validation ''' logger.debug("cloudflare: CloudFlare replied with " + str(req.status_code)) if r...
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 n...
java
github
https://github.com/apache/kafka
clients/src/main/java/org/apache/kafka/clients/admin/DescribeShareGroupsOptions.java
# # File: courseware/capa/inputtypes.py # """ Module containing the problem elements which render into input objects - textline - textbox (aka codeinput) - schematic - choicegroup (aka radiogroup, checkboxgroup) - javascriptinput - imageinput (for clickable image) - optioninput (for option list) - filesubmission (...
unknown
codeparrot/codeparrot-clean
# -*- coding: utf-8 -*- # # Copyright (C) 2007-2010 Edgewall Software # All rights reserved. # # This software is licensed as described in the file COPYING, which # you should have received as part of this distribution. The terms # are also available at http://babel.edgewall.org/wiki/License. # # This software consists...
unknown
codeparrot/codeparrot-clean
{ "kind": "Dashboard", "apiVersion": "dashboard.grafana.app/v0alpha1", "metadata": { "name": "v30.value_mappings_and_tooltip_options.v42" }, "spec": { "annotations": { "list": [ { "builtIn": 1, "datasource": { "type": "grafana", "uid": "-- Graf...
json
github
https://github.com/grafana/grafana
apps/dashboard/pkg/migration/conversion/testdata/migrated_dashboards_output/v1beta1-mig-v30.value_mappings_and_tooltip_options.v42.v0alpha1.json
# # 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...
python
github
https://github.com/apache/airflow
airflow-core/tests/unit/decorators/test_mapped.py
# 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...
unknown
codeparrot/codeparrot-clean
from __future__ import absolute_import from typing import Any, Optional, Callable, Tuple, Text from six.moves import zip from django.utils.translation import ugettext as _ from django.utils.datetime_safe import datetime from django.http import HttpRequest, HttpResponse from zerver.decorator import api_key_only_webho...
unknown
codeparrot/codeparrot-clean
## Input ```javascript function foo() { const {'data-foo-bar': t} = {'data-foo-bar': 1}; return t; } export const FIXTURE_ENTRYPOINT = { fn: foo, params: [], isComponent: false, }; ``` ## Code ```javascript import { c as _c } from "react/compiler-runtime"; function foo() { const $ = _c(1); let t0; ...
unknown
github
https://github.com/facebook/react
compiler/packages/babel-plugin-react-compiler/src/__tests__/fixtures/compiler/destructure-string-literal-invalid-identifier-property-key.expect.md
# 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
# -*- coding: utf-8 -*- # # PhDB documentation build configuration file, created by # sphinx-quickstart on Thu Sep 18 12:55:50 2014. # # 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. # # All ...
unknown
codeparrot/codeparrot-clean
# (c) 2012-2014, Michael DeHaan <michael.dehaan@gmail.com> # # 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 License, or # (at your option) an...
unknown
codeparrot/codeparrot-clean
/* * 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/main/java/org/springframework/resilience/InvocationRejectedException.java
# This file is part of Androguard. # # Copyright (c) 2012 Geoffroy Gueguen <geoffroy.gueguen@gmail.com> # 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://...
unknown
codeparrot/codeparrot-clean
//===--- APIntMap.h - A map with APInts as the keys -------------*- 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/Basic/APIntMap.h
from config import config, ConfigSubsection, ConfigSlider, ConfigYesNo, ConfigNothing from enigma import eDBoxLCD from Components.SystemInfo import SystemInfo from Screens.InfoBar import InfoBar from Screens.Screen import Screen class dummyScreen(Screen): skin = """<screen position="0,0" size="0,0" transparent="1"> ...
unknown
codeparrot/codeparrot-clean
/* * Copyright 2012-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-boot
core/spring-boot-autoconfigure/src/test/java/org/springframework/boot/autoconfigure/condition/ConditionalOnWarDeploymentTests.java
# -*- coding: utf-8 -*- ############################################################################## # For copyright and license notices, see __openerp__.py file in module root # directory ############################################################################## from openerp import fields, models, api class acc...
unknown
codeparrot/codeparrot-clean
/*------------------------------------------------------------------------- * * list.c * implementation for PostgreSQL generic list package * * See comments in pg_list.h. * * * Portions Copyright (c) 1996-2026, PostgreSQL Global Development Group * Portions Copyright (c) 1994, Regents of the University of Ca...
c
github
https://github.com/postgres/postgres
src/backend/nodes/list.c
# Copyright (C) 2009 Google Inc. All rights reserved. # # Redistribution and use in source and binary forms, with or without # modification, are permitted provided that the following conditions are # met: # # * Redistributions of source code must retain the above copyright # notice, this list of conditions and the ...
unknown
codeparrot/codeparrot-clean
""" Python 'utf-16' Codec Written by Marc-Andre Lemburg (mal@lemburg.com). (c) Copyright CNRI, All Rights Reserved. NO WARRANTY. """ import codecs, sys ### Codec APIs encode = codecs.utf_16_encode def decode(input, errors='strict'): return codecs.utf_16_decode(input, errors, True) class IncrementalEncoder(co...
unknown
codeparrot/codeparrot-clean
--- navigation_title: "Classic" mapped_pages: - https://www.elastic.co/guide/en/elasticsearch/reference/current/analysis-classic-tokenfilter.html --- # Classic token filter [analysis-classic-tokenfilter] Performs optional post-processing of terms generated by the [`classic` tokenizer](/reference/text-analysis/analy...
unknown
github
https://github.com/elastic/elasticsearch
docs/reference/text-analysis/analysis-classic-tokenfilter.md
""" core implementation of testing process: init, session, runtest loop. """ import py import pytest, _pytest import inspect import os, sys, imp try: from collections import MutableMapping as MappingMixin except ImportError: from UserDict import DictMixin as MappingMixin from _pytest.mark import MarkInfo tra...
unknown
codeparrot/codeparrot-clean
<!--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/ja/model_doc/biogpt.md
# # 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 us...
unknown
codeparrot/codeparrot-clean
# Copyright (C) 2010 Google Inc. All rights reserved. # # Redistribution and use in source and binary forms, with or without # modification, are permitted provided that the following conditions are # met: # # * Redistributions of source code must retain the above copyright # notice, this list of conditions and the f...
unknown
codeparrot/codeparrot-clean
// Copyright (c) HashiCorp, Inc. // SPDX-License-Identifier: BUSL-1.1 package configschema import ( "testing" "github.com/zclconf/go-cty/cty" "github.com/hashicorp/terraform/internal/tfdiags" ) func TestCoerceValue(t *testing.T) { tests := map[string]struct { Schema *Block Input cty.Value WantValu...
go
github
https://github.com/hashicorp/terraform
internal/configs/configschema/coerce_value_test.go
# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause) %YAML 1.2 --- $id: http://devicetree.org/schemas/fsi/aspeed,ast2600-fsi-master.yaml# $schema: http://devicetree.org/meta-schemas/core.yaml# title: Aspeed FSI master maintainers: - Eddie James <eajames@linux.ibm.com> description: The AST2600 and later cont...
unknown
github
https://github.com/torvalds/linux
Documentation/devicetree/bindings/fsi/aspeed,ast2600-fsi-master.yaml
import Link from "next/link"; const Header = () => { return ( <h2 className="text-2xl md:text-4xl font-bold tracking-tight md:tracking-tighter leading-tight mb-20 mt-8"> <Link href="/" className="hover:underline"> Blog </Link> . </h2> ); }; export default Header;
typescript
github
https://github.com/vercel/next.js
examples/cms-cosmic/components/header.tsx
""" Update all copyright notices to the current year. Does a search for a specific copyright notice of last year and replaces it with a version for this year. Other copyright mentionings are listed, but left unmodified. If an argument is given, use that as the name of the copyright holder, otherwise use the name speci...
unknown
codeparrot/codeparrot-clean
// Code generated by "stringer -type=OperationType operation_type.go"; DO NOT EDIT. package backendrun import "strconv" func _() { // An "invalid array index" compiler error signifies that the constant values have changed. // Re-run the stringer command to generate them again. var x [1]struct{} _ = x[OperationTy...
go
github
https://github.com/hashicorp/terraform
internal/backend/backendrun/operationtype_string.go
# oracle/zxjdbc.py # Copyright (C) 2005-2012 the SQLAlchemy authors and contributors <see AUTHORS file> # # This module is part of SQLAlchemy and is released under # the MIT License: http://www.opensource.org/licenses/mit-license.php """ .. dialect:: oracle+zxjdbc :name: zxJDBC for Jython :dbapi: zxjdbc :c...
unknown
codeparrot/codeparrot-clean
package listeners import ( "crypto/tls" "fmt" "net" "strings" "github.com/Microsoft/go-winio" "github.com/docker/go-connections/sockets" ) // Init creates new listeners for the server. func Init(proto, addr, socketGroup string, tlsConfig *tls.Config) ([]net.Listener, error) { ls := []net.Listener{} switch p...
go
github
https://github.com/moby/moby
daemon/listeners/listeners_windows.go
// Copyright IBM Corp. 2016, 2025 // SPDX-License-Identifier: MPL-2.0 package pluginidentityutil import ( "fmt" "time" "github.com/hashicorp/vault/sdk/framework" ) // PluginIdentityTokenParams contains a set of common parameters that plugins // can use for setting plugin identity token behavior. type PluginIdent...
go
github
https://github.com/hashicorp/vault
sdk/helper/pluginidentityutil/fields.go
/* * Copyright (C) Igor Sysoev * Copyright (C) Nginx, Inc. */ #include <ngx_config.h> #include <ngx_core.h> #include <ngx_http.h> static void ngx_http_read_client_request_body_handler(ngx_http_request_t *r); static ngx_int_t ngx_http_do_read_client_request_body(ngx_http_request_t *r); static ngx_int_t ngx_http_cop...
c
github
https://github.com/nginx/nginx
src/http/ngx_http_request_body.c
//// [tests/cases/conformance/jsdoc/callbackTagVariadicType.ts] //// //// [callbackTagVariadicType.js] /** * @callback Foo * @param {...string} args * @returns {number} */ /** @type {Foo} */ export const x = () => 1 var res = x('a', 'b') //// [callbackTagVariadicType.js] /** * @callback Foo * @param {...string...
javascript
github
https://github.com/microsoft/TypeScript
tests/baselines/reference/callbackTagVariadicType.js
# -*- coding: utf-8 -*- # Generated by Django 1.11.4 on 2018-08-05 20:47 from __future__ import unicode_literals from django.db import migrations, models import django.db.models.deletion class Migration(migrations.Migration): dependencies = [ ('crm', '0044_reportingperiod_status'), ] operations ...
unknown
codeparrot/codeparrot-clean
import argparse import subprocess import myhdl from myhdl import (Signal, intbv, always_seq, always_comb, concat, ConcatSignal,) from rhea.cores.uart import uartlite from rhea.cores.memmap import command_bridge from rhea.cores.misc import glbl_timer_ticks from rhea import Global, Clock, Reset from ...
unknown
codeparrot/codeparrot-clean
"""A collection of string operations (most are no longer used). Warning: most of the code you see here isn't normally used nowadays. Beginning with Python 1.6, many of these functions are implemented as methods on the standard string object. They used to be implemented by a built-in module called strop, but strop is n...
unknown
codeparrot/codeparrot-clean
#! /usr/bin/env python3 # Variant of "which". # On stderr, near and total misses are reported. # '-l<flags>' argument adds ls -l<flags> of each file found. import sys if sys.path[0] in (".", ""): del sys.path[0] import sys, os from stat import * def msg(str): sys.stderr.write(str + '\n') def main(): pathli...
unknown
codeparrot/codeparrot-clean
# customised version of 'waf dist' for Samba tools # uses git ls-files to get file lists import Utils, os, sys, tarfile, stat, Scripting, Logs, Options from samba_utils import * dist_dirs = None dist_blacklist = "" def add_symlink(tar, fname, abspath, basedir): '''handle symlinks to directories that may move dur...
unknown
codeparrot/codeparrot-clean
from scrapy.spider import BaseSpider class InitSpider(BaseSpider): """Base Spider with initialization facilities""" def __init__(self, *a, **kw): super(InitSpider, self).__init__(*a, **kw) self._postinit_reqs = [] self._init_complete = False self._init_started = False def ...
unknown
codeparrot/codeparrot-clean
#!/usr/bin/env python # 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. """\ Wrapper script around Rietveld's upload.py that simplifies working with groups of files. """ import json import optparse impo...
unknown
codeparrot/codeparrot-clean
// #docplaster // #docregion import {Component} from '@angular/core'; import {trigger, transition, state, animate, style} from '@angular/animations'; // #docregion toggle-animation @Component({ // #enddocregion toggle-animation selector: 'app-open-close-toggle', templateUrl: 'open-close.4.html', styleUrls: ['o...
typescript
github
https://github.com/angular/angular
adev/src/content/examples/animations/src/app/open-close.4.ts
import numpy import six from chainer import cuda from chainer import function from chainer.utils import type_check class NegativeSamplingFunction(function.Function): def __init__(self, sampler, sample_size): self.sampler = sampler self.sample_size = sample_size def _make_samples(self, t): ...
unknown
codeparrot/codeparrot-clean
#!/bin/sh test_description='merge conflict in crlf repo b---M / / initial---a ' GIT_TEST_DEFAULT_INITIAL_BRANCH_NAME=main export GIT_TEST_DEFAULT_INITIAL_BRANCH_NAME . ./test-lib.sh test_expect_success setup ' git config core.autocrlf true && echo foo | append_cr >file && git add file && git comm...
unknown
github
https://github.com/git/git
t/t6413-merge-crlf.sh
# -*- Mode:Python -*- ########################################################################## # # # This file is part of AVANGO. # # ...
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
# 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 use ...
unknown
codeparrot/codeparrot-clean
"use strict"; module.exports = function filter(config) { // This test can't run in development mode return config.mode !== "development"; };
javascript
github
https://github.com/webpack/webpack
test/cases/chunks/statical-dynamic-import-destructuring/test.filter.js
# Create your views here. import csv import os from django import forms from django.http import HttpResponse from django.shortcuts import render_to_response from django.template import RequestContext import tempfile class MsgForm(forms.Form): subject = forms.CharField(max_length=100) message = forms.CharField...
unknown
codeparrot/codeparrot-clean
################################################################# # lightingPanel.py # Written by Yi-Hong Lin, yihhongl@andrew.cmu.edu, 2004 ################################################################# # Import Tkinter, Pmw, and the floater code from this directory tree. from direct.tkwidgets.AppShell import AppSh...
unknown
codeparrot/codeparrot-clean
//===--- FeatureSet.cpp - Language feature support --------------*- C++ -*-===// // // This source file is part of the Swift.org open source project // // Copyright (c) 2024 - 2025 Apple Inc. and the Swift project authors // Licensed under Apache License v2.0 with Runtime Library Exception // // See https://swift.org/L...
cpp
github
https://github.com/apple/swift
lib/AST/FeatureSet.cpp
import { Form, Scripts, ScrollRestoration, isRouteErrorResponse, } from "react-router"; import type { Route } from "./+types/root"; import appStylesHref from "./app.css?url"; export default function App() { return ( <> <div id="sidebar"> <h1>React Router Contacts</h1> <div> ...
typescript
github
https://github.com/remix-run/react-router
tutorials/address-book/app/root.tsx
#!/usr/bin/env python # Copyright 2014 The Swarming Authors. All rights reserved. # Use of this source code is governed by the Apache v2.0 license that can be # found in the LICENSE file. import logging import os import sys import unittest ROOT_DIR = os.path.dirname(os.path.dirname(os.path.abspath(__file__))) sys.pat...
unknown
codeparrot/codeparrot-clean
#!/usr/bin/env python import os import re import shutil import subprocess import sys import stat from lib.config import LIBCHROMIUMCONTENT_COMMIT, BASE_URL, PLATFORM, \ get_target_arch, get_chromedriver_version from lib.util import scoped_cwd, rm_rf, get_atom_shell_version, make_zip, \ ...
unknown
codeparrot/codeparrot-clean
import Logging /// A container providing arbitrary storage for extensions of an existing type, designed to obviate /// the problem of being unable to add stored properties to a type in an extension. Each stored item /// is keyed by a type conforming to ``StorageKey`` protocol. public struct Storage: Sendable { ///...
swift
github
https://github.com/vapor/vapor
Sources/Vapor/Utilities/Storage.swift
# Copyright 2014 Basho Technologies, Inc. # # This file is provided to you 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
import { ok, test } from '../../test'; const items = [{ id: 'a' }, { id: 'b' }]; export default test({ get props() { return { /** @type {{ id: string } | null} */ foo: null, items }; }, test({ assert, component, target }) { const select = target.querySelector('select'); ok(select); const optio...
javascript
github
https://github.com/sveltejs/svelte
packages/svelte/tests/runtime-legacy/samples/binding-select-null-placeholder-2/_config.js
<?php declare(strict_types=1); /* * This file is part of Composer. * * (c) Nils Adermann <naderman@naderman.de> * Jordi Boggiano <j.boggiano@seld.be> * * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ namespace Composer\Reposit...
php
github
https://github.com/composer/composer
src/Composer/Repository/PathRepository.php
#!/usr/bin/python # coding=utf-8 ################################################################################ from test import unittest from diamond.metric import Metric class TestMetric(unittest.TestCase): def testgetPathPrefix(self): metric = Metric('servers.com.example.www.cpu.total.idle', ...
unknown
codeparrot/codeparrot-clean
<?php // autoload.php @generated by Composer require_once __DIR__ . '/composer/autoload_real.php'; return ComposerAutoloaderInit46489d6835a727203ffccd612295440e::getLoader();
php
github
https://github.com/composer/composer
tests/Composer/Test/Fixtures/functional/installed-versions2/vendor/autoload.php
import logging from django.contrib.contenttypes.models import ContentType from django.template.loader import render_to_string from django.contrib.sites.models import Site from django.conf import settings from django_twitter import utils log = logging.getLogger("django_twitter.signals") def tweet(sender, instance, *...
unknown
codeparrot/codeparrot-clean
import re from urllib import robotparser from urllib.parse import urljoin from downloader import Downloader def get_robots_parser(robots_url): rp = robotparser.RobotFileParser() rp.set_url(robots_url) rp.read() return rp def get_links(html): webpage_regex = re.compile("""<a[^>]+href=["'](.*?)["']"...
unknown
codeparrot/codeparrot-clean
# -*-coding:Utf-8 -* # Copyright (c) 2010-2017 LE GOFF Vincent # All rights reserved. # # Redistribution and use in source and binary forms, with or without # modification, are permitted provided that the following conditions are met: # # * Redistributions of source code must retain the above copyright notice, this # ...
unknown
codeparrot/codeparrot-clean
""" !Changing this line will break Test_findfile.test_found! Non-gui unit tests for idlelib.GrepDialog methods. dummy_command calls grep_it calls findfiles. An exception raised in one method will fail callers. Otherwise, tests are mostly independent. *** Currently only test grep_it. """ import unittest from test.test_s...
unknown
codeparrot/codeparrot-clean
from units.compat import unittest from units.compat.mock import patch from ansible.module_utils import basic from ansible.module_utils._text import to_bytes import ansible.modules.system.ufw as module import json # mock ufw messages ufw_version_35 = """ufw 0.35\nCopyright 2008-2015 Canonical Ltd.\n""" ufw_verbose_h...
unknown
codeparrot/codeparrot-clean
# pylint: disable=missing-docstring # pylint: disable=redefined-outer-name from lettuce import step, world from nose.tools import assert_equal, assert_false, assert_regexp_matches from common import get_codemirror_value, press_the_notification_button, type_in_codemirror KEY_CSS = '.key h3.title' DISPLAY_NAME_KEY = "...
unknown
codeparrot/codeparrot-clean
""" Author: Dr. Mohamed Amine Bouhlel <mbouhlel@umich.edu> Dr. Nathalie.bartoli <nathalie@onera.fr> This package is distributed under New BSD license. TO DO: - define outputs['sol'] = self.sol """ import numpy as np import scipy from smt.surrogate_models.surrogate_model import SurrogateModel from smt.uti...
unknown
codeparrot/codeparrot-clean
import XCTest import Vapor final class AsyncCommandsTests: XCTestCase { var app: Application! override func setUp() async throws { app = try await Application.make(.testing) } override func tearDown() async throws { try await app.asyncShutdown() } func testAsyncCommands() asy...
swift
github
https://github.com/vapor/vapor
Tests/VaporTests/AsyncCommandsTests.swift
@keyframes why { 0% { color: red; } 100% { color: blue; } }
css
github
https://github.com/sveltejs/svelte
packages/svelte/tests/css/samples/global-keyframes-with-no-elements/expected.css