WhereIsAI/github-issue-similarity huggingface dataset:
Issue 1:
trait TA { fn ta(&self) { println!("Default TA"); } }
trait TB: TA { fn tb(&self) { println!("Default TB"); } }

trait AutoTA: TB {}
impl<T:AutoTA> TA for T { fn ta(&self) { println!("AutoTA"); } }

struct A;
impl TB for A {}

The above code misses impl TA for A, but the compiler reports

error: the trait AutoTAis not implemented for the typeA [E0277]

Even worse, when a new piece of code is added:

trait AutoAutoTA: TB {}
impl<T: AutoAutoTA> AutoTA for T {}

the comiler reports:

error: the trait AutoAutoTAis not implemented for the typeA [E0277]

These error messages aren't accurate. example, the last implies that the only way to fix it is to impl the AutoAutoTA.

I hope the compiler just report the direct reason. it should report:

error: the trait TAis not implemented for the typeA [E0277]

Issue 2:
This is a more general version of #22478. (i.e. probably should be considered to supersede it)

trait A {
fn a(self);
}

trait B {
fn b(self);
}

impl<T: B> A for T {
fn a(self) {
B::b(self)
}
}

struct C;

fn main() {
A::a(C);
}

Compiling this will result in

t.rs:18:5: 18:9 error: the trait `B` is not implemented for the type `C` [E0277]
t.rs:18 A::a(C);
^~~~
error: aborting due to previous error

but impl<T: B> A for T, T = C and C does not implement B and therefore the impl in question should not even be taken into consideration, even if it is the only implementation of a trait.
Issue 1:
I am using Internet Explorer with zoom setting at 100%. Any help would be greatly appreciated.

Issue 2:
Challenge Change the Font Size of an Element has an issue.

User Agent is: Mozilla/5.0 (Windows NT 6.1; Trident/7.0; SLCC2; .NET CLR 2.0.50727; .NET CLR 3.5.30729; .NET CLR 3.0.30729; Media Center PC 6.0; .NET4.0C; .NET4.0E; rv:11.0) like Gecko.

Please describe how to reproduce this issue, and include links to screenshots if possible.

My code:

<style>
.red-text {
color: red;

}
p {

font-size: 16px;

}
</style>

<h2 class="red-text">CatPhotoApp</h2>

<p class="red-text">Kitty ipsum dolor sit amet, shed everywhere shed everywhere stretching attack your ankles chase the red dot, hairball run catnip eat the grass sniff.</p>
<p>Purr jump eat the grass rip the couch scratched sunbathe, shed everywhere rip the couch sleep in the sink fluffy fur catnip scratched.</p>
Issue 1:
The code snippets in https://flutter.io/cookbook/ currently have 754 analyzer errors [1]. We should clean up those errors and then enforce that the code stays clean by including the cookbook in our travis check [2].

This will also ensure that the code in the cookbook doesn't go stale with new Flutter/Dart releases.

[1] https://travis-ci.org/flutter/website/builds/361245834#L1064

[2] https://github.com/flutter/website/blob/master/tool/extract.dart#L16

/cc @filiph, @mjohnsullivan, @devoncarew

Issue 2:
Currently, we have a (small, simple) analysis options file used when analyzing the website code snippets. We should do some work to unify that with the analysis options files used when analyzing flutter code. This could be introducing an inheritance mechanism to analysis options files (a fairly invasive change), duplicate the lint list, or have some code that autogenerates the website options file one on the fly (this last option seems pretty good).

See flutter/website#666 for context.
Issue 1:
To reproduce the issue: here http://jsfiddle.net/Q9K8L/ click on an option twice before clicking on a submit button. Radio button option is not sent with a submit.

I suspect data-toggle="buttons" data attribute causes this issue.

Tested on Chrome Version 31.0.1650.57 m and FireFox 24.0

Issue 2:
The active class stays on the button, but the checked property is removed from the radio input.

http://jsfiddle.net/meleyal/dafPH/
Issue 1:
test case:

function test(a) {
return a * 2;
}

var cb = async (...args) => await test(...args);

cb(123)
.then((result) => console.log(result))
.catch((e) => console.error(e));

expected result: 246

actual result: NaN

for example, http://babeljs.io/docs/advanced/transformers/other/bluebird-coroutines/ in this case do work as expected

Issue 2:
Hi,

It seems there is a bug when combining async + rest parameters syntax.

Here is a simplified version that reproduces the case with a simple async of value.

const foo = async (...msgs) => {
let t = await msgs[0];
console.log(t);
}

foo('a'); // displays "{}" instead of "a" value

Just by adding console.log(msgs), it makes it work.

const foo = async (...msgs) => {
console.log(msgs);
let t = await msgs[0];
console.log(t);
}

foo('a'); // displays "a"

Basically, adding console.log(msgs) moves the args to a distinct array:

for (var _len = arguments.length, msgs = Array(_len), _key = 0; _key < _len; _key++) {
msgs[_key] = arguments[_key];
}

In the repl:

https://babeljs.io/repl/#?experimental=true&evaluate=true&loose=false&spec=false&code=const%20asyncArg%20%3D%20async%20(msg)%20%3D%3E%20%7B%0D%0A%20%20let%20t%20%3D%20await%20msg%3B%0D%0A%20%20console.log(t)%3B%0D%0A%7D%0D%0A%0D%0Aconst%20asyncArgs%20%3D%20async%20(...msgs)%20%3D%3E%20%7B%0D%0A%20%20let%20t%20%3D%20await%20msgs%5B0%5D%3B%0D%0A%20%20console.log(t)%3B%0D%0A%7D%0D%0A%0D%0AasyncArg('1')%3B%0D%0AasyncArgs('2')%3B%0D%0A
Issue 1:
This is tough for me to reliably reproduce, but I've seen it a half-dozen times and think it needs an issue. Elasticsearch can still lose inserted documents when a single primary node is isolated by a simple network partition. Nothing fancy, no overlapping partitions required. Sometimes it's only a few documents, from immediately following the partition:

{:valid? false,
:lost "#{640 643 645 649}",
:recovered
"#{140..142 144 146 148..152 155 157 159..162 164..168 171 174..175 177 179..185 187 190..192 194 197 199..200 202 205..208 214 224 234 238 240..247 249..254 256..264 266..282 285 296 317 342 363 388 431}",
:ok
"#{0..137 140..142 144 146 148..152 155 157 159..162 164..168 171 174..175 177 179..185 187 190..192 194 197 199..200 202 205..208 210..212 214 224 234 238 240..247 249..254 256..264 266..639 641..642 644 646..648 650..654}",
:recovered-frac 96/655,
:unexpected-frac 0,
:unexpected "#{}",
:lost-frac 4/655,
:ok-frac 598/655}

Other times, the cluster seems to get really confused, and loses over half of the acknowledged records, distributed throughout the history:

{:valid? false,
:lost
"#{53..55 126..129 131..142 144..167 169..189 191..212 214..235 237..260 262..281 283..305 307..327 329..352 354..367 374 376}",
:recovered
"#{46..47 49 52 60 428..430 432..435 437..440 442..445 447..450 452..455 457..473}",
:ok
"#{0..47 49 52 60 428..430 432..435 437..440 442..445 447..450 452..455 457..473}",
:recovered-frac 15/158,
:unexpected-frac 0,
:unexpected "#{}",
:lost-frac 118/237,
:ok-frac 91/474}

The logs aren't particularly informative here, but I have noticed some interesting messages which seem correlated with data loss: for instance:

[2015-04-02][WARN ][index.shard] [n4] [jepsen-index][0] suspect illegal state: trying to move shard from primary mode to replica mode

and

[2015-04-02 17:19:54,370][DEBUG][action.index ] [n2] observer: timeout notification from cluster service. timeout setting [1m], time since start [1m]

which I think is a hardcoded message.

Again, these are tough to reproduce--only 1 in 10 runs or so--so I'll keep working on finding a failure schedule that reliably triggers the fault.

Issue 2:
This ticket is meant to capture an issue which was discovered as part of the work done in #7493 , which contains a failing reproduction test with @awaitFix.

If a network partition separates a node from the master, there is some window of time before the node detects it. The length of the window is dependent on the type of the partition. This window is extremely small if a socket is broken. More adversarial partitions, for example, silently dropping requests without breaking the socket can take longer (up to 3x30s using current defaults).

If the node hosts a primary shard at the moment of partition, and ends up being isolated from the cluster (which could have resulted in Split Brain before), some documents that are being indexed into the primary may be lost if they fail to reach one of the allocated replicas (due to the partition) and that replica is later promoted to primary by the master.
Issue 1:
I'm submitting a ... (check one with "x")

[x] bug report => search github for a similar issue or PR before submitting
[ ] feature request
[ ] support request => Please do not submit support request here, instead see https://github.com/angular/angular/blob/master/CONTRIBUTING.md#question

Current behavior

[routerLink] with async/observable property assignment does not re-evaluate [routerLinkActive] when the observable emits a new value.

Expected behavior

When the value emitted to [routerLink] changes, [routerLinkActive] should re-evaluate against the newly emitted value whether or not the link is "active."

Minimal reproduction of the problem with instructions

<a class="waves-effect" [routerLink]="observable$ | async" [routerLinkActive]="['active']" [routerLinkActiveOptions]="{ exact: true }">LINK

the application of the "active" class will not be re-evaluated when a new value is emitted by observable$.

e.g.

obervable$ = Observable.interval(1000).map(i => ['/page/' + i])

If you are on /page/0 link will be active on first emission, but will not go inactive once i > 1.

What is the motivation / use case for changing the behavior?

Using observables with routerLink should work.

Please tell us about your environment:

Chrome 55m, Windows 10

Angular version: 2.0.X

2.4.1

Browser: [all | Chrome XX | Firefox XX | IE XX | Safari XX | Mobile Chrome XX | Android X.X Web Browser | iOS XX Safari | iOS XX UIWebView | iOS XX WKWebView ]

Language: [all | TypeScript X.X | ES6/7 | ES5]

TypeScript 2.1.4.0

Node (for AoT issues): node --version =

Issue 2:
[ x] bug report => search github for a similar issue or PR before submitting

[ ] feature request

[ ] support request => Please do not submit support request here, instead see

Current behavior

Look at this Plunker.

When you choose one of four heroes HeroComponent is loaded. Inside its templete there is another <router-outlet> where you can navigate beetween HeroDetailComponent and HeroNameComponent components. HeroDetailComponent is loaded by default as it has path: '' in routing configuration but link 'Details" isn't mark as active.

When we navigate to 'Name' and then back to details by clicking 'Details' link - active class starts to be added.

Also when we are in HeroNameComponent and then we choose again active hero from list (only curently active hero) then details button is shown as acivated correctly .

Its seems to doesn't work especially when component is reused, without creating new instance.

Expected behavior

When clicking one of heroses, details button should be marked as active.

Angular version: 2.2.3, also ~2.1.0

Browser: [all ]

Language: [TypeScript]
Issue 1:
I have searched the issues of this repository and believe that this is not a duplicate.

I have checked the FAQ of this repository and believe that this is not a duplicate.

Environment

Dubbo version: xxx

Operating System version: xxx

Java version: xxx

Steps to reproduce this issue

xxx

xxx

xxx

Pls. provide [GitHub address] to reproduce this issue.

Expected Result

What do you expected from the above steps？

Actual Result

What actually happens?

If there is an exception, please attach the exception trace:

Just put your stack trace here!

Issue 2:
I have searched the issues of this repository and believe that this is not a duplicate.

I have checked the FAQ of this repository and believe that this is not a duplicate.

Environment

Dubbo version: 2.7.3

Operating System version: all

Java version: 1.8

Steps to reproduce this issue

为什么消费端发送请求，服务端响应请求，序列化操作都是在I/O线程上？当消费端连接数很小时，压力不是很大吗？序列化操作放在业务线程上是不是更好呢

Pls. provide [GitHub address] to reproduce this issue.

Expected Result

What do you expected from the above steps？

Actual Result

What actually happens?

If there is an exception, please attach the exception trace:

Just put your stack trace here!
Issue 1:
Description

I have problems in cloning a kernel after the parameters of the kernel are set using set_params

I assume that this is way the kernel code has been written (logic other than the initialization in the constructor)

Steps/Code to Reproduce

from sklearn.base import clone
from sklearn.gaussian_process.kernels import RBF

rbf = RBF(length_scale=[2.0, 3.0])
params = rbf.get_params()
print(params)
# {'length_scale_bounds': (1e-05, 100000.0), 'length_scale': array([ 2., 3.])}
clone(rbf) # Does not break

rbf_also = RBF(length_scale=[2.0])
print(rbf_also.get_params())
{'length_scale': 2.0, 'length_scale_bounds': (1e-05, 100000.0)}
clone(rbf_also) # Does not break

rbf = RBF(length_scale=[2.0, 3.0])
params['length_scale'] = [2.0]
rbf.set_params(**params)
clone(rbf)

Expected Results

I would expect it to clone without breaking.

Issue 2:
Clusters can be found within a training dataset (transductive) then used to train a classifier, so as to extend the clustering model to new instances. See snippet at #4543 (comment)

@selwyth is apparently working on this.
Issue 1:
Hey!

While trying to fix egeloen/IvoryCKEditorBundle#212 I have added a form_javascript Twig functions which allows to render form javascript related code where you want in the template.

Doing so, allow to link javascript code to a specific form type, allow to render your javascript where you want in the page (often at the bottom of the page), allow to take benefit of the form theming inheritance (for example: form -> text -> textarea) and also define a standard way of linking javascript code to a form.

I have decided to open the issue because my implementation is not new, it has been inspired by GenemuFormBundle and DatetimepickerBundle which both rely on the exact same concept and the exact same code is duplicated along different bundles...

Now my question is does it belong to the core or to a third party library? WDYT?

Issue 2:
I have a page that looks like:

_______________
Action block
Ignore / Reject / ....
_______________

all data
table > tr > td * N

_______________
Action block
Ignore / Reject / ....
_______________

As you can see, I have the same "action block" on my page.

All buttons are symfony form. and Right now I'm not able to display the same form twice.

I can use "hacky" code like that:

{# this is a hack, this block in not in the main stream #}
{% block actions %}
<div class="panel panel-default">
<div class="panel-heading">Actions</div>
<div class="panel-body">
{{ form(form_actions)}}
</div>
</div>
{% endblock %}

{% set actions = block('actions') %}

{% block body %}
{{ actions|raw }}
table
{{ actions|raw }}
{% endblock %}

But I don't like it.

May be I should not use SF form to handle that, But I need CSRF protection. And now, the way to handle CSRF check in a controller, is not so easy.

(PS: I see this issue was rejected in the past, but I have a different use case here).
Issue 1:
One of the common idioms in JavaScript is using a getter function that takes string of a property name of an object and returns the value of the property. For example:

var obj = {a: 1, b: '2'};
var model = new Backbone.Model(obj);
var a = mode.get('a'); // a is number

Right now, the get function can only be defined as returning any, because we can't annotate it with anything better. It would be nice to be to define the return type based on the properties of an interface for example:

declare interface Model {
a: number;
b: string;
}
declare function get<T as Model[keyArg]>(keyArg: string): T; // syntax is for conveying idea only

get('a'); // number
get('b'); // string
get('c'); // any

declare function get2<T, T2 as T[keyArg]>(keyArg: string): T2; // generic version

get2<Window>('setTimeout'); // function
get2<Window>('nonsense'); // any

declare function get3<T as Model[keyArg]>(keyArg: any): T; // compile error, only support string and maybe number.

declare function set<T as Model[keyArg]>(keyArg: string, value: T): void; // set syntax for the same thing

This would allow better definitions a lot of functions in common libraries like Lodash/Underscore, Immutable.js, Backbone.

Currently TypeScript supports specialized overload signature. For example

declare function get(key: string): any;
declare function get(key: 'key'): string;

The suggestion above can already be partially implemented at application level by using specialized overload signature with code generator. The suggestion would allow this to be implemented more generally (especially for libraries).

Potential implementation may also be used to refine { [key: string]: someType }, but that might be more complex as it requires self referencing.

Issue 2:
How do I use the compiled typescript files with systemjs? Can typescript compile in the System.register format as traceur can?
Issue 1:
Hello,

My apologies if this is a duplicate of an existing issue, but shouldn't input type="search" elements assigned to the form-control class be assigned "-webkit-appearance: none;" so that these search fields look as expected when wrapped in .input-group?

Issue 2:
When downloading the CSS (happens without making any changes in the theme), get the following error:

{“type":"Parse","message":"Syntax Error on line 792","index":25132,"filename":"bootstrap.css","line":792,"column":11,"extract":[" *margin: -5px 0 5px;"," ove rflow: hidden;"," background-color: @top;"]}
Issue 1:
test.rs:

mod test;
fn main(){}

causes

rust: task 7f855ac0c250 ran out of stack
error: internal compiler error: unexpected failure
note: the compiler hit an unexpected failure path. this is a bug
note: try running with RUST_LOG=rustc=1,::rt::backtrace to get further details and report the results to github.com/mozilla/rust/issues
rust: task failed at 'explicit failure', /private/tmp/rust-GCHx/rust-0.6/src/librustc/rustc.rc:357
rust: domain main @0x7f855b009810 root task failed

Issue 2:
While I was playing with the new rustc 0.6, I encountered an internal compiler error

~/project/protobuf-rust(master) > RUST_LOG=rustc=1,::rt::backtrace rustc protobuf.rs --test -o protobuf-tests
rust: task 7fbd705018b0 ran out of stack
error: internal compiler error: unexpected failure
note: the compiler hit an unexpected failure path. this is a bug
note: try running with RUST_LOG=rustc=1,::rt::backtrace to get further details and report the results to github.com/mozilla/rust/issues
rust: task failed at 'explicit failure', /Users/kimhyunkang/usr/pkgs/rust-0.6/src/librustc/rustc.rc:357
rust: domain main @0x7fbd70819410 root task failed

The source code is here: https://gist.github.com/kimhyunkang/5307274

Compiler version is 0.6, built with gcc, on OS X 10.7.5

~/project/protobuf-rust(master) > rustc --version
rustc 0.6
host: x86_64-apple-darwin

~/project/protobuf-rust(master) > gcc --version
i686-apple-darwin11-llvm-gcc-4.2 (GCC) 4.2.1 (Based on Apple Inc. build 5658) (LLVM build 2336.1.00)
Copyright (C) 2007 Free Software Foundation, Inc.
This is free software; see the source for copying conditions. There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
Issue 1:
Hi

This is a suggestion.

bootstrap is one of a wonderful project that I've seen but i think if the customize page has a little features it becomes more wonderful

I don't know what colors in the fields look like in customize page in getbootstrap.com and i have to copy paste that HEX code to see what is the color of them then change it while if you put a little div box beside each field to shows the color it was very useful

Or better than this is put a color picker something like this:

http://twitterbootstrap3navbars.w3masters.nl/

Then we customize the color and see what is output then compile it

I think this page doesn't use more

Thanks

Issue 2:
Using javascript to automatically update a small preview for colour variables on the customiser (perhaps using input groups).

For example:
Issue 1:
Version

2.5.16

Reproduction link

https://codesandbox.io/s/github/weihongyu12/vue-typescript-demo

Steps to reproduce

Uses @vue/cli to build the project. The configuration uses TypeScript. However, in the process of using, in the methods, there is no access to the computed. The construction does not exist on type 'Vue'.

<template>
<ul
v-if="show"
class="picker">
<li
v-for="(item, index) of pickerList"
:key="index">{{ item }}</li>
</ul>
</template>

<script lang="ts">
import Vue from 'vue';

export default Vue.extend({
name : 'Picker',
props: {
columns: {
type: Array,
default: [],
},
show: {
type: Boolean ,
default: false,
},
},
computed: {
pickerList(): Array<string> {
const arr = [];
const columns: any = this.columns;
for (const item of columns) {
arr.push(item.title);
}
return arr;
},
pickerMap() : Map<string, number> {
const map = new Map();
const columns: any = this.columns;
for (const item of columns) {
map.set(item.title, item.id);
}
return map;
},
},
methods: {
onConfirm(value: string): void {
const resumeId = this.pickerMap.get(value); // Property 'pickerMap' does not exist on type 'Vue'.
this.$emit('confirm', resumeId);
},
},
});
</script>

What is expected?

I don't know if it's because of my writing, or because of the configuration that caused me this error. I wrote the code based on the official document. I believe it can be build successfully.

What is actually happening?

When I run npm run build, an error Property 'pickerMap' does not exist on type 'Vue'. The complete prompt is as follows:

ERROR in E:/project/demo/src/components/picker.vue
44:29 Property 'pickerMap' does not exist on type 'Vue'.
42 | methods: {
43 | onConfirm(value: string): void {
> 44 | const resumeId = this.pickerMap.get(value);
| ^
45 | this.$emit('confirm', resumeId);
46 | },
47 | },

I do not know of any reason for this error. It is imperative that I have a friend to help me solve this error, but I hope that the official can speed up the improvement of TypeScript's documentation, because I believe TypeScript will become popular. Thank you.

Issue 2:
Version

2.5.2

Reproduction link

https://github.com/wonderful-panda/vue-sandbox

Steps to reproduce

Compile this code by tsc

import Vue, { VNode } from "vue";

const NgComponent = Vue.extend({
name: "NgComponent",
props: {
foo: { type: String },
bar: {} // any types are accepted
},
render(h): VNode {
return h("div", this.foo);
}
});

or clone from repro link and npm install && npm run build

What is expected?

Successfully compiled.

And this.foo is treated as string, this.bar is treated as any.

What is actually happening?

Failed to compile.

src/index.ts(10,30): error TS2339: Property 'foo' does not exist on type 'CombinedVueInstance<Vue, {}, {}, {}, Readonly<{}>>'.

Workaround:

import Vue, { VNode } from "vue";

Vue.extend({
name: "Workaround",
props: {
foo: { type: String },
bar: {} as (() => any) // any types are accepted
},
render(h): VNode {
return h("div", this.foo);
}
});
Issue 1:
It would be very useful if atom could open files from the browser like atom://open?URL=/Users/me/myfile.txt., like sublime text's subl://open

This would be great for people writing/debugging web apps like me :)

Issue 2:
It should open an html handler like:

The handler opens atom, but doesn't works with params.

atom://open?url=file://Users/myuser/myapp/myfile.rb&line=32&column=12

it would be very useful for rails_panel !