WhereIsAI/github-issue-similarity huggingface dataset:
Issue 1:
I just noticed that this:

In [1]: import numpy as np

In [2]: arr = np.zeros((2, 3), dtype=np.int16) + np.int16(3201)

In [3]: arr.T.dot(arr)
Out[3]:
array([[-19966, -19966, -19966],
[-19966, -19966, -19966],
[-19966, -19966, -19966]], dtype=int16)

spits out no warning about integer overflow. Is it possible to generate one?

Issue 2:
Simple demo:

In [1]: np.uint8(0) - np.uint8(1)
RuntimeWarning: overflow encountered in ubyte_scalars
Out[1]: 255

In [2]: np.uint8(0)[...] - np.uint8(1)[...]
Out[2]: 255

Should we even warn at all for unsigned integers?
Issue 1:
Website or app

https://react.dev

Repro steps

Open an incognito tab

visit a react 18 website

try and use dev tools (I'm on 4.27.1)

How often does this bug happen?

Every time

DevTools package (automated)

No response

DevTools version (automated)

No response

Error message (automated)

No response

Error call stack (automated)

No response

Error component stack (automated)

No response

GitHub query string (automated)

No response

Issue 2:
This technically is a feature, a missing one from version 3.

On version 3 you could visualize files locations which was key in finding bugs, me and my team are currently struggling due to this removed feature on version 4.

You should fix this ASAP as it costs a lot of time now.
Issue 1:
Currently there is no way to retrieve function/method parameter names with the reflect package. The only introspection available is for the types of the input and output parameters of a function. The seems to be an exception with the reflect package, since it does offer naming information in most other cases.

When building RPC/API libraries it is useful to be able to retrieve these method parameters names for purposes of runtime schema output, input validation on unstructured data, and possibly some API semantics. There are some alternatives right now:

Parse the source and use code generation to compile this metadata into the running program.

Use structs for all input/output and then use the field names in the structs, along with their tags, for introspection.

Some other considerations:

I understand that this might lead to binary and/or memory size increase due to the additional metadata that might have to be stored. This change might not be ideal this far into the 1.X cycle, but I think it should at least be considered for 2.0.

A fairly straightforward way to do this, that would not break backwards compatibility, would be to add two methods to reflect.Type that would retrieve the In/Out parameter names by Index.

Apologies if this is a duplicate issues. I searched the forums (nuts/dev) and this issue tracker and could not find any previous issues filed on this topic.

Issue 2:
I was hoping

// setInterfaceValue sets an interface value to a concrete value,
// but first it checks that the assignment will succeed.
func setInterfaceValue(ivalue reflect.Value, value reflect.Value) {
if !value.Type().AssignableTo(ivalue.Type()) {
errorf("cannot assign value of type %s to %s", value.Type(), ivalue.Type())
}
ivalue.Set(value)
}

Could be changed to
errorf("%s is not assignable to type %s", value.Type(), ivalue.Type(),
value.Type(), ivalue.Type())

I feel that the documentation on gob could be improved, though from previous discussions
it sounds like there is disagreement on adding examples for interfaces. While perhaps
independently this error seems sufficient, I found it confusing in the set of errors I
encountered while trying to understand how to correctly use the interface encoding, and
I did not fully realize what that meant until I looked at the source to see
reflect.AssignableTo was being used. I feel like changing the wording in this way makes
it more clear that "assign" is being used like in the language of the spec,
and not in a less precise manner.
Issue 1:
Using the latest release, using the SimplePreAuthenticatorInterface as per the docs, results in errors.

Issuing a return null, rather than a return new PreAuthenticatedToken, in createToken() results in a Fatal Error since the AuthenticationProviderManager::authenticate() is expecting a TokenInterface instance. The docs say we can return (filtering URL section) when authentication is not required. Throwing an exception is the only means to exit the method, but, I don't know what others think, using an Exception for this conveys the wrong intention. Also, when used in conjunction with AuthenticationFailureHandlerInterface, throwing an Exception causes the onAuthenticationFailure() method to be called.

In my instance, I'm using it to validate a captch (among other things) on the login screen. I was previously extending UsernamePasswordFormAuthenticationListener to do this, which will cause problems if any other bundle tries to extend the same class. I obviously don't want the captcha to be validated on every page.

What would be the correct Exception to throw from createToken() when we simply don't want to authorize?

Issue 2:
Symfony cookbook entry for Api Key Authentication states that you can return null from SimplePreAuthenticatorInterface::createToken. If you don't want to authenticate at certain url:

public function createToken(Request $request, $providerKey)
{
// set the only URL where we should look for auth information
// and only return the token if we're at that URL
$targetUrl = '/login/check';
if (!$this->httpUtils->checkRequestPath($request, $targetUrl)) {
return;
}

// ...
}

However, when I did it, I got the following error:

Catchable Fatal Error: Argument 1 passed to Symfony\Component\Security\Core\Authentication\AuthenticationProviderManager::authenticate() must be an instance of Symfony\Component\Security\Core\Authentication\Token\TokenInterface, null given

createToken method is called from SimplePreAuthenticationListener and when I examined it, this looked like the part that is problematic:

$token = $this->simpleAuthenticator->createToken($request, $this->providerKey);
$token = $this->authenticationManager->authenticate($token);

So when SimpleAuthenticator returns null, it passes that null to AuthenticationManager::authenticate which doesn't accept nulls:

interface AuthenticationManagerInterface
{
public function authenticate(TokenInterface $token);
}
Issue 1:
I am seeing an issue with the settings part of the installation. Whenever I press Settings to change some of the behaviors of the program, another program (Max 6.0) opens instead of the actual settings.

Environment

Windows build number: [run `[Environment]::OSVersion` for powershell, or `ver` for cmd]
Win32NT 10.0.18362.0 Microsoft Windows NT 10.0.18362.0

Windows Terminal version (if applicable):
0.5.2762.0

Any other software?

Steps to reproduce

Just press the settings button

Expected behavior

To open the settings for Windows Terminal

Actual behavior

Opens another program called Max

Issue 2:
Allow users to specify multiple fontFace options in profiles.json

I use Terminal on numerous machines that may not have all my favorite fonts (hello, Cascadia Code and Fira Code!) installed on them. I'd love to be able to specify multiple fontFace options that Terminal could work through until it finds a valid one. For example, specify "Cascadia Code", "Fira Code", "Consolas" so that it would eventually find a valid system font.

Proposed technical implementation details (optional)

TBD
Issue 1:
ℹ Computer information

Windows build number: 2004

PowerToys version: 0.20

PowerToy module: Settings > KBM

📝 Provide detailed reproduction steps (if any)

Set theme to white on general page

Open remap window on kbm page

✔️ Expected result

Window colour is white.

❌ Actual result

Window colour is black.

Note: My system default is set to black!

📷 Screenshots

NA

Issue 2:
Environment

Windows build number: Microsoft Windows [Version 10.0.18362.356]
PowerToys version: 0.11.0
PowerToy module for which you are reporting the bug (if applicable): Fancy Zones

Steps to reproduce

Use Win + CTRL + <LEFT> or Win + CTRL + <RIGHT> to switch between virtual desktops with Fancy Zones enabled.

Expected behavior

Animation should remain smooth when switching between virtual desktops.

Actual behavior

Animation stutters and lags. Disabling Fancy Zones resolves the problem.

Screenshots
Issue 1:
Current implementation of cputicks on ARM is very low precision which hurts block profile and tracer.

http://gperftools.googlecode.com/svn/trunk/src/base/cycleclock.h

contains lots of goodness, and in particular cputicks implementation for arm:

#elif defined(ARMV3)
#if defined(ARMV6) // V6 is the earliest arch that has a standard cyclecount
uint32 pmccntr;
uint32 pmuseren;
uint32 pmcntenset;
// Read the user mode perf monitor counter access permissions.
asm volatile ("mrc p15, 0, %0, c9, c14, 0" : "=r" (pmuseren));
if (pmuseren & 1) { // Allows reading perfmon counters for user mode code.
asm volatile ("mrc p15, 0, %0, c9, c12, 1" : "=r" (pmcntenset));
if (pmcntenset & 0x80000000ul) { // Is it counting?
asm volatile ("mrc p15, 0, %0, c9, c13, 0" : "=r" (pmccntr));
// The counter is set up to count every 64th cycle
return static_cast<int64>(pmccntr) * 64; // Should optimize to << 6
}
}
#endif

Should consider switching to it.

There is also an impl for power processors.

Issue 2:
Please answer these questions before submitting your issue. Thanks!

What version of Go are you using (go version)?

go version devel +c63dbd8 Thu Mar 10 18:35:10 2016 +0000 linux/ppc64le

Doesn't work on any earlier versions either.

What operating system and processor architecture are you using (go env)?

ppc64le

What did you do?

If possible, provide a recipe for reproducing the error.

A complete runnable program is good.

A link on play.golang.org is best.

go tool objdump a.out

What did you expect to see?

A disassembly of the program.

What did you see instead?

objdump: disassemble a.out: unsupported architecture

I've seen a CL for this from Minux a while ago but haven't seen any recent updates.

If this was started but needs finishing I could help with that.
Issue 1:
https://github.com/JuliaLang/julia/blob/master/doc/manual/embedding.rst

The advice on compiling the test:

gcc -o test -I$JULIA_DIR/include/julia -L$JULIA_DIR/usr/lib -ljulia test.c

is wrong. For a start the directory $JULIA_DIR/include/julia doesn't exist.

This also affects the embedding example https://github.com/JuliaLang/julia/blob/master/examples/embedding.c as the manual page above seems to be the goto advice on how to compile it.

See google user group question.

Issue 2:
I was trying to follow this guide: http://julia.readthedocs.org/en/latest/manual/embedding/. I ran into an error on the first example.

I have the latest prerelease downloaded for OS X from http://julialang.org/downloads/. I have

JULIA_DIR=/Applications/Julia-0.3.0-prerelease-a673e4c4de.app/Contents/Resources/julia

I got the example to compile with

gcc -o test -I$JULIA_DIR/include/julia -L$JULIA_DIR/lib/julia -ljulia test.c, but not with gcc -o test -I$JULIA_DIR/include/julia -L$JULIA_DIR/usr/lib -ljulia test.c as in the guide.

When I ran the test executable, I got an error:

dyld: Library not loaded: @rpath/libjulia.dylib
Referenced from: /Users/stevend2/PythonProjects/ParallelSparseMatMul.jl/./test
Reason: image not found
[1] 2528 trace trap ./test

Any ideas on what's going on? I'd really appreciate your help.
Issue 1:
Do you want to request a feature or report a bug?

Probably neither, but I am stuck with this.

What is the current behavior?

Rendering multiple rows in table that are expanded by the "parent" row is not possible due to not being permitted in and the absence of fragmentation

If the current behavior is a bug, please provide the steps to reproduce and if possible a minimal demo of the problem via https://jsfiddle.net or similar (template: https://jsfiddle.net/reactjs/69z2wepo/).

Here's to get an idea https://jsfiddle.net/69z2wepo/67419/

What is the expected behavior?

This is the expected behaviour, I guess, until Fiber lands. I am just looking for an explanation on how to achieve this.

Which versions of React, and which browser / OS are affected by this issue? Did this work in previous versions of React?

I am on 15.3.2 but probably all pre-fiber versions have this.

Thanks for any help!

Issue 2:
Note from maintainers:

We know this is an issue and we know exactly what set of problem can be solved. We want this too but it is a hard problem with our current architecture. Additional comments expressing desire for this feature are not helpful. Feel free to subscribe to the issue (there's button in the right hand column) but do not comment unless you are adding value to the discussion. "Me too" and "+1" are not valuable, nor are use cases that have already been written in the comments (e.g., we know that you can't put <tr> or <dd> elements with a <div>).

Consider the following:

var ManagePost = React.createClass({

render: function() {
var posts = this.props.posts

var something;
var somethingelse;

var row = posts.map(function(post){
return(
<div>
<div className="col-md-8">
</div>
<div className="cold-md-4">
</div>
</div>
)
});

return (
{row}
);
}

});

If you remove the <div></div> in the map, you get the following error: Adjacent XJS elements must be wrapped in an enclosing tag

it isn't till I re-add the surrounding, and rather pointless, divs that it compiles with out issue. I am running 0.11.1

Is this being addressed? It adds extra, and again - IMO - useless and pointless html to the page, that while harming nothing - looks messy and unprofessional. Maybe I am just doing something wrong, please enlighten me if I am.
Issue 1:
Due to changes in the new version of ffmpeg, OpenCV can't be built with the current Version.

As crackwitz (Moderator) mentioned in my post in the forum:

they (deprecated and) removed the codec member from AVStream recently, in favor of codecpar

Issue 2:
related:

https://forum.opencv.org/t/error-avstream-aka-struct-avstream-has-no-member-named-codec/3506

ffmpeg changed its AVStream structure. in ffmpeg v3.1 (~2016) the codecpar member was introduced to replace codec member. codec has been deprecated since then. it is still available in ffmpeg v4.4 but not in the master branch.

availability is modulated by #define FF_API_LAVF_AVCTX (LIBAVFORMAT_VERSION_MAJOR < 59)

this version was bumped to 59 a month ago in FFmpeg/FFmpeg@85ba17f

OpenCV v4.5.2/master still assumes the existence of the codec member:

opencv/modules/videoio/src/cap_ffmpeg_impl.hpp

Line 606
in
ae4cc40

avcodec_close( video_st->codec );

I've checked issues and pull requests for mentions of codecpar and it seems this hasn't been reported yet.
Issue 1:
This bug is in reference to this style block from forms.less, shown below. In a nutshell, as soon you start typing into an input field with type=email the text and border instantly turn red. The user gets the following experience with that input field:

unfocused and blank - border is black

focused, but still blank - border is red (if required=true)

enters "a" - border and text are red

"a@" - border and text are red

"a@b" - border is blue, text is black

Note that the user still hasn't even finished entering their email address, even if the email address is technically legal according to the RFC. Tested with recent versions of Firefox and Chrome.

The red color is premature and scary. I need more explicit control for when the text (and border) turn red. All of the HTML5 input validation attributes result in similar problems. The rules below are a little too aggressive, in my opinion. Can we make them optional, move them into a js plugin, etc.?

// HTML5 invalid states
// Shares styles with the .control-group.error above
input:focus:invalid,
textarea:focus:invalid,
select:focus:invalid {
color: #b94a48;
border-color: #ee5f5b;
&:focus {
border-color: darken(#ee5f5b, 10%);
@shadow: 0 0 6px lighten(#ee5f5b, 20%);
.box-shadow(@shadow);
}
}

Issue 2:
The title is quite explicit :)

If you define a input type with a tag required, when the user focuses the input, a red border appears even if the user hasn't entered nor did anything.

It's feel like something is wrong but nothing has been done yet.

The normal state should be blue.
Issue 1:
This code:

trait Foo {}

impl Foo {
fn foo(&self) {}
}

generates this error:

impl-dst.rs:3:1: 5:2 error: duplicate definition of type or module `Foo`
impl-dst.rs:3 impl Foo {
impl-dst.rs:4 fn foo(&self) {}
impl-dst.rs:5 }
impl-dst.rs:1:1: 1:13 note: first definition of type or module `Foo` here
impl-dst.rs:1 trait Foo {}
^~~~~~~~~~~~

I couldn't find any existing issue on this, but this is expected to work, right?

Issue 2:
Currently, statics must have a type annotation as doing global type inference to resolve the type is a bad idea. However, this leads to some annoying duplication, especially when defining a static struct instance. For example, from extra::base64:

pub static STANDARD: Config =
Config {char_set: Standard, pad: true, line_length: None};

There's no ambiguity in the type of the RHS, but the LHS must repeat the type anyways.

Would it be possible/reasonable to infer the type of statics from the RHS of the assignment where possible? Things like this would be work:

pub static STANDARD =
Config {char_set: Standard, pad: true, line_length: None};

pub static HELLO = "hello, world!";

pub static HELLO_BYTES = bytes!("hello, world!");

pub static BAR = 18u8;

but

pub static BAZ = 10;

would not since the type isn't specified (or maybe it would resolve to int?). Untyped integer literals and generic types containing them are actually the only things I can think of that would require a type annotation.
Issue 1:
We should be able to get away with using umbrellas and not individual libs to link.

This represents shaking the tree to get rid of the duplication.

That is, I think we can get away with just using one of these:

windowsapp.lib

onecoreuap.lib

onecoreuap_apiset.lib

onecore.lib

onecore_apiset.lib

and none of things like this:

kernel32.lib

gdi32.lib

user32.lib

etc.

This represents someone groveling around common.build.post.props and friends and shaking them out.

Issue 2:
Description of the new feature/enhancement

Proposed technical implementation details (optional)
Issue 1:
Environment

Windows build number: [10.0.18363.900]
PowerToys version: 0.19.0
PowerToy module: PowerToys Run

Steps to reproduce

Use Alt + Tab to switch window.

Do something or not. Seems not to change something, as long it is not alt.

Press Space

Expected behavior

After using Alt+Tab PowerToys should not pop up. Because Alt+Space is the Shortcut.

Actual behavior

PowerToys Run pop up. When click back to the window the next space opens PowerToys Run again. Until you press alt again.

Issue 2:
Environment

Windows build number: [run "ver" at a command prompt]
PowerToys version: 0.19
PowerToy module for which you are reporting the bug (if applicable): PT Run

Steps to reproduce

Remap key from alt-space to win-space

execute shortcut multiple times

Expected behavior

don't have start menu false positive executions

Actual behavior

Lots of start menu executions
Issue 1:
Describe the issue:

When I try this, the result is of 8144 elements

np.arange(0, 81.43, 0.01).shape

(8144,)

But, it should be 8143

See the following counter example:

np.arange(0, 81.45, 0.01).shape

(8145,)

np.arange(0, 81.44, 0.01).shape

(8144,)

np.arange(0, 11.44, 0.01).shape

(1144,)

Reproduce the code example:

import numpy as np
np.arange(0, 81.43, 0.01).shape

np.arange(0, 81.45, 0.01).shape

np.arange(0, 81.44, 0.01).shape

np.arange(0, 11.44, 0.01).shape

Error message:

No response

NumPy/Python version information:

1.20.1 3.8.8 (default, Apr 13 2021, 19:58:26)

[GCC 7.3.0]

Issue 2:
np.arange(begin, begin + n * spacing, spacing) should generate an array [begin, begin + spacing, begin + 2*spacing, ..., begin + (n-1) * spacing].

However in the following example, it generated an array of size (n+1): [begin, begin + spacing, begin + 2*spacing, ..., begin + n * spacing].

An epsilon is needed to generate the expected answer.

np.arange(begin, begin + n*spacing - epsilon, spacing)

Reproducing code example:

import numpy as np
arr = np.arange(125.8,224.8,3)
print(arr)
epsilon = 1e-6
arr = np.arange(125.8,224.8-epsilon,3)
print(arr)

Error message:

arr = np.arange(125.8,224.8,3)

print(arr)

Out[13]:

array([125.8, 128.8, 131.8, 134.8, 137.8, 140.8, 143.8, 146.8, 149.8,

152.8, 155.8, 158.8, 161.8, 164.8, 167.8, 170.8, 173.8, 176.8,

179.8, 182.8, 185.8, 188.8, 191.8, 194.8, 197.8, 200.8, 203.8,

206.8, 209.8, 212.8, 215.8, 218.8, 221.8, 224.8])

epsilon = 1e-6

arr = np.arange(125.8,224.8-epsilon,3)

print(arr)

Out[16]:

array([125.8, 128.8, 131.8, 134.8, 137.8, 140.8, 143.8, 146.8, 149.8,

152.8, 155.8, 158.8, 161.8, 164.8, 167.8, 170.8, 173.8, 176.8,

179.8, 182.8, 185.8, 188.8, 191.8, 194.8, 197.8, 200.8, 203.8,

206.8, 209.8, 212.8, 215.8, 218.8, 221.8])

NumPy/Python version information:

1.20.2 3.8.10 (default, May 19 2021, 13:12:57) [MSC v.1916 64 bit (AMD64)]
Issue 1:
Reproduce:

$ brew install python --framework
$ mkvirtualenv bean -p /usr/local/Cellar/python/2.7.2/Frameworks/Python.framework/Python
$ pip install -U celery-with-beanstalk

Relevent lines from pip.log:

Downloading celery-with-beanstalk-2.4.tar.gz
Downloading from URL http://pypi.python.org/packages/source/c/celery-with-beanstalk/celery-with-beanstalk-2.4.tar.gz#md5=348fe773ee727ab8daeddd5e1339a87d (from http://pypi.python.org/simple/celery-with-beanstalk/)
Running setup.py egg_info for package celery-with-beanstalk
Traceback (most recent call last):
File "<string>", line 14, in <module>
IOError: [Errno 2] No such file or directory: '/Users/glind/venvs/bean/build/celery-with-beanstalk/setup.py'
Complete output from command python setup.py egg_info:
Traceback (most recent call last):

File "<string>", line 14, in <module>

IOError: [Errno 2] No such file or directory: '/Users/glind/venvs/bean/build/celery-with-beanstalk/setup.py'

----------------------------------------
Command python setup.py egg_info failed with error code 1
Exception information:
Traceback (most recent call last):
File "/Users/glind/venvs/bean/lib/python2.7/site-packages/pip-1.0.2-py2.7.egg/pip/basecommand.py", line 126, in main
self.run(options, args)
File "/Users/glind/venvs/bean/lib/python2.7/site-packages/pip-1.0.2-py2.7.egg/pip/commands/install.py", line 223, in run
requirement_set.prepare_files(finder, force_root_egg_info=self.bundle, bundle=self.bundle)
File "/Users/glind/venvs/bean/lib/python2.7/site-packages/pip-1.0.2-py2.7.egg/pip/req.py", line 986, in prepare_files
req_to_install.run_egg_info()
File "/Users/glind/venvs/bean/lib/python2.7/site-packages/pip-1.0.2-py2.7.egg/pip/req.py", line 222, in run_egg_info
command_desc='python setup.py egg_info')
File "/Users/glind/venvs/bean/lib/python2.7/site-packages/pip-1.0.2-py2.7.egg/pip/__init__.py", line 255, in call_subprocess
% (command_desc, proc.returncode))
InstallationError: Command python setup.py egg_info failed with error code 1

ls -1:

(bean)517 glind ~ $ ls -1 /Users/glind/venvs/bean/build/celery-with-beanstalk/
PKG-INFO
README
celery_with_beanstalk.egg-info
pip-egg-info
setup.cfg
tmp6vUV58.py

Issue 2:
Seems like setup.py is missing from the package (there's tmpEiXCu1.py which looks like setup.py)
Issue 1:
Example of Http class on angular.io API calls Observable.map() which doesn't work because RxJs operators aren't included by default and you have to import them manually.

The same thing is described also here http.get(..).map function is not working with alpha 48.

Issue 2:
since I updated to alpha 48, http.get(...).map is no longer working.

EXCEPTION: TypeError: json.map is not a function in [null]

@Injectable()
export class WPService implements IWPService {
baseURL: string = 'http://localhost/wptest/api';
http: Http;
constructor(http: Http) {
this.http = http;
}
GetPosts() {
var query = this.baseURL + '/get_posts/';
return new JsonObject(this.http.get(query));
}
}

@Injectable()
export class JsonObject {
constructor(json: Observable<any>) {
json.map(res => res.json()).map(data => { // <=
for (var entry in data) {
if (data.hasOwnProperty(entry)) {
this[entry] = data[entry];
}
}
}).subscribe();
}
}

when I downgraded to alpha 47, .map worked again. maybe it has something to do with the integrated rxjs