WhereIsAI/github-issue-similarity huggingface dataset:
Issue 1:
This is difficult to explain, so I've written an isolated test case:

let instances = new Map();

class Resource{

static get(id){
let list = instances.get(this) || {};
return list[id];
}

static add(id, instance){
let list = instances.get(this);
if(!list)
instances.set(this, list = {});
list[id] = instance;
}

constructor(id){
let type = this.constructor;
let byId = type.get(id);

// Already created. Return reference to existing instance.
if(byId){
return byId;
}

this.id = id;
type.add(id, this);
}
}

class SubtypeResource extends Resource{

}

let resourceA = new SubtypeResource(200);
let resourceB = new SubtypeResource(200);
console.log(resourceA === resourceB); // "true" if natively supported; "false" if transpiled

Blacklisting es6.classes solves the problem, but that naturally requires an interpreter to support it natively. I'm running the latest version of Node (4.2.1), so it's no big deal. But it'd be different if it were for client-side delivery.

This only happens with subclasses, so it might have something to do with the way the transformer maps references to constructor functions. E.g., the following code runs fine either natively or through Babel:

console.log(new Resource(200) === new Resource(200)); // true

To summarise what my code's doing: I'm writing a Node program to scrape data from a site that lacks a formal API. Resources are loaded once and done so asynchronously, collating patches of data from numerous different sources. I thought an elegant approach would be to return references to existing instances instead of manually checking if they've been created already:

let instance;
if(SubtypeResource.get(id)){
instance = SubtypeResource.get(id);
}
else{
instance = new SubtypeResource(id);
SubtypeResource.add(id, instance);
}

Issue 2:
The current implementation doesn't handle parent classes that return specific objects properly. The value returned from [[Construct]] should be used as the this binding value in the child constructor.

class Other {
method(){
console.log('other');
}
}
class Base {
constructor(){
return new Other();
}
method(){
console.log('base');
}
}
class Sub extends Base {
constructor(){
super();
this.method();
}
}

var s = new Sub();
console.log('expected true, got ' + (s instanceof Other));

Seems like

var Sub = (function (_Base) {
_inherits(Sub, _Base);

function Sub() {
_classCallCheck(this, Sub);

_get(Object.getPrototypeOf(Sub.prototype), 'constructor', this).call(this);
this.method();
}

return Sub;
})(Base);

should be more like

var Sub = (function (_Base) {
_inherits(Sub, _Base);

function Sub() {
_classCallCheck(this, Sub);

var _this = _get(Object.getPrototypeOf(Sub.prototype), 'constructor', this).call(this);
if (_this === undefined) _this = this;
_this.method();
return _this;
}

return Sub;
})(Base);
Issue 1:
There's a link in the Deployments section of the 201 walkthrough to a longer description that's broken. It links to http://kubernetes.io/docs/user-guide/deployment but should link to http://kubernetes.io/docs/user-guide/deployments (missing an s).

Issue 2:
I wish /docs/user-guide/deployment/ existed. It is linked from http://kubernetes.io/docs/user-guide/walkthrough/k8s201/ under the Deployments section
Issue 1:
Apache Airflow version: 2.1.1

Kubernetes version (if you are using kubernetes) (use kubectl version): AWS EKS, AWS ECS

Environment:

Cloud provider or hardware configuration: AWS

OS (e.g. from /etc/os-release): Debian GNU/Linux 10

Kernel (e.g. uname -a):

Install tools:

Others:

What happened:

I have enabled RBAC and using FAB OAUTH to authenticate users using AZURE AD. Users are able to sign-in using Azure SSO. I have referenced my webserver config file from https://github.com/dpgaspar/Flask-AppBuilder/blob/master/examples/oauth/config.py with OAUTH_PROVIDER as Azure.

Now all our users are acquiring role ADMIN and I am not able to edit their role to other available roles as there is no edit option coming in the List USER page. My user to have an ADMIN role.

What you expected to happen:

As ADMIN is having can edit on UserOAuthModelView permission I should be able to edit the roles for different users.

How to reproduce it:

Anything else we need to know:

Issue 2:
Apache Airflow version: 2.1.0

Browsers: Chrome and Firefox

What happened:

Before upgrading to 2.1.0

After upgrading to 2.1.0

What you expected to happen:

Show/Edit/Delete under Security -> Users are available

How to reproduce it:

Go to Security -> Users (as an admin of course)
Issue 1:
Q
A

Bug report?
yes (documentation)

Feature request?
no

BC Break report?
no

RFC?
no

Symfony version
all

Hello,

I'm digging through Symfony's Security components trying to implement a custom security bundle, and I really miss one thing: The Big Picture. There is a lot written about individual components and even source code is quite understandable, but there is nothing about how these components work together.

The workflow diagrams in HttpKernel documentation are extremely helpful. There should be similar diagrams included in Security component documentation. How all these components interact with each other? What happens during ordinary HTTP request? What happens during login? What happens during subsequent HTTP requests? …? …?

The documentation says there are some components (Guards missing, btw) and that's it. No relation between them is provided. No context. Nothing about basic principles nor ideas.

Security is important and must be well understood to make it right. A cookbook without context is not enough — it helps when one understands, but does not make him understand. Symfony Security component is powerful and complex, so it is hard to get into it.

Someone who has deep understanding of the Security component, please, draw few diagrams how it works. It will help many other developers.

Issue 2:
If write following config:

<service id="service" alias="service_alias"/>
<service id="sevice_alias" alias="service"/>

Infinite loop will occur in the ResolveReferencesToAliasesPass class. Think such circular references should be catched and an exception should occur instead of falling into infinite loop.
Issue 1:
TypeScript version: 1.7.5

For example:

hoge.ts

export default class Hoge {}

fuga.ts

import Hoge from "./hoge"
new Hoge();

tsc hoge.ts fuga.ts -t es6 -m commonjs

compile result:

hoge.js

class Hoge {
}
exports.Hoge = Hoge;

fuga.js

var hoge_1 = require("./hoge");
new hoge_1.default();

Compiled code doesn't work because require("./hoge") returns { Hoge: Hoge } and hoge_1.default is undefined.

Issue 2:
export default class {

}

compiled code is:

class {
}
exports. = default_1;

compile command is tsc --module commonjs --target ES6 default.ts, TypeScript version is 1.7.5
Issue 1:
Challenge Name

http://beta.freecodecamp.com/en/challenges/css-flexbox/using-the-flexdirection-property-to-make-a-row

Issue Description

I guess since the default value for flex-direction is row, this test can pass without doing anything at all. Maybe a reg-ex is in order to make sure the user enters code?

Issue 2:
CHALLENGE:

http://beta.freecodecamp.com/en/challenges/css-flexbox/using-the-flexdirection-property-to-make-a-row

ISSUE:

Clicking 'Run tests' button passes the tests without the test conditions being met. I did not add the CSS property flex-direction to the #box-container element, and give it a value of row.

BROWSER INFO:

Chrome 55.0.2883.87 m

Windows 7

Desktop

SCREENSHOT:
Issue 1:
Splitting off from: #8876

Issue 2:
Just helped track down an issue an internal customer was having whereby multiple adb instances were fighting each other:

/usr/bin/adb existed as part of the adb Debian package that was installed on the user's system. It seemed to be restarting its server automatically when killed because of an entry in init.d

$ANDROID_HOME/platform-tools/adb was the user's preferred adb instance and was also the instance detected by flutter tools since it lived in a proper SDK folder structure.

There was initially an issue whereby one adb client process would detect a mismatch between the client and server versions and restart the appropriate server, and in so doing, it'd echo a message to the terminal that flutter tools mistook for a device line (fixed in #9693).

Once that issue was fixed, the two adb servers still seemed to be fighting each other, causing the preferred adb to show no connected devices even though there were devices connected. The solution we eventually found for this was uninstalling /usr/bin/adb (via sudo apt-get remove adb)...

This experience, along with reports within the Flutter team of multiple adb instances not playing nicely with each other and with Flutter tools, means we probably want to add a doctor validator that will warn the user if multiple adb binaries are detected.
Issue 1:
We recently migrated our ES 1.1.1 cluster to ES 1.2.2, after that we found that one field 'displayPublishedDateTime', which is defined as dataOptionalTime type in the mapping, seems corrupted and not able to order by it in the query.

In the query, when order by desc on it, its sort value is '\b', and order by asc, its sort value is shown as '' \u0001\u0000\u0000\u0000(aC3@X", see the following query and results. In other queries, which order by 'displayPublishedDateTime', the order actually didn't take effect. It looks like that Elasticsearch was unable to get the correct sort value for this field.

Query

GET /doc-v2/_search
{
"query": {
"match": {
"_id": "AAUYRY"
}
},
"_source":[
"_id",
"_document.displayPublishedDateTime",
],
"sort": [
{
"_document.displayPublishedDateTime": {
"order": "desc"
}
}
]
}

Results for 'desc'

{
"took": 46,
"timed_out": false,
"_shards": {
"total": 25,
"successful": 25,
"failed": 0
},
"hits": {
"total": 1,
"max_score": null,
"hits": [
{
"_index": "doc-v2",
"_type": "article",
"_id": "AAUYRY",
"_score": null,
"_source": {
"_document": {
"displayPublishedDateTime": "2014-05-20T06:58:47Z"
}
},
"sort": [
"\\\b"
]
}
]
}
}

Results for 'asc'

{
"took": 78,
"timed_out": false,
"_shards": {
"total": 25,
"successful": 25,
"failed": 0
},
"hits": {
"total": 1,
"max_score": null,
"hits": [
{
"_index": "doc-v2",
"_type": "article",
"_id": "AAUYRY",
"_score": null,
"_source": {
"_document": {
"displayPublishedDateTime": "2014-05-20T06:58:47Z"
}
},
"sort": [
" \u0001\u0000\u0000\u0000(aC3@X"
]
}
]
}
}

Issue 2:
When querying with "preference": "_local", the _source is returned instead of the requested fields.

$ curl -XPUT 'http://ks398280.kimsufi.com:9200/test/test/1' -d '{"user": "foo", "amount": 35, "data": "some more data"}'

$ curl -XPOST 'http://ks398280.kimsufi.com:9200/test/test/_search?pretty' -d '{
"query": {
"match": {
"data": {
"query": "some"
}
}
},
"fields": ["user", "amount"]
}'

{
"took" : 1,
"timed_out" : false,
"_shards" : {
"total" : 5,
"successful" : 5,
"failed" : 0
},
"hits" : {
"total" : 1,
"max_score" : 0.15342641,
"hits" : [ {
"_index" : "test",
"_type" : "test",
"_id" : "1",
"_score" : 0.15342641,
"fields" : {
"amount" : 35,
"user" : "foo"
}
} ]
}
}

$ curl -XPOST 'http://ks398280.kimsufi.com:9200/test/test/_search?pretty' -d '{
"query": {
"match": {
"data": {
"query": "some"
}
},
"preference": "_local"
},
"fields": ["user", "amount"],
}'

{
"took" : 1,
"timed_out" : false,
"_shards" : {
"total" : 5,
"successful" : 5,
"failed" : 0
},
"hits" : {
"total" : 1,
"max_score" : 0.15342641,
"hits" : [ {
"_index" : "test",
"_type" : "test",
"_id" : "1",
"_score" : 0.15342641, "_source" : {"user": "foo", "amount": 35, "data": "some more data"}
} ]
}
}
Issue 1:
In OSX Mavericks and Atom 0.121.0, there is a bar with nothing in the top of the screen, when Atom is in FullScreen mode.

Is this a bug?

Issue 2:
Open an Atom window with a file or project. (For some reason, this bug didn't happen when I tried to reproduce from an empty Atom window.)

Enter fullscreen mode (Ctrl-Cmd-F)

Open another window of Atom. (e.g. with the command line, File > Open [and then select a folder], or with the Project Quick Open package)

The window that opens will have a vestigial title bar at the top that looks like this:

It's not a big deal, but it does undermine the purpose of fullscreen mode a little bit. ;)

This is on Atom 0.120.0 running on OS X 10.9.3. I was able to reproduce the problem in safe mode.
Issue 1:
When building a Pipeline with custom transformers, what is the best way to serialize that for later use?

If you use pickle, you need to define those functions in the new environment, so that doesn't seem like a solution to me. I ran into the same issue with dill and joblib.

What is the best practice here?

Thanks!

Issue 2:
pred=[1e-10, 0, 0]

sol=[1, 0, 0]

metrics.roc_auc_score(sol, pred) # 0.5, wrong, 1 is correct

pred=[1, 0, 0]

sol=[1, 0, 0]

metrics.roc_auc_score(sol, pred) # 1 correct
Issue 1:
Version

2.5.16

Reproduction link

https://github.com/ondrej-janosik/vue-bug-props/blob/master/src/App.vue

Steps to reproduce

Create a new project with VUE CLI, just add typescript

Open is VS code

Create a property in data in App.vue

Access this property in a computed method - works

Add prop with type array

Computed property context is broken - not work

Change prop type to for example to object - works

What is expected?

A computed property should have the same context even if prop with type array is presented

What is actually happening?

Computed property context is missing

Issue 2:
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 1:
As I see gvfs starts with a PROPFIND (I'm using litmus_test_server.go).

(By the way, at the moment go test fails, too).

I'm not a DAV expert at all, but I'd really like to have this work with Windows (for camlistore.org :)).

Where should I start? What's missing, or known lack of care?

Issue 2:
Hello,

Just like we have FormatFloat(...) string and AppendFloat(...) []byte, it would be nice
to avoid a costly string conversion when parsing numbers from a byteslice.

Simple code like:

func main() {
s := "123.45"
r := bytes.NewBufferString(s)
runtime.UpdateMemStats()
println(runtime.MemStats.Mallocs)
var v float64
fmt.Fscanf(r, "%f", &v)
runtime.UpdateMemStats()
println(runtime.MemStats.Mallocs)
}

says it's doing 7 allocations in the Scanf.
Issue 1:
Is this behavior of np.double desired? I'm wondering about the middle case which I would have expected to be array([3.]) instead of 3.0. I assume there is nothing special about double or 3 and that this is probably not a real issue, so it can be closed soon.

>>> np.double(np.asarray(3))
3.0
>>> np.double(np.asarray([3]))
3.0
>>> np.double(np.asarray([3, 4]))
array([ 3., 4.])

Issue 2:
Hi all, I'm reporting a problem when using np.float64 as a constructor.

For any a = np.array([[scalar]]) assuming type(scalar) in (int, float), this raises AssertionError:

assert np.float64(a).shape is a.shape

The shape after casting to np.float64 is () instead of the expected (1,1). We can see what's going on more clearly when only this last assertion fails:

scalar = 0.0 # example
a = np.array([[scalar]])
assert type(a) is np.ndarray
assert type(np.float64(a)) is np.ndarray #AssertionError

The problem is that np.float64(a) is np.float64(scalar). Contrary to expectations, np.float64(a) is not np.float64([[scalar]])

This happens with v1.14.2 as well as master. I've tested with python 3.6.4/2.7.11 on ubuntu 16.04/Mac OS 10.12.3.
Issue 1:
As discussed #5156 and in other places, the load balancer creation should not be synchronous with resource creation (goes against the "dumb resources" model) but instead be applied by a controller both before and after creation.

Issue 2:
I'm trying to bring up a service and pod (https://github.com/youtube/vitess/examples/kubernetes/vtctld-up.sh). The service has createExternalLoadBalancer: true. The call nearly always returns:

ERROR: F0306 15:59:47.443762 17632 create.go:81] Timeout: request did not complete within allowed duration.

I then proceed to create a firewall rule (created successfully) and access the service, which occasionally works. Note the non-determinism:

I nearly always get the timeout error (> 90%).

Even if I get the timeout error, I can still create the firewall rule and it's a toss-up whether I can access the service or not.

If I automate these steps in a script (bring up cluster, bring up service, create firewall rule), I am virtually never able to access the service using the forwarded IP and port.

Our thoughts are that adding the external load balancer makes bringing up the service take longer, putting it at risk of timeout. I couldn't find a way to increase the timeout threshold in kubectl create.

In addition there may be some hidden steps or waits between steps that are needed since the automation never works, but running the steps manually sometimes does.

Also of note is that this seems to be new behavior. Prior to 3/5/2015, I hadn't seen any issues (if the timeout error occurred, it didn't have any impact), automation worked completely fine.
Issue 1:
ok text/template/parse 0.007s
--- FAIL: TestOverflowRuntimeTimer (0.10 seconds)
sleep_test.go:402: runtime timer stuck: overflow in addtimer
FAIL
FAIL time 4.651s

Fails on several builds, FreeBSD, OpenBSD, Windows. I believe all these builders are
running inside vm's so this could be related

What is the expected output? What do you see instead?

Is this test failure an actual problem, or just noise by slow builders with a poor sense
of the passage of time ?

Please use labels and text to provide additional information.

http://build.golang.org/log/5467657de567ee1ff619b30da43ef06871b2698c
http://build.golang.org/log/977d7ed62d3cc11c571832016b98020056523485

Issue 2:
What steps will reproduce the problem?

panic messages should list the go version (from runtime.theVersion) as well as the
operating system and arch details as close to the top of the panic message as possible.

This would greatly aide in debugging problems reported on the mailing list and IRC as
those are the first details requested and the most often omitted.
Issue 1:
Issue Description

It looks likes there's a bug in the Beta FreeCodeCamp's signup

When user signups for the first time, it directs to a blank page. I would've assumed it would return back to the homepage (or at least returns back to page where it was before clicking the sign-up page)

Browser Information

Browser Name, Version: Chrome/55.0.2883.95

Operating System: Macintosh; Intel Mac OS X 10_11_6

Mobile, Desktop, or Tablet: MacBookPro

Screenshot

Issue 2:
After creating an user in beta(tried the same email I have FCC associated with). I was redirected to http://beta.freecodecamp.com/api/users

And all I see, is {}

After refreshing this page, I am getting the error displayed: The xxxxxxxxxx@gmail.com email address is already associated with an account. Try signing in with it here instead. With what I did log in afterwards

Browser Name, Version: Chrome Version 55.0.2883.87

Operating System: Windows 7 64bit
Issue 1:
What steps will reproduce the problem?
If possible, include a link to a program on play.golang.org.

Compile & run the code in:
https://gist.github.com/ernestokarim/5033404

It cannot be reproduced in the playground because it needs sqlite3.

What is the expected output?

Run without bugs.

What do you see instead?

Using any revision after this one:
https://code.google.com/p/go/source/detail?r=ddb9e6365e57

it starts to consume file descriptors without end, you can check it:
while [ 1 ] ; do ls /proc/6559/fd | wc -l ; sleep 1; done

even if I'm closing the prepared statements correctly. In the iteration 1021 it fails
with "unable to open database file".

Which compiler are you using (5g, 6g, 8g, gccgo)?

8g.

Which operating system are you using?

Fedora 17, 32 bits. SQLite3, the latest version from the website.

Which version are you using? (run 'go version')

go version devel +c0258d9a3589 Wed Feb 27 15:22:14 2013 -0800 linux/386

Please provide any additional information below.

mattn/go-sqlite3#41

Issue 2:
What steps will reproduce the problem?
1. compile attached program and run it

What is the expected output?
the last value consumed by any of the multiple readers should be '9'

What do you see instead?
the last value generated before the channel was closed is 9, but more often than not the last value consumed by any of the chan's readers is 8.

Which compiler are you using (5g, 6g, 8g, gccgo)?
6g

Which operating system are you using?
OSX

Which revision are you using? (hg identify)
684ebd420f34+ tip

Please provide any additional information below.
The "9" does appear to be consumed occasionally:

$ while true; do ./6.out | egrep 'consumed: [89]'; done | egrep -n 'consumed: 9'
180:consumed: 9
356:consumed: 9
569:consumed: 9
984:consumed: 9
989:consumed: 9
2166:consumed: 9
2235:consumed: 9
2295:consumed: 9
2350:consumed: 9
2929:consumed: 9
3039:consumed: 9

Attachments:

t.go (405 bytes)
Issue 1:
It seems to be something like this issue:

#18893

In my case, the renderer outputEncoding is GammaEncoding and I'm using an EffectComposer with a GammaCorrectionShader pass at the end.

If I use a reflector with the default LinearEncoding then it runs fine, but the reflection colors are screwed, they appear too dark. If I use sRGBEncoding as the reflector encoding, then the reflection colors are correct but it's running slow as hell, probably recompiling the shaders all the time.

Is there a way I can get correct colors without recompiling the shaders all the time?

Issue 2:
Description of the problem

I'm experiencing horrible render performance when using the combination of the Water.js shader, a plane with a MeshStandardMaterial and the renderer.output using sRGBEncoding.

Recreated water example in jsfiddle and added renderer.outputEncoding = THREE.sRGBEncoding (line 119) in the fiddle: https://jsfiddle.net/4esfwtkh/

The performance does not dip:

By not setting render.output to sRGBEncoding and using MeshStandardMaterial it will run ok (comment line 117)

By setting render.output to sRGBEncoding but using MeshBasicMaterial it will run ok (comment line 55 and uncomment line 56)

When the water is not visible in the camera frustum (i.e. by looking from below)

Three.js version

Dev

r114

r113