sharjeelyunus/github-issues-dataset huggingface dataset:
Repository: godot
Issue: Godot mono - Unable to properly store or retrieve long or ulong types in a Godot.Collections.Dictionary
Labels: bug,topic:dotnet

<!-- Please search existing issues for potential duplicates before filing yours:
https://github.com/godotengine/godot/issues?q=is%3Aissue
-->

**Godot version:**
v3.2.3.stable.mono.official

**OS/device including version:**
Windows 10 Version 10.0.18363 Build 18363

**Issue description:**
After storing a long or a ulong in a dictionary, inspecting the value shows that a truncated or otherwise incorrect value is stored in the dictionary. Trying to convert the value, via `System.Convert.ToInt64(dictionary["key"])`, returns the incorrect value that was stored. Even worse, the incorrect value may be negative, throwing an error when trying to unbox it as an ulong. 

Attempting to unbox the stored object using a cast throws `System.InvalidCastException: Specified cast is not valid.`

**Steps to reproduce:**
1. Create a new Godot.CollectionsDictionary
2. Store a long or ulong in the created dictionary
3. Inspect or print the value from the dictionary, note that the value is incorrect

**Minimal reproduction project:**
[LongULongIssue.zip](https://github.com/godotengine/godot/files/5727687/LongULongIssue.zip)
Repository: pytorch
Issue: Flattening nn.Parameters while maintaining gradients from neural network forward pass
Labels: module: nn,module: optimizer,triaged,enhancement

## 🚀 Feature

Given some neural network `a`, while `a.parameters()` returns a list of Tensors for each parameter in the network, an alternate parameter return `a.parameters_flattened()`, which returns a Nx1 tensor, which shares the same elementwise gradients as the tensors in `a.parameters()`.

## Motivation

When defining custom gradient descent methods and optimizers for networks (like [here](https://arxiv.org/pdf/1905.12103.pdf) its often much easier (and cleaner) to assume the parameters of some network are a Nx1 vector, which then we can perform matrix operations, allowing us to reduce overhead and casework from having the parameters be split up into multiple tensors.

However, if we try to reshape the list of tensors returned by `network.parameters()`, this creates a new computation branch, which does not share gradients with a normal forward pass of the neural network. Is there some way of returning the parameters of the network as a tensor that shares the same gradients as the network parameters?

## Pitch

Basically, in addition to `network.parameters()` returning a list of tensors that represent the weights/tensors of the neural net, I was wondering if there exists something like `network_parameters_flattened()` which contains the same weights, but flattened, which also share the gradient with a forward pass of the network.

## Alternatives

In defining a custom optimizer, which optimizes the weights multiple players, I've just instead used a less efficient representation, where if I just represent a player's parameters as lists of tensors, and map a function over the list whenever I need to add two players parameters together. An idea of this is [here](https://github.com/18jeffreyma/multi_cmd/blob/9c15ec98e123c5e3376e58b85fb3a2c2db1e599f/multi_cmd/cmd_utils.py#L50).

## Additional context

Specifically for the research community in prototyping, I think this would be an extremely feature, but I understand if it might not be possible given how reshaping and concatenation produce new tensors by default.


cc @albanD @mruberry @jbschlosser @vincentqb
Repository: godot
Issue: Editor preview generation causes several minutes of editor stuttering.
Labels: bug,topic:editor



<!-- Please search existing issues for potential duplicates before filing yours:
https://github.com/godotengine/godot/issues?q=is%3Aissue
-->

**Godot version:**
<!-- Specify commit hash if using non-official build. -->
9c3293b844fd5fa524778b519c2e0ce6ff495c19

**OS/device including version:**
<!-- Specify GPU model, drivers, and the backend (GLES2, GLES3, Vulkan) if graphics-related. -->
Win 10

**Issue description:**
<!-- What happened, and what was expected. -->
It appears that when we import textures that are broken into resource atlas regions, there is a lot of stuttering in the editor for sometimes several minutes.  I inspected the usage, and it looks like the spikes in CPU are traced to preview generation.

I don't know if this a regression or old issue, I don't do texture importing very often to notice.  The team's artist will periodically report that editor is sometimes laggy for a long time when she sometimes starts it up.  I've captured it once last week on her machine, and now I encountered it on my machine when merging new character work into my development branch.

Even if it were something heavy, it's supposed to be working in a thread in the background, so not sure why it would seize up and cause such hiccups.

Here are the code paths and their measures.

![devenv_KsLrWfEfDk](https://user-images.githubusercontent.com/13004169/102849288-84588200-441f-11eb-9834-8b3581567d92.png)

![devenv_hGQbFWWk2d](https://user-images.githubusercontent.com/13004169/102849295-86badc00-441f-11eb-8d00-b3fcf060baa4.png)


**Steps to reproduce:**
Has something to do with thumbnail generation.  Might be due to a large texture and with small atlas regions in TRES files.  First speculation is that maybe it's reloading the large source texture over and over again to generate dozens of these small atlas thumbnails.

Using the MRP below should give the results.  May have to clear thumbnails from app data and restart to reproduce it more than once.

**Minimal reproduction project:**
<!-- A small Godot project which reproduces the issue. Drag and drop a zip archive to upload it. -->

This works on my machines, hopefully when starting this project, noticeable stuttering is reproduced.
[Stuttering.zip](https://github.com/godotengine/godot/files/5728903/Stuttering.zip)
Repository: react
Issue: Bug: CSS variables can't be a space character
Labels: Type: Bug,Component: DOM,Status: Unconfirmed

<!--
  Please provide a clear and concise description of what the bug is. Include
  screenshots if needed. Please test using the latest version of the relevant
  React packages to make sure your issue has not already been fixed.
-->

React version: v16/v17

## Steps To Reproduce

1. https://codesandbox.io/s/empty-css-value-jmbfl?file=/src/App.js
2. Notice the "should be black border" has a pink border
3. Dangerously setting inner HTML works because it doesn't go through reacts `trim()` flow
4. I've tracked the suspect code to here https://github.com/facebook/react/blob/6cbb9394d1474e3a728b49dc7f3a11d61a421ce3/packages/react-dom/src/shared/dangerousStyleValue.js#L44

<!--
  Your bug will get fixed much faster if we can run your code and it doesn't
  have dependencies other than React. Issues without reproduction steps or
  code examples may be immediately closed as not actionable.
-->

Link to code example: https://codesandbox.io/s/empty-css-value-jmbfl?file=/src/App.js

<!--
  Please provide a CodeSandbox (https://codesandbox.io/s/new), a link to a
  repository on GitHub, or provide a minimal code example that reproduces the
  problem. You may provide a screenshot of the application if you think it is
  relevant to your bug report. Here are some tips for providing a minimal
  example: https://stackoverflow.com/help/mcve.
-->

## The current behavior

CSS variables have their value trimmed - resulting in `' '` become `''` which then removes the CSS variable from the browser.

![image](https://user-images.githubusercontent.com/6801309/102850783-52bad780-446e-11eb-8cd3-222061febb48.png)

## The expected behavior

The `' '` value should not be trimmed.

![image](https://user-images.githubusercontent.com/6801309/102850909-944b8280-446e-11eb-9a88-9660469faf3e.png)

One potential option is to, for any custom properties that have a space value, don't trim.

```js
if (isCustomProperty && value === ' ') {
   return value;
}

return ('' + value).trim();
```

I'm happy to do the bug fix. I would also love for this to get released on v16.

---

Found a work around:

https://codesandbox.io/s/empty-css-value-forked-g5jud?file=/src/App.js

```js
style={{ "--border-color": "var(--, )" }}
```
Repository: flutter
Issue: Maybe add pointer for Colors.black* documentation to Colors.grey
Labels: framework,f: material design,d: api docs,team-design,triaged-design

I have been unable to lay the Colors.black12 (or any variation of black) on top of a scaffold that has background of Colors.black.. i.e, the Colors.black12 does not show up when layed on top..

also bottomNavigationBar is not able to have a color passed to it when the BottomType is BottomNavigationBarType.shifting,

however when I change it to BottomNavigationBarType.fixed, the color is able to be changed
Repository: pytorch
Issue: Wrong error is raised for property of nn.Module (again)
Labels: module: nn,triaged

## 🐛 Bug

Same as https://github.com/pytorch/pytorch/issues/33934. See there for details. The same issue exists in 1.7.0. 

```py
In [7]: class A(torch.nn.Module):
   ...:     @property
   ...:     def attr(self): return self.c
   ...:
   ...:

In [8]: A().attr
---------------------------------------------------------------------------
ModuleAttributeError                      Traceback (most recent call last)
<ipython-input-8-d29dd47872e1> in <module>
----> 1 A().attr

~/miniconda3/lib/python3.7/site-packages/torch/nn/modules/module.py in __getattr__(self, name)
    777                 return modules[name]
    778         raise ModuleAttributeError("'{}' object has no attribute '{}'".format(
--> 779             type(self).__name__, name))
    780
    781     def __setattr__(self, name: str, value: Union[Tensor, 'Module']) -> None:

ModuleAttributeError: 'A' object has no attribute 'attr'
```



It is totally unfixed because the PR that claims to have fixed it (https://github.com/pytorch/pytorch/pull/34324) uses wrong unit tests (this link points to 1.7.0 branch):
https://github.com/pytorch/pytorch/blob/e85d494707b835c12165976b8442af54b9afcb26/test/test_nn.py#L1065-L1077
The `assertIn`s wouldn't run at all. 

cc @albanD @mruberry @jbschlosser @mpariente @ezyang
Repository: vscode
Issue: Support cancelation in getSession
Labels: feature-request,authentication

<!-- ⚠️⚠️ Do Not Delete This! bug_report_template ⚠️⚠️ -->
<!-- Please read our Rules of Conduct: https://opensource.microsoft.com/codeofconduct/ -->
<!-- Please search existing issues to avoid creating duplicates. -->
<!-- Also please test using the latest insiders build to make sure your issue has not already been fixed: https://code.visualstudio.com/insiders/ -->

<!-- Use Help > Report Issue to prefill these. -->
- VSCode Version: 1.51.1
- OS Version:

Steps to Reproduce:

1. Using the example code github-authentication-sample. Open extension and execute command 'Github authentication example', then a prompt in browser shows
2.close the page
3. In vs code, execute the command again
4. Prompt didn't showup(1.50.1 doesn't have the issue)

<!-- Launch with `code --disable-extensions` to check. -->
Does this issue occur when all extensions are disabled?: Yes
Repository: pytorch
Issue: RandomSampler generator created in every iteration
Labels: module: dataloader,triaged

## 🐛 Bug

In the [`RandomSampler`](https://github.com/pytorch/pytorch/blob/590e7168ed66bc1060a0bff6c35cc1eea86db0ae/torch/utils/data/sampler.py#L73) sampler class, when no generator is provided in the init function, a new generator is created every time the `__iter__` method is called. This is caused because the generator object created is not assigned to `self.generator`. Thus, `self.generator` always remains `None`, and the `generator` object is created in every iteration. This is not desired behavior as it adds extra memory and time requirements unnecessarily.

## Potential Solution

This can be solved by just adding the following line after [this](https://github.com/pytorch/pytorch/blob/590e7168ed66bc1060a0bff6c35cc1eea86db0ae/torch/utils/data/sampler.py#L117) line.
```
self.generator = generator
```
This will assign the newly created generator to `self.generator` so that it can be used in the following iterations, instead of creating a new one again.


cc @SsnL @VitalyFedyunin @ejguan
Repository: godot
Issue: PhysicalBone is delayed if it has not ragdolled parent
Labels: bug,topic:physics

**Godot version:**
3.2.2 stable

**OS/device including version:**
Any


**Issue description:**
If you have ragdoll and some bones are unragdolled and are moving, ragdolled parts are moved behind with a delay. This is not correct physical behavior and not related to air friction.

**Steps to reproduce:**
Create KinematicBody with skeleton and mesh
Make some bones of skeleton ragdolled through skeleton.start_physics_simulation(bones_array)
Move KinematicBody


**Minimal reproduction project:**
Just press "Moving" toggle and look at movement. 

There are joint settings in the left side, however godot 3.2.2 constains bug that makes using .set for PhysicalBone not working, you need to compile godot with this fix in order to use them https://github.com/godotengine/godot/pull/44535 

These sliders on the left are just optional and not related to this exact issue. 

Change PhysicsFPS in project settings to change the delay. Higher PhysicsFPS results in less delay and stretch, while lower PhysicsFPS makes long stretch and delay.

[godot_physics_delay_bug.zip](https://github.com/godotengine/godot/files/5728727/godot_physics_delay_bug.zip)

What to look for. Physical bones are moving without air drag and are delayed.
![image](https://user-images.githubusercontent.com/46406204/102870963-d2d14500-444e-11eb-8e48-1563ecc861a8.png)
Repository: opencv
Issue: Proposal // new image operations // feature distribution and histogram matchings
Labels: feature,category: contrib,effort: few weeks

Dear All,

   together with my colleagues I have been working over this year on two image processing operations `Feature Distribution Matching` and `Histogram Matching` in multiple color spaces for `unsupervised Domain Adaptation (DA)` for object detection. Both methods solely match image statistics between source and target domains. You can find more details about the methods and motivation in our paper [Keep it Simple: Image Statistics Matching for Domain Adaptation](https://arxiv.org/abs/2005.12551) and repository [image-statistics-matching](https://github.com/continental/image-statistics-matching).

   From my point of view, both methods can be widely used as image pre-processing techniques for various purposes. I'm just wondering whether this might be of interest for `OpenCV`, so it would be great to hear your opinion on this.

Thanks in advance for your response!

Best,
Alexey
Repository: godot
Issue: Shader param in AutoLoad scene set to empty if .import directory is missing
Labels: bug,topic:editor,topic:shaders

**Godot version:** 3.2.3 & 3.2.4.beta4

**OS/device including version:** not graphics-related.

**Issue description:**
There is an AutoLoad scene in my project and a shader is attached to one node in the scene. The shader has a `sampler2D` uniform, and the corresponding shader param is set to an image texture.

My project is in a Git repository and the `.import/` directory is ignored. When I open the project after a fresh checkout of the repository, the scene acts as if the shader param is not set.

* The shader param slot shows "empty".
* Reopening the project solves the issue.
* If saving the scene instead of restarting the editor, the shader param is set to empty.

It works fine if the scene is not in AutoLoad. It also works fine if the image is used in a `TextureRect` instead of shader param.

**Steps to reproduce:**
1. Extract the MRP and open the project. `src/Singleton.tscn` shows a white rectangle.
2. Close the project and reopen. The image is shown correctly.
3. Close the project, delete `.import` directory, and reopen. It shows a white rectangle again.

**Minimal reproduction project:** 
[ShaderParam.zip](https://github.com/godotengine/godot/files/5729084/ShaderParam.zip)
Repository: flutter
Issue: Did flutter open Stack-smashing Protection when compling libflutter.so ?
Labels: engine,P2,team-engine,triaged-engine

I did an binary check on libflutter.so.
The result shows x86_64 and arm64-v8a didn't open  Stack-smashing Protection. But  armeabi-v7a ver had open it.
So I want to make sure did you guys open the protection when complie?
For open the protection can add -fstack-protector or -fstack-protector-all flag when complie with GCC. 
![image](https://user-images.githubusercontent.com/16860032/102886243-bbff1280-448f-11eb-9bac-d61198cbac37.png)

Flutter doctor
Doctor summary (to see all details, run flutter doctor -v):
[√] Flutter (Channel stable, v1.17.5, on Microsoft Windows [Version 10.0.18363.720], locale zh-CN)

libflutter.so version is  ee76268252c22f5c11e82a7b87423ca3982e51a7.

If necessary I opend libflutter.so with **IDA PRO** and searched key words **__stack_chk_fail** to find out library is on protect or not.

![image](https://user-images.githubusercontent.com/16860032/102886900-edc4a900-4490-11eb-9386-c979ed67f16f.png)

![image](https://user-images.githubusercontent.com/16860032/102886920-f4ebb700-4490-11eb-8a7c-30007f788ff5.png)
Repository: TypeScript
Issue: Type information lost when passed as object key
Labels: Needs Investigation

**TypeScript Version:**  4.2.0-dev.20201222

<!-- Search terms you tried before logging this (so others can find this issue more easily) -->
**Search Terms:** type information lost

**Code**

js: 

```js
/** @typedef {{ [K in string] : (data: any) => void }} Event */

/**
 * @template {Event} E
 */
function createEventEmitter () {
  /** @type {Set<{ [T in keyof E]: E[T] }>} */
  const events = new Set()

  /**
   * @template {keyof E} T
   *
   * @param {T} event event register to
   * @param {E[T]} listener listener to register
   */
  function on (event, listener) {
    events.add({ [event]: listener })
  }

  return { on }
}

module.exports = { createEventEmitter }
```

ts:

```ts
type Event = { [K in string] : (data: any) => void }

export function createEventEmitter<E extends Event> () {
  const events: Set<{ [T in keyof E]: E[T] }> = new Set()

  function on<T extends keyof E> (event: T, listener: E[T]) {
    events.add({ [event]: listener })
  }

  return { on }
}

```

**Expected behavior:**
No errors

**Actual behavior:**
In function `on` variable `event` has type `T extends keyof E`, but `add` operation shows an error

![изображение](https://user-images.githubusercontent.com/24425566/102889032-500eb100-4473-11eb-90fa-1170089a5b57.png)


**Related Issues:** <!-- Did you find other bugs that looked similar? -->
https://github.com/microsoft/TypeScript/issues/42060
Repository: TypeScript
Issue: Generic type param not narrowed in true branch of conditional type
Labels: Needs Investigation,Rescheduled

<!-- 🚨 STOP 🚨 STOP 🚨 STOP 🚨

Half of all issues filed here are duplicates, answered in the FAQ, or not appropriate for the bug tracker. Even if you think you've found a *bug*, please read the FAQ first, especially the Common "Bugs" That Aren't Bugs section!

Please help us by doing the following steps before logging an issue:
  * Search: https://github.com/Microsoft/TypeScript/search?type=Issues
  * Read the FAQ: https://github.com/Microsoft/TypeScript/wiki/FAQ

Please fill in the *entire* template below.
-->

<!--
Please try to reproduce the issue with the latest published version. It may have already been fixed.
For npm: `typescript@next`
This is also the 'Nightly' version in the playground: http://www.typescriptlang.org/play/?ts=Nightly
-->
**TypeScript Version:**  4.1.2

<!-- Search terms you tried before logging this (so others can find this issue more easily) -->
**Search Terms:** conditional type true branch generic narrowing

**Code**

```ts
type Num = 0 | 1 | 2
type Chr = 'a' | 'b' | 'c'

type Unit = Num | Chr

type NumCommand = 'add' | 'invert'
type ChrCommand = 'concat' | 'toLower'

type Command<U extends Unit> =
  U extends Num ? NumCommand :
  U extends Chr ? ChrCommand :
  never

type NumCommandData<C extends NumCommand> =
  C extends 'add' ? { otherNum: Num } :
  never

type ChrCommandData<C extends ChrCommand> =
  C extends 'concat' ? { otherChr: Chr } :
  never

type CommandData<U extends Unit, C extends Command<U>> =
  U extends Num ? NumCommandData<C> :
  U extends Chr ? ChrCommandData<C> :
  never
```

**Expected behavior:** in `CommandData` we are narrowing the generic parameter `U` using a conditional type, so in the true branch of the conditional `C` should also be "narrowed" (not sure if that's the correct term in this case) to the specific command type that depends on U.

**Actual behavior:** the compiler says that in the true branches of `CommandData` conditionals, C does not satisfy the constraint of either `NumCommandData` or `ChrCommandData`

**Playground Link:** [playground](https://www.typescriptlang.org/play?#code/C4TwDgpgBAcgrgWygXigKAD5QAyagRjwCY01RIoBhACwCcU8ByAQ0aYCM2tGBjNs8NACqAOwCWwFLERQsNWqXLR4CSgHsECZiIAmDbsx06uURmJEA3CLWD8lVOus3a9yJjzUiezW02BqAGTUAd2s7QSoNLV0AHiEoCAAPYAhdAGcoUQkAPgYoTITk1J0MlSgAfmlVKJcoAC40fPiklPSHekr5J2i9BvyRCCsFAQoVbpcAER9mGMpC1pKq8d1ct3y5luKMliNGCqgAbyg1YGprFTqqqABfesaoAaHFCK6a3SngGY2ittfnFbyVHmW1MHi8Pj2lSOJzOtHkl3kNzu-UG1meFGWOg+M2aP0WWWAABogZtfm8dHFsqt7riFqUZJUxuTsbNcn0CqTFojOo5mdNWciHqjaEA)

**Related Issues:** maybe #24085 ?
Repository: go
Issue: os: ReadFile on directories does not return EISDIR in windows
Labels: help wanted,OS-Windows,NeedsInvestigation

<!--
Please answer these questions before submitting your issue. Thanks!
For questions please use one of our forums: https://github.com/golang/go/wiki/Questions
-->

### What version of Go are you using (`go version`)?

<pre>
$ go version
go version 1.15.6 windows/amd64
</pre>

### Does this issue reproduce with the latest release?
Yes


### What operating system and processor architecture are you using (`go env`)?

<details><summary><code>go env</code> Output</summary><br><pre>
$ go env
set GO111MODULE=
set GOARCH=amd64
set GOBIN=
set GOCACHE=C:\Users\vagrant\AppData\Local\go-build
set GOENV=C:\Users\vagrant\AppData\Roaming\go\env
set GOEXE=.exe
set GOFLAGS=
set GOHOSTARCH=amd64
set GOHOSTOS=windows
set GOINSECURE=
set GOMODCACHE=C:\Users\vagrant\go\pkg\mod
set GONOPROXY=
set GONOSUMDB=
set GOOS=windows
set GOPATH=C:\Users\vagrant\go
set GOPRIVATE=
set GOPROXY=https://proxy.golang.org,direct
set GOROOT=c:\go
set GOSUMDB=sum.golang.org
set GOTMPDIR=
set GOTOOLDIR=c:\go\pkg\tool\windows_amd64
set GCCGO=gccgo
set AR=ar
set CC=gcc
set CXX=g++
set CGO_ENABLED=1
set GOMOD=C:\Users\vagrant\go\wintest\go.mod
set CGO_CFLAGS=-g -O2
set CGO_CPPFLAGS=
set CGO_CXXFLAGS=-g -O2
set CGO_FFLAGS=-g -O2
set CGO_LDFLAGS=-g -O2
set PKG_CONFIG=pkg-config
set GOGCCFLAGS=-m64 -mthreads -fno-caret-diagnostics -Qunused-arguments -fmessage-length=0 -fdebug-prefix-map=C:\Users\vagrant\AppData\Local\Temp\go-build505615858=/tmp/go-build -gno-record-gcc-switches

</pre></details>

### 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.
-->
https://play.golang.org/p/GwvDhx3PqK-


### What did you expect to see?
All good


### What did you see instead?
Unexpected error: read /: The handle is invalid
Repository: go
Issue: x/build/cmd/coordinator: make logic for cleaning up TryBot runs that reach "0 builds remaining" more robust
Labels: Builders,NeedsFix

During investigation of #43312 we observed that some TryBot runs would reach 0 builds remaining, yet wouldn't complete. We should try to understand the root cause and fix it.

**Edit:** The root cause is well understood now, see [comment](https://github.com/golang/go/issues/43323#issuecomment-789865414) from Mar 3.

CC @golang/release.