WhereIsAI/github-issue-similarity huggingface dataset:
Issue 1:
ISSUE TYPE

Bug Report

COMPONENT NAME

include_role

ANSIBLE VERSION

ansible 2.2.1.0
config file = /etc/ansible/ansible.cfg
configured module search path = Default w/o overrides

OS / ENVIRONMENT

N/A

SUMMARY / STEPS TO REPRODUCE

When I include a role from another role, the include statement of the included role is not able to find the file. For example:

Role A includes role B

- name: Include other role
include_role:
name: roleB

and role B is split into multiple task files:

- name: Install
include: install.yml

- name: Configure
include: configure.yml

When role B is directly used from a play everything works fine, but using it from task A failed with 'file not found errors'.

I have been able to 'fix' this issue by using the role_path variable:

- name: Install
include: "{{ role_path }}/tasks/install.yml"

- name: Configure
include: "{{ role_path }}/tasks/configure.yml"

Issue 2:
I was making an ansible-galaxy role today and when placing the lookup_folder plugin at the same level as the rest of the folders and then using it it returns that it can't find the plugin. Do we have anyway to use lookup_plugins at a role level without forcing uses to manually add it to there playbook?

Here is the repo in question. Master is how i got it to work for testing that the lookup_plugins folder only works when at the same level as the playbook https://github.com/nowait-tools/ansible-rabbitmq the branch galaxy test is the one that fails.
Issue 1:
Electron Version: v3.0.0-beta.5

Operating System (Platform and Version): Mac 10.12.6 (16G1510)

Last known working Electron version: v2

Expected Behavior

Window controls should be visible.

Actual behavior

They are invisible. HOWEVER, they are clickable, if you click in the right spot.

To Reproduce

mainWindow = new BrowserWindow({
acceptFirstMouse: true,
backgroundColor: '#333333',

width: Math.min(width, 2480),
height: Math.min(height, 1350),

title: path.basename(filename),

minWidth: 1024,
minHeight: 640,
show: false,
resizable: true,
titleBarStyle: 'hiddenInset',
webPreferences: {
webgl: true,
experimentalFeatures: true,
experimentalCanvasFeatures: true,
devTools: true,
plugins: true
}
})

Issue 2:
Electron version: 2.0.0-beta.8

Operating system: MacOS 10.12.6

Create a window with vibrancy of "light"/"dark" and a titleBarStyle of "hiddenInset" and the app crashes on quit. Other combinations may also cause a crash but I haven't tested them.

This is a regression, it works with v1.8.4.

new BrowserWindow({
width: 800,
height: 600,
titleBarStyle: "hiddenInset",
vibrancy: "light"
})

Here is a repro: https://github.com/davej/electron-quick-start
Issue 1:
Requires back port from master

diff --git a/deps/pcre.mk b/deps/pcre.mk

index bdc784d..cb4a45d 100644

--- a/deps/pcre.mk

+++ b/deps/pcre.mk

@@ -5,7 +5,7 @@ PCRE_CFLAGS := -O3

PCRE_LDFLAGS := $(RPATH_ESCAPED_ORIGIN)

$(SRCDIR)/srccache/pcre2-$(PCRE_VER).tar.bz2: | $(SRCDIR)/srccache

$(JLDOWNLOAD) $@ https://ftp.csx.cam.ac.uk/pub/software/programming/pcre/pcre2-$(PCRE_VER).tar.bz2

$(JLDOWNLOAD) $@ https://ftp.pcre.org/pub/pcre/pcre2-$(PCRE_VER).tar.bz2

$(SRCDIR)/srccache/pcre2-$(PCRE_VER)/source-extracted: $(SRCDIR)/srccache/pcre2-$(PCRE_VER).tar.bz2

Issue 2:
Currently, the v0.6.2 release of Julia will not build successfully, since the build process attempts to download the dependency PCRE from a dead link.

This issue was already fixed in latest/unstable in PR #26757 and backported in PR #26848, but this fix is not reflected in the latest release, here: https://github.com/JuliaLang/julia/releases.
Issue 1:
The majority of search frontends usually display the highlighted chunks below the hit title. The problem is that on non highlighting queries, such as a numerical range, no highlighting chunk will be brought back in the search. If you don't want your display to look bad, you usually display an excerpt of the beginning of the file, or of the first contiguous paragraph, etc... The easy way to do that is to always ask for the full field content in your ES query, but this is a very costly solution in any case (unnecessary memory and bandwidth).

I would like to suggest an enhancement to ElasticSearch to add the possibility to get back a excerpt of the highlighted field in case the query doesn't highlight. The syntax would be:

"highlight" : {
"fields" : {
"content" : {
"fragment_size" : 150,
"number_of_fragments" : 3,
"fallback" : "excerpt_basic" // or "excerpt_firstparagraph" or any other more advanced impl to come
}
}
}

Jérémie

Issue 2:
Highlighting is great as providing an highlighted excerpt, but if you run no query against one field, you will have no output at all.

Highlighting could provide a non highlighted excerpt (some number of characters from the beginning of the value) as a fallback.

This would be yield shorted answers than always asking for the whole field content (that may be quite long).

{
"highlight" : {
"fields" : {
"text" : {
"number_of_fragments" : 3,
"size_of_fragments" : 150,
"no_results" : VALUE
}
}
}
}

Where VALUE could take: hide (default), show, or a character count.

Where show would be equivalent to setting the character count to number_of_fragments * size_of_fragments.
Issue 1:
If you know how to fix the issue, make a pull request instead.

I tried using the @types/react (version 16.9.19) package and had problems.

I tried using the latest stable version of tsc (version 3.7.5). https://www.npmjs.com/package/typescript

I have a question that is inappropriate for StackOverflow. (Please ask any appropriate questions there).

Mention the authors (see Definitions by: in index.d.ts) so they can respond.

Authors: @johnnyreilly, @bbenezech, @pzavolinsky, @digiguru, @ericanderson, @DovydasNavickas, @theruther4d, @guilhermehubner, @ferdaber, @jrakotoharisoa, @pascaloliv, @Hotell, @franklixuefei, @Jessidhia, @saranshkataria, @lukyth, @eps1lon, @zieka, @dancerphil

Simple example code:

const ExampleComponent: FC<{}> = () => {
// some data example
const data = [{ name: '123' }, { name: '321' }];

// return React Elements array
return data.map(t => <div key={t.name}>{t.name}</div>);
};

Throws an error:

TS2322: Type '() => JSX.Element[]' is not assignable to type 'FC<{}>'. Type 'Element[]' is not assignable to type 'ReactElement<any, string | ((props: any) => ReactElement<any, string | ... | (new (props: any) => Component<any, any, any>)> | null) | (new (props: any) => Component<any, any, any>)>'.

Issue 2:
I tried using the @types/react package and had problems.

I tried using the latest stable version of tsc. https://www.npmjs.com/package/typescript

I have a question that is inappropriate for StackOverflow. (Please ask any appropriate questions there).

Mention the authors (see Definitions by: in index.d.ts) so they can respond.

Authors: @johnnyreilly @bbenezech @pzavolinsky @digiguru @ericanderson @morcerf @tkrotoff @DovydasNavickas @onigoetz @richseviora

React 16 components can have multiple root elements.

const Items = ({ items }: MyProps) => items.map(item => <div key={item.id}>{item.name}</div>)

However, TypeScript will break with:

error TS2605: JSX element type 'Element[]' is not a constructor function for JSX elements. Property 'render' is missing in type 'Element[]'.
Issue 1:
The reference states pretty clearly that the memory layout of structs is undefined by default, and presumably the same thing can be said of complex enum variants.

However, for C-like enums (simple enums which correspond to some integer type), it doesn't seem to be clear whether implicit discriminators are well defined. One resource (no longer in the actual docs, it seems) says that they are well defined (starts with 0, increases by 1 for each variant). But I couldn't find any other docs that comment on this (the reference does state that an enum with #[repr(C)] will have the default C ABI enum size - but also that enum representation in C is undefined? Is that referring to the implicit discriminators?).

In essence, can we assume that implicit discriminators start with 0 and increase by 1 per variant, or is this never an assumption we can make?

Issue 2:
The current Rust alpha allows one to attach two lifetimes with the same name to two distinct loop blocks.

This is a backwards compatibility risk for hypothesized future versions of Rust where the lifetime labels can be used in e.g. type annotations (rather than solely used for labelled break/continue statements).

Example:

fn main() {
let d = 3;
'a: for i in (0..d).rev() {
println!("i: {}", i);
}

'a: for i in (d..d*2).rev() {
println!("i: {}", i);
}
}
Issue 1:
Migrated issue, originally created by paj (@paj)

MSSQL does not natively support LIMIT with an OFFSET, but it may be possible to emulate the behavior. One option is to use MSSQL 2005's ROW_NUMBER() function; another is just to seek the cursor by the offset.

Issue 2:
Migrated issue, originally created by Anonymous

It could be very useful (at least for me) if SQLAlchemy can support manually add Oracle hints (http://www.adp-gmbh.ch/ora/sql/hints/index.html).

This can be useful because sometimes Oracle (in version 10, the 11 should be better), isn't able to optimize the request the right way, and a little hint like /+ INDEX(TABLE)/ manually added can drastically improve the performance.

I tried to add this feature in SQLAlchemy 0.5.3, but the architecture is a bit complicated for me to understand.

I can try again to modify the source code and propose a patch, but I need a little help on how to "cleanly" integrate this functionnality into SQLAlchemy.

You can contact me at canarix (at) gmail

Thanks in advance,

CanariX
Issue 1:
Hi @tomwanzek,

I'm trying to reproduce the following d3 example (http://bl.ocks.org/cjrd/6863459) in my Angular2 app with d3-drag and d3-select capabilities but I found the following error:

TypeError: Cannot read property 'button' of null
at SVGGElement.defaultFilter (drag.js:10)
at SVGGElement.mousedowned (drag.js:41)
at SVGGElement.<anonymous> (d3.js:811)
at ZoneDelegate.invokeTask (zone.js:275)
at Object.onInvokeTask (ng_zone.js:262)
at ZoneDelegate.invokeTask (zone.js:274)
at Zone.runTask (zone.js:151)
at SVGGElement.ZoneTask.invoke (zone.js:345)

My Typescript file has the following imports:

import * as d3 from 'd3';
import * as d3Drag from 'd3-drag';
import * as d3Selection from 'd3-selection';

Finally, I'm using d3 v4.4.4 (with @types from npm repository) and Angular2. Using only d3-select, the example works but without drag&drop capabilities.

I'm not sure wether it is a bug or coding error but any tip would be appreciated.

Thanks,

Issue 2:
d3-geo has seen a minor version update to 1.5 adding a new method.

The definitions should be updated to reflect path.measure(...) and any other relevant changes since the last version against which d3-geo was validated.

The minor version of d3 definitions should also be bumped to 4.6. Could be done in the same PR.

@Ledragon

cc @gustavderdrrache
Issue 1:
See this code example:

>>> t = [[1]]
>>> p = [[0]]
>>> metrics.ndcg_score(t, p)
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
File "/Users/cbournhonesque/.pyenv/versions/bento/lib/python3.8/site-packages/sklearn/utils/validation.py", line 63, in inner_f
return f(*args, **kwargs)
File "/Users/cbournhonesque/.pyenv/versions/bento/lib/python3.8/site-packages/sklearn/metrics/_ranking.py", line 1567, in ndcg_score
_check_dcg_target_type(y_true)
File "/Users/cbournhonesque/.pyenv/versions/bento/lib/python3.8/site-packages/sklearn/metrics/_ranking.py", line 1307, in _check_dcg_target_type
raise ValueError(
ValueError: Only ('multilabel-indicator', 'continuous-multioutput', 'multiclass-multioutput') formats are supported. Got binary instead

It works correctly when the number of elements is bigger than 1: https://stackoverflow.com/questions/64303839/how-to-calculate-ndcg-with-binary-relevances-using-sklearn

Issue 2:
I'm trying to calculate the NDCG score for binary relevance:

from sklearn import metrics

# test 1
y_true = [[3]]
y_score = [[5]]
metrics.ndcg_score(y_true, y_score)

And getting error

ValueError: Only ('multilabel-indicator', 'continuous-multioutput', 'multiclass-multioutput') formats are supported. Got binary instead

Below code snippet is working which has more than 1 item. Please suggest why single item array is not working.

from sklearn import metrics

# test 1
y_true = [[6 ,5, 4, 3, 2, 1]]
y_score = [[120, -2, -6, -3, 2, 12]]
metrics.ndcg_score(y_true, y_score)
Issue 1:
Original ticket http://projects.scipy.org/scipy/ticket/754 on 2008-10-13 by trac user shashmik, assigned to @wnbell.

Running scipy version 0.7.0.dev4763

coo_matrix.tocsr + tocsc both ignore the sum_duplicates parameter:

In [1]: from numpy import *
In [2]: from scipy.sparse import *
In [3]: data = array([1,1,1,1,1,1,1])
In [4]: row = array([0,0,1,3,1,0,0])
In [5]: col = array([0,2,1,3,1,0,0])
In [6]: A = coo_matrix( (data,(row,col)), shape=(4,4))
In [8]: A.tocsr(sum_duplicates=False).todense()
Out[8]:
matrix([[3, 0, 1, 0],
[0, 2, 0, 0],
[0, 0, 0, 0],
[0, 0, 0, 1]])
In [9]: A.tocsc(sum_duplicates=False).todense()
Out[9]:
matrix([[3, 0, 1, 0],
[0, 2, 0, 0],
[0, 0, 0, 0],
[0, 0, 0, 1]])

Issue 2:
scipy/scipy/optimize/optimize.py

Line 160
in
fcdc3d7

sum(100.0*(x[1:] - x[:-1]**2.0)**2.0 + (1 - x[:-1])**2.0

Should be

sum(100.0*(x[1:] - x[:-1]**2.0)**2.0 + (1 - x[:-1])**2.0 )
Issue 1:
Before filing a bug, please check whether it has been fixed since
the latest release: run "hg pull -u" and retry what you did to
reproduce the problem. Thanks.

What steps will reproduce the problem?
1. Build the attached source using a cgo Makefile

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

It should compile. Instead, the compiler complains about the C type being
an invalid receiver type.

What is your $GOOS? $GOARCH?

linux 386

Which revision are you using? (hg identify)

4c468c07d05c tip

Please provide any additional information below.

The failure to compile seems to have been introduced in the current tip commit.

Attachments:

ptr.go (141 bytes)

Issue 2:
by raul.san@sent.com:

Tested in Ubuntu 12.04.2 LTS

The compilation test in 1.1rc2 fails in amd64/linux (in 386/linux is ok):

# ../test/bench/go1
ok _/usr/local/go/test/bench/go1 2.990s

# ../test
runoutput rotate0.go : incorrect output
go build command-line-arguments: signal: killed

runoutput rotate1.go : incorrect output
go build command-line-arguments: signal: killed

runoutput rotate2.go : incorrect output
go build command-line-arguments: signal: killed

signal: killed
Issue 1:
In #23461 I described how difficult it is to write automation around kubectl. You want to check for errors at each stage, but you don't want the script to be so brittle that it only works if the apiserver is up and reachable 100% of the time. Asking users (including ourselves) to add the retry logic in the shell does not seem correct, so I'd like to see us add retry logic (off by default if we want) to kubectl.

@kubernetes/kubectl

Issue 2:
Issue 1:
Hi,

I've noticed that numpy's testsuite hangs when numpy is built against MKL 2018.2 - but runs to completion when built against MKL 2017.1.

This is the case for numpy v1.14.2, 1.14.x HEAD and master branches.

I'm on CentOS 7.4 x86_64 on a Broadwell processor, python 2.7.5 (but also affects other pythons), Cython 0.28.2, nose 1.3.7.

By executing this: python -c "import numpy; numpy.test(verbose=2)"

I can see that the hang occurs while running this test: numpy.distutils.tests.test_exec_command.TestExecCommand.test_basic

At this point, the python interpreter is consuming an entire CPU core and, if I strace it, I see a stream of identical lines, all showing:

sched_yield() = 0

Any ideas, please?

Thanks!

Issue 2:
Hello!

Linux Mint: 18.3 (Sylvia)

Python: 3.6.3

NumPy: 1.13.3

Cython 0.27.3

I am trying to build numpy and scipy wheels from source using the intel mkl compilers. Numpy compiles just fine, however when I run the test suite, the suite hangs on test_path_type_input within test_einsum.TestEinSumPath (or maybe the test after it? not sure because the last test name visible is this one; see screen cap)

Running the test suite for scipy results in the suite hanging on test_lapack within test_build.TestF77Mismatch

In both cases (numpy and scipy) the tests run and pass fine when run individually, so I'm not sure what else might be the cause.

Any help is greatly appreciated. See screen shot for images of the test suites when they're stuck is included.
Issue 1:
Within the svg glyphicon, the id of the font is:

https://github.com/twbs/bootstrap/blob/master/fonts/glyphicons-halflings-regular.svg#L6

<font id="glyphicons_halflingsregular" horiz-adv-x="1200" >

However, in css, it is linked like so:

https://github.com/twbs/bootstrap/blob/master/less/glyphicons.less#L17

~"url('@{icon-font-path}@{icon-font-name}.svg#glyphicons-halflingsregular') format('svg')";

When you disable all fonts but the svg variant, it displays in Safari 7 as little boxes. When you change the reference to an underscore, it displays fine in safari:

~"url('@{icon-font-path}@{icon-font-name}.svg#glyphicons_halflingsregular') format('svg')";

Issue 2:
https://github.com/twbs/bootstrap/blob/master/less/glyphicons.less#L17

This font face declaration is setup to reference the font name as a variable.

However the SVG font ID after the hash is hard coded.

Though this is not really an issue it could later become a problem if the font name and SVG font ID changes, and only the variable is updated and not properly tested.

Will submit a PR that uses a new variable @icon-font-svg-id

Edit *

Further more the font icon ID is incorrect

https://github.com/twbs/bootstrap/blob/master/less/glyphicons.less#L17

https://github.com/twbs/bootstrap/blob/master/fonts/glyphicons-halflings-regular.svg#L6

glyphicons_halflingsregular vs glyphicons-halflingsregular
Issue 1:
OS Version: Windows10

VSCode version: 0.10.12-alpha

Steps:

launch app and open a folder which contain .TS file.

Verify any error message is showing up.

Expected: If there is not extensions installed for TS lint then error should not be highlighted in editor.

Actual:

While verifying bug #4107 with "Express Node.js typescript" project. I observed that there are two error messages showing up in my .ts file and when I closely watched, I found there is no extension installed for TS lint. I also removed extension for ESlint as well and restarted app.

I observer that still it is showing two errors messages in the editor and when I hover over on it, it is displaying :

[ts] cannot find module 'http'

[ts] Cannot find name process.

But when I clicked on error icon from the status bar then could see in the pop-up (in command palette) it is showing up duplicate error message like below.

Questions:

When there is no linter installed for TS or ES then why it is displaying red mark in the code.

Is there any reference left for the TSLint in the system after removing extension which is causing this issue.

I also verified in the extension directory and didn't find any reference of TS or ES lint extension.

Issue 2:
VSCode Version: 1.2.0

OS Version: OS X el capitan

Steps to Reproduce:

scroll to the bottom of an editor, so that the last line is aligned with the bottom of the editor

notice that the scroll bar position indicator is not at the bottom of the scroll bar

Expected behavior:

the scroll bar position is mapped to the full length of the file without the overflow that allows scrolling further.

the dark scroll position that indicates the beginning and the end of the page shrinks as you scroll beyond the end of the file
Issue 1:
Consider wanting to create a <paper-button> component that can use attributes or properties:

Attribute-based configuration:

<!-- Will always be disabled -->
<paper-button disabled>Save</button>

Property-based configuration:

<!-- Will be conditionally disabled -->
<paper-button [disabled]="isDisabled">Save</paper-button>

Good news is this works today. Bad news is that it requires a little non-intuitive massaging, and could be a lot cleaner for Angular component authors.

For example, here's today's utility functions:

// Utility functions shared among component authors.
dynamic getDynamic(inputValue, {defaultValue, onString(String strValue)}) {
if (inputValue == null) {
return defaultValue;
} else if (inputValue is String) {
return onString(inputValue);
} else {
return inputValue;
}
}

bool getBool(
inputValue, {
bool defaultValue: false,
bool onString(String strValue)}) {
if (inputValue is String && onString == null) {
return _parseBool(inputValue, defaultValue);
}
return getDynamic(
inputValue,
defaultValue: defaultValue,
onString: onString);
}

And the property setter itself:

// The component itself
bool _disabled = false;
void set disabled(value) {
_disabled = getBool(value);
}

Proposal

Have an alternative/Angular framework assisted way of doing this. Maybe annotation-based:

@Attribute.onNull(false)
void set disabled(bool disabled) {
_disabled = disabled;
}

I realize this could be done using pipes, but the following is needed:

Register a pipe that may or may not be used

Inject PipeRegstry

Create a transformer from the registry

Use the transformer on the property setter

This could be a lot cleaner/simpler, and is more natural with native/web components.

(Slightly related to #2869)

Issue 2:
Say I have a component that needs to know about its disabled state in some event:

@Component({
selector: '[md-button][href]',
bind: {disabled: 'disabled'}
})
class MdAnchor {
onClick(event) {
// Disabled anchors don't navigate anywhere.
if (this.disabled) {
event.preventDefault();
}
}
}

This will work fine if we have something like

<a md-button href="http://google.com" [disabled]="isDisabled()">Google</a>

However, if you instead do

<a md-button href="http://google.com" disabled>Google</a>

This code will not work, as this.disabled will be the empty string. I would have to update the value in onChange:

onChange() {
this.disabled = this.disabled || this.disabled == '';
}

or always use a method:

isDisabled() {
return this.disabled || this.disabled == '';
}

TL;DR: Change detection will set disabled to the empty string, which is falsy, but still implies disabled state.
Issue 1:
I have this wired bug since I update from v0.15 to v2.4.4.

This is my classes:

class ParentClass {
constructor() {}
}

// This is my ChildClass
class ChildClass extends ParentClass {
constructor() {
super();
}
}

Compiles to:

"use strict";

var _inherits = function (child, parent) {
child.prototype = Object.create(parent && parent.prototype, {
constructor: {
value: child,
enumerable: false,
writable: true,
configurable: true
}
});
if (parent) child.__proto__ = parent;
};

var ParentClass = function ParentClass() {};

// This is my ChildClass
var ChildClass = (function () {
// This is my ChildClassvar _ParentClass = ParentClass;
var ChildClass = function ChildClass() {
_ParentClass.call(this);
};

_inherits(ChildClass, _ParentClass);

return ChildClass;
})();

You can see the comment // This is my ChildClass is duplicate and break the definition of var _ParentClass = ParentClass;:

ReferenceError: _ParentClass is not defined

Quick fix: turning off comment in format option.

Issue 2:
Issue originally made by @SimenB

Bug information

Babel version: 6.3.13

Node version: 4.2.3

npm version: 3.5.2

Input code

import meep from 'meep';

meep('meep');

Description

The default keyword is not wrapped in quotes. It's wrapped correctly in the _interopRequireDefault-function, but usage is not wrapped (it's (0, _meep2.default) instead of (0, _meep2['default']))

I'm unsure which of es3-member-expression-literals and es3-property-literals should add the quotes.

I created a gist reproducing the problem: https://gist.github.com/SimenB/0b84772c01305e5485f3