messages listlengths 2 2 | language stringclasses 8
values | prompt_type stringclasses 2
values | lint_errors int64 0 129 ⌀ | cyclomatic_complexity int64 0 32 ⌀ | license stringclasses 7
values | commit stringlengths 40 40 | repos stringlengths 5 116k | new_file stringlengths 4 220 | status stringclasses 6
values | error stringlengths 26 74 ⌀ | is_valid_syntax bool 2
classes |
|---|---|---|---|---|---|---|---|---|---|---|---|
[
{
"role": "user",
"content": "Write typescript code for the following: Bring in skeleton of new to zipfile slicer"
},
{
"role": "assistant",
"content": "module microtome.slicer {\n export class ToZipSlicer {\n\n constructor(slicer:AdvancedSlicer){\n }\n\n do(cfg: microtome.printer.Prin... | typescript | new_file | 0 | 1 | apache-2.0 | 8277dea295d72a5063c2c672f4852286fa29ac9f | DanielJoyce/microtome,DanielJoyce/microtome,Microtome/microtome,Microtome/microtome,DanielJoyce/microtome,DanielJoyce/microtome,Microtome/microtome | lib/ts/toZipSlicer.ts | accepted | null | true |
[
{
"role": "user",
"content": "Write typescript code for the following: test: Add MOVE_SLIDE_DOWN test for slide reducer"
},
{
"role": "assistant",
"content": "import { expect } from 'chai';\nimport { MOVE_SLIDE_DOWN } from '../../../../app/constants/slides.constants';\n\nexport default function(... | typescript | new_file | 0 | 1 | mit | 5db64ce545a4a291fa1944b03de974eae11d94f8 | Team-CHAD/DevDecks,Team-CHAD/DevDecks,DevDecks/devdecks,chengsieuly/devdecks,DevDecks/devdecks,Team-CHAD/DevDecks,DevDecks/devdecks,chengsieuly/devdecks,chengsieuly/devdecks | test/reducers/slides/actions/moveSlideDown-spec.ts | rejected_duplicate | Near-duplicate of sample 112479 | true |
[
{
"role": "user",
"content": "Write typescript code for the following: Add SetService and method to get all Sets"
},
{
"role": "assistant",
"content": "import {Injectable} from 'angular2/core';\nimport {Http, Response} from 'angular2/http';\nimport {Observable} from 'rxjs/Rx';\nimport 'rxjs/add/... | typescript | new_file | 0 | 2 | mit | 1c53eb937eac55d4c084d24e155ad2ead75eccd8 | christianhg/magicalc,christianhg/magicalc,christianhg/magicalc | app/set/set.service.ts | accepted | null | true |
[
{
"role": "user",
"content": "Write typescript code for the following: Add an example of iterating over the values of a union of literals"
},
{
"role": "assistant",
"content": "import { Union, Literal } from '../index'\n\nconst Day = Union(\n Literal('Sunday'),\n Literal('Monday'),\n Literal(... | typescript | new_file | 0 | 1 | mit | bb916e3c770ee967b3187f3a1863876777ee61f8 | pelotom/runtypes,typeetfunc/runtypes,pelotom/runtypes | src/examples/union-values.ts | accepted | null | true |
[
{
"role": "user",
"content": "Write typescript code for the following: Write basic view for update notif banner"
},
{
"role": "assistant",
"content": "import React from 'react'\nimport styled, { ThemeProvider } from 'styled-components'\n\ninterface Theme {\n wide?: boolean\n}\n\nexport interf... | typescript | new_file | null | null | mit | 7d6117cc6936466a104ada267f2e4ed7979357fa | WorldBrain/WebMemex,WorldBrain/WebMemex | src/common-ui/components/NotifBanner.tsx | rejected_syntax | Syntax error detected by tree-sitter | false |
[
{
"role": "user",
"content": "Write typescript code for the following: Add test for enums with members with unicode names"
},
{
"role": "assistant",
"content": "/// <reference path='fourslash.ts' />\r\n\r\n////enum Foo {\r\n//// X, Y, '☆'\r\n////}\r\n////var x = Foo./**/\r\n\r\ngoTo.marker()... | typescript | new_file | 0 | 0 | apache-2.0 | b56c7d64d2a95e49dd0db81d92da3d0188567243 | fdecampredon/jsx-typescript-old-version,hippich/typescript,mbebenita/shumway.ts,popravich/typescript,hippich/typescript,hippich/typescript,fdecampredon/jsx-typescript-old-version,fdecampredon/jsx-typescript-old-version,mbebenita/shumway.ts,popravich/typescript,mbebenita/shumway.ts,popravich/typescript | tests/cases/fourslash/completionListInvalidMemberNames2.ts | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```typescript\n// Type definitions for countdown.js\n// Project: http://countdownjs.org/\n// Definitions by: Gabriel Juchault https://github.com/gjuchault\n// Definitions: https://github.com/DefinitelyTyped/DefinitelyTyped\n\n/// <reference path=\"cou... | typescript | edit | 0 | 1 | mit | b140e9b8f238b277469930d82353b6c5316b09fd | jimthedev/DefinitelyTyped,rcchen/DefinitelyTyped,subash-a/DefinitelyTyped,dsebastien/DefinitelyTyped,nainslie/DefinitelyTyped,scriby/DefinitelyTyped,slavomirvojacek/DefinitelyTyped,aciccarello/DefinitelyTyped,arusakov/DefinitelyTyped,micurs/DefinitelyTyped,mcrawshaw/DefinitelyTyped,slavomirvojacek/adbrain-typescript-de... | countdown/countdown-tests.ts | accepted | null | true |
[
{
"role": "user",
"content": "Write typescript code for the following: Add unit tests for quota serialization [WAL-2551]"
},
{
"role": "assistant",
"content": "import { OfferingComponent } from '@waldur/marketplace/types';\n\nimport { formatOfferingRequest } from './utils';\n\nconst OFFERING_FOR... | typescript | new_file | 0 | 1 | mit | a8d03e63b6cb6e5b21e90d754a3f158f4ea1bef5 | opennode/waldur-homeport,opennode/waldur-homeport,opennode/waldur-homeport,opennode/waldur-homeport | src/marketplace/offerings/store/utils.spec.ts | accepted | null | true |
[
{
"role": "user",
"content": "Write typescript code for the following: Add ts version of Abstract Factory"
},
{
"role": "assistant",
"content": "abstract class Item {\n protected caption: string;\n\n constructor(caption: string) {\n this.caption = caption;\n }\n\n abstract makeHtml(): str... | typescript | new_file | 0 | 1 | mit | e3a764f6b83628089b294beb85535103ce4f4f75 | Erichain/design-patterns-in-typescript,Erichain/design-patterns-in-typescript | abstract-factory/ts-version.ts | accepted | null | true |
[
{
"role": "user",
"content": "Write typescript code for the following: Add a test to ensure that statsstore unsubscribes"
},
{
"role": "assistant",
"content": "import { expect } from 'chai'\n\nimport { TestStatsDatabase } from '../helpers/databases'\n\nimport { StatsStore } from '../../src/lib/s... | typescript | new_file | 0 | 1 | mit | 2e9073b507b8209b4ce49d7e0f164f6b6c63f054 | kactus-io/kactus,kactus-io/kactus,say25/desktop,j-f1/forked-desktop,artivilla/desktop,artivilla/desktop,shiftkey/desktop,j-f1/forked-desktop,shiftkey/desktop,artivilla/desktop,say25/desktop,desktop/desktop,kactus-io/kactus,j-f1/forked-desktop,desktop/desktop,desktop/desktop,say25/desktop,desktop/desktop,artivilla/deskt... | app/test/unit/stats-store-test.ts | accepted | null | true |
[
{
"role": "user",
"content": "Write typescript code for the following: Add a provider to calculate pax times and convert between classes"
},
{
"role": "assistant",
"content": "import { Injectable } from '@angular/core';\nimport { Http } from '@angular/http';\nimport 'rxjs/add/operator/map';\nimp... | typescript | new_file | 0 | 1 | mit | 0e64070d18f0d3ca7984cdc613bf17ccf4a85568 | blatzblaster/ionic-solo,blatzblaster/ionic-solo,blatzblaster/ionic-solo | app/providers/pax-calculator/pax-calculator.ts | accepted | null | true |
[
{
"role": "user",
"content": "Write typescript code for the following: Add test for short circuiting of &&"
},
{
"role": "assistant",
"content": "/*@ foo :: (arr: Array<Immutable, string>) => { boolean | true } */\nfunction foo(arr) {\n if (arr.length > 0) {\n if (arr[0] === \"blah\") {\n ... | typescript | new_file | 0 | 3 | bsd-3-clause | ee2e97fc6f68ee30c7c4d9e4fc0dabbe94f039ec | UCSD-PL/RefScript,UCSD-PL/RefScript,UCSD-PL/RefScript | tests/pos/operators/short-circuit.ts | accepted | null | true |
[
{
"role": "user",
"content": "Write typescript code for the following: Add parent to numbered list"
},
{
"role": "assistant",
"content": "// Numbered lists - Add parent number in sub number\n// Import from 'docx' rather than '../build' if you install from npm\nimport * as fs from \"fs\";\nimport... | typescript | new_file | 0 | 1 | mit | ef12ada5d7dd4e45f0956ef7070d677c17966662 | dolanmiu/docx,dolanmiu/docx,dolanmiu/docx | demo/57-add-parent-numbered-lists.ts | accepted | null | true |
[
{
"role": "user",
"content": "Write typescript code for the following: Remove logos from core econ charts"
},
{
"role": "assistant",
"content": "import {MigrationInterface, QueryRunner} from \"typeorm\";\nimport {Chart} from '../model/Chart'\n\nexport class CoreEconRemoveLogos1546730871436 imple... | typescript | new_file | 0 | 3 | mit | 4e5ac7cf9e0b0e45d3ae0fd4e8760721959b5979 | OurWorldInData/our-world-in-data-grapher,OurWorldInData/owid-grapher,OurWorldInData/owid-grapher,OurWorldInData/owid-grapher,owid/owid-grapher,owid/owid-grapher,OurWorldInData/our-world-in-data-grapher,OurWorldInData/our-world-in-data-grapher,owid/owid-grapher,owid/owid-grapher,OurWorldInData/owid-grapher,OurWorldInDat... | src/migration/1546730871436-CoreEconRemoveLogos.ts | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```typescript\n/* Note that this is a sample function for the purpose of running the below CustomFunctionsMappings test */\nfunction ADD10(n: number) {\n return n + 10;\n}\n\nCustomFunctionMappings = {\n addTen: ADD10\n};\n\nasync function getSt... | typescript | edit | 0 | 3 | mit | 12ac8b7383e607ae228ff838c73ebbdcd56d64a5 | dsebastien/DefinitelyTyped,mcliment/DefinitelyTyped,AgentME/DefinitelyTyped,georgemarshall/DefinitelyTyped,georgemarshall/DefinitelyTyped,georgemarshall/DefinitelyTyped,AgentME/DefinitelyTyped,borisyankov/DefinitelyTyped,AgentME/DefinitelyTyped,borisyankov/DefinitelyTyped,georgemarshall/DefinitelyTyped,dsebastien/Defin... | types/custom-functions-runtime/custom-functions-runtime-tests.ts | accepted | null | true |
[
{
"role": "user",
"content": "Write typescript code for the following: Add crumpet HTTP service which returns an Observable of Crumpet[] or throws an observable error."
},
{
"role": "assistant",
"content": "/**\n * Created by lthompson on 18/06/2016.\n */\nimport {Injectable} from \"@angular/cor... | typescript | new_file | 0 | 2 | unlicense | 7f9a43951468f4f0046e6073be178b12e2187a51 | luketn/WonderCrumpet | app/services/crumpet-service.ts | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```typescript\nimport { storiesOf } from '@storybook/angular';\nimport { TokenComponent, ITEMS, DEFAULT_NAME } from './moduleMetadata/token.component';\n\nstoriesOf('Metadata|Individual', module)\n .add('Individual 1', () => ({\n template: `<story... | typescript | edit | 0 | 1 | mit | 63b50531d6cf9bafa62e4df783cd17d068b2264b | storybooks/react-storybook,storybooks/react-storybook,storybooks/storybook,rhalff/storybook,storybooks/storybook,storybooks/storybook,rhalff/storybook,rhalff/storybook,kadirahq/react-storybook,rhalff/storybook,storybooks/react-storybook,storybooks/storybook,rhalff/storybook,storybooks/react-storybook,kadirahq/react-sto... | examples/angular-cli/src/stories/metadata-individual.stories.ts | accepted | null | true |
[
{
"role": "user",
"content": "Write typescript code for the following: Create stub replacement for envForAuthentication"
},
{
"role": "assistant",
"content": "import { envForAuthentication } from './authentication'\nimport { IGitAccount } from '../../models/git-account'\n\n/**\n * Create a set o... | typescript | new_file | 0 | 1 | mit | 359d4626415ea07a11c1864a285bbc16ca85e888 | say25/desktop,shiftkey/desktop,artivilla/desktop,desktop/desktop,j-f1/forked-desktop,j-f1/forked-desktop,artivilla/desktop,kactus-io/kactus,artivilla/desktop,kactus-io/kactus,artivilla/desktop,desktop/desktop,say25/desktop,desktop/desktop,desktop/desktop,shiftkey/desktop,kactus-io/kactus,j-f1/forked-desktop,kactus-io/k... | app/src/lib/git/environment.ts | rejected_duplicate | Near-duplicate of sample 115919 | true |
[
{
"role": "user",
"content": "Write typescript code for the following: Add TS Prim's MST algorithm"
},
{
"role": "assistant",
"content": "import { Vertex, Edge } from '../graph';\nimport { Tree, Node } from '../../trees/tree';\n\ntype MstEdge<T> = [Vertex<T, number>, number, Vertex<T, number>];\... | typescript | new_file | 0 | 2 | mit | 558e188c60a81dfdfc147edfd708f37cfd268efc | hAWKdv/DataStructures,hAWKdv/DataStructures | typescript/graphs/algorithms/prims-mst.ts | accepted | null | true |
[
{
"role": "user",
"content": "Write typescript code for the following: Add barebones raised voice context"
},
{
"role": "assistant",
"content": "import { TokenizableConvention } from './TokenizableConvention'\nimport { TokenizerSnapshot } from './TokenizerSnapshot'\nimport { TokenizerContext } f... | typescript | new_file | 0 | 1 | mit | 5b20b8bf4160812cd94c7282c9320606ef18eb88 | start/up,start/up | src/Parsing/Inline/RaisedVoiceContext.ts | accepted | null | true |
[
{
"role": "user",
"content": "Write typescript code for the following: Add a transcoder manager class"
},
{
"role": "assistant",
"content": "import { transcodeTarget, sourceTextureFormat, Transcoder } from './transcoder';\r\nimport { Nullable } from '../../types';\r\nimport { WASMMemoryManager }... | typescript | new_file | 0 | 6 | apache-2.0 | f9a1ce531ebf5bf4ce1079df3313ebb5d12d3f14 | RaananW/Babylon.js,sebavan/Babylon.js,sebavan/Babylon.js,sebavan/Babylon.js,RaananW/Babylon.js,NicolasBuecher/Babylon.js,BabylonJS/Babylon.js,Kesshi/Babylon.js,NicolasBuecher/Babylon.js,Kesshi/Babylon.js,BabylonJS/Babylon.js,BabylonJS/Babylon.js,Kesshi/Babylon.js,NicolasBuecher/Babylon.js,RaananW/Babylon.js | src/Misc/KTX2/transcoderManager.ts | accepted | null | true |
[
{
"role": "user",
"content": "Write typescript code for the following: Add types subdirectory for @nteract/epics"
},
{
"role": "assistant",
"content": "export const LAUNCH_KERNEL_SUCCESSFUL = \"LAUNCH_KERNEL_SUCCESSFUL\";\nexport type NewKernelAction = {\n type: \"LAUNCH_KERNEL_SUCCESSFUL\",\n ... | typescript | new_file | 0 | 0 | bsd-3-clause | 091f9dede75d89be1b3f37551893c29fdddd0ec8 | rgbkrk/nteract,nteract/composition,nteract/nteract,nteract/composition,nteract/composition,rgbkrk/nteract,nteract/nteract,nteract/nteract,nteract/nteract,nteract/nteract,rgbkrk/nteract,rgbkrk/nteract,rgbkrk/nteract | packages/epics/src/types/actions.ts | accepted | null | true |
[
{
"role": "user",
"content": "Write typescript code for the following: Add component for Persistent Character Library"
},
{
"role": "assistant",
"content": "import * as React from \"react\";\nimport { PersistentCharacter } from \"../../../common/PersistentCharacter\";\nimport { LibrariesCommande... | typescript | new_file | null | null | mit | b56f1d18ba9576d92a93cdd536ab8a81a465d6ab | cynicaloptimist/improved-initiative,cynicaloptimist/improved-initiative,cynicaloptimist/improved-initiative | client/Library/Components/PersistentCharacterLibraryViewModel.tsx | rejected_syntax | Syntax error detected by tree-sitter | false |
[
{
"role": "user",
"content": "Write typescript code for the following: Add 2 passing config tests"
},
{
"role": "assistant",
"content": "import { expect } from 'chai'\nimport { Up } from '../../../index'\nimport { insideDocumentAndParagraph } from '../Helpers'\nimport { AudioNode } from '../../.... | typescript | new_file | 0 | 1 | mit | a009c227726d0bb7e0a9219c7a1636e8b6265c83 | start/up,start/up | src/Test/Ast/Config/Audio.ts | accepted | null | true |
[
{
"role": "user",
"content": "Write typescript code for the following: Add reducer to respond to watcher selection actions."
},
{
"role": "assistant",
"content": "import { SelectWatcherTreeNodeAction } from '../actions/watcherTree';\nimport { SELECT_WATCHER_FILE, SELECT_WATCHER_FOLDER } from '..... | typescript | new_file | 0 | 3 | mit | 621321e5439cb9f03387c5b86c4276c2c93c5a02 | Anveio/mturk-engine,Anveio/mturk-engine,Anveio/mturk-engine | src/reducers/watcherTree.ts | accepted | null | true |
[
{
"role": "user",
"content": "Write typescript code for the following: Implement to provide seamless metadata and upgrade route"
},
{
"role": "assistant",
"content": "import { Annotation } from 'alveo-transcriber';\n\nconst STORAGE_VERSION = \"att_1.0\";\n\nexport class Transcription {\n remote... | typescript | new_file | 0 | 1 | bsd-3-clause | 4c07c087e22c556f0b2369cbb090e6b5ce1550bf | Alveo/alveo-transcriber,Alveo/alveo-transcriber,Alveo/alveo-transcriber,Alveo/alveo-transcriber | src/app/transcription/transcription.ts | accepted | null | true |
[
{
"role": "user",
"content": "Write typescript code for the following: :sparkles: Add output template to send a DialogDelegateRequest"
},
{
"role": "assistant",
"content": "import { BaseOutput, Output, OutputOptions, OutputTemplate } from '@jovotech/framework';\n\nexport interface SendDialogDele... | typescript | new_file | 0 | 1 | apache-2.0 | 33cfcd47dc9b3c41f640cd258e1d4f905f6f085f | jovotech/jovo-framework-nodejs,jovotech/jovo-framework-nodejs | platforms/platform-alexa/src/output/templates/SendDialogDelegateRequest.ts | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```typescript\nimport React, {PureComponent} from 'react'\nimport uuid from 'uuid'\n\nimport {ErrorHandling} from 'src/shared/decorators/errors'\nimport FancyScrollbar from 'src/shared/components/FancyScrollbar'\nimport TemplatePreviewListItem from 's... | typescript | edit | null | null | mit | 32e4d0bf8dedc6ad9a0b413498bcc1988f6bcca7 | influxdata/influxdb,mark-rushakoff/influxdb,influxdb/influxdb,mark-rushakoff/influxdb,nooproblem/influxdb,mark-rushakoff/influxdb,mark-rushakoff/influxdb,li-ang/influxdb,nooproblem/influxdb,nooproblem/influxdb,li-ang/influxdb,nooproblem/influxdb,influxdb/influxdb,influxdb/influxdb,influxdb/influxdb,influxdb/influxdb,in... | ui/src/tempVars/components/TemplatePreviewList.tsx | rejected_syntax | Syntax error detected by tree-sitter | false |
[
{
"role": "user",
"content": "Write typescript code for the following: Add the label Data Service\n\nThis could be a lengthy chat."
},
{
"role": "assistant",
"content": "/// <reference path=\"label.d.ts\" />\n/// <reference path=\"../scripts/typings/angularjs/angular.d.ts\" />\n/// <reference p... | typescript | new_file | 0 | 1 | apache-2.0 | 6123a88f187b8b725cf7770d30b0a5de920fa774 | BillWagner/TypeScriptAngular,BillWagner/TypeScriptAngular,BillWagner/TypeScriptAngular,BillWagner/TypeScriptAngular | ngLabels/App_Script/LabelDataService.ts | accepted | null | true |
[
{
"role": "user",
"content": "Write typescript code for the following: Add helper method to convert an observable to a promise."
},
{
"role": "assistant",
"content": "import { Injectable } from '@angular/core';\nimport { Observable } from 'rxjs';\n\n@Injectable()\n\nexport class ObservableHelper... | typescript | new_file | 0 | 1 | bsd-2-clause | 24bd8ab233f01c838f0869b9841b2cf7d30af38f | ohsu-qin/qiprofile,ohsu-qin/qiprofile,ohsu-qin/qiprofile,ohsu-qin/qiprofile | src/helpers/observable.service.ts | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```typescript\nimport React, {PureComponent, ReactChildren} from 'react'\n\ninterface Props {\n children?: ReactChildren\n title: string\n onDismiss?: () => void\n}\n\nclass OverlayHeading extends PureComponent<Props> {\n constructor(props: Props)... | typescript | edit | null | null | mit | d25ff39991efef7d7d7651f1517061defc26f55d | nooproblem/influxdb,nooproblem/influxdb,mark-rushakoff/influxdb,influxdata/influxdb,influxdb/influxdb,influxdb/influxdb,influxdb/influxdb,mark-rushakoff/influxdb,mark-rushakoff/influxdb,mark-rushakoff/influxdb,influxdata/influxdb,nooproblem/influxdb,influxdb/influxdb,li-ang/influxdb,nooproblem/influxdb,nooproblem/influ... | ui/src/shared/components/overlay/OverlayHeading.tsx | rejected_syntax | Syntax error detected by tree-sitter | false |
[
{
"role": "user",
"content": "Write typescript code for the following: Add some tests for forwardContext"
},
{
"role": "assistant",
"content": "import * as React from 'react';\nimport {expect} from 'chai';\n\nimport {forwardContext} from './forwardContext';\n\ndescribe('forwardContext', () => {\... | typescript | new_file | 0 | 1 | mit | 1f6a9b62cb2c526662546faeeda6e04e14990a3c | alitaheri/react-mixout | src/injectors/forwardContext.spec.ts | accepted | null | true |
[
{
"role": "user",
"content": "Write typescript code for the following: Add following features\n - Validate user sessions from local storage\n - Check for credentials\n - Get credentials. This get session from server and save in the broswer local storage\n - Get user details. This returns user details of ser... | typescript | new_file | 0 | 3 | mit | 36f8b6b65efba6d520e6d7d34f4994a43a5d6713 | shavindraSN/examen,shavindraSN/examen,shavindraSN/examen | client/service/auth.service.ts | accepted | null | true |
[
{
"role": "user",
"content": "Write typescript code for the following: Create util function for matching string casing"
},
{
"role": "assistant",
"content": "export default function matchStringCasing(original: string, template: string) {\n return original\n .split('')\n .map(\n (lett... | typescript | new_file | 0 | 3 | mit | ba189ce84b1c279544f9e94fc2318a6bc6ba477e | martinhartt/messagelint,martinhartt/messagelint,martinhartt/messagelint | src/util/matchStringCasing.ts | accepted | null | true |
[
{
"role": "user",
"content": "Write typescript code for the following: Create SorceryService and method to get all Sorceries"
},
{
"role": "assistant",
"content": "import {Injectable} from 'angular2/core';\nimport {Observable} from 'rxjs/Rx';\n\nimport {Card} from '../card/card';\nimport {CardSe... | typescript | new_file | 0 | 1 | mit | 52539db5f0369c29f6caa98e19b46e56dc86245f | christianhg/magicalc,christianhg/magicalc,christianhg/magicalc | app/sorcery/sorcery.service.ts | accepted | null | true |
[
{
"role": "user",
"content": "Write typescript code for the following: Add yaml setting file support"
},
{
"role": "assistant",
"content": "/// <reference types=\"node\" />\nimport * as fs from 'fs';\nimport Setting from './Setting';\nimport yaml from 'yaml';\n\nclass YamlSetting extends Setting... | typescript | new_file | 0 | 3 | mit | 36089487f99c926e4aaddf9904da46f053558c4b | woodstage/node-app-settings,woodstage/node-app-settings | src/YamlSetting.ts | accepted | null | true |
[
{
"role": "user",
"content": "Write typescript code for the following: Create file move counter script"
},
{
"role": "assistant",
"content": "import { FileMoveService as fms, datastore } from '../models';\nimport _ = require(\"underscore\");\nimport moment = require('moment');\n\nasync function ... | typescript | new_file | 0 | 2 | bsd-2-clause | 2d6e91a2e8396e5702d29d12f30928c9557d7fda | mustpax/sortmybox,mustpax/sortmybox,mustpax/sortmybox | src/remote/countMoves.ts | accepted | null | true |
[
{
"role": "user",
"content": "Write typescript code for the following: Add empty state service using request animation frame."
},
{
"role": "assistant",
"content": "/// <reference path=\"../../typings/rx-dom/rx.dom.d.ts\" />\n/// <reference path=\"../../node_modules/rx/ts/rx.all.d.ts\" />\n\nimp... | typescript | new_file | 0 | 2 | mit | 1bc1c5ae173f5ec397cd8db7660df8c2ffb92aca | mapillary/mapillary-js,mapillary/mapillary-js | src/state/StateService2.ts | accepted | null | true |
[
{
"role": "user",
"content": "Write typescript code for the following: Add start of Open Source page"
},
{
"role": "assistant",
"content": "import { NextPage } from \"next\"\nimport Head from \"next/head\"\nimport Page from \"../layouts/main\"\n\nconst OpenSourcePage: NextPage = () => {\n retur... | typescript | new_file | null | null | mit | 737d1170242ebb6ea0478dd0459d2d6d31d5385b | JosephDuffy/josephduffy.co.uk,JosephDuffy/josephduffy.co.uk,JosephDuffy/josephduffy.co.uk | pages/open-source.tsx | rejected_syntax | Syntax error detected by tree-sitter | false |
[
{
"role": "user",
"content": "Write typescript code for the following: Add typescript type tests for map"
},
{
"role": "assistant",
"content": "import {expectType} from 'tsd';\n\nimport * as fl from '../../index.js';\n\nconst resolved = fl.resolve (42);\nconst rejected = fl.reject ('uh-oh');\n\n... | typescript | new_file | 0 | 0 | mit | 76c48d03a25df69f54e5f31bbec162d81d03d20a | fluture-js/Fluture,fluture-js/Fluture,fluture-js/Fluture | test/types/map.test-d.ts | accepted | null | true |
[
{
"role": "user",
"content": "Write typescript code for the following: Add test case for code fixes on qualified names used instead of indexed access types."
},
{
"role": "assistant",
"content": "/// <reference path='fourslash.ts' />\r\n\r\n//// export interface Foo {\r\n//// bar: string;\r\n/... | typescript | new_file | 0 | 0 | apache-2.0 | e9330d49949e64a103cb9f7eb303c4b2cb300b90 | kitsonk/TypeScript,weswigham/TypeScript,alexeagle/TypeScript,TukekeSoft/TypeScript,kitsonk/TypeScript,donaldpipowitch/TypeScript,SaschaNaz/TypeScript,kitsonk/TypeScript,synaptek/TypeScript,SaschaNaz/TypeScript,minestarks/TypeScript,SaschaNaz/TypeScript,donaldpipowitch/TypeScript,weswigham/TypeScript,alexeagle/TypeScrip... | tests/cases/fourslash/codeFixReplaceQualifiedNameWithIndexedAccessType01.ts | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```typescript\nclass $mol_build_server extends $mol_server {\n\t\n\texpressGenerator() {\n\t\treturn ( req : any , res : any , next : () => void )=> {\n\t\t\ttry {\n\t\t\t\treturn this.generator( req.url ) || next()\n\t\t\t} catch( error ) {\n\t\t\t\t... | typescript | edit | 0 | 4 | mit | 73415cd4b02160eb30e393baf8beca9a00c8d550 | eigenmethod/mol,nin-jin/mol,nin-jin/mol,eigenmethod/mol,nin-jin/mol,eigenmethod/mol | build/server/server.env=node.ts | rejected_duplicate | Near-duplicate of sample 115929 | true |
[
{
"role": "user",
"content": "Write typescript code for the following: Add tests for dataset utils"
},
{
"role": "assistant",
"content": "import { xBetweenDates } from './utils';\r\n\r\ndescribe('DatasetUtils', () => {\r\n describe('xBetweenDates', () => {\r\n it('should create function', ()... | typescript | new_file | 0 | 1 | apache-2.0 | f61101f3f57c135dc551fb1557f35b418b08789d | googleinterns/guide-doge,googleinterns/guide-doge,googleinterns/guide-doge | src/datasets/utils.spec.ts | accepted | null | true |
[
{
"role": "user",
"content": "Write typescript code for the following: feat(infrastructure): Add EventRegistry for Listen/Unlisten management"
},
{
"role": "assistant",
"content": "import {\n ElementRef,\n Injectable,\n Renderer2\n} from '@angular/core';\n\ntype UnlistenerMap = WeakMap<EventL... | typescript | new_file | 0 | 3 | mit | d02e7c30fe3d1be406043bb02713db32718597e8 | trimox/angular-mdc-web,trimox/angular-mdc-web | src/lib/common/event-registry.ts | accepted | null | true |
[
{
"role": "user",
"content": "Write typescript code for the following: test: Add test for OPEN_NEW_DECK for slides reducer"
},
{
"role": "assistant",
"content": "import { expect } from 'chai';\nimport { OPEN_NEW_DECK } from '../../../../app/constants/slides.constants';\n\nexport default function... | typescript | new_file | 0 | 1 | mit | 8c5130a3d8981fea9cb2caeaf5491c1ea7788087 | chengsieuly/devdecks,Team-CHAD/DevDecks,Team-CHAD/DevDecks,Team-CHAD/DevDecks,chengsieuly/devdecks,DevDecks/devdecks,DevDecks/devdecks,chengsieuly/devdecks,DevDecks/devdecks | test/reducers/slides/actions/openNewDeck-spec.ts | accepted | null | true |
[
{
"role": "user",
"content": "Write typescript code for the following: Add test for deprecated method decorator"
},
{
"role": "assistant",
"content": "import { DeprecatedMethod } from './../../src/';\n\ndescribe('DeprecatedMethod decorator', () => {\n\n it('should throw an exception', () => {... | typescript | new_file | 0 | 1 | mit | a6448afdf3e0e490889caf6e397f210db90d4d2f | semagarcia/typescript-decorators,semagarcia/typescript-decorators | test/method-decorators/deprecated.spec.ts | accepted | null | true |
[
{
"role": "user",
"content": "Write typescript code for the following: Add tests for note-list components"
},
{
"role": "assistant",
"content": "import * as helper from '../../test_helper';\nvar remoteConsole = require('remote').require('console')\n\ndescribe('note-list', () => {\n var noteList... | typescript | new_file | 0 | 1 | mit | b0118425f0eb0ae28115c8bfba931797a7dd86f8 | ueokande/adversaria,ueokande/adversaria,ueokande/adversaria | test/views/components/note_list_test.ts | accepted | null | true |
[
{
"role": "user",
"content": "Write typescript code for the following: Add tests using the injector"
},
{
"role": "assistant",
"content": "import {\n it,\n describe,\n expect,\n inject\n} from 'angular2/testing';\nimport {\n APP_ID\n} from 'angular2/angular2';\n\n\ndescribe('default test in... | typescript | new_file | 0 | 1 | apache-2.0 | ca2219af4958d19fc202c670e1f583135457b49b | katonap/ng2-test-seed,katonap/ng2-test-seed,katonap/ng2-test-seed | src/test/using_injector_test.ts | accepted | null | true |
[
{
"role": "user",
"content": "Write typescript code for the following: Add firestore api body types"
},
{
"role": "assistant",
"content": "export interface FirestoreApiBody {\n fields: MapValue\n}\n\ntype FieldValue =\n StringValue |\n BooleanValue |\n ArrayValue |\n IntegerValue ... | typescript | new_file | 0 | 0 | apache-2.0 | ab6479243b7da21316cf872490bd9b3db45df645 | squanchy-dev/squanchy-firebase,squanchy-dev/squanchy-firebase | functions/src/patch/firestore-api.ts | accepted | null | true |
[
{
"role": "user",
"content": "Write typescript code for the following: Add issue types from OpenNeuro"
},
{
"role": "assistant",
"content": "const warning = Symbol('warning')\nconst error = Symbol('error')\nconst ignore = Symbol('ignore')\ntype Severity = typeof warning | typeof error | typeof i... | typescript | new_file | 0 | 0 | mit | 1c25fc418e948df22364b33338b81f9d7e1d95ff | nellh/bids-validator,nellh/bids-validator,nellh/bids-validator | bids-validator/src/types/issues.ts | accepted | null | true |
[
{
"role": "user",
"content": "Write typescript code for the following: Add vcs authentication info dummy"
},
{
"role": "assistant",
"content": "import { Dummy, TextDummy, TypesDummy } from '../../test/helpers';\nimport { VcsAuthenticationInfo, VcsAuthenticationTypes } from './vcs';\n\n\nexport c... | typescript | new_file | 0 | 2 | mit | 1fae391e07620a33381f14c61ebc4357deecf150 | seokju-na/geeks-diary,seokju-na/geeks-diary,seokju-na/geeks-diary | src/core/dummies.ts | accepted | null | true |
[
{
"role": "user",
"content": "Write typescript code for the following: Add test for adapter errors"
},
{
"role": "assistant",
"content": "import { module, test } from 'qunit';\nimport { setupTest } from 'ember-qunit';\nimport Pretender from 'pretender';\nimport { TestContext } from 'ember-test-h... | typescript | new_file | 0 | 2 | mit | 47d86ae32c670c29635f164ac47d0ee1122e8535 | ember-data/active-model-adapter,ember-data/active-model-adapter,ember-data/active-model-adapter | tests/unit/adapters/active-model-adapter-errors-test.ts | accepted | null | true |
[
{
"role": "user",
"content": "Write typescript code for the following: Add tests to check health check endpoint"
},
{
"role": "assistant",
"content": "/*\nCopyright 2019 The Matrix.org Foundation C.I.C.\n\nLicensed under the Apache License, Version 2.0 (the \"License\");\nyou may not use this fi... | typescript | new_file | 0 | 1 | apache-2.0 | e6f786759ad8b51e2f574437e17aede6989876ab | matrix-org/matrix-appservice-slack,matrix-org/matrix-appservice-slack,matrix-org/matrix-appservice-slack,matrix-org/matrix-appservice-slack | src/tests/integration/HttpTests.ts | accepted | null | true |
[
{
"role": "user",
"content": "Write typescript code for the following: Add functional test for writeScreenshot"
},
{
"role": "assistant",
"content": "import { browser } from 'protractor';\nimport * as support from '../specs/support';\nimport { LandingPage } from '../specs/page_objects';\n\ndescr... | typescript | new_file | 0 | 1 | apache-2.0 | c7699bd1e179f68f0210ddbe33de295544f6126b | ldimaggi/fabric8-test,ldimaggi/fabric8-test,ldimaggi/fabric8-test,ldimaggi/fabric8-test,ldimaggi/fabric8-test,ldimaggi/fabric8-test | ee_tests/src/functional/screenshot.spec.ts | accepted | null | true |
[
{
"role": "user",
"content": "Write typescript code for the following: Define bas class of threejs pushers"
},
{
"role": "assistant",
"content": "import { EventDispatcher } from \"../util/eventdispatcher\";\n\nexport abstract class Pipeline extends EventDispatcher {\n constructor() {\n su... | typescript | new_file | 0 | 1 | apache-2.0 | 38f78b8978d1904ef96d09621990879c0f420989 | Tomella/explorer-3d,Tomella/explorer-3d,Tomella/explorer-3d | source/push3js/pipeline.ts | accepted | null | true |
[
{
"role": "user",
"content": "Write typescript code for the following: Add test for nested projection\n\nNot uet failing but I have set mongoose debug to true which will show the find query being run during the test.\nThis shows that the entire Author subdocument is being fetching."
},
{
"role": "as... | typescript | new_file | 0 | 1 | mit | 074e6763fa334c50a5d3064fc26c954700748381 | nodkz/graphql-compose-mongoose | src/__tests__/github_issues/271-test.ts | accepted | null | true |
[
{
"role": "user",
"content": "Write typescript code for the following: Add test for using unicode escape as function name"
},
{
"role": "assistant",
"content": "/// <reference path='fourslash.ts' />\r\n\r\n////function \\u0042 () { /*0*/ }\r\n////export default function \\u0043 () { /*1*/ }\r\n... | typescript | new_file | 0 | 0 | apache-2.0 | d0d1ee918ff4e5ba72c6b350741f57fa723fdbea | chocolatechipui/TypeScript,RReverser/TypeScript,kpreisser/TypeScript,nojvek/TypeScript,kpreisser/TypeScript,TukekeSoft/TypeScript,shanexu/TypeScript,HereSinceres/TypeScript,jdavidberger/TypeScript,pcan/TypeScript,DLehenbauer/TypeScript,moander/TypeScript,zhengbli/TypeScript,Eyas/TypeScript,enginekit/TypeScript,nojvek/T... | tests/cases/fourslash/completionListForUnicodeEscapeName.ts | accepted | null | true |
[
{
"role": "user",
"content": "Write typescript code for the following: Add failing level-2 heading node test"
},
{
"role": "assistant",
"content": "/// <reference path=\"../../../typings/mocha/mocha.d.ts\" />\n/// <reference path=\"../../../typings/chai/chai.d.ts\" />\n\nimport { expect } from '... | typescript | new_file | 0 | 1 | mit | 2060918c050b7c5af83cac14e02c254f2cbab61a | start/up,start/up | src/Test/Ast/HeadingLevels2AndUp.ts | accepted | null | true |
[
{
"role": "user",
"content": "Write typescript code for the following: Create root saga and reducer"
},
{
"role": "assistant",
"content": "import { combineReducers } from \"redux\";\nimport { all } from \"redux-saga/effects\";\n\nimport * as signIn from \"./sign-in\";\n\nexport const reducer = c... | typescript | new_file | 0 | 1 | mit | 11553eba932b2718208d591b033977f0ed546d7e | raviqqe/code2d,raviqqe/code2d,raviqqe/code2d,raviqqe/code2d | app/src/redux/index.ts | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```typescript\nexport class TestCase {\n expect(returnValue): this\n describe(message: string): this\n should(message: string): this\n assert(message: string, assertFunction: (actualReturnValue: any) => void): this\n}\n\nexport function test(testF... | typescript | edit | 0 | 1 | mit | f11504922f238b9a52aff7f1a079482e7966b7c1 | mikec/sazerac | types/main.d.ts | accepted | null | true |
[
{
"role": "user",
"content": "Write typescript code for the following: Add base FS respository class"
},
{
"role": "assistant",
"content": "import { Component } from '@nestjs/common'\nimport * as fs from 'fs'\nimport { User } from './entity'\nimport * as path from 'path'\n\n@Component()\nexport ... | typescript | new_file | 0 | 2 | apache-2.0 | 5c83025a6fbc185e4228e9a6d16b3155b7609f28 | m1cr0man/m1cr0blog,m1cr0man/m1cr0blog,m1cr0man/m1cr0blog | src/modules/users/repository.ts | accepted | null | true |
[
{
"role": "user",
"content": "Write typescript code for the following: Add (failing) test for cyclic object persistence"
},
{
"role": "assistant",
"content": "/**\n * Created by rossng on 02/04/2018.\n */\nimport { Store } from 'vuex'\nimport Vuex = require('vuex')\nimport Vue = require('vue')\n... | typescript | new_file | 0 | 1 | mit | 9de26873e9dc59035b3e10c1105af533573812cc | championswimmer/vuex-persist,championswimmer/vuex-persist | test/vuex-mockstorage-cyclic.spec.ts | accepted | null | true |
[
{
"role": "user",
"content": "Write typescript code for the following: Add regression test for de-dup'ing."
},
{
"role": "assistant",
"content": "/// <reference path='fourslash.ts' />\r\n\r\n// @typeRoots: T1,T2\r\n\r\n// @Filename: app.ts\r\n////import * as A from \"[|/*1*/|]\";\r\n\r\n// @File... | typescript | new_file | 0 | 0 | apache-2.0 | 211be0ae69f217db437ca13185ad76586aab5054 | basarat/TypeScript,nojvek/TypeScript,basarat/TypeScript,SaschaNaz/TypeScript,Microsoft/TypeScript,alexeagle/TypeScript,alexeagle/TypeScript,RyanCavanaugh/TypeScript,kpreisser/TypeScript,nojvek/TypeScript,kitsonk/TypeScript,microsoft/TypeScript,kpreisser/TypeScript,SaschaNaz/TypeScript,Microsoft/TypeScript,kitsonk/TypeS... | tests/cases/fourslash/completionListInImportClause06.ts | accepted | null | true |
[
{
"role": "user",
"content": "Write typescript code for the following: feat(Index): Add main program entry point and initialize components"
},
{
"role": "assistant",
"content": "import * as readline from \"readline\";\nimport {CommandParser, BattlelineEvent, Position, Card} from \"./command_pars... | typescript | new_file | 0 | 1 | mit | ae8754822e75c07b6b51dc6024b2594045632ddb | grantpatten/battleline-ai,grantpatten/battleline-ai | src/index.ts | accepted | null | true |
[
{
"role": "user",
"content": "Write typescript code for the following: Add custom promisified Node library functions"
},
{
"role": "assistant",
"content": "\n /*#######.\n ########\",#:\n #########',##\".\n ##'##'## .##',##.\n ## ## ## # ##\",#.\n ## ## ## ## ##'\n ## ## ## ... | typescript | new_file | 0 | 2 | mit | 845895559059dc4f34ad1329942803187e18902c | kube/vscode-clang-complete,kube/vscode-clang-complete | server/src/utils.ts | accepted | null | true |
[
{
"role": "user",
"content": "Write typescript code for the following: Add unit tests for property logger"
},
{
"role": "assistant",
"content": "import { LoggerProperty } from './../../src/';\n\ndescribe('LoggerMethod decorator', () => {\n\n beforeEach(() => {\n spyOn(console, 'log');\... | typescript | new_file | 0 | 1 | mit | 6cc70e918bc4c1619b86816c840e0b62727a2416 | semagarcia/typescript-decorators,semagarcia/typescript-decorators | test/property-decorators/logger.spec.ts | accepted | null | true |
[
{
"role": "user",
"content": "Write typescript code for the following: Add minimal test for initTypes"
},
{
"role": "assistant",
"content": "import {ProjectConfigurationUtils} from '../../../../app/core/configuration/project-configuration-utils';\nimport {ConfigurationDefinition} from '../../../... | typescript | new_file | 0 | 1 | apache-2.0 | 37bef945e199661c157abcfd44c13ece389524ef | codarchlab/idai-field-client,codarchlab/idai-field-client,codarchlab/idai-field-client,codarchlab/idai-field-client | test/unit/core/configuration/project-configuration-utils.spec.ts | accepted | null | true |
[
{
"role": "user",
"content": "Write typescript code for the following: Add mail function as seperate mailing service provider"
},
{
"role": "assistant",
"content": "///<reference path=\"../../../typings/globals/nodemailer/index.d.ts\"/>\n\nimport { Router, Response, Request, NextFunction } from ... | typescript | new_file | 0 | 1 | mit | b30795109f03950205536425095c7fbb7e013fc7 | shavindraSN/examen,shavindraSN/examen,shavindraSN/examen | server/libs/api/mail-functions.ts | accepted | null | true |
[
{
"role": "user",
"content": "Write typescript code for the following: Create card spaces for merchants"
},
{
"role": "assistant",
"content": "import { MigrationBuilder, ColumnDefinitions } from 'node-pg-migrate';\nimport shortUuid from 'short-uuid';\n\nexport const shorthands: ColumnDefinitions... | typescript | new_file | 0 | 1 | mit | 3f05fcf6868a9ad08c6bf927cbf2fd5cba1dadc4 | cardstack/cardstack,cardstack/cardstack,cardstack/cardstack,cardstack/cardstack,cardstack/cardstack,cardstack/cardstack | packages/hub/db/migrations/20220301101637933_create-card-space-profiles-for-existing-merchants.ts | accepted | null | true |
[
{
"role": "user",
"content": "Write typescript code for the following: Add test for horizontal layout"
},
{
"role": "assistant",
"content": "/*\n The MIT License\n \n Copyright (c) 2018 EclipseSource Munich\n https://github.com/eclipsesource/jsonforms\n \n Permission is hereby granted, fre... | typescript | new_file | 0 | 1 | mit | 020a8b00e9cbe207497112e700411cd421a0c3b7 | qb-project/jsonforms,qb-project/jsonforms,qb-project/jsonforms | packages/ionic/test/horizontal-layout.spec.ts | accepted | null | true |
[
{
"role": "user",
"content": "Write typescript code for the following: Add e2e step to test the list of datasets arranged by date"
},
{
"role": "assistant",
"content": "import { $$, steps } from '../support/world';\n\nsteps(({Then}) => {\n Then(/^the datasets should be sorted by date in descend... | typescript | new_file | 0 | 1 | bsd-3-clause | 21d4ebf547894cad8aba149cf0eb699060926be4 | cumulous/web,cumulous/web,cumulous/web,cumulous/web | e2e/steps/datasets-list.ts | accepted | null | true |
[
{
"role": "user",
"content": "Write typescript code for the following: Add a new empty settings screen that will contain settings like how far away from the users location that parking lots should be shown in the app."
},
{
"role": "assistant",
"content": "/**\n * Created by archheretic on 19.04... | typescript | new_file | null | null | mit | 61dac30a2bc1d5d6109b6775853075bd6da6dfb4 | Archheretic/ParkingLotTrackerMobileApp,Archheretic/ParkingLotTrackerMobileApp,Archheretic/ParkingLotTrackerMobileApp,Archheretic/ParkingLotTrackerMobileApp | src/views/settingsScreen.tsx | rejected_syntax | Syntax error detected by tree-sitter | false |
[
{
"role": "user",
"content": "Write typescript code for the following: Write tests for packet reader"
},
{
"role": "assistant",
"content": "import PacketReader from 'dimensions/packets/packetreader';\n\ndescribe(\"packetreader\", () => {\n let reader: PacketReader;\n \n beforeEach(() =>... | typescript | new_file | 0 | 1 | mit | 3eefb1834c363a730287b599ca46c935a3e3cc3a | popstarfreas/Dimensions,popstarfreas/Dimensions,popstarfreas/Dimensions | spec/dimensions/packets/packetreaderspec.ts | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```typescript\nimport {\n createStyles,\n Theme,\n withStyles,\n WithStyles\n} from \"@material-ui/core/styles\";\nimport Typography from \"@material-ui/core/Typography\";\nimport * as classNames from \"classnames\";\nimport * as React from \"reac... | typescript | edit | null | null | bsd-3-clause | 5ff5d9588784bd790f67fc25cf5fce7d8a35ed1b | mociepka/saleor,mociepka/saleor,UITools/saleor,UITools/saleor,mociepka/saleor,UITools/saleor,UITools/saleor,maferelo/saleor,maferelo/saleor,UITools/saleor,maferelo/saleor | saleor/static/dashboard-next/components/Tab/Tab.tsx | rejected_syntax | Syntax error detected by tree-sitter | false |
[
{
"role": "user",
"content": "Write typescript code for the following: Add JSON Format for Locations example"
},
{
"role": "assistant",
"content": "import 'reflect-metadata';\nimport { UtilService } from '../src/app/shared/util.service';\nimport xmljs = require('xml-js')\n\nconst a = [\n {\n ... | typescript | new_file | 0 | 0 | mit | dd75d76d8cad8718337697b711caad8e5cc42890 | luchillo17/Electron-Webpack,luchillo17/Electron-Webpack,luchillo17/Electron-Webpack | TestFiles/FormatTestLocations.ts | accepted | null | true |
[
{
"role": "user",
"content": "Write typescript code for the following: Test that signature help doesn't show 'this'"
},
{
"role": "assistant",
"content": "/// <reference path='fourslash.ts' />\r\n////class Foo<T> {\r\n//// public implicitAny(n: number) {\r\n//// }\r\n//// public explici... | typescript | new_file | 0 | 0 | apache-2.0 | 0060b4d66332adb2fc5eb99b84f3e2095d176d58 | ziacik/TypeScript,Eyas/TypeScript,Microsoft/TypeScript,jwbay/TypeScript,plantain-00/TypeScript,kpreisser/TypeScript,kpreisser/TypeScript,jeremyepling/TypeScript,weswigham/TypeScript,mihailik/TypeScript,donaldpipowitch/TypeScript,Microsoft/TypeScript,ziacik/TypeScript,DLehenbauer/TypeScript,erikmcc/TypeScript,vilic/Type... | tests/cases/fourslash/signatureHelpThis.ts | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```typescript\nimport _ from 'lodash'\n\ninterface Result {\n lastValues: number[]\n series: string[]\n}\n\ninterface Series {\n name: string\n values: number[] | null\n columns: string[] | null\n}\n\ninterface TimeSeriesResult {\n series: Serie... | typescript | edit | 0 | 1 | mit | f73392c13b22f6465467058feb1ac8d4df708c23 | li-ang/influxdb,mark-rushakoff/influxdb,li-ang/influxdb,influxdb/influxdb,influxdb/influxdb,nooproblem/influxdb,influxdata/influxdb,nooproblem/influxdb,mark-rushakoff/influxdb,influxdb/influxdb,mark-rushakoff/influxdb,mark-rushakoff/influxdb,influxdb/influxdb,influxdb/influxdb,influxdata/influxdb,influxdb/influxdb,noop... | ui/src/shared/parsing/lastValues.ts | accepted | null | true |
[
{
"role": "user",
"content": "Write typescript code for the following: Create Cherry Pick Confirmation Dialog"
},
{
"role": "assistant",
"content": "import * as React from 'react'\n\nimport { Dialog, DialogContent, DialogFooter } from '../dialog'\nimport { Ref } from '../lib/ref'\nimport { OkCan... | typescript | new_file | null | null | mit | 106ce79244e18f24a353f7715d9e03fdf8198f9e | desktop/desktop,desktop/desktop,artivilla/desktop,artivilla/desktop,say25/desktop,desktop/desktop,j-f1/forked-desktop,say25/desktop,j-f1/forked-desktop,j-f1/forked-desktop,j-f1/forked-desktop,desktop/desktop,shiftkey/desktop,shiftkey/desktop,shiftkey/desktop,say25/desktop,artivilla/desktop,say25/desktop,artivilla/deskt... | app/src/ui/cherry-pick/confirm-cherry-pick-abort-dialog.tsx | rejected_syntax | Syntax error detected by tree-sitter | false |
[
{
"role": "user",
"content": "Write typescript code for the following: Add tests for client-id / app name parsing\n\nSummary: Add tests for client-id / app name parsing. We've had a lot of bugs here in the past. Get some good test coverage so we have some assurance the shared utils for it won't be broken.\n... | typescript | new_file | 0 | 1 | mit | 006003ae6b17b23e93fd89014a1a5b7bbb467d55 | facebook/flipper,facebook/flipper,facebook/flipper,facebook/flipper,facebook/flipper,facebook/flipper,facebook/flipper,facebook/flipper,facebook/flipper,facebook/flipper,facebook/flipper | src/utils/__tests__/clientUtils.node.tsx | accepted | null | true |
[
{
"role": "user",
"content": "Write typescript code for the following: Add test file hover file item"
},
{
"role": "assistant",
"content": "import {\n FileItem,\n IFileItemProps\n} from '../../src/components/FileItem';\nimport * as React from 'react';\nimport 'jest';\nimport { shallow } from \... | typescript | new_file | null | null | bsd-3-clause | 656ea7cf9d2db58c7e69c2bd82b420bacc39b280 | jupyterlab/jupyterlab-git,jupyterlab/jupyterlab-git,jupyterlab/jupyterlab-git | tests/test-components/FileItem.spec.tsx | rejected_syntax | Syntax error detected by tree-sitter | false |
[
{
"role": "user",
"content": "Write typescript code for the following: Add action creators for watcherFolder actions."
},
{
"role": "assistant",
"content": "import { SELECT_WATCHER_FOLDER } from '../constants/index';\n\nexport interface SelectWatcherFolder {\n readonly type: SELECT_WATCHER_FOLD... | typescript | new_file | 0 | 1 | mit | 45fd54a60ec72813a876cc21dcd63913956bb891 | Anveio/mturk-engine,Anveio/mturk-engine,Anveio/mturk-engine | src/actions/watcherFolders.ts | accepted | null | true |
[
{
"role": "user",
"content": "Write typescript code for the following: Add utility functions for converting data in root state to comply with Polaris filter API."
},
{
"role": "assistant",
"content": "import { StatusFilterType } from 'types';\nimport { Map, Set } from 'immutable';\nimport { Appl... | typescript | new_file | 0 | 1 | mit | 67cc169a9dcca4e6ea301451007573549abc5c59 | Anveio/mturk-engine,Anveio/mturk-engine,Anveio/mturk-engine | src/utils/databaseFilter.ts | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```typescript\nimport _ from 'lodash'\n\nexport function getNested<T = any>(obj: any, path: string, fallack: T): T {\n return _.get<T>(obj, path, fallack)\n}\n\n```\n\nApply this change: Correct spelling of 'fallack' to 'fallback' in getNested"
},
... | typescript | edit | 0 | 0 | mit | 559d42c26a7ff92f53dbf17b78f1d21c7070212b | nooproblem/influxdb,li-ang/influxdb,mark-rushakoff/influxdb,nooproblem/influxdb,influxdata/influxdb,influxdb/influxdb,influxdb/influxdb,influxdb/influxdb,influxdb/influxdb,mark-rushakoff/influxdb,mark-rushakoff/influxdb,nooproblem/influxdb,influxdb/influxdb,li-ang/influxdb,nooproblem/influxdb,mark-rushakoff/influxdb,no... | ui/src/utils/wrappers.ts | accepted | null | true |
[
{
"role": "user",
"content": "Write typescript code for the following: chore: Create hack for RXJS subject\n\nMore here:\nhttps://github.com/ReactiveX/rxjs/issues/2539#issuecomment-312683629"
},
{
"role": "assistant",
"content": "// TODO: Remove this when RxJS releases a stable version with a co... | typescript | new_file | 0 | 0 | mit | b86a9a656cfbfbebff3e1ebff0ace086ebff8355 | GetTerminus/terminus-ui,GetTerminus/terminus-ui,GetTerminus/terminus-ui,GetTerminus/terminus-ui | src/lib/src/utilities/rxjs-lift-hack.ts | accepted | null | true |
[
{
"role": "user",
"content": "Write typescript code for the following: Add 2 passing config tests"
},
{
"role": "assistant",
"content": "import { expect } from 'chai'\nimport { Up } from '../../../index'\nimport { insideDocumentAndParagraph } from '../Helpers'\nimport { PlainTextNode } from '../... | typescript | new_file | 0 | 1 | mit | bf09c732d91232724c19c40c915a8a1ea8bf584e | start/up,start/up | src/Test/Ast/Config/Spoiler.ts | accepted | null | true |
[
{
"role": "user",
"content": "Write typescript code for the following: Add tests on has, set, clear and toggle flags MAILWEB-3468"
},
{
"role": "assistant",
"content": "import { Message } from '@proton/shared/lib/interfaces/mail/Message';\nimport { MESSAGE_FLAGS } from '@proton/shared/lib/mail/c... | typescript | new_file | 0 | 1 | mit | 496f25e564a41406e8dade1f59ef15b2f58e7b17 | ProtonMail/WebClient,ProtonMail/WebClient,ProtonMail/WebClient | packages/shared/test/mail/helpers.spec.ts | accepted | null | true |
[
{
"role": "user",
"content": "Write typescript code for the following: Add passing table of contents HTML test"
},
{
"role": "assistant",
"content": "import { expect } from 'chai'\nimport Up from '../../../index'\nimport { DocumentNode } from '../../../SyntaxNodes/DocumentNode'\nimport { Heading... | typescript | new_file | 0 | 1 | mit | 2f88959ac4e79fa5e053110f19933f8714796fc1 | start/up,start/up | src/Test/Html/Config/Outline.ts | accepted | null | true |
[
{
"role": "user",
"content": "Write typescript code for the following: Rename 'Eswatini' back to 'Swaziland'"
},
{
"role": "assistant",
"content": "import {MigrationInterface, QueryRunner} from \"typeorm\"\n\nexport class RenameEswatiniBackToSwaziland1544803202664 implements MigrationInterface {... | typescript | new_file | 0 | 1 | mit | 4a1c0a9cdd066d0fc536b14c5c1b2d4f6d9c93a8 | OurWorldInData/owid-grapher,OurWorldInData/owid-grapher,owid/owid-grapher,OurWorldInData/our-world-in-data-grapher,OurWorldInData/our-world-in-data-grapher,OurWorldInData/owid-grapher,owid/owid-grapher,OurWorldInData/owid-grapher,OurWorldInData/our-world-in-data-grapher,owid/owid-grapher,OurWorldInData/our-world-in-dat... | src/migration/1544803202664-RenameEswatiniBackToSwaziland.ts | accepted | null | true |
[
{
"role": "user",
"content": "Write typescript code for the following: Add 3 failing spoiler block tests"
},
{
"role": "assistant",
"content": "import { expect } from 'chai'\nimport Up from '../../../index'\nimport { insideDocumentAndParagraph } from '../Helpers'\nimport { DocumentNode } from '.... | typescript | new_file | 0 | 1 | mit | a47c47a3ed4a6a8172d185aaa9e1037361baee1f | start/up,start/up | src/Test/Ast/EdgeCases/SpoilerBlock.ts | accepted | null | true |
[
{
"role": "user",
"content": "Write typescript code for the following: Add another test for for-loop"
},
{
"role": "assistant",
"content": "function foo():void { \n for (var x:number = 1; x < 3; x++) { }\n}\n\nfunction bar():void {\n var x:number;\n for (x = 1; x < 3; x++) { }\n}\n"
}
] | typescript | new_file | 0 | 2 | bsd-3-clause | 327903befe9e06d605ffe9e9b14cd9a586c63b9d | UCSD-PL/RefScript,UCSD-PL/RefScript,UCSD-PL/RefScript | tests/pos/loops/for-06.ts | accepted | null | true |
[
{
"role": "user",
"content": "Write typescript code for the following: Add test for inverted clodule"
},
{
"role": "assistant",
"content": "/// <reference path=\"fourslash.ts\" />\r\n\r\n////module M {\r\n//// module A {\r\n//// var o;\r\n//// }\r\n//// class A {\r\n//// /... | typescript | new_file | 0 | 0 | apache-2.0 | 1db708814222fc07c31c92dc256ef59a04029967 | hippich/typescript,fdecampredon/jsx-typescript-old-version,popravich/typescript,fdecampredon/jsx-typescript-old-version,mbebenita/shumway.ts,mbebenita/shumway.ts,fdecampredon/jsx-typescript-old-version,mbebenita/shumway.ts,hippich/typescript,hippich/typescript,popravich/typescript,popravich/typescript | tests/cases/fourslash/invertedCloduleAfterQuickInfo.ts | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```typescript\nbeforeEach(() => {\n jasmine.addMatchers({\n toContainText: function() {\n return {\n compare: function(actual, expectedText) {\n let actualText = actual.textContent;\n ... | typescript | edit | 0 | 1 | mit | 116d75f939011dc7476b56dcfd5015e8ccdda8c1 | westlab/door-front,antonybudianto/angular2-starter,foxjazz/eveview,foxjazz/memberbase,westlab/door-front,dabcat/myapp-angular2,jasoncbuehler/mohits_awesome_chat_app,jasoncbuehler/mohits_awesome_chat_app,Michael-xxxx/angular2-starter,foxjazz/eveview,westlab/door-front,NiallBrickell/angular2-starter,Michael-xxxx/angular2... | test-helpers/matchers.ts | accepted | null | true |
[
{
"role": "user",
"content": "Write typescript code for the following: Add tests for reduce store"
},
{
"role": "assistant",
"content": "import { FluxReduceStore } from '../lib/flux-reduce-store';\nimport { StoreError } from '../lib/flux-store';\n\ndescribe('FluxReduceStore', () => {\n let stor... | typescript | new_file | 0 | 1 | mit | 6d95231c0cc06d62614ef70a9ccdaaa4ee60b942 | delta62/flux-lite,delta62/flux-lite | spec/flux-reduce-store-spec.ts | accepted | null | true |
[
{
"role": "user",
"content": "Write typescript code for the following: Create types for `flutter test`\n\nSee #636."
},
{
"role": "assistant",
"content": "interface Notification {\n\ttype: string;\n\ttime: number;\n}\n\ninterface StartNotification extends Notification {\n\tprotocolVersion: strin... | typescript | new_file | 0 | 0 | mit | 242f0959da49cd5d7a365910cb95cabea9a472ac | Dart-Code/Dart-Code,Dart-Code/Dart-Code,Dart-Code/Dart-Code,Dart-Code/Dart-Code,Dart-Code/Dart-Code | src/debug/flutter_test.ts | accepted | null | true |
[
{
"role": "user",
"content": "Write typescript code for the following: Add unit test for platform clipboard implementation"
},
{
"role": "assistant",
"content": "import clipboard = require('./clipboard');\nimport testLib = require('../lib/test');\n\nvar clip = clipboard.createPlatformClipboard()... | typescript | new_file | 0 | 1 | bsd-3-clause | 29bacf4901012d9a5538963894325f5537592cf2 | robertknight/passcards,robertknight/passcards,robertknight/passcards,robertknight/passcards | cli/clipboard_test.ts | accepted | null | true |
[
{
"role": "user",
"content": "Write typescript code for the following: Add a function for updating the working directory from the index"
},
{
"role": "assistant",
"content": "import { git } from './core'\nimport { Repository } from '../../models/repository'\n\nexport async function checkoutIndex... | typescript | new_file | 0 | 2 | mit | a9c4e58b08f6534d16b81205d7f54fa0ec3d9fb3 | artivilla/desktop,kactus-io/kactus,desktop/desktop,hjobrien/desktop,hjobrien/desktop,j-f1/forked-desktop,j-f1/forked-desktop,gengjiawen/desktop,say25/desktop,artivilla/desktop,kactus-io/kactus,desktop/desktop,gengjiawen/desktop,say25/desktop,say25/desktop,j-f1/forked-desktop,artivilla/desktop,kactus-io/kactus,shiftkey/... | app/src/lib/git/checkout-index.ts | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```typescript\nconst prom1 = new Promise<number>((resolve, reject) => {\n\tresolve(12);\n});\n\nconst prom2 = new Promise<string>((resolve, reject) => {\n\treject('an error');\n}).then((val) => {\n console.log(val);\n return val;\n}).catch((err) => ... | typescript | edit | 0 | 1 | mit | ad6df613ec4de34581f875808842927f65d7f0b4 | borisyankov/DefinitelyTyped,magny/DefinitelyTyped,georgemarshall/DefinitelyTyped,georgemarshall/DefinitelyTyped,markogresak/DefinitelyTyped,georgemarshall/DefinitelyTyped,magny/DefinitelyTyped,georgemarshall/DefinitelyTyped,borisyankov/DefinitelyTyped,dsebastien/DefinitelyTyped,mcliment/DefinitelyTyped,dsebastien/Defin... | types/promise-polyfill/promise-polyfill-tests.ts | accepted | null | true |
[
{
"role": "user",
"content": "Write typescript code for the following: feat(containermodal): Create an module for container modal."
},
{
"role": "assistant",
"content": "/*\n MIT License\n\n Copyright (c) 2017 Temainfo Sistemas\n\n Permission is hereby granted, free of charge, to any person obta... | typescript | new_file | 0 | 0 | mit | f27a6ec5d64893c1c767aa8dcddeeeabf095f80c | TemainfoSistemas/truly-ui,TemainfoSistemas/truly-ui,TemainfoSistemas/truly-ui | src/modal/container-modal/index.ts | rejected_duplicate | Near-duplicate of sample 116016 | true |
[
{
"role": "user",
"content": "Write typescript code for the following: Add 2 passing chart tests"
},
{
"role": "assistant",
"content": "import { expect } from 'chai'\nimport Up from '../../../index'\nimport { DocumentNode } from '../../../SyntaxNodes/DocumentNode'\nimport { TableNode } from '../... | typescript | new_file | 0 | 1 | mit | 39a03a39dab15f8c6e954da87f38a38685aa6a9c | start/up,start/up | src/Test/Ast/Config/Chart.ts | accepted | null | true |
[
{
"role": "user",
"content": "Write typescript code for the following: Create a constants folder for each type of editor"
},
{
"role": "assistant",
"content": "export const ANDROIDSTUDIO = \"ANDROIDSTUDIO\";\nexport const ATOM = \"ATOM\";\nexport const CHROME = \"CHROME\";\nexport const ECLIPSE ... | typescript | new_file | 0 | 0 | bsd-3-clause | 892ed5f3af7e111a958411f47945a80d3025512a | wakatime/desktop,wakatime/desktop,wakatime/wakatime-desktop,wakatime/desktop,wakatime/wakatime-desktop | src/constants/editors.ts | accepted | null | true |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.