WhereIsAI/github-issue-similarity huggingface dataset:
Issue 1:
Only in 4.x.

Issue 2:
I'm submitting a...

[x] Feature request

Current behavior

Currently, we set the view encapsulation at the component level.

@Component({
selector: 'song-track',
encapsulation: ViewEncapsulation.Native
})

Meaning that if I want to use native Shadow DOM throughout my app, I have to add that bit of configuration to every single component.

Expected behavior

It would be great if I could set it at the module level.

@NgModule({
imports: [...],
declarations: [...],
providers: [
...
{ provide: ViewEncapsulationMode, useValue: ViewEncapsulation.Native },
...
],
bootstrap: [AppComponent]
})
export class AppModule { }

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

Simply to make my life easier and make the framework a bit more friendly to use.
Issue 1:
I have been experimenting with large matrix inversions (have to inverse the whole matrix is my specific case) to check the runtime. It all works well until I tried to inverse a 50000 by 50000 matrix:

In [10]: A = np.eye(50000)

In [11]: A
Out[11]:
array([[ 1., 0., 0., ..., 0., 0., 0.],
[ 0., 1., 0., ..., 0., 0., 0.],
[ 0., 0., 1., ..., 0., 0., 0.],
...,
[ 0., 0., 0., ..., 1., 0., 0.],
[ 0., 0., 0., ..., 0., 1., 0.],
[ 0., 0., 0., ..., 0., 0., 1.]])

In [12]: %time X = np.linalg.inv(A)
CPU times: user 2.95 s, sys: 3.24 s, total: 6.19 s
Wall time: 6.19 s

In [13]: X.shape
Out[13]: (50000, 50000)

In [14]: np.abs(X).sum()
Out[14]: 0.0

The run time of ~6 seconds is very small. But more importantly: I should not have the inv() function to return an all-zero matrix without any error!

Am I missing something here? Is it a result I should be expecting?

About my environment:

Right before running the snippet above, I made sure I had enough RAM:

$ cat /proc/meminfo | grep MemFree
MemFree: 138568436 kB

Running Conda 3.12.0 with:

numpy 1.9.2 py27_p0 [mkl]

OS: Linux seftrtools1 3.16.0-34-generic #47~14.04.1-Ubuntu SMP Fri Apr 10 17:49:16 UTC 2015 x86_64 x86_64 x86_64 GNU/Linux

$ python --version
Python 2.7.6

$ ulimit
unlimited

Issue 2:
Can I revisit this one? @carlkl pointed out that this is a rather significant change in behavior. Previously, for platforms and compilers where double == long double, at Numpy compile time, such as MSVC, this would give npy_longdouble as double. This is useful in the case when we are compiling using Numpy, but with a compiler where it is not true that double == long double. One example is compiling Scipy with mingw-w64, where, by default long double is Float80. Could y'all say more about why this change is needed? Why do we need to force npy_longdouble to be the compiler long double, rather than Numpy long double?

Originally posted by @matthew-brett in #20206 (comment)

Also pinging @seiko2plus, @mattip, and since it seems faintly C++ related @serge-sans-paille
Issue 1:
Bug report

What is the current behavior?

Two entries and common chunk (see the linked repo for more details):

index1 - imports dep1 which imports dep2. actually uses both of them

index2 - imports dep1 but only uses a function that does not depend on dep2

commons - contains everything that is used by more than one entry

The issue is that dep2 is detected only as required only for index1 (since index2 does not actually use it). By itself that is kind of fine - when loading commons+index1, everything works, because dep2 is loaded from index1 chunk.

However when loading index2, fails with runtime error due to the fact that in commons chunk, dep1 still lists dep2 as dependency - but it is not included in either commons or index2.

If the current behavior is a bug, please provide the steps to reproduce.

https://github.com/Knagis/webpack-concat-issue/tree/commons-error

What is the expected behavior?

no runtime errors (either dep2 is included in commons chunk or it is loaded only when calling the function that uses it or various other combinations of moving/splitting the modules so that it works for both entries)

Other relevant information:

webpack version: 5.1.3

Node.js version: 12.13.1

Operating System: Win10

Additional tools:

Issue 2:
Bug report

What is the current behavior?

when the first request, only add one(the very last one import css/less file) to the html, cause the page style error

example

index.jsx(entry):

import 'styles/my.less';

import 'styles/index.less';

expected html

<style>{my.less content}</style>
<style>{index.less content}</style>

first request result html

<style>{index.less content}</style>

second or more request result html

<style>{my.less content}</style>
<style>{index.less content}</style>

bug reason

style-loader will check the module.id and then use it to identify and add dom to html, but during the first request, the hot module is missing the id property, so cause the error

a simple solution

If the current behavior is a bug, please provide the steps to reproduce.

What is the expected behavior?

Other relevant information:

webpack version: v5.72.0

Node.js version: v12.19.2

Operating System: macOS

Additional tools:

style-loader@3.3.1
Issue 1:
Before filing a bug, please check whether it has been fixed since
the latest release: run "hg pull", "hg update default", rebuild, and
retry
what you did to
reproduce the problem. Thanks.

What steps will reproduce the problem?
1. Checkout the latest version of the Go code
2. Try to build a simple Hello World application:

package main

import "fmt"

func main() {
fmt.Println("Hello")
}

What is the expected output?
The expected output is that Go will build the application.

What do you see instead?
The error: mkdir C:\Users\lmauldin\AppData\Local\Temp\go-build862896274\local\c:: The
filename, directory name, or volume label syntax is incorrect.

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

Which operating system are you using?
Windows 7 X64

Which revision are you using? (hg identify)
50adb6a9e76c tip

Please provide any additional information below.
I think the latest changes to the Go cmd caused the problem because this was working
correctly yesterday morning (03/01/2012).

Issue 2:
With the following code:

package main

/*
#include <stdlib.h>
typedef void (*destructor)(void*);
static void my_func(destructor d, char *p) {
d(p);
}
*/
import "C"

func main() {
C.my_func(C.destructor(C.free), C.CString("test"))
}

I get the following error:

$ go build cgo_bug.go
# command-line-arguments
ld: illegal text-relocation to '_free' in /usr/lib/libpthread.dylib from 'main.init' in /var/folders/07/ks1g8j_n40v01c_gc7bzx_z00000gn/T//go-link-gyr5vG/go.o for architecture x86_64
clang: error: linker command failed with exit code 1 (use -v to see invocation)
/usr/local/opt/go/libexec/pkg/tool/darwin_amd64/6l: running clang failed: unsuccessful exit status 0x100
$ go version
go version default darwin/amd64
Issue 1:
Current switching order is as tab display order, which is useless when opening many tabs.

Other editors uses MRU order to improve it (Intellij IDEA, Sublimetext, VS.net, Windows alt-tab etc..)

It's better to popup an open file list (in MRU order) when do switching (like IntelliJ IDEA / Windows alt-tab does).

Issue 2:
@zcbenz I looked into this one for a while this afternoon and I can't figure it out. Do you think there's any way we could defer setting the value on the hidden input until the editor updates? Setting it directly in the textInput event handler seems to be causing an extra reflow. We certainly have other things to fix in this timeline as well, but I'd like to have one layout event per keystroke. Any ideas?
Issue 1:
struct Net : torch::nn::Module {

Net()

: conv1(torch::nn::Conv2dOptions(1, 20, /kernel_size=/5).stride(1)),

conv2(torch::nn::Conv2dOptions(20, 40, /kernel_size=/5)),

fc1(640, 120),

fc2(120, 10) {

register_module("conv1", conv1);

register_module("conv2", conv2);

register_module("conv2_drop", conv2_drop);

register_module("fc1", fc1);

register_module("fc2", fc2);

}

torch::Tensor forward(torch::Tensor x) {

x = torch::relu(torch::max_pool2d(conv1->forward(x), 2));//(28-5)+1=24,12 x 12 x 10

x = torch::relu(torch::max_pool2d(conv2_drop->forward(conv2->forward(x)), 2));//(12-5)+1=8,4 x 4 x 20

//x = torch::relu(torch::avg_pool2d(conv2_drop->forward(conv2->forward(x)), 2));//(12-5)+1=8,4 x 4 x 20

x = x.view({ -1, 640 });
x = torch::relu(fc1->forward(x));
x = torch::dropout(x, /*p=*/0.5, /*training=*/is_training());
x = fc2->forward(x);
return torch::log_softmax(x, /*dim=*/1);
}
torch::nn::Conv2d conv1;
torch::nn::Conv2d conv2;
torch::nn::Dropout2d conv2_drop;
torch::nn::Linear fc1;
torch::nn::Linear fc2;

};

cc @yf225 @houseroad @spandantiwari @lara-hdr @BowenBao @neginraoof

Issue 2:
🚀 Feature

Having torch onnx feature available through the C++ API.

Motivation

I have some C++ frontend trained models, and I want to export them in onnx format in order to use them in external inference engines.

Pitch

Same API as the python's torch.onnx.export would be enough.

Alternatives

An alternative would be to have easy C++ frontend model import in the python side, but I think this is more related to #16367

cc @BowenBao @neginraoof
Issue 1:
./app/console --version

Symfony version 2.0.0-RC2 - app/dev/debug

Running

./app/console doctrine:generate:crud

Produces this controller:

Issue 2:
When I run:

Ruud@RuudBook:/www/myapp$ ./app/console generate:doctrine:crud

The Entity shortcut name: MyVendorBundle:User

Do you want to generate the "write" actions [no]? yes

Configuration format (yml, xml, php, or annotation) [annotation]:

Routes prefix [/user]:

You are going to generate a CRUD controller for "MyVendorBundle:User"
using the "annotation" format.

Do you confirm generation [yes]?

Generating the CRUD code: OK
Generating the Form code: OK

You can now start using the generated code!

I get this:

<?php

namespace MyVendor\Bundle\Controller;

use Symfony\Bundle\FrameworkBundle\Controller\Controller;
use Sensio\Bundle\FrameworkExtraBundle\Configuration\Method;
use Sensio\Bundle\FrameworkExtraBundle\Configuration\Route;
use Sensio\Bundle\FrameworkExtraBundle\Configuration\Template;
use MyVendor\Bundle\Entity\User;
use MyVendor\Bundle\Form\UserType;

/**
* User controller.
*
* @Route("/user")
*/
class UserController extends Controller
{/www/myapp/vendor/bundles/Sensio/Bundle/GeneratorBundle/Command/../Resources/skeleton/crud/actions/index.php/www/myapp/vendor/bundles/Sensio/Bundle/GeneratorBundle/Command/../Resources/skeleton/crud/actions/show.php/www/myapp/vendor/bundles/Sensio/Bundle/GeneratorBundle/Command/../Resources/skeleton/crud/actions/new.php/www/myapp/vendor/bundles/Sensio/Bundle/GeneratorBundle/Command/../Resources/skeleton/crud/actions/create.php/www/myapp/vendor/bundles/Sensio/Bundle/GeneratorBundle/Command/../Resources/skeleton/crud/actions/edit.php/www/myapp/vendor/bundles/Sensio/Bundle/GeneratorBundle/Command/../Resources/skeleton/crud/actions/update.php/www/myapp/vendor/bundles/Sensio/Bundle/GeneratorBundle/Command/../Resources/skeleton/crud/actions/delete.php
}

I'm using MAMP PHP Version 5.3.5

Am I missing something?

[ I'm using the Standard RC2 release btw ]
Issue 1:
Python 3.6.6 (default, Jul 19 2018, 14:25:17)

[GCC 8.1.1 20180712 (Red Hat 8.1.1-5)] on linux

Type "help", "copyright", "credits" or "license" for more information.

import tensorflow

Illegal instruction (core dumped)

Issue 2:
System information

OS Platform and Distribution (Windows 10):

**TensorFlow installed from :pip3

**TensorFlow version :1.5

**Python version: 2.7.14

**GPU model and memory: Nvidia GT540M 1GB

Describe the problem

On importing tensorflow i get this error. Downgraded to 1.5 still the same error as on the lastest version.

Spyder and Jupyter both result in the same error
Issue 1:
have formatOnType: true

pressing enter on the end of the line does not indent the next line properly, it is not indented at all

I can repro for both TS and JS

Simple snippet to repro. Pressing enter on end of first line I would expect to get indentation

function f() {
};

Works for our insider build so it seems like it is a regression -> important

fyi @alexandrudima @dbaeumer

Issue 2:
I've followed the setup instructions found on https://code.visualstudio.com/updates#vscode to get the Salsa preview working.

Upon enabling Salsa, when pressing Enter to go to a new line; the cursor will always jump to the beginning of the line instead of keeping the indentation level of the line before it, this happens in JavaScript files.

I'm not sure if this was caused solely by Salsa or a combination of other settings. But when turning Salsa off, the indentation works properly again.

Here is my config before adding the Salsa config path.

// Place your settings in this file to overwrite the default settings
{
// Controls the rendering size of tabs in characters. Accepted values: "auto", 2, 4, 6, etc. If set to "auto", the value will be guessed when a file is opened.
"editor.tabSize": 4,
// Controls if the editor will insert spaces for tabs. Accepted values: "auto", true, false. If set to "auto", the value will be guessed when a file is opened.
"editor.insertSpaces": true,
// Controls after how many characters the editor will wrap to the next line. Setting this to 0 turns on viewport width wrapping
"editor.wrappingColumn": 0,
// Controls if the editor should automatically format the line after typing
"editor.formatOnType": true,
// Complete functions with their parameter signature.
"javascript.suggest.useCodeSnippetsOnMethodSuggest": false,
// When enabled, will trim trailing whitespace when you save a file.
"files.trimTrailingWhitespace": true
}
Issue 1:
I have searched the issues of this repository and believe that this is not a duplicate.

I have checked the FAQ of this repository and believe that this is not a duplicate.

Steps to reproduce this issue

Now the travis ci of master branch failed

https://api.travis-ci.org/v3/job/471789633/log.txt

Issue 2:
I have searched the issues of this repository and believe that this is not a duplicate.

I have checked the FAQ of this repository and believe that this is not a duplicate.

Environment

Dubbo version: 2.5.3

Operating System version: centos7

Java version: jdk8

Steps to reproduce this issue

服务发布时，使用kill -15或者kill -9杀死老进程，然后启动服务，dubbo对外服务端口处于Linux系统临时端口范围内；

启动过程中偶尔会报 Address already in use: bind 异常，概率很低；

如果这种问题出现，需要重新发布或者重启下服务，不太友好 :(

问题分析

dubbo服务监听端口处于Linux系统临时端口范围内，从老进程被kill掉，到新进程启动，这段时间内可能该端口已被系统分配给其他进程作为临时端口使用了，导致服务启动不了，本地已验证。（ps：该问题还有可能是其他原因导致，不过暂时没有分析出来）

如何解决：

dubbo对外监听端口不要设置在Linux临时端口范围，或者将Linux临时端口范围设置成不包括服务对外监听端口。

dubbo启动过程中可以对绑定端口做容错处理，该容错功能可默认不启用，启用时如果报了端口被占用异常，可以在原有端口上做自增然后再次尝试。（看了目前dubbo的代码）

ps：可以将端口配置-1让dubbo选择临时端口作为监听端口，不过我们服务目前都是指定固定端口。

因此，dubbo后续是否可以考虑增加一个对端口占用容错的特性呢，谢谢~
Issue 1:
It'd be really useful to be able to convert a .png image to a .jpg at the same time I'm resizing it.

For example, I've been sent a bunch of .png files that I want to stick on a website. Currently, I'm loading them in to PhotoShop, resizing and exporting as JPEGs. It'd save me so much time if I could just right-click > 'Resize pictures', choose the fit dimensions and the output format.

Loving that you've brought PowerToys back! thanks for all the hard work, it's really appreciated.

Issue 2:
Hello,

I took a look at the image resizer feature and found it really interesting, but I was wondering if it could also encode to another format. There are times when you have a bunch of png images that you want to convert to png, to have a lighter file, with or without a resize of the image. I think it could be interesting to add this option. It could simply be a drop list added when you create a new format size, with encode to : [Keep format, png, jpg ...]
Issue 1:
(Updated - my first examples were wrong)

In the following example the document will be deleted:

DELETE testidx
PUT testidx
PUT testidx/doc/_mapping
{
"_ttl":{
"enabled": "true"
}
}

GET testidx/_mapping

PUT testidx/doc/_mapping
{
"_ttl":{
"enabled": "false"
}
}
# _ttl is enabled anyway
GET testidx/_mapping
POST testidx/doc/1
{
"text":"foo",
"_ttl": "10ms"
}

#document will be deleted after a while
GET testidx/doc/1

Issue 2:
When putting a mapping, if there is a conflict in properties, an exception is thrown. However, any conflicts in the other parameters ( eg _all, dynamic etc) are silently ignored.

These should also throw errors.

# [Sat Mar 12 19:38:18 2011] Protocol: http, Server: 127.0.0.1:9200
curl -XPUT 'http://127.0.0.1:9200/foo/'

# [Sat Mar 12 19:38:18 2011] Response:
# {
# "ok" : true,
# "acknowledged" : true
# }

# [Sat Mar 12 19:38:21 2011] Protocol: http, Server: 127.0.0.1:9200
curl -XPUT 'http://127.0.0.1:9200/foo/bar/_mapping' -d '
{
"bar" : {
"_all" : {
"enabled" : 0
},
"dynamic" : 0,
"properties" : {
"text" : {
"type" : "string"
}
}
}
}
'

# [Sat Mar 12 19:38:21 2011] Response:
# {
# "ok" : true,
# "acknowledged" : true
# }

# [Sat Mar 12 19:38:24 2011] Protocol: http, Server: 127.0.0.1:9200
curl -XPUT 'http://127.0.0.1:9200/foo/bar/_mapping' -d '
{
"bar" : {
"_all" : {
"enabled" : 1
},
"dynamic" : 1,
"properties" : {
"text" : {
"type" : "string"
}
}
}
}
'

# [Sat Mar 12 19:38:24 2011] Response:
# {
# "ok" : true,
# "acknowledged" : true
# }
Issue 1:
No nodejs intellisense after latest upgrade 0.10.10 on mac. Also, tab is behaving wrongly. (All extensions removed)

Issue 2:
Extracted from microsoft/vscode#3509.

According to #6807 the default for module type is commonjs. However, in this example without a jsconfig.json then there are no completion proposals:

no jsconfig.json

add a file bar.js:

exports.foo = 3;

add app.js add the following:

var bar = require('./bar');
bar.

There a no completions on bar.

The work around is to add a jsconfig.json that defines the module type to commonjs:

jsconfig.json

{
"compilerOptions": {
"module": "commonjs"
}
}
Issue 1:
Python 2.7.9, scikit-learn 0.16.1

MacBook Pro, 16GB RAM, MacOS 10.10.3

When running the following code in an iPython notebook, it runs for a long time producing no output, and then the iPython kernel crashes and has to restart.

import numpy as np
from sklearn.manifold import TSNE

X = np.random.random((100000, 100))
tsne = TSNE(n_components=2, perplexity=40, learning_rate=100, verbose=2).fit_transform(X)

Running the same code from the command line produces one line of output

[t-SNE] Computing pairwise distances...

and then it dies.

The error is pretty much the same as reported in this older issue. I'll attach a crash log next, but I think it's out of memory because if I reduce the rows of X to 10000, then it runs to completion without error.

Some suggested improvements:

Estimate the memory required to carry out this operation and warn or error out earlier.

Try to recover from OOM errors in libBLAS more gracefully.

If possible, reduce the memory requirements of sklearn.manifold.TSNE or implement out-of-core

Document the memory requirements in sklearn.manifold (and sklearn.decomposition), and perhaps warn about potential OOM errors and what they'll look like to users. You've already nicely documented the runtime complexities of the algorithms but have not documented their space complexities.

Issue 2:
[The bug here is that some BLAS libraries will crash if you pass in > 16 GiB arrays, because they use 32-bit indices internally. The most obvious solution is to break the dot call into multiple calls to dgemm, though there are also other possibilities. Original report follows:]

On python 2.7.8, numpy 1.9.1, on Mac OS X:

import numpy
numpy.random.seed(1)
X = numpy.random.random((50000,100))
numpy.dot(X, X.T)

Results in:

Segmentation fault: 11

Segfault doesn't occur on smaller arrays (e.g. 30000x100 is fine). In case it's useful, some linkage info:

>>> numpy.__config__.show()
atlas_threads_info:
NOT AVAILABLE
blas_opt_info:
extra_link_args = ['-Wl,-framework', '-Wl,Accelerate']
extra_compile_args = ['-msse3', '-DAPPLE_ACCELERATE_SGEMV_PATCH', '-I/System/Library/Frameworks/vecLib.framework/Headers']
define_macros = [('NO_ATLAS_INFO', 3)]
atlas_blas_threads_info:
NOT AVAILABLE
openblas_info:
NOT AVAILABLE
lapack_opt_info:
extra_link_args = ['-Wl,-framework', '-Wl,Accelerate']
extra_compile_args = ['-msse3', '-DAPPLE_ACCELERATE_SGEMV_PATCH']
define_macros = [('NO_ATLAS_INFO', 3)]
openblas_lapack_info:
NOT AVAILABLE
atlas_info:
NOT AVAILABLE
lapack_mkl_info:
NOT AVAILABLE
blas_mkl_info:
NOT AVAILABLE
atlas_blas_info:
NOT AVAILABLE
mkl_info:
NOT AVAILABLE
Issue 1:
System information (version)

OpenCV => 4.6

Operating System / Platform => Fedora 36

Detailed description

After running imshow, using cv2.waitKey(0) does not close the window even after the user closes the pop-up window as the documentation suggests. Rather, the pop-up window of the image closes, but the terminal running the python file never quits. Basically, only closes pop-up, but doesn't quit the script. (since the code is still running the waitKey(0), user cannot exit the file using exit() either)

Steps to reproduce

import cv2

img = cv2.imread("rock.jpg")
cv2.imshow("The Rock", img)
cv2.waitKey(0)
cv2.destroyAllWindows()

Issue 2:
System information (version)

OpenCV => 4.5.3

Operating System / Platform => openSUSE Tumbleweed

Compiler => gcc 11.2

Steps to reproduce

Build OpenCV with Qt backend.

cmake .. -DBUILD_LIST=highgui -DWITH_QT=ON -DWITH_GTK=OFF -DHIGHGUI_ENABLE_PLUGINS=OFF

Run minimal program:

#include <opencv2/highgui.hpp>

int main()
{
cv::Mat img(200, 200, CV_8UC1);
cv::imshow("img", img);
cv::waitKey(0);
}

Close the window though close button, waitKey() does not return.

Issue submission checklist

I report the issue, it's not a question

I checked the problem with documentation, FAQ, open issues,

forum.opencv.org, Stack Overflow, etc and have not found solution

I updated to latest OpenCV version and the issue is still there

There is reproducer code and related data files: videos, images, onnx, etc