WhereIsAI/github-issue-similarity huggingface dataset:
Issue 1:
I think that we should try to implement an official module like the Deno DOM third-party module that includes the DOMParser. The whole part about Deno is to mirror the Browser APIs, but we don't even have an official DOM Parser in the std. I think that this should definitely be in the std as it is something that is in every single browser shipped out of the box. I understand that the deno-dom third party module does include a DOMParser, but there are a couple of issues and if a module were created by Deno, it would be worked on as a community. The author of the module did amazing at starting the project, but we must have one included with Deno. Also, it would make Deno viable for scraping which is very important for a lot of node users. Thank you for your time!

Issue 2:
Similar to other browser globals but recognize this is an ambitious request. If web compatibility is a goal then from my perspective this should be too.

Currently there are only a few options for constructing a DOM on the backend. Some folks are using Chromium/Puppeteer but this is really memory intensive and crummy for places where coldstart performance is important (like AWS Lambda). JSDom has some support for doing this but resolving esmodules mixed with Node require is clunky at best. A first class runtime solution on the backend for Web Components would be extremely useful for those of us that want to render as much of the DOM as possible before sending it to the client.

I think that's a very large audience and a worthwhile goal. Thanks for considering!
Issue 1:
Currently I am implementing some Dropdown component and I have something like this.

return (
<div className={classnames(classes)} tabIndex="-1">
{Children.map(children, this.render_child)}
</div>
)

...

@autobind
render_child(element, index) {
return cloneElement(element, {
key: element.key || index,
selected: this.props.selected,
onClick: this.click_handler
})
}

The business requirement put me in this situation. I created the list of item of the Dropdown component.

// this is using map from some array so I will return an array.
render_menu_item(key) {
if(!key) { //whatever checking
return
}

return (
<MenuItem value={key}>{text}</MenuItem>
)
}

Now, because I use element.key in some case element could be null so give me an error. I propose to remove the null or undefined from the Children.map because then I will be filtering all the time the null values whenever I have this situation.

I understand I can forEach but I think is not the best implementation, in the end you change the map function alright so

Issue 2:
My use case: wrapping all non-empty children into divs.

render() {
return (
<div style={rootStyle} onWheel={this.handleWheel}>
{Children.map(this.props.children, this.wrapChild)}
</div>
);
},

wrapChild(child, index) {
if (!child) { // I know this is probably wrong kind of comparison; don't care
return (
<div style={this.getChildStyle(index)}>
{child}
</div>
);
}
},

This is all nice but I also need to know how many valid children I have wrapped.

Children.count will return the number of children including the “empty” children. I want to strip them out.

Can we have Children.filter?
Issue 1:
under OSX 10.10.3 atom build 0.199.0 if you close all windows then hit atom->preferences the preferences windows does not come up. You have to do it twice.

If using keyboard shortcuts you must hit command+, two times in order to actually get the presences window.

Expected behavior: hit it once and the preferences window comes up. If no windows are currently open then it should not only open a window, but then automatically open preferences.

Issue 2:
Atom: 0.198.0

OSX: 10.10.3

Steps to reproduce:

Open atom

Close all atom windows (shift+cmd+w)

Open preferences (cmd+,)

Expected behavior: new window opened with settings view

Actual behavior: new window opened with new empty file
Issue 1:
I just moved to using 3.0 version of OpenCV. This error seems to follow me. I have treid cleaning the project, moving to 3.1, but I cant seem to figure out what I'm missing:

$ cmake .
-- OpenCV ARCH:
-- OpenCV RUNTIME:
-- OpenCV STATIC: ON
CMake Warning at /Applications/opencv-3.1.0/cmake/OpenCVConfig.cmake:166 (message):
Found OpenCV Windows Pack but it has no binaries compatible with your
configuration.

You should manually point CMake variable OpenCV_DIR to your build of OpenCV
library.
Call Stack (most recent call first):
CMakeLists.txt:10 (find_package)

CMake Error at CMakeLists.txt:10 (find_package):
Found package configuration file:

/Applications/opencv-3.1.0/cmake/OpenCVConfig.cmake

but it set OpenCV_FOUND to FALSE so package "OpenCV" is considered to be
NOT FOUND.

-- Configuring incomplete, errors occurred!

Any tips on tackling this will help. I am building OpenCV on OSX El Capitan. I am not sure if this is a problem with cmake or opencv. Envorinment variables seem to be correct. Thanks!

Issue 2:
System information (version)

OpenCV => 3.4

Operating System / Platform => Windows 64 Bit

Compiler => Visual Studio 2017

Detailed description

I have a problem while writing a video file whose frame size is huge(3840*2160). VideoWriter did not give any error but output file is missing codec information hence producing corrupted file.

Steps to reproduce

bool read_write_video(string video_path, string out_video_path) {
VideoCapture capture(0);
try {
capture.open(video_path);
double dWidth = capture.get(CV_CAP_PROP_FRAME_WIDTH);
double dHeight = capture.get(CV_CAP_PROP_FRAME_HEIGHT);
Size frameSize(static_cast<int>(dWidth), static_cast<int>(dHeight));
double fps = capture.get(CV_CAP_PROP_FPS);
int four_cc = (int)capture.get(CV_CAP_PROP_FOURCC);
if (four_cc <= 0) {
return false;
}
VideoWriter videowriter(out_video_path, four_cc, fps, frameSize, true);
while(capture.isOpened()){
Mat frame;
capture.read(frame);
if (frame.empty()) break;
videowriter.write(frame);
frame.release();
}
videowriter.release();
capture.release();
return true;
}
catch (exception ex) {
return false;
}
}
Issue 1:
Hello!

I am at the Insider Dev Tour in Stockholm, Watching Simon Wåhlin speak right now, would be cool if you could use the opache function without getting text blurred, so you could read whats on the Visual Studio Code, Atom or browser or something like that, that is under the console to easier see what to type from a StackOverflow post, some kind of guide or code that you are working with

Issue 2:
Perhaps I overlooked it browsing through the json file but i didn't see another means to achieve transparency and i'm not a fan of the acrylic effects blurring factor or the fact that it turns off when the window is not selected. The traditional console provides for a static opacity just like in most nix envs, i'd hope it's just a matter of time before it's implemented here?
Issue 1:
Perhaps this isn't really a bug but here goes...feel free to move it if needed.

Maybe It's me being to stupid but I can't for the life of me find out how to remove a single zone from a layout even though I know how to add new ones? Lets say you have three zones vertically distributed as 33%/33%/33% and want to remove one of them to get 66%/33%. I noticed you can make one of the zones overlap another one and get kind of the same result, but not sure if that has any side effects.

Issue 2:
Summary of the new feature/enhancement

There's no way (at least an intuitive one) to delete a splitter. I tried RMB and MMB with Alt/Ctrl/Shift combinations, Delete button and nothing worked. I think there should be an option to do that.
Issue 1:
Tested on Windows 10

Issue 2:
0.10.10 (Feburary build) has a regression is that the following JavaScript keywords are no longer highlighted in the Dark Visual Studio & Light Visual Studio themes:

var let const function get set class interface module namespace

This only affects JavaScript (not TypeScript).

The workaround if to switch to the Dark+ Default and Light+ theme.

Note that there are other colorizing issues open, not caused by this regression: e.g. 'import' and 'from'. See microsoft/TypeScript-TmLanguage#37
Issue 1:
Describe the bug

When importing Spotlights from GLB, their target seems to be reset after page reload, resulting in different lighting / broken scene.

To Reproduce

Steps to reproduce the behavior:

Go to https://threejs.org/editor/

Import World.zip

Note spotlights shining from above

Refresh page

Note spotlights all shining towards (0,0,0)

Expected behavior

Spotlights still work after page reload

Screenshots

After dropping GLB (and turning physical lighting on)

After page reload

Note: it seems that generally, when creating a spotlight the target can't be moved in the threejs editor. Is this expected? Should I open a separate issue for this?

Issue 2:
{
"uuid": "F7A1537F-0DA9-4FC2-9436-1BCC2A930EDA",
"type": "SpotLight",
"castShadow": true,
"matrix": [1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1, 0, 215.52757263183594, -383.2663269042969, 587.3773193359375, 1],
"color": 255,
"intensity": 2,
"distance": 1300,
"angle": 0.3490658503988659,
"decay": 1,
"penumbra": 0
}

this is what I get for the spot light. importing it in 3js editor it looks at the origin.
Issue 1:
After token < auto-complete doesn't really work on .tsx files.

Two examples:

Here I would like to have boolean in the auto-complete list, but only functions are showed, so It only shows Boolean.

Here however I want a React element:

intrinsic types like div work properly 👍

components defined in this module as well 👍

but components imported are not shown in the list 👎

Still, thanks for 1.8, is much better!

Issue 2:
It looks like it's also missing in any other JSX-expression context.
Issue 1:
Sorry about the bug title, I don’t know exactly the best way to phrase it.

Given the following code:

interface A {
(key:'foo'):string;
(key:string):void;
}

interface A1 extends A {
(key:'bar'):string;
}

interface A2 extends A {
(key:'baz'):string;
}

interface B extends A1, A2 {
(key:'blah'):string;
}

var b:B;

b('foo').length; // OK
b('bar').length; // OK
b('baz').length; // Error
b('blah').length; // OK

The resulting list of overloads is:

(key:'blah'):string;
(key:'bar'):string;
(key:'foo'):string;
(key:string):void;
(key:'baz'):string;
(key:'foo'):string;
(key:string):void;

As a result, calling b('baz') resolves to void type since the 4th item in the list is the first one that matches, but this does not match the author’s expectation. Section 7.2 of the spec doesn’t really address the case where multiple inheritance creates an inheritance graph that splits and joins.

The author’s expectation is that the duplicate A superclass overload options would be eliminated so the total overload list would look more like this:

(key:'blah'):string;
(key:'baz'):string;
(key:'bar'):string;
(key:'foo'):string;
(key:string):string;

The expected list above starts with A2, not A1 as the current compiler seems to do, but that part is somewhat less important than the fact that signatures from A are being duplicated in the calculated overload list. At minimum I’d hope that the compiler could reorder the list so that the non-specialized signature in a list of specialized signatures always goes to the bottom.

Thoughts?

Issue 2:
TypeScript Version:

nightly (1.9.0-dev.20160515)

Code

var a: '_RESULT' = '_RESULT';
var b: '__RESULT' = '__RESULT';

Expected behavior:

Both variables are assigned with no errors.

Actual behavior:

a is assigned with no errors, but b reports type mismatch. This happens whenever I use strings tagged with __ (double-underscore) as a prefix.
Issue 1:
Browser Information

Browser Name, Version: Chrome 55

Operating System: Mac OS X 10

Mac Book Pro

Video

http://d.pr/v/9Ggi/qaGt102x

Issue 2:
In all the exercises, we the users are forced to press the enter key before writing any code.

Update:

We have locked the conversation temporarily on this thread to collaborators only, this has been resolved in staging, and will be live soon.

The fix can be confirmed on the beta website.

The workaround currently on production website is:

Press the Enter key on the challenge editor and then proceed with the challenge.

Apologies for the inconvenience meanwhile.

Reach us in the chat room if you need any assistance.
Issue 1:
The easiest way to repro this is with a brand new list of ~100 images. Start the activity, stay at the top of the list, see the top images load quickly. Then quickly scroll to the very bottom of the list and wait for the last few images to load. This takes about a minute for the 4 images in view to load. This only reproduces when using OkHttpUrlLoader.

Logcat output

12-01 18:13:07.454: V/GenericRequest(20821): Got onSizeReady in 0.061036 this: 882211473
12-01 18:13:07.454: V/GenericRequest(20821): finished setup for calling load in 0.183106 this: 882211473
12-01 18:13:07.454: V/GenericRequest(20821): finished onSizeReady in 0.396729 this: 882211473
12-01 18:13:07.454: V/GenericRequest(20821): finished run method in 0.518799 this: 882211473
12-01 18:14:09.285: V/GenericRequest(20821): Resource ready in 61831.054689 size: 2.130157470703125 fromCache: false this: 882211473

Seems like maybe requests are backed up or something? Not being cancelled correctly? If you have any thoughts to what might be going on or some pointers about where to start looking myself that'd be greatly appreciated.

Thanks.

Issue 2:
OkHttp and HttpUrlConnection both trigger strict mode violations when cancel is called on the main thread (See #257, and the TODO in HttpUrlFetcher).
Issue 1:
When resizing the following example to XS size 'C' cell text disappears.

Text won't disappear when using col-xs-11 .

https://gist.github.com/naoro/1b34f7b0b663df7eaf48

It happens both in latest firefox & chrome.

Issue 2:
I'm trying to include input group in navigation bar. It looks fine on large screen. However, when I resize screen to small size it collapses.

Hre is jsfidle file: http://jsfiddle.net/petwho/7wcVJ/5/

(See how it is collapsed when I scale it down)
Issue 1:
Bug Report

Current Behavior

babel is confused about a duplicate declaration when a type is imported and a value with the same name is declared locally. See code below.

Input Code

The following code results in a "Duplicate declaration" error, but is accepted by TypeScript (the compiler). It's because the SomeThing import is a type (for example export interface SomeThing{}), whereas the local const declaration is a value, so the two are not actually in any conflict.

import { SomeThing } from './module';
const SomeThing = 1;

Expected behavior/code

The babel typescript transform should accept the same code as the typescript compiler.

Babel Configuration (.babelrc, package.json, cli command)

module.exports = {
presets: [
"next/babel",
"@zeit/next-typescript/babel"
],
plugins: [
["react-intl", { messagesDir: "./locale/en/messages/" }],
["emotion", { inline: true, autoLabel: true }],
["transform-define", require("./env.js")]
]
};

Environment

Babel version(s): @babel/plugin-syntax-typescript@7.0.0-beta.47

Issue 2:
There's a bug where a variable _ref isn't defined when you declare a generator using a spread.

ES6:

let a = function*(args) {
this.runRoute(...args);
};

Compiled:

"use strict";

var _toArray = function (arr) {
return Array.isArray(arr) ? arr : Array.from(arr);
};

var a = regeneratorRuntime.mark(function callee$0$0(args) {
return regeneratorRuntime.wrap(function callee$0$0$(context$1$0) {
while (1) switch (context$1$0.prev = context$1$0.next) {
case 0:
(_ref = this).runRoute.apply(_ref, _toArray(args)); // _ref is not defined
case 1:
case "end":
return context$1$0.stop();
}
}, callee$0$0, this);
});

You can check it out

I think the requirements to duplicate this bug are the following:

The function must be a generator.

The function must use a spread.

The function must be calling another function on this.

You really just need to add a let _ref = this; sometime before.

For now, I'll just have to write the spread manually:

let a = function*(args) {
this.runRoute.apply(this, args);
};
Issue 1:
I ran into a scenario yesterday that surprised me a bit. I was using an object literal to store some unique keys that I later extracted with a for-in loop. The keys were all numbers, but I quickly ran into a problem at runtime because i had forgotten that JavaScript coerces number type keys to strings for objects.

To wit, given the coercion of keys to strings, I was surprised that this type checked:

var ids: Array<number> = [];
const myCollection = {
0: true,
1: true
};

for (var key in myCollection) {
ids.push(key);
}

console.log(ids); // => ["0", "1"]

Is this expected behavior, or should this throw a compile time warning?

(TSC Version 1.7.5)

Issue 2:
In the following statement,

for (let subscription in this._subscriptions) {
// Do something with subscription
}

The variable subscription is considered type any. Although I'm compiling with noImplicitAny as true, no error is given. Based on the for spec, it seems as if subscription should implicitly be considered string.

Because of this, it's possible to compile with typo functions that will cause errors at runtime.
Issue 1:
Please could you expose handlers for /_next/on-demand-entries-ping requests and /_next/webpack-hmr requests so that an outer server can respond properly during development. If the container matches the pattern then it should be able to route these requests down to next for a valid response.

Issue 2:
Describe the solution you'd like

with-antd-mobile is working but the example allows no custom css/less.

Either add custom css in with-antd-mobile or have with-antd-mobile-less like the one we have on with-antd-less
Issue 1:
Issue Id: 37805625-bfb3-36ca-de37-e04bbd17e7b9
Versions
- 0.10.8
- 149e7a0
- 45d6935
Stack
TypeError: e.text.substr is not a function
at e. (out/vs/workbench/workbench.main.js:40:17379)
at e.doElement (out/vs/workbench/workbench.main.js:38:18496)
at e.li (out/vs/workbench/workbench.main.js:38:17765)
at e.renderMessage (out/vs/workbench/workbench.main.js:40:16633)
at out/vs/workbench/workbench.main.js:40:16382
at Array.forEach (native)
at e. (out/vs/workbench/workbench.main.js:40:16358)
at e.doElement (out/vs/workbench/workbench.main.js:38:18496)
at e.ul (out/vs/workbench/workbench.main.js:38:17641)
at e.renderMessages (out/vs/workbench/workbench.main.js:40:16223)

Issue 2:
The user should be able to make a permanent decision of associating a file extension to a mode. This could work as follows:

user selects clicks on language picker

user clicks on entry to "Permanently associate extension"

user gets asked for the language mode to store

user gets asked to store it in workspace or global settings

change is made and user is informed that settings have been updated and if he wants to review

For this we need a couple of things:

being able to write to workspace settings and not only global settings

finding out if the settings file is currently dirty (if that is true we either abort or update the buffer).

//cc @aeschli
Issue 1:
Describe what you were doing when the bug occurred:

clicked "Ranked" in "Profiler"

Please do not remove the text below this line

DevTools version: 4.2.1-3816ae7c3

Call stack: at chrome-extension://fmkadmapgofadopljbjfkapdkoienihi/build/main.js:40:157108

at Map.forEach ()

at commitIndex (chrome-extension://fmkadmapgofadopljbjfkapdkoienihi/build/main.js:40:157054)

at e.getRankedChartData (chrome-extension://fmkadmapgofadopljbjfkapdkoienihi/build/main.js:40:157577)

at vl (chrome-extension://fmkadmapgofadopljbjfkapdkoienihi/build/main.js:40:314907)

at gi (chrome-extension://fmkadmapgofadopljbjfkapdkoienihi/build/main.js:32:59907)

at jl (chrome-extension://fmkadmapgofadopljbjfkapdkoienihi/build/main.js:32:107381)

at Lc (chrome-extension://fmkadmapgofadopljbjfkapdkoienihi/build/main.js:32:92715)

at Pc (chrome-extension://fmkadmapgofadopljbjfkapdkoienihi/build/main.js:32:92640)

at wc (chrome-extension://fmkadmapgofadopljbjfkapdkoienihi/build/main.js:32:89544)

Component stack: in vl

in div

in div

in div

in wo

in Unknown

in n

in Unknown

in div

in div

in Li

in $e

in dn

in Ca

in Pc

Issue 2:
PLEASE INCLUDE REPRO INSTRUCTIONS AND EXAMPLE CODE

I got this error when I click 'Ranked'.

Please do not remove the text below this line

DevTools version: 4.0.4-3c6a219

Call stack: at chrome-extension://fmkadmapgofadopljbjfkapdkoienihi/build/main.js:11:11441

at Map.forEach ()

at commitIndex (chrome-extension://fmkadmapgofadopljbjfkapdkoienihi/build/main.js:11:11387)

at e.getRankedChartData (chrome-extension://fmkadmapgofadopljbjfkapdkoienihi/build/main.js:11:11920)

at _i (chrome-extension://fmkadmapgofadopljbjfkapdkoienihi/build/main.js:56:277123)

at Ha (chrome-extension://fmkadmapgofadopljbjfkapdkoienihi/build/main.js:43:55890)

at Xl (chrome-extension://fmkadmapgofadopljbjfkapdkoienihi/build/main.js:43:98280)

at Hl (chrome-extension://fmkadmapgofadopljbjfkapdkoienihi/build/main.js:43:84255)

at Fl (chrome-extension://fmkadmapgofadopljbjfkapdkoienihi/build/main.js:43:81285)

at chrome-extension://fmkadmapgofadopljbjfkapdkoienihi/build/main.js:43:25363

Component stack: in _i

in div

in div

in div

in Or

in Unknown

in n

in Unknown

in div

in div

in Ha

in le

in ve

in ko

in Ul
Issue 1:
This code fails to compile:

fn rereborrow(v: &r/int) -> &r/int { &_&_v }

fn main() {}

With error:

test.rs:1:38: 1:42 error: illegal borrow: borrowed value does not live long enough

test.rs:1 fn rereborrow(v: &r/int) -> &r/int { &_&v }

^~~~

test.rs:1:35: 1:44 note: borrowed pointer must be valid for the lifetime &r as defined on the block at 1:35...

test.rs:1 fn rereborrow(v: &r/int) -> &r/int { &&v }

^~~~~~~~~

test.rs:1:35: 1:44 note: ...but borrowed value is only valid for the block at 1:35

test.rs:1 fn rereborrow(v: &r/int) -> &r/int { &&_v }

^~~~~~~~~

error: aborting due to previous error

shell returned 101

Issue 2:
In this test case (src/test/run-pass/region-return-interior-of-option-in-self.rs):

// xfail-test

struct cell<T> {
value: T;
}

struct cells<T> {
vals: ~[option<cell<T>>];
}

impl<T> &cells<T> {
fn get(idx: uint) -> &self/T {
match self.vals[idx] {
some(ref v) => &v.value,
none => fail
}
}
}

fn main() {}

an error is reported. The reason is that the region R for v is inferred to be too narrow, because it doesn't realize R must be as wide as the region for &v.value.
Issue 1:
The README dynamic's graph gif ( e.g dynamic graph ) is still in 0.3 mode and has Variable all over. Considering the recent release, would make sense to update it.

Issue 2:
This GIF (see below) needs to be tweaked a bit:

When I run this code, the first error is:

RuntimeError: element 0 of variables does not require grad and does not have a grad_fn

Looking at the direction of arrows and assuming that we need to calculate the gradient with respect to three variables (prev_h, W_h, W_x), setting requires_grad=True for all four variables raises another error:

RuntimeError: output and gradOutput shapes do not match: output [20 x 1], gradOutput [1 x 20]

So I changed the next_h.backward to next_h.backward(torch.ones(20, 1)). So now the code is:

import torch
from torch.autograd import Variable

x = Variable(torch.randn(1, 10))
prev_h = Variable(torch.randn(1, 20), requires_grad=True)
W_h = Variable(torch.randn(20, 20), requires_grad=True)
W_x = Variable(torch.randn(20, 10), requires_grad=True)

i2h = torch.mm(W_x, x.t())
h2h = torch.mm(W_h, prev_h.t())
next_h = i2h + h2h
next_h = next_h.tanh()

next_h.backward(torch.ones(20, 1))

I am submitting this issue because I don't want this GIF to mislead beginners when learning PyTorch.