WhereIsAI/github-issue-similarity huggingface dataset:
Issue 1:
Using latest release of kube-apiserver and kubectl, with etcd 2.2.1 and a fresh data directory

Client Version: version.Info{Major:"1", Minor:"3+", GitVersion:"v1.3.0-alpha.4", GitCommit:"9990f843cd62caa90445cf76b07d63ba7b5c86fd", GitTreeState:"clean", BuildDate:"2016-05-17T21:58:54Z", GoVersion:"go1.6.2", Compiler:"gc", Platform:"linux/amd64"} Server Version: version.Info{Major:"1", Minor:"3+", GitVersion:"v1.3.0-alpha.4", GitCommit:"9990f843cd62caa90445cf76b07d63ba7b5c86fd", GitTreeState:"clean", BuildDate:"2016-05-17T21:51:30Z", GoVersion:"go1.6.2", Compiler:"gc", Platform:"linux/amd64"}

I can create a ThirdPartyResource type okay with lets say a name of student.stable.acme.com via ./kubectl create -f student-type-setup.yaml, this returns a sucess message. I then can get and list via curl at /apis/stable.acme.com/v1/students no problem.

However if I add another third party resource type say course.stable.acme.com, I can't list from this, server returns a 404, even though it was added successfully.

More strangely, if at this point I restart the api server, 'courses' now lists okay, but voila 'student's no longer list. Guessing as my etcd knowledge is very very limited - it's almost as if they are keyed to the same key. At this stage I'm guessing this is related to storage.

Issue 2:
I am trying to install the following thirdparty resources:

metadata:
name: compute-node.tess.io
apiVersion: extensions/v1beta1
kind: ThirdPartyResource
description: "A compute node object is used by the mastercontroller to track computes in cloud"
versions:
- name: v1

And

metadata:
name: node-pool.tess.io
apiVersion: extensions/v1beta1
kind: ThirdPartyResource
description: "A node pool object to nodes is analogous to what a replicationcontroller is to pods"
versions:
- name: v1

The first one gets successfully registered when I try to create it. But the second on never gets registered and kubectl does not throw an error out either. I digged a little deep into the kube-apiserver logs and I see the following error:

Recovered from panic: "http: multiple registrations for /apis/tess.io/v1" (http: multiple registrations for /apis/tess.io/v1)

When I digged deep into the thirdparty controller and master.go, here: https://github.com/kubernetes/kubernetes/blob/master/pkg/master/master.go#L611, I see that we have not covered the case where there can be 2 API objects defined on the same resource path prefix, like /apis/tess.io/v1/nodepools and /apis/tess.io/v1/computenodes

Is there something I am missing, or is this a genuine issue you think ?
Issue 1:
use std::io;

fn make_proc() -> proc() {
let s = ~"foo";
proc() {
drop(s);
io::stderr().write_str(s).unwrap();
}
}

fn main() {
let p = make_proc();
p();
}

$ rustc -v
rustc 0.10-pre (68a4f7d 2014-02-24 12:42:02 -0800)
host: x86_64-unknown-linux-gnu

$ rustc foo.rs
$ ./foo
Segmentation fault

(Apologies if this has already been fixed; I'm using Servo's rustc.)

Issue 2:
Updated bug

The compiler allows this code when it shouldn't

fn main() {
let a = ~"";
let b: ~[&str] = a.lines().collect();
drop(a);
for s in b.iter() {
println!("{}", *s);
}
}

Original description

The following code is buggy:

let foo = ~"hello";
let foo: ~[&str] = foo.words().collect();
let invalid_string = foo[0];

Invalid string contains, as the name suggests, an invalid string; sometimes I get a string filled with \x00, sometimes just garbage, and usually it will eventually assert that the string contains invalid characters.

It appears that the first foo gets dropped when the second one is assigned?

Either the first foo is supposed to be dropped as happens now, and the borrow checker should forbid this code (since the old foo no longer exists, &str cannot have a lifetime), or it should let the first foo live until the end of the current scope, and make the above work.
Issue 1:
Environment

Windows build number: [10.0.18362.387]
PowerToys version: 0.12.0.0
PowerToy module for which you are reporting the bug (if applicable): FancyZones

Steps to reproduce

Install GreenShot from https://getgreenshot.org/downloads/

Set GreenShot to capture a region (draw a box) for capture

Apply a custom Fanzyzones layout. Mine is 3 columns, with the left column split into 3 rows.

Press [Print Screen]

Expected behavior

I should be able to capture the screen from any monitor. Draw a box around what I want captured. Open GreenShot to edit/annotate.

Actual behavior

The zones are duplicating into other zones, and the mouse is locked into the center zone. The information I wanted to capture is no longer on the screen, overwritten by the left panel information. The program completely malfunctions and I have to press [ESC] to stop the screen capture.

Screenshots

Issue 2:
Summary of the new feature/enhancement

I mainly want to use PowerToys Run to switch between running apps, and occasionally start new apps through it. Currently it works in a way, that it shows in the results the installed apps first, and only then the running apps.

Proposed technical implementation details (optional)

It would be great if there would be an option where I could choose if I want PowerToys to show me the installed apps or the running apps first.
Issue 1:
Code Sample

import pandas as pd
import io

text = """
A B C
1 1 1
1 2 2
2 1 3
2 2 4
"""
df = pd.read_csv(io.StringIO(text), delimiter = ' ')
# Note the output of get_level_values is the list of all values [1, 1, 2, 2]
print(df.index.get_level_values('A').tolist())
df.set_index(['A','B'], inplace = True)
df.index.set_levels(df.index.get_level_values('A').map(lambda x: x * 2), level='A', inplace=True)
print(df.index.get_level_values('A').tolist())
# outputs [2, 2, 2, 2]

Expected Output

[2, 2, 4, 4]

# If I re-order the input as:
text = """
A B C
1 1 1
2 1 2
1 2 3
2 2 4
"""
# it works as I expected giving [2, 4, 2, 4]

Is this a bug or expected behaviour?

output of pd.show_versions()

INSTALLED VERSIONS

commit: None

python: 3.5.1.final.0

python-bits: 64

OS: Windows

OS-release: 7

machine: AMD64

processor: Intel64 Family 6 Model 60 Stepping 3, GenuineIntel

byteorder: little

LC_ALL: None

LANG: None

pandas: 0.18.1

nose: 1.3.7

pip: 8.1.1

setuptools: 20.3

Cython: 0.23.4

numpy: 1.10.4

scipy: 0.17.0

statsmodels: 0.6.1

xarray: None

IPython: 4.1.2

sphinx: 1.3.1

patsy: 0.4.0

dateutil: 2.5.1

pytz: 2016.2

blosc: None

bottleneck: 1.0.0

tables: 3.2.2

numexpr: 2.5

matplotlib: 1.5.1

openpyxl: 2.3.2

xlrd: 0.9.4

xlwt: 1.0.0

xlsxwriter: 0.8.4

lxml: 3.6.0

bs4: 4.4.1

html5lib: None

httplib2: None

apiclient: None

sqlalchemy: 1.0.12

pymysql: 0.7.5.None

psycopg2: None

jinja2: 2.8

boto: 2.39.0

pandas_datareader: None

Issue 2:
Small example:

In [87]: df = pd.DataFrame(columns=pd.MultiIndex.from_product([['A','B'],['a','b']]))

Setting the levels with an incorrect levels (too short), fails (correctly of course):

In [92]: df.columns.set_levels(['c'], level=1)
...
ValueError: On level 1, label max (1) >= length of level (1). NOTE: this index
is in an inconsistent state

When using inplace=True, this also gives the same error message, but the index is actually changed to this inconsistent state:

In [93]: df.columns.set_levels(['c'], level=1, inplace=True)
...
ValueError: On level 1, label max (1) >= length of level (1). NOTE: this index
is in an inconsistent state

In [94]: df.columns
Out[94]:
MultiIndex(levels=[[u'A', u'B'], [u'c']],
labels=[[0, 0, 1, 1], [0, 1, 0, 1]])

Just showing this df in the console did crash my session in the case above, in the example from #13741, it gave the error "IndexError: index 1 is out of bounds for axis 0 with size 1"
Issue 1:
Which lifecycle methods can I define on a modern ES6-class-style React component? The same as for a classic component spec? I checked the docs but I can't find much yet on the ES6 classes. Am I missing something?

Issue 2:
Do you want to request a feature or report a bug?

bug (though the React code is working as intended)

What is the current behavior?

When hydrating from server-rendered DOM, if react-reconciler encounters an unexpected node it will peek ahead to the next DOM node and test if it is the expected node. If so, react-reconciler will delete the unexpected node and continue on by using the second node to hydrate. If the second node does not match the instance then the reconciler gives up and begins inserting DOM nodes without trying to reconcile.

In our case, we are server-side rendering the entire #document server-side and re-hydrating at that level. Some 3rd party analytics scripts are injected at the top of before the hydrate call happens, causing the entire application to be injected into the body instead of reconciled with the existing nodes.

If the current behavior is a bug, please provide the steps to reproduce and if possible a minimal demo of the problem via https://jsfiddle.net or similar (template for React 16: https://jsfiddle.net/Luktwrdm/, template for React 15: https://jsfiddle.net/hmbg7e9w/).

I can force this to happen in our app by injecting two (or more) empty script tags at the top of . I've not been able to reproduce via jsfiddle; unsure what the exact combination of flags are to force this specific code path.

document.body.insertBefore(document.createElement('script'), document.body.children[0]);
document.body.insertBefore(document.createElement('script'), document.body.children[0]);

What is the expected behavior?

Ideally the reconciler would look at all of the sibling nodes to find the matching element.

A comment in the code at the relevant location says

// If we can't hydrate this instance let's try the next one.
// We use this as a heuristic. It's based on intuition and not data so it
// might be flawed or unnecessary.

I hacked together a change to prove out inspecting all sibling elements and that seems to be working with no unintended consequences. I modified

nextInstance = getNextHydratableSibling(nextInstance);

to be

while (nextInstance = getNextHydratableSibling(nextInstance), nextInstance && !canHydrate(fiber, nextInstance)) {};

So nextInstance will either be the hydratable sibling or it will be null.

Using performance.now() on my Mac Book Pro, I do not observe this O(1) -> O(n) change to be measurable in my situation.

with matching DOM: 118-144ms
with mismatched DOM: 116-172ms
mismatchedDOM & updated function: 116-163ms

Which versions of React, and which browser / OS are affected by this issue? Did this work in previous versions of React?

This was introduced with React 16s new hydration approach. (I'll take this over the Invariant 42 full-stop error; thanks for building the new approach!).
Issue 1:
Expected Behavior

App should run as expected on 127.0.0.1 with debugger mode enabled

# Paste a minimal example that causes the problem.
# .. E:/web/public/myblog.in/hello.py
from flask import Flask
app = Flask(__name__)

@app.route('/')
def hello_world():
return 'Hello, World!'

all configs and venv enabled as https://flask.palletsprojects.com/en/1.1.x/quickstart/

export FLASK_APP=hello.py

Actual Behavior

flask run works as expected. I can see the "Hello world" without issues, unless I enabled debug mode as export FLASK_ENV=development in which case if I run flask run I get

$ flask run
* Serving Flask app "hello.py" (lazy loading)
* Environment: development
* Debug mode: on
* Restarting with stat
e:\web\public\myblog.in\venv\scripts\python.exe: Error while finding module specification for 'E:\\web\\public\\myblog.in\\venv\\Scripts\\flask' (ModuleNotFoundError: No module named 'E:\\web\\public\\myblog')

You can see in the last error it says No module named 'E:\\web\\public\\myblog (it should be ..\\myblog.in (.in) is missing, maybe that is the issue (bug)

Environment

Python version: 3.7.1

Flask version: 1.1.x

Werkzeug version: 0.15.5

Issue 2:
When jsonify is called on an object with a 'date' it throws:

TypeError: datetime.date(2012, 3, 30) is not JSON serializable

There is an innocuous fix - see http://stackoverflow.com/questions/455580

def date_handler(obj):
if hasattr(obj, 'isoformat'):
return obj.isoformat()
else:
raise TypeError, 'Object of type %s with value of %s is not JSON serializable' % (type(obj), repr(obj))

And https://github.com/mitsuhiko/flask/blob/master/flask/helpers.py#L142 becomes:

json_str = json.dumps(dict(*args, **kwargs), indent=None, default=date_handler)

This strikes me as preferable to TypeError.

Alternatively, jsonify could accept a default argument that is passed to json.dumps.
Issue 1:
When bundling multiple files with -m system, the module names should include the file extension. Otherwise, they are loaded but not executed by systemjs.

Before:

System.register("app/boot", [...], ...

After:

System.register("app/boot.js", [...], ...

See here: systemjs/systemjs#1065

Issue 2:
Currently, TS can't find modules when you use a file extension in the import name (import {Foo} from './foo.ts';) - SystemJS updated and file extensions are now required (though the spec issue is still under discussion) on imports (without setting some legacy settings in System.config). So when compiling with --module, you can either have a functioning typechecker (no extensions on your imports) or a functioning runtime (.js on your imports, since your result files have .js extensions). This is complicated further by systemjs's bundler, which looks for dependent files before TS transpiles them, so you have to use .ts extensions on your imports so the bundler can resolve the paths to real ones.

This extension madness is all incredibly awkward to work with, and I'm not sure if this needs module resolution logic updating on our part, arguing for old behavior on the loader spec, or talking to systemjs and having them change how they're finding modules ignoring the spec.
Issue 1:
Unable to require dependencies on the constructor of a service.

Angular @angular/core : 2.0.0

"angular-cli": "1.0.0-beta.16"

"typescript": "2.0.2"

Note : If I just clear the constructor dependencies defined in the CustomerService class then it works like a charm.

@Injectable() export class CustomerService constructor(private authService: AuthService, private siteService: SiteService) { }

AuthService and Site Service Class and It's dependencies are loaded with no problem. Just some sudo facade of AuthService and SiteService Class

@Injectable()
export class AuthService
constructor(private http: Http, private storageService: StorageService,
private siteService: SiteService, private router: Router) {}

@Injectable()
export class SiteService {
constructor(private http: Http, private storageService: StorageService) {}
And also App Module @ngModule decorator.

@NgModule({
declarations: [
AppComponent,
AuthComponent,
LoginComponent,
HeaderComponent,
SignupComponent,
CompanyComponent,
Step2Component
],
imports: [
BrowserModule,
FormsModule,
HttpModule,
AngularAppRoutingModule
],
providers: [ AuthGuard, AuthService, StorageService, StepsNavigatorGuard, SiteService, CustomerService],
bootstrap: [AppComponent]
})

Issue 2:
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

Services that implement the OnDestroy interface that are included in the root NgModule providers are automatically instantiated. If the service injects the Router, it throws an error.

Error: Bootstrap at least one component before injecting Router

Expected/desired behavior

Services injecting the router that implement the OnDestroy interface are instantiated without error.

Reproduction of the problem

If the current behavior is a bug or you can illustrate your feature request better with an example, please provide the steps to reproduce and if possible a minimal demo of the problem via https://plnkr.co or similar (you can use this template as a starting point: http://plnkr.co/edit/tpl:AvJOMERrnz94ekVua0u5).

http://plnkr.co/edit/JQVPXQt62G2W56S84R5R?p=preview

What is the expected behavior?

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

Please tell us about your environment:

Angular version: 2.0.0-rc.5

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]

@MikeRyan52 @meenie @vsavkin
Issue 1:
ISSUE TYPE

Documentation Report

COMPONENT NAME

ansible/lib/ansible/modules/cloud/amazon/*

ANSIBLE VERSION

ansible 2.3.0.0
config file = /etc/ansible/ansible.cfg
configured module search path = Default w/o overrides
python version = 2.7.12 (default, Nov 19 2016, 06:48:10) [GCC 5.4.0 20160609]

SUMMARY

Working with three modules from the cloud/amazon library

iam

iam_policy

s3_bucket

I had to experiment with the ansible user I created on amazon to get the user privileges correct for each module. This was because I want to allow the anisble user the MINIMUM required to perform the actions in my role and no more. Finally I created the following two policies:

//Create a user
{
"Version": "2012-10-17",
"Statement": [
{
"Sid": "AllowUsersToPerformUserActions",
"Effect": "Allow",
"Action": [
"iam:GetUser",
"iam:UpdateUser",
"iam:CreateUser",
"iam:CreateAccessKey",
"iam:PutUserPolicy",
"iam:ListUsers",
"iam:ListAccessKeys",
"iam:ListGroups",
"iam:ListRoles",
"iam:ListInstanceProfiles",
"iam:ListGroupsForUser",
"iam:ListUserPolicies",
"iam:ListAttachedUserPolicies"
],
"Resource": "*"
}
]
}

//Create a bucket
{
"Version": "2012-10-17",
"Statement": [
{
"Sid": "DBCreateVersionedBucketWithTags",
"Effect": "Allow",
"Action": [
"s3:CreateBucket",
"s3:ListBucket",
"s3:GetBucketPolicy",
"s3:GetBucketVersioning",
"s3:GetBucketRequestPayment",
"s3:GetBucketTagging",
"s3:PutBucketPolicy",
"s3:PutBucketTagging",
"s3:PutBucketVersioning"
],
"Resource": [
"*"
]
}
]
}

However, I am still not completely sure these are the MINIMUM required by the modules.

Can I request that the module documentation include a set of minimal permissions for performing each module operation? Or is that beyond the scope of the docs?

Many thanks

Issue 2:
Documentation Report

COMPONENT NAME

aws modules (various)

ANSIBLE VERSION

2.2.1.0

Documentation for AWS specific modules (ec2_vol etc), should outline which IAM permissions are required for the module to work.

EXPECTED RESULTS

There should be a note on the AWS specific module outlining the list of IAM permissions that module uses to do it's job. Otherwise the end user is left with the prospect of pouring through ansible source code, and trying to guess what has been called. At the very least, the sts coded errors should be displayed to the user in the output together with the existing 'permission denied' error.

ACTUAL RESULTS

Currently the error message of 'permission denied' is pretty useless, as you don't know WHICH permission was denied, or which was being attempted, either.
Issue 1:
This seems to be specific to Pandas as opposed to matplotlib. Worked as desired as of a few months ago when I last updated from master.

This is the desired behavior in matplotlib:

plt.barh([0,1], [.3, .5], xerr=[[.1,.2], [.3,.4]],
color = ['red','green'],
ecolor='black')

In the Pandas call, it seems to ignore the second error bar argument, both the upper and lower bounds of the error bar are the same:

s = pd.Series([.3,.5])
s.plot(kind='barh', xerr=[[.1,.2], [.3,.4]],
color = ['red','green'],
ecolor='black')

Issue 2:
According to the documentation, asymmetric error bars should be able to be passed in to plot as an Mx2 array for a Series object or a Mx2xN array for a DataFrame object.

However, the code only seems to parse this correctly for a DataFrame: https://github.com/pydata/pandas/blob/master/pandas/tools/plotting.py#L1338

When passing raw error values as yerr, it seems that the first values are used as two-sided error differences, instead of being plotted as raw upper and lower values. Note the symmetric error bars below:

Using the underlying matplotlib function directly yields the expected results, but without the pandas-generated decorations:

This was originally noted in this StackOverflow question and I corroborated the other user's experience.
Issue 1:
Environment

Windows build number: 19042
PowerToys version: v0.19.0
PowerToy module for which you are reporting the bug (if applicable): PowerToys Run

Steps to reproduce

Keep a browser windows or PowerToys setting page in focus (active) and use the shortcut for PowerToys Run search box to open.

Expected behavior

The search window should open.

Actual behavior

The shortcut (Alt+Space) opens the window settings option

#Additional comments

I haven't tested it with all apps. It works properly with my PDF reader (Foxit Reader).

Issue 2:
Have integration/ability to save Virtual desktop sessions after power off

Virtual desktop would be the best feature of windows productivity if only you could actually save the desktops and have the option to either have them start up on boot or the option to click on a saved session once booted and for all the windows/apps to start up again where you left off.
Issue 1:
Here's the example:

http://imgur.com/j53FLmE

So I applied (e.g.):

transform: scale(0.5);

The element scales propertly, but its content inside as you can see the body is the dotted outline of the document inside that webview.

The project:

https://github.com/rokyed/cocoChanelJS

If more information needed, I will provide anything I will be asked concerning this project.

Thanks for the answers.

Electron version: 0.36.10

Operating system: Linux Mint

Issue 2:
Electron version: 0.36.8

Operating system: OS X 10.11.2

Origin webview:

Add transform: scale(0.3) to it:

The content of webview is scaled to 0.3*0.3 = 0.09 of the origin size.

Add transform: scale(0.5) to it:

The content of webview is scaled to 0.5*0.5 = 0.25 of the origin size.
Issue 1:
Hi,

I tried searching in github but nothing helped

I am trying to run Angular 2 on New Visual Studio 2015 with basic setup

installed latest libraries

npm:3.10.7,

typescript: 2.0.3,

node js: v6.6.0,

rxjs: 5.0.0-beta.12,

angular2: 2.0.0-beta.17

when I run in chrome getting error like "Failed to load resource: the server responded with a status of 404 (Not Found)"

Can anybody help me on this?

Issue 2:
Hi All,

I am trying to run Angular 2 on New Visual Studio 2015 with basic setup

installed latest libraries

npm:3.10.7,

typescript: 2.0.3,

node js: v6.6.0,

rxjs: 5.0.0-beta.12,

angular2: 2.0.0-beta.17

when I run in chrome getting error like "Failed to load resource: the server responded with a status of 404 (Not Found)"

Can anybody help me on this?
Issue 1:
Electron version: 1.4.15

Operating system: macOS Sierra, Windows 10

Expected behavior

Top level menu items should be hidden when the visible property is false and not be clickable when enabled property is false.

Actual behavior

The visible and enabled properties do not behave correctly on top level menu items. It seems to work correctly for submenu items.

How to reproduce

Create a menu with this code:

const { Menu } = require('electron').remote;

const template = [
{
label: 'Should not be visible',
visible: false,
submenu: [
{
label: 'Should not be visible either',
visible: false
}
]
},
{
label: 'Should not be enabled',
enabled: false,
submenu: [
{
label: 'Should not be enabled either',
enabled: false
}
]
},
];

const menu = Menu.buildFromTemplate(template);

Menu.setApplicationMenu(menu);

Both menu items will still be visible and clickable.

Issue 2:
It looks like there are plenty of options like visible, enable, etc in the menu-item but I couldn't find any way to do something with the menu after creating it. One of many failed attemps..

var menu = Menu.buildFromTemplate(template);
menu.items[3].visible = false;
menu.items[3].enable = false;