WhereIsAI/github-issue-similarity huggingface dataset:
Issue 1:
Calling pandas.io.sql.read_frame can results in data frame with duplicate column names. For example when SQL query contains joins on tables with duplicate columns.

Data frames with duplicate column names cause errors in many pandas functions. I can't even rename columns as df.columns = new_columns generates errors.

I think correct behavior would be for pandas.io.sql.read_frame have an option to "deduplicate" column names (for example by adding a number) or generate an error with duplicate column names.

Issue 2:
tz naive case:

index = pd.Index([23, 26, 30])
dti = pd.DatetimeIndex(['2015-09-23', '2015-09-26', '2015-09-30'])
ser = pd.Series(dti, index=index).reindex(range(23, 31))
df = pd.DataFrame(ser)

>>> ser # for reference
23 2015-09-23
24 NaT
25 NaT
26 2015-09-26
27 NaT
28 NaT
29 NaT
30 2015-09-30
dtype: datetime64[ns]

>>> ser.interpolate()
23 2015-09-23
24 NaT
25 NaT
26 2015-09-26
27 NaT
28 NaT
29 NaT
30 2015-09-30
dtype: datetime64[ns]

>>> df.interpolate()
0
23 2015-09-23
24 NaT
25 NaT
26 2015-09-26
27 NaT
28 NaT
29 NaT
30 2015-09-30

tz-aware case

index = pd.Index([23, 26, 30])
dti = pd.DatetimeIndex(['2015-09-23', '2015-09-26', '2015-09-30'], tz='US/Central')
ser = pd.Series(dti, index=index).reindex(range(23, 31))
df = pd.DataFrame(ser)

>>> ser
23 2015-09-23 00:00:00-05:00
24 NaT
25 NaT
26 2015-09-26 00:00:00-05:00
27 NaT
28 NaT
29 NaT
30 2015-09-30 00:00:00-05:00
dtype: datetime64[ns, US/Central]

>>> ser.interpolate()
23 2015-09-23 00:00:00-05:00
24 NaT
25 NaT
26 2015-09-26 00:00:00-05:00
27 NaT
28 NaT
29 NaT
30 2015-09-30 00:00:00-05:00
dtype: datetime64[ns, US/Central]

>>> df.interpolate()
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
File "/usr/local/lib/python2.7/site-packages/pandas/core/generic.py", line 4738, in interpolate
'object') == len(_maybe_transposed_self.T):
File "/usr/local/lib/python2.7/site-packages/pandas/core/frame.py", line 1909, in transpose
return super(DataFrame, self).transpose(1, 0, **kwargs)
File "/usr/local/lib/python2.7/site-packages/pandas/core/generic.py", line 599, in transpose
new_values = self.values.transpose(axes_numbers)
File "/usr/local/lib/python2.7/site-packages/pandas/core/base.py", line 696, in transpose
nv.validate_transpose(args, kwargs)
File "/usr/local/lib/python2.7/site-packages/pandas/compat/numpy/function.py", line 54, in __call__
self.defaults)
File "/usr/local/lib/python2.7/site-packages/pandas/util/_validators.py", line 218, in validate_args_and_kwargs
validate_kwargs(fname, kwargs, compat_args)
File "/usr/local/lib/python2.7/site-packages/pandas/util/_validators.py", line 157, in validate_kwargs
_check_for_default_values(fname, kwds, compat_args)
File "/usr/local/lib/python2.7/site-packages/pandas/util/_validators.py", line 69, in _check_for_default_values
format(fname=fname, arg=key)))
ValueError: the 'axes' parameter is not supported in the pandas implementation of transpose()

The ValueError for the DataFrame case is in issue #19198.
Issue 1:
Brought to mind by the message from DevMode which tells you that you can use ProdMode but doesn't tell you why or how. Nor do I think it should. I think it should have a link.

A1 has links which is great! Also helped with size of the production version I'm sure. Let's do that in A2 too!

Issue 2:
I'm submitting a ... (check one with "x")

[x] bug report
[x] feature request
[ ] support request

Current behavior

Suppose we have such an input:

<input #nativeControl #ngControl="ngModel" type="number" min="30">

Now if we enter 25 in that box, the ngControl.valid property will be true, while nativeControl.validity.valid will be false and nativeControl.validity.rangeUnderflow will be true.

Moreover, if we enter invalid characters (e.g. only dashes) in such a field, ngControl.valid property will be true. At the same time, nativeControl.validity.valid will be false and nativeControl.validity.badInput will be true;

Another example: <input type="email"> is not validated by Angular (i.e. is always valid), while HTML5 validation correctly sets ValidityState.typeMismatch to true (and ValidityState.valid to false) if invalid email address is entered.

Currently I'm testing this with chrome but I don't think there will be any differences with other browsers. They all implement HTML5 validation pretty much without any issues.

Expected behavior

I think HTML5 standard already implements validation mechanism pretty well. Please view https://developer.mozilla.org/en-US/docs/Web/Guide/HTML/HTML5/Constraint_validation and https://developer.mozilla.org/en-US/docs/Web/API/ValidityState for example. I think Angular should either emulate, or even directly depend on that mechanism (ValidityState values defined by HTML5).

Yes I know one can implement custom validator in angular and basically emulate anything, but... I think I'd rather have <input type="email"> validation out of the box, rather than to reinvent the wheel and write new validator just for email checking.

[EDIT] Minimal reproduction of the problem with instructions

Please view an example: http://plnkr.co/edit/5pzh5pV2ExF3vKGhgEtq?p=info

Just enter number in first input, or email in second input, and you will see that Angular's validator does not respect min attribute (of <input type="number">) and also <input type="email"> inputs.

Angular version: 4.0.X

Browser: [all]

Language: [TypeScript 2.X]
Issue 1:
I have hooked up Deno to lint source files on-demand. But there are numerous linting rules which we, as a company, need to ignore. Adding them to every single source file would be highly cumbersome, and undesirable. I will absolutely get push back from developers who will simply refuse to lint their code entirely.

Is it possible to provide a global list of ignore rules for deno lint in the command line, either with an option or file listing the rules to ignore? If not, could this be added? These would have to be ignored for the purpose of reporting unused ignore rules actually embedded in the file.

Currently I have to do a kludge that involves prepending each file to be linted with my global list of directives to ignore, which means (a) that error lines are out by 1 because Deno sees the ignore line as part of the input source, (b) Deno reports a bunch of (ban-unused-ignore) errors, and (c) the reported filename is stdin instead of the actual file being linted (which breaks the editor link to the file & line in error).

Issue 2:
User can enable / disable rules, but not customize the rules denoland/deno#1880 (comment)
Issue 1:
Bug Report

Current Behavior

@babel/plugin-transform-block-scoping (and maybe some other plugin in preset-env) incorrectly renames a FunctionDeclaration in a nested block even though it should behave like a var declaration.

Input Code

REPL

if(true) {
function run() {
return true;
}
}

function test() {
return run();
}

Note: turning function run() { into var run = function() { behaves correctly.

Expected behavior/code

Same as Input

Actual output

if (true) {
function _run() { // <-------
return true;
}
}

function test() {
return run();
}

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

{
"plugins": ["@babel/plugin-transform-block-scoping"]
}

or

{
"presets": ["@babel/preset-env"]
}

Environment

Babel version(s): 7.4.0

Node/npm version: Node 10

OS: macOS

Monorepo: -

How you are using Babel: via babel-core

Issue 2:
Bug Report

Current behavior

Babel is not able to output the optional chaining operator without first transpiling it.

With a browserslist of: last 2 Chrome versions

ERROR in ./index.js 3:14
Module parse failed: Unexpected token (3:14)
File was processed with these loaders:
* ./node_modules/babel-loader/lib/index.js
You may need an additional loader to handle the result of these loaders.
| (() => {
| const x = 'abc';
> const y = x?.length;
| })();

With a browserslist of: last 2 Chrome versions, IE 11, it succeeds. However the output (as expected) has the optional chaining operator transpiled to

var x = 'abc';
var y = x === null || x === void 0 ? void 0 : x.length;

Input Code

const x = 'abc';
const y = x?.length;

Expected behavior

Babel would succeed even when the browserslist only lists browsers that currently support the optional chaining operator.

Babel Configuration

babel.config.js

module.exports = {
presets: ['@babel/preset-env'],
};

.browserslistrc

last 2 Chrome versions

webpack.config.js

module.exports = {
entry: './index.js',

module: {
rules: [
{
test: /\.js$/,
use: 'babel-loader',
},
],
},
};

index.js

(() => {
const x = 'abc';
const y = x?.length;
})();

Environment

Babel version: v7.11.6

Node/Yarn version: Node 12.18.4/Yarn 1.22.4

OS: Windows 10

Monorepo: No

How you are using Babel: loader

Possible Solution

Additional context

Add any other context about the problem here. Or a screenshot if applicable
Issue 1:
Challenge http://www.freecodecamp.com/challenges/waypoint-build-web-apps-with-expressjs has an issue. Please describe how to reproduce it, and include links to screenshots if possible.

Steps 18 & 19 on this way point:

"session & cookie" and JSON Me are not in the current expressworks steps.

I'd recommend updating the description to simply have the student complete all the steps. PARAM PAM PAM for example, seems like a very useful exercise for the basejumps, but it's not included in the way point steps.

Issue 2:
Challenge http://freecodecamp.com/challenges/waypoint-build-web-apps-with-expressjs has an issue.

Session and Cookie is no longer in expressworks. the two that seem to be the replacement for this are called PARAM PAM PAM and WHAT'S IN QUERY. Also, after Hello World, expressworks has a Static step that helps with the Stylish CSS step done right before the PARAM PAM PAM step. I can create a pull request with the new suggested setup if you guys want. Or if there is something that I am not seeing or the page needs to be setup in a different way please let me know.
Issue 1:
There's a race condition I encountered and fixed when adding the integration spec, but I need to add a unit test around this behavior. See: #1991 (comment)

In this condition, "activate" is called multiple times with the same Instruction instance, which ended up bypassing the reuse check. I might need to refactor to generalize the added behavior.

Issue 2:
Behavior of rerouting during a navigation:

before any components are committed, cancel and start over (recognition, canActivate, or loadResources/resolve) phases

if any components are committed (any phases after load/resolve), then finish current nav before beginning the next
Issue 1:
For regular C# functions, intellisense works as expected:

However, no intellisense shows up for constructors:

Issue 2:
From @mjkkirschner on November 27, 2015 17:33

using Version 0.10.2 (0.10.2) on mac os x 10.11- I'm using one of the unity3d integration plugins (on the unity side) and getting autocomplete/intellisense, but not on the unity engine .dll or other referenced dlls in my projects, when using constructors. I expect to see parameter info for the constructor.

If I hold control over the type I get the first overload with no way to switch to others.

if I press control+ space I get autocomplete window but nothing to do with the constructor

Copied from original issue: microsoft/vscode#757
Issue 1:
D:\code\msys64\home\Tony\julia\test>..\usr\bin\julia -e "versioninfo()"
Julia Version 0.3.0-prerelease+2898
Commit f2b3192* (2014-05-05 18:19 UTC)
Platform Info:
System: Windows (x86_64-w64-mingw32)
CPU: Intel(R) Core(TM) i7-2630QM CPU @ 2.00GHz
WORD_SIZE: 64
BLAS: libopenblas (USE64BITINT DYNAMIC_ARCH NO_AFFINITY)
LAPACK: libopenblas
LIBM: libopenlibm
blas_num_threads=8

D:\code\msys64\home\Tony\julia\test>..\usr\bin\julia runtests.jl linalg2
* linalg2
LLVM ERROR: Program used external function 'ldexpf' which could not be resolved!

Stack dump:
0. Running pass 'X86 Machine Code Emitter' on function '@julia_givensAlgori
thm19933'
blas_num_threads=8

According to bisect,

f2b3192eb2e59dd34e1e2838036a13167410814f is the first bad commit
commit f2b3192eb2e59dd34e1e2838036a13167410814f
Author: Jeff Bezanson <jeff.bezanson@gmail.com>
Date: Mon May 5 14:19:23 2014 -0400

use pow, powf instead of powi. fixes #6506

LLVM seems to be able to optimize small constant powers here too.
the pow intrinsic had the same bug as powi.

Did working around one LLVM bug here expose another?

Issue 2:
It'd be great to have shorter syntax for broadcasted setfield! and getfield on arrays of types.

Something like this perhaps

struct Foo
x::Int
end

foos = map(v->Foo(v), 1:3)

foos..x # [1,2,3]
foos..x .= 1
foos..x # [1,1,1]
foos..x = 4:6
foos..x # [4,5,6]

The clash with intervals has been pointed out, but perhaps a special case could be made where the first argument is an array?

Currently the above functionality requires this (there may be better options than these):

map(foo-> foo.x, foos) # [1,2,3]
foreach(foo -> foo.x = 1, foos)
map(foo-> foo.x, foos) # [1,1,1]
foreach((foo, x) -> foo.x = x, foos, 4:6)
map(foo-> foo.x, foos) # [4,5,6]

cc. @Octogonapus
Issue 1:
Very much like OneHotEncoder, but will have a parameter for setting threshold. If a feature value occurs more than the specified threshold, then it will get encoded like OneHotEncoder. Otherwise, feature values occurring fewer than the threshold, they will get encoded into the last bit of the encoded array.

Issue 2:
The OneHotEncoder should have an option to summarize categories that are not frequent - or we should have another transformer to do that beforehand.

Generally having a maximum number of categories or having a minimum frequency per category would make sense as thresholds. This is similar to what we're doing in CountVectorizer but I think common enough for categorical variables that we should explicitly make it easy to do.
Issue 1:
Environment

Windows build number: Microsoft Windows [Version 10.0.19008.1]
Windows Terminal version (if applicable): 0.6.2951.0

Any other software?

Steps to reproduce

Copy a set of lines by marking using mouse and then Ctrl+C. You can also use "copyOnSelect" : true, in the settings.

Open vim and paste using Shift + Insert.

You would be able to see extra newlines after each line of copied text

Expected behavior

You should not be seeing extra newlines when you copy text

Actual behavior

Extra newlines after each line of copied text.

Issue 2:
I've tried WSL2 + docker + Windows Terminal. It's very good for developing.

It will be better if some features in SecureCRT & ConEmu can be introduced,

Save or redirect the output text in the terminal to some file with this feature

The format of the filename can be generated like yyyy-mm-dd_HH_MM_SS.log

(like SecureCRT).

This is very useful while using something like adb logcat etc.

Can change a new file while day changing.

File name has session name (just like SecureCRT & ConEmu
Issue 1:
VSCode Version: 0.10.11

OS Version: win10 x64

I am a python programmer, and I wan't to add indentation guide lines like this:

What should I do? or what plug-ins can achieve this effect?

Thanks a lot

Issue 2:
Hi, is there any chance we can get indent guides (the vertical lines that run down to matching indents). Could not find reference to them anywhere in VS code or the gallery. Thanks - Adolfo
Issue 1:
I'm running Telegram bot and noticed the free memory degradation when running bot for a long time. Firstly, I suspect my code; then I suspect bot and finally I came to requests. :)

I used len(gc.get_objects()) to identify that problem exists. I located the communication routines, then cleared all bot code and comes to the example that raises the count of gc objects on every iteration.

Expected Result

len(gc.get_objects()) should give the same result on every loop iteration

Actual Result

The value of len(gc.get_objects()) increases on every loop iteration.

Test N2
GetObjects len: 27959
Test N3
GetObjects len: 27960
Test N4
GetObjects len: 27961
Test N5
GetObjects len: 27962
Test N6
GetObjects len: 27963
Test N7
GetObjects len: 27964

Reproduction Steps

token = "XXX:XXX"
chat_id = '111'
proxy = {'https':'socks5h://ZZZ'} #You may need proxy to run this in Russia

from time import sleep
import gc, requests

def garbage_info():
res = ""
res += "\nGetObjects len: " + str(len(gc.get_objects()))
return res

def tester():
count = 0
while(True):
sleep(1)
count += 1
msg = "\nTest N{0}".format(count) + garbage_info()
print(msg)

method_url = r'sendMessage'
payload = {'chat_id': str(chat_id), 'text': msg}

request_url = "https://api.telegram.org/bot{0}/{1}".format(token, method_url)
method_name = 'get'

session = requests.session()
req = requests.Request(
method=method_name.upper(),
url=request_url,
params=payload
)
prep = session.prepare_request(req)

settings = session.merge_environment_settings(
prep.url, None, None, None, None)
# prep.url, proxy, None, None, None) #Change the line to enable proxy
send_kwargs = {
'timeout': None,
'allow_redirects': None,
}
send_kwargs.update(settings)
resp = session.send(prep, **send_kwargs)

# For more clean output
gc.collect()

tester()

System Information

{
"chardet": {
"version": "3.0.4"
},
"cryptography": {
"version": "2.3.1"
},
"idna": {
"version": "2.7"
},
"implementation": {
"name": "CPython",
"version": "3.6.6"
},
"platform": {
"release": "4.15.0-36-generic",
"system": "Linux"
},
"pyOpenSSL": {
"openssl_version": "1010009f",
"version": "17.5.0"
},
"requests": {
"version": "2.19.1"
},
"system_ssl": {
"version": "1010007f"
},
"urllib3": {
"version": "1.23"
},
"using_pyopenssl": true
}

Issue 2:
Summary.

Expected Result

Program running normally

Actual Result

Program consuming all ram till stops working

Reproduction Steps

Pseudocode:

def function():
proxies = {
'https': proxy
}
session = requests.Session()
session.headers.update({'User-Agent': 'user - agent'})
try: #
login = session.get(url, proxies=proxies) # HERE IS WHERE MEMORY LEAKS
except: #
return -1 #
return 0

System Information

$ python -m requests.help

{
"chardet": {
"version": "3.0.4"
},
"cryptography": {
"version": ""
},
"idna": {
"version": "2.6"
},
"implementation": {
"name": "CPython",
"version": "3.6.3"
},
"platform": {
"release": "10",
"system": "Windows"
},
"pyOpenSSL": {
"openssl_version": "",
"version": null
},
"requests": {
"version": "2.18.4"
},
"system_ssl": {
"version": "100020bf"
},
"urllib3": {
"version": "1.22"
},
"using_pyopenssl": false
}
Issue 1:
I am using Colab where OpenCV version is 4.1.2 and while trying to do inference of a YOLOv7 model I got following error:

error: OpenCV(4.1.2) /io/opencv/modules/dnn/src/darknet/darknet_io.cpp:554: error: (-212:Parsing error) Unsupported activation: logistic in function 'ReadDarknetFromCfgStream'

And above error came in this line of code net = cv2.dnn.readNet('/content/gdrive/MyDrive/yolov7/yolov7-obj.cfg', '/content/gdrive/MyDrive/yolov7/weights/yolov7-obj_final.weights')

The weight and cfg file can be used from the following official links: https://raw.githubusercontent.com/AlexeyAB/darknet/master/cfg/yolov7-tiny.cfg and https://github.com/AlexeyAB/darknet/releases/download/yolov4/yolov7-tiny.weights

Issue 2:
OpenCV => 4.6.0

Operating System / Platform => Windows 64 Bit

Compiler => Visual Studio 2017

-->

Compiler => ❔

Detailed description

How support to YOLOv7 by onnx format?

https://github.com/WongKinYiu/yolov7
Issue 1:
What is the general sentiment on having the deno-cli crate producing a lib that can be imported by other projects? I think that taking this path would also help making this module lighter - for instance, subproject like the LSP could become a separate crate consuming the deno-cli module, etc.

Issue 2:
I'm working on a project where I'd like to instantiate multiple instances of the full Deno runtime from within Rust code. Because the cli package only provides a binary, that isn't currently possible. I'd like to avoid the inefficiencies of shelling out to multiple separate Deno processes, and instead spin them up in Rust threads.

Adding a [lib] target to Cargo.toml in the cli package would fix this, but it would probably require changes to the package to expose a Rust API with all of the CLI options.
Issue 1:
We're using a custom ShaderMaterial that we clone for each mesh so they can have unique uniforms.

But it turns out that internally UniformsUtils.clone() is called which clones the texture parameter. This means each one counts as unique and gets uploaded to the GPU separately. Not good!

So unless we're going about this the wrong way, it would seem better if texture parameters were copied by reference rather than cloned as hard to see anyone wanting to duplicate the textures like this.

Issue 2:
The description of the .normals attribute in the buffergeometry docs says:

Stores the x, y, and z components of the face or vertex normal vector of each vertex in this geometry.

But as far as I am aware only vertex normals are supported in WebGL.
Issue 1:
nightly build

const x = Math.random() > 0.5 ? 'hey' : 1;
if (typeof x === 'number') {
[].map(() => x + 2); // expected should typecheck, actual no-no-no
}

numbers can't mutate, x holds a number, also it is a constant, constant can't change its value, so ...

Issue 2:
This is a place holder for changes to the type narrowing behavior in TypeScript 2.0:

Generic type parameters are now narrowed

function g<T>(obj: T) {
var t: T;
if (obj instanceof RegExp) {
t = obj; // RegExp is not assignable to T
}
}

See the explanation by @Arnavion in #7719 (comment)

Type narrowing does not work for catprued variables in functions and class expressions

export class Class {
constructor(public p) { }
}

var c: Class | string;
var x: Class;

if (c instanceof Class) {
function inner() {
x = c; // Error, type of c is not narrowed, c is Class | string
}
x = c; // OK, c is Class
}
Issue 1:
google.golang.org/cloud packages are renamed and are available at cloud.google.com/go. google.golang.org/cloud resource is still available but won't be after September 12. More information is been available on our API clients' announce mailing list at https://groups.google.com/forum/#!topic/google-api-go-announce/nXY-DYZGqz8

Issue 2:
The Google Cloud API client libraries for Go are making some breaking changes:

The import paths are changing from google.golang.org/cloud/... to

cloud.google.com/go/.... For example, if your code imports the BigQuery client

it currently reads

import "google.golang.org/cloud/bigquery"

It should be changed to

import "cloud.google.com/go/bigquery"

Client options are also moving, from google.golang.org/cloud to

google.golang.org/api/option. Two have also been renamed:

WithBaseGRPC is now WithGRPCConn

WithBaseHTTP is now WithHTTPClient

The cloud.WithContext and cloud.NewContext methods are gone, as are the

deprecated pubsub and container functions that required them. Use the Client

methods of these packages instead.

You should make these changes before September 12, 2016, when the packages at

google.golang.org/cloud will go away.
Issue 1:
I am trying to build go on IPv6 only machine and seeing following error:

--- FAIL: TestDialTimeout (0.01s)

dial_test.go:108: got error "dial tcp 127.0.0.1:61521: connection reset by peer"; not a timeout

--- FAIL: TestIPv4MulticastListener (0.00s)

multicast_test.go:55: First ListenMulticastUDP on failed: listen udp 224.0.0.254: setsockopt: no such device

FAIL

FAIL net 2.086s

Test should check if IPv4/IPv6 addresses assigned on the machine before starting test.

Issue 2:
http://www.freebsd.org/ipv6/ipv6only.html

Sure, it fails, of course.