WhereIsAI/github-issue-similarity huggingface dataset:
Issue 1:
VSCode Version: 0.10.11

OS Version: OS X 10.11.5

Steps to Reproduce:

Open a file and change the language and/or indentation type.

Close the window.

Reopen the window.

The file will be loaded again but it will have the default language and indentation type.

Issue 2:
i have yaml in .controller, .asset etc files

%YAML 1.1
%TAG !u! tag:unity3d.com,2011:

when i open the file it does not detect it is yaml and sets it to plain text mode?

i can choose yaml from the language mode selector (to get nice coloring) but then i get an error on that first yaml 1.1 line

Expected a JSON object, array or literal

should it auto detect? or is there a way to associate files with languages? (no, see link below)

how to fix error?

thanks

https://code.visualstudio.com/docs/languages/overview

Q: Can I map additional file extensions to a language?

A: Currently this is not supported but it's on the way.
Issue 1:
As reported to matplotlib.users, passing duplicate points to tricontour can cause it to hang. Here is a minimal example:

import matplotlib.pyplot as plt
import matplotlib.tri as tri
import numpy as np
from numpy.random import uniform, seed

seed(0)
npts = 7
x = uniform(-2,2,npts)
y = uniform(-2,2,npts)
z = x*np.exp(-x**2-y**2)

y[1:2] = y[0] # Duplicate points make tricontour hang!
x[1:2] = x[0]
triang = tri.Triangulation(x, y)
plt.triplot(triang)
plt.tricontour(triang, z, 15, linewidths=0.5, colors='k')
plt.show()

Issue 2:
Plotting with markeredgecolor="none" causes markers to not display (probably fully transparent) in current master 1.5.x. It might be related to this pull request. The plot in Out[3] below does not show anything. In matplotlib 1.4 it displays markers as expected.

~/matplotlib (master)$ ipython
Python 2.7.6 (default, Aug 25 2014, 18:32:19)
Type "copyright", "credits" or "license" for more information.

IPython 2.2.0 -- An enhanced Interactive Python.
? -> Introduction and overview of IPython's features.
%quickref -> Quick reference.
help -> Python's own help system.
object? -> Details about 'object', use 'object??' for extra details.

In [1]: %matplotlib
Using matplotlib backend: TkAgg

In [2]: import matplotlib; import matplotlib.pyplot as plt; import numpy as np

In [3]: plt.plot(np.arange(3), 'ro', mec='none')
Out[3]: [<matplotlib.lines.Line2D at 0x4171610>]

In [4]: matplotlib
Out[4]: <module 'matplotlib' from '/apps/stonefs1/azhu/venv/el5-stonelib/lib/python2.7/site-packages/matplotlib-1.5.x-py2.7-linux-x86_64.egg/matplotlib/__init__.pyc'>

In [5]: matplotlib.__version__
Out[5]: '1.5.x'
Issue 1:
Image loading starts again after scrolling in recyclerView. Can it resume loading or loading in background?

Issue 2:
Me again :)

Got some questions about when images are recycled and how internals works, since I get way more java.lang.RuntimeException: Canvas: trying to use a recycled bitmap than before switching to Glide.

Since I can't reproduce it's hard to find the cause.

Numbers are not very high (5000 crash on more than 7 000 000 screen views per week glide 3.6.0) but high enough for me to investigate.

Most calls are basics :

Glide.with(ctx)
.load(xxx)
.centerCrop()
.animate(R.anim.abc_fade_in)
.error(R.drawable.default_thumb_fanart_misc)
.into(mViewFanart);

Context is sometimes application context to simplify reused code, is there impact of not using fragment / activities ?

The only other call that could trigger is:

.into(new SimpleTarget<Bitmap>() {
@Override
public void onResourceReady(Bitmap bitmap, GlideAnimation<? super Bitmap> glideAnimation) {
if (isAdded() && mViewThumb != null) {
mViewThumb.setImageBitmap(bitmap);
}
}

@Override
public void onLoadFailed(Exception e, Drawable errorDrawable) {
if (isAdded() && mViewThumb != null) {
mViewThumb.setImageDrawable(errorDrawable);
}
}

@Override
public void onLoadCleared(Drawable placeholder) {
super.onLoadCleared(placeholder);
try {
mViewThumb.setImageResource(R.drawable.default_thumb_big);
} catch (Exception ignore) {
}
}
});

But from my understanding of the docs the onLoadCleared that I use should cover this problem.

Any advice / tips on how / what to check to find the root cause ?
Issue 1:
Hi,

I haven't found any way to configure proxy, which makes downloading of packages impossible for me. I'm behind a proxy at my work.

Thanks!

Issue 2:
Noticed two Halp tickets about this so far:

support/a10f96d4b08f11e3934b3dfc0d230d46

support/45b5441aa86911e39c8bef69aceed9d5

Finally, I didn't find any way to set my proxy info in the settings of your app, and I'm not sure you are respecting the proxy settings of the OS. So my first attempt to send feedback failed.

...

I tried to submit this via the built-in feedback but it didn't say it was successful, it seemed to time out just like fetching packages or themes:

Built-in package and theme fetching doesn't work when proxies are required. "Fetching featured packages and themes failed. connect ENETUNREACH". DNS resolves on this corporate network, but connections must use http or https proxies.

Self-updating Atom itself works.

So, it seems that proxy settings are not respected, and it's not possible to set them in Atom.
Issue 1:
Electron version: 4.0.x

Operating system: Windows 7 & macOS 10.14.2

Expected Behavior

The tray menu displays the same speed as normal.

Actual behavior

Windows 7:

It took almost a second to show up.

Almost impossible to display when the number of menus increases.

macOS 10.14.2:

No difference from the normal menu. There is no problem.

To Reproduce

multi-level-menu-for-tray

link issue#16156

Also you can run with the following commands:

$ git clone https://github.com/orangeChu/multi-level-menu-for-tray.git
$ cd multi-level-menu-for-tray
$ npm install
$ npm start || electron .

Issue 2:
electron@3.0.12(It also happens in 4.0.0)

win7 ultimate 64bit

Hi guys,

When I try to create multi-level menu for tray-menu,it worked,but loading speed is too slow.

Example code is below.

main.js

'use strict';
const app = require('electron').app;
const Tray = require('electron').Tray;
const Menu = require('electron').Menu;
const path = require('path');

let tray;
let contextMenu;

class Test {
constructor() {

}

initApp() {
app.on('ready', () => {
this.createTray();
});
}

createTray() {
tray = new Tray(path.join(__dirname, 'icon.png'));
tray.setToolTip('Test');

let childMenu = [];
let submenu = [];
let lastLv = [];

for (let index = 0; index < 5; index++) {
lastLv.push({
label: `lastLv${index}`
});
}

for (let index = 0; index < 10; index++) {
childMenu.push({
label: `childMenu${index}`,
type: 'submenu',
submenu: lastLv
});
}

for (let index = 0; index < 500; index++) {
submenu.push({
label: `menuItem${index}`,
type: 'submenu',
submenu: childMenu
});
}

contextMenu = Menu.buildFromTemplate([{
label: 'test',
type: 'submenu',
submenu
}]);

tray.on('right-click', () => {
//It may be cost 2's or more
tray.popUpContextMenu(contextMenu);
});
}
}

new Test().initApp();
Issue 1:
When I tried to modify the file name of the release version apk through the gradle script, the build failed. This is what I add in build.gradle:

applicationVariants.all { variant ->
variant.outputs.all { output ->
def outputFile = output.outputFile
if (outputFile != null
&& outputFile.name.endsWith('.apk')
&& outputFile.name.contains('-release')) {
outputFileName = "industry_${defaultConfig.versionCode}_v${defaultConfig.versionName}_${new Date().format("yyyyMMdd")}.apk"
}
}
}

flutter doctor:

Doctor summary (to see all details, run flutter doctor -v):
[✓] Flutter (Channel beta, v0.8.2, on Mac OS X 10.13.6 17G65, locale en-CN)
[✓] Android toolchain - develop for Android devices (Android SDK 27.0.3)
[✓] iOS toolchain - develop for iOS devices (Xcode 10.0)
[✓] Android Studio (version 3.1)
[!] IntelliJ IDEA Ultimate Edition (version 2018.2.1)
✗ Flutter plugin not installed; this adds Flutter specific functionality.
[✓] VS Code (version 1.27.1)
[✓] Connected devices (2 available)

Issue 2:
I just tried flutter run and it failed with this message: Gradle build failed to produce an Android package.

Can we print a message like "Please see this log file for more information" ? I'd love to know what to do.

I looked and there's no .log file in my project's root.
Issue 1:
Hi!

I've run into issue when trying to use shadows in my scene that is rendered into two separate viewports (separate scenes, based on http://mrdoob.github.io/three.js/examples/webgl_multiple_views.html). The moment I enable shadowing, shadow map (used only in one scene, one viewport) is corrupted. Please see the image attached. There is only one shadow receiver in the screenshot and no object casting shadows, yet, parts of the ground are suggested as in shadow. When I remove renderer.enableScissorTest(true), shadows are ok (but I lose my other viewport rendering of course).

Can this be done with some workaround?

three.js r58, win7, latest google chrome, latest firefox

Great library btw! Keep up the good work and thanks for any advice!

Regards,

Boris Zapotocky

Issue 2:
Hi,

first of all I love the three.js framework and so I have play arround with it and found something strange and want to know if this is "by design" or if this shouldn't be the case.

You can use te same scene object in multiple CanvasRenderer instances, but not in multiple WebGLRenderer instance.

So for WebGLRenderer you need a dedicated scene for each WebGLRenderer instance.

Example render which is NOT working with WebGLRenderer:

function render() {
mesh1.rotation.x += 0.01;
mesh1.rotation.y += 0.02;
renderer1.render(scene1, camera1);
renderer2.render(scene1, camera1);
}

Example render which is working with WebGLRenderer:

function render() {
mesh1.rotation.x += 0.01;
mesh1.rotation.y += 0.02;
renderer1.render(scene1, camera1);
renderer2.render(scene2, camera1);
}

As I mention both examples are working fine with the CanvasRenderer, it also doesn't matter if I use the same camera or different ones.

Thanks for confirmation and Greetings,

Markus B.
Issue 1:
Hi,

I am a newbie to Elasticsearch, i was going through the code and found lack of Documentation. Because of which lot of confusion about what is happening.

As i am going through the code (fresh eye) will like to add JavaDocs while browsing the code.

Issue 2:
A hosted version of the Javadocs will greatly help out on the mailing-list/forum when trying to point out a class/method to someone. The online documentation is great for illustrating concepts, but something at the class level would also help
Issue 1:
savefig saves cropped images by default.

Bug summary

It's probably an issue that almost everybody who uses matplotlib would have encountered. If you generate a figure - which often contains axis labels and legends - and save it with default settings, you'll get a cropped image.

It's a duplicate of my question on stackoverflow.

Code for reproduction

import matplotlib.pyplot as plt
def plot():
plt.figure(figsize=[3,3],linewidth=5,edgecolor='r')
ax=plt.subplot()
ax.plot(range(10),range(10),label='label')
ax.set_xlabel('xlabel\nxlabel\nxlabel')
ax.set_ylabel('ylabel\nylabel\nylabel')
ax.legend(bbox_to_anchor=[1,1])
plot()
plt.savefig('no_tight_layout.png')

Actual outcome

Expected outcome

If I generate the same plot in a jupyter notebook, without using tight_layout option, I see that all the elements of the plot are contained within the figure boundaries (shown in red).

This figure is generated in the output cell of a jupyter notebook(!).

Then why it is not saved as it is? Why the saved image is by default different from the image jupyter notebook?

In my opinion this is a very fundamental issue with matplotlib.

Would't it make the lives of the users easier, if by default, all the elements are contained in the saved figure without the need of any workarounds?

(Thanks to stackoverflow), we know few workarounds but each has a caveat of its own..

Workaround #1: from within matplotlib: use of tight_layout option.

plot()
plt.savefig('tight_layout.png',bbox_inches='tight')

It works for simple figures.

However, in my experience, it is not reliable option in the case of more complex, multi-panel figures.

tight_layout often fails with errors such as these:

UserWarning: This figure includes Axes that are not compatible with tight_layout, so results might be incorrect.
UserWarning: tight_layout not applied: number of rows in subplot specifications must be multiples of one another.

Workaround #2: from outside of matplotlib: save the image in SVG format and then convert to png. For example using --export-area-drawing option in the inkscape command line UI or "resize to page" option in the inkscape's GUI.

However, in this case you have to depend on external softwares which are difficult to add as dependencies in python packages (currently conda only hosts Windows version of inkscape).

So my question is..

Why doesn't matplotlib save the whole figure by default?

Matplotlib version

Operating system: Ubuntu 18.04

Matplotlib version: 3.1.2 (this is issue reproducible in previous version too.)

Matplotlib backend (print(matplotlib.get_backend())):

Python version: 3.6.5

Jupyter version (if applicable): 1.0

Other libraries:

Issue 2:
Some ideas:

Drop the duplicate "nothing" entries in the marker style combo box (at least present in 1.5.0rc3).

Sort the entries alphabetically.

Add an icon with a representation of the marker/line style.
Issue 1:
Kubelet relies on docker history to get the size of layers for each image, so that it can deduplicate shared layers. This is fine for docker v1.9 or before. For docker 1.10+, docker stops generating a random image ID for each layer, and just uses the content addressable IDs. Except for the top layer, every other layer has a <missing> ID. Kubelet relies on using the image layer IDs as keys, and this affects the calculation of total used space.

======== d023c050c065 ===========
IMAGE CREATED CREATED BY SIZE COMMENT
d023c050c065 7 days ago /bin/sh -c #(nop) ENTRYPOINT &{["/dashboard" 0 B
<missing> 7 days ago /bin/sh -c #(nop) EXPOSE 9090/tcp 0 B
<missing> 7 days ago /bin/sh -c #(nop) ADD dir:6bf26a2727be5df090a 58.65 MB
<missing> 4 months ago /bin/sh -c #(nop) MAINTAINER Piotr Bryk <bryk 0 B
======== 18ea23a675da ===========
IMAGE CREATED CREATED BY SIZE COMMENT
18ea23a675da 2 weeks ago /bin/sh -c #(nop) CMD ["nginx" "-g" "daemon o 0 B
<missing> 2 weeks ago /bin/sh -c #(nop) EXPOSE 443/tcp 80/tcp 0 B
<missing> 2 weeks ago /bin/sh -c ln -sf /dev/stderr /var/log/nginx/ 11 B
<missing> 2 weeks ago /bin/sh -c ln -sf /dev/stdout /var/log/nginx/ 11 B
<missing> 2 weeks ago /bin/sh -c /tmp/build.sh 53.91 MB
<missing> 2 weeks ago /bin/sh -c #(nop) COPY file:bf2b48e7f6cbf1964 8.221 kB
<missing> 7 weeks ago /bin/sh -c #(nop) CMD ["/bin/sh"] 0 B
<missing> 7 weeks ago /bin/sh -c #(nop) ADD file:2df43ffb0761746c1f 56.57 MB

On the other hand, we can get all the layers from inspecting the image, but there is no information about its sizes.

"RootFS": {
"Type": "layers",
"Layers": [
"sha256:5f70bf18a086007016e948b04aed3b82103a36bea41755b6cddfaf10ace3c6ef",
"sha256:4636ee4859c26ceb06787821cbfb166a81ca82db61656ab01ae168d5e7dee664",
"sha256:5f70bf18a086007016e948b04aed3b82103a36bea41755b6cddfaf10ace3c6ef",
"sha256:5f70bf18a086007016e948b04aed3b82103a36bea41755b6cddfaf10ace3c6ef"
]
}

/cc @vishh @ronnielai @Random-Liu

Issue 2:
Followed the README.md for cluster setup with 4 nodes using

$ kubectl scale rc cassandra --replicas=4

Following status command supposed to list all 4-nodes in cluster

$ kubectl exec -ti cassandra -- nodetool status

Instead of 4-nodes, we see just 1-node.

Seems like the "KubernetesSeedProvider" is not doing the needed cluster discovery?
Issue 1:
My project has one root folder with a bunch of related projects in subfolders each with their own git rep attached.

In Xamarin Studio it shows each project/subfolder with a description of which branch each repo is on.. i.e. "master". So instantly I can see each project is its own repo and which branch they are currently set to.

I deliberately avoided git submodules for other reasons.

Is it possible for VSCode to support different subfolders each with their own git repo?

Issue 2:
Right now it doesn't seem possible to opening multiple project folders in the same window which imho is a bit constraining. If you are working on modular modern projects it's a must have to be productive.
Issue 1:
Symfony version(s) affected: master

Description

Routes are not recognized when using one dynamic on one hand, and one with a specified host on the other hand.

How to reproduce

Here is a simple PHPUnit test :

public function testDynamic()
{
$routes = new RouteCollection();
$routes->add('a_host', new Route('/', [], [], [], 'api.example.com'));
$routes->add('a_dot', new Route('/a/{letter}.dot', [], [], [], 'localhost'));
$routes->add('a_dot_any_host', new Route('/b/{letter}.dot'));

$dumper = new PhpMatcherDumper($routes);
eval(substr($dumper->dump(), 5));

$context = new RequestContext();
$urlMatcher = new \ProjectUrlMatcher($context);
$this->assertInternalType('array', $urlMatcher->match('/a/a.dot'));
$this->assertInternalType('array', $urlMatcher->match('/b/a.dot'));
}

The second test will raise a Symfony\Component\Routing\Exception\ResourceNotFoundException.

Possible Solution

I think the host pattern is too greedy in the dynamic host routes compilation and should not match / as well as ., as it was in previous commit.

See https://github.com/symfony/symfony/pull/27511/files#diff-3b72491a9ba1cff58442b845ae837eb3R382

Additional context

The problem occurs if you specify a route with a specified host and the profiler : the exception.css route of the profiler doesn't match...

Issue 2:
Symfony version(s) affected: 4.1.1

Description

We have a URL with a variable that will contain a dot, but that doesn't work under Symfony 4.1.1 any more when there is another route that has a host requirement set.

How to reproduce

Put the following in routes.yaml:

foo:
path: /foo
host: 'foo.example.com'
controller: foo_controller

bar:
path: /bar/{baz}
controller: baz_controller

Try to visit /bar/abc.123

When you remove host: 'foo.example.com' from the foo route it does work.
Issue 1:
Electron version: 0.36.10

Operating system: Windows 8.1 64bit

Hello ! I have just created a simple window which loads an url.

The problem is that while visiting the URL in chrome or any other browser, everything is fine, but when opening it in Electron, it says jQuery is not defined.

The problem comes from here:

<script type="text/javascript" src="https://code.jquery.com/jquery-1.11.3.min.js"></script>
<script type="text/javascript">
// some code using jQuery
</script>

Returning Uncaught ReferenceError: $ is not defined.

if I would set a timeout, everything works. But, wasn't that supposed to happen when async tag is set to true ?

This behaviour looks pretty much like async="true" on script tags.

I have also tried setting that async tag to false but still, same behaviour.

I decided not to use a local index.html file that would contain a webview because of the white background that appears, and then, the did-finish-loading which gets triggered when the local page loads but not the webview ( which is to be expected )

Therefore I am running the app like the following window.loadURL('https://tribul.net');

Is it an expected behaviour ?

Issue 2:
jQuery contains something along this lines:

if ( typeof module === "object" && typeof module.exports === "object" ) {
// set jQuery in `module`
} else {
// set jQuery in `window`
}

module is defined, even in the browser-side scripts. This causes jQuery to ignore the window object and use module, so the other scripts won't find $ nor jQuery in global scope..

I am not sure if this is a jQuery or atom-shell bug, but I wanted to put this on the web, so others won't search as long as I did.
Issue 1:
When the same [router-link] is clicked multiple times, multiple history entries are created with the exact same URL. Would it be possible to compare the current URL of the page to the destination URL, and not call pushState if the URL is already correct?

From a user perspective, if I am on page A and click a link to page B, then click the link to page B again, I should only have to press the back button once to get back to page A.

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

[ ] feature request

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

Current behavior

I am using upgrade adapter. When using *ngIf on components angular runs the components outside of zone which causes the GUI not to update.

Expected behavior

I expect the angular component to run in a zone regardless of upgrade adapter (because without it works just fine)

Minimal reproduction of the problem with instructions

zone lost example open the console click on ng2 and you will see that I am logging if in zone ore not. As you can see when using *ngIf we suddenly are outside of zone!

here is example without upgrade adapter which is working and logging in the console that we still are in zone.

zone working

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

It is working without upgrade adapter so it should work in the same way with upgrade adapter.

Please tell us about your environment:

chrome

Angular version: 2.4.1

Browser: [all ]

Language: [ TypeScript]
Issue 1:
Bug Report

Current Behavior

When the value of an enum case references a string case on another enum an unexpected extra key is added to the compiled javascript object. This is especially apparent when the case names do not match.

Input Code

https://bit.ly/2nRTcds

enum Foo {
foo = "foo"
}

enum Baz {
baz = Foo.foo
}

Expected behavior/code

With the code above, I would expect a javascript object that contained one key, "baz", with the value "foo". Instead, "Baz" has two keys, "baz", "foo", with the values, "foo" and "baz" respectively. This does not match what the Typescript compiler produces: https://bit.ly/2nbliQX

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

No special configuration. See the babel REPL link above for the full configuration.

Environment

Babel version(s): v7.6.2

Node/npm version: NA

OS: NA

Monorepo: no

How you are using Babel: repl

Issue 2:
I was looking through the Babel docs, and I don't see a way to specify a different file other than .babelrc for the Babel config.

My use case is I am writing a test runner. A project might use Babel in more than one way. For example, they may transpile their source with some Babel settings, but may transpile their tests with another Babel setting.

So ideally, what I would have in the project root, would be:

project-root/
.babelrc // used by project source
suman.babelrc // used for transpiling tests

my thinking is that when I use babel-cli, I could pass the path to suman.babelrc to babel via the command line, or an env variable, either one.

Is this supported yet? Like I said, had trouble finding out if this is supported. Thanks!