sharjeelyunus/github-issues-dataset huggingface dataset:
Repository: pytorch
Issue: DataParallel support for scripted modules in C++
Labels: oncall: jit,triaged

## 🐛 Bug

As I said in this post https://discuss.pytorch.org/t/is-it-possible-to-execute-the-script-module-in-c-on-multiple-gpus-in-parallel/101222, I had a model(object_detection.pt) generated by `torch.jit.trace().save()`  using Pytorch. Then, I converted it to TorchScript, loaded, and finally executed the script module in C++.

According to this post https://discuss.pytorch.org/t/how-to-trace-jit-in-evaluation-mode-using-multi-gpu-learned-model/33280, it seems that I am not able to parallelize the model in C++ after it is loaded if the model is generated in Pytorch. I was told that I could wrap my module into it DataParallel after loading. I tried so but failed with many data type errors, and was finally advised to report an error here.

## To Reproduce

Steps to reproduce the behavior:

1. Generated a model by `torch.jit.trace().save()`  using Pytorch
2. Converted the model to TorchScript, loaded the script module based on the official guide.
3. Tried to parallelize it using DataParallel but failed (before it was executed) in C++.

## Expected behavior

The model is parallelized and can run on multiple GPUs.

## Environment

 - PyTorch Version: I tried both 1.6 and 1.7
 - OS: Ubuntu 16.04
 - How you installed PyTorch (`conda`, `pip`, source): LibTorch
 - Build command you used (if compiling from source): 
 - Python version: 3.5.2
 - CUDA/cuDNN version: 10.1/8.0
 - GPU models and configuration: GeForce ® GTX 1080 Ti 

cc @gmagogsfm
Repository: godot
Issue: TileMap/TileSet: AtlasTile priority cannot be utilized since update_cell_bitmask() won't call atlastile_get_subtile_by_priority()
Labels: bug,topic:core

<!-- 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. -->
3.2.3 with mono

**OS/device including version:**
<!-- Specify GPU model, drivers, and the backend (GLES2, GLES3, Vulkan) if graphics-related. -->
OSX

**Issue description:**
<!-- What happened, and what was expected. -->
I was trying to get randomized subtile selection using priority in an AtlasTile working (by scripting, not in editor), whereas the first subtile was always chosen despite there are 3 different subtiles.

I check all my setup and cannot find why. Then I'm reading the source code at tile_map.cpp update_cell_bitmask() around line 1009 (master) here: 


		} else if (tile_set->tile_get_tile_mode(id) == TileSet::ATLAS_TILE) {
	==>		if (tile_set->autotile_get_bitmask(id, Vector2(p_x, p_y)) == TileSet::BIND_CENTER) {
				Vector2 coord = tile_set->atlastile_get_subtile_by_priority(id, this, Vector2(p_x, p_y));

				E->get().autotile_coord_x = (int)coord.x;
				E->get().autotile_coord_y = (int)coord.y;
			}
		}

where autotile_get_bitmask(id, coord) should take a subtile coord as its second parameter, but the invocation here passed in the map coordinate? 

The evaluation won't be true and there are hardly any occasions atlastile_get_subtile_by_priority() can be called. I don't think it makes sense to check bitmask for an AtlasTile because bitmask only has its usage in an AutoTile?

I didn't try to fix it yet due to lack of environment. And apparently the need in my game can be easily worked around by implementing some subtile randomize logic in the game script and pass an autotile_coord to tile_map::set_cell().

Btw, thank you for the great engine! Maybe the best 2d engine I've ever used (only used the 2d part for the time being).

**Steps to reproduce:**
N/A

**Minimal reproduction project:**
<!-- A small Godot project which reproduces the issue. Drag and drop a zip archive to upload it. -->
N/A
Repository: storybook
Issue: Build storybook with production react
Labels: dependencies,help wanted,performance issue

The [largest package in the vendors bundle](https://app.packtracker.io/organizations/184/projects/150/commits/c1e2477b3d6378d933af8eb612f8a30eeb939c9f/explore) is `react-dom.development.js` at a whopping 840k. If we can use the production bundle we might be able to get a nice performance boost.
Repository: storybook
Issue: Bundle optimizations: UI libraries
Labels: performance issue

We use a number of [large libraries](https://app.packtracker.io/organizations/184/projects/150/commits/c1e2477b3d6378d933af8eb612f8a30eeb939c9f/explore) which may have smaller drop-in alternatives

- overlay-scrollbars 359kb => ???
- react-hotkeys 310kb => X only used once
- react-color 161kb => react-colorful (5% of the size?)
- etc.
Repository: angular
Issue: Create dynamic component loading documentation
Labels: P4,needs: discussion,feature: votes required,area: docs

<!--🔅🔅🔅🔅🔅🔅🔅🔅🔅🔅🔅🔅🔅🔅🔅🔅🔅🔅🔅🔅🔅🔅🔅🔅🔅🔅🔅🔅🔅🔅🔅

Oh hi there! 😄

To expedite issue processing please search open and closed issues before submitting a new one.
Existing issues often contain information about workarounds, resolution, or progress updates.

🔅🔅🔅🔅🔅🔅🔅🔅🔅🔅🔅🔅🔅🔅🔅🔅🔅🔅🔅🔅🔅🔅🔅🔅🔅🔅🔅🔅🔅🔅🔅🔅🔅-->

# 📚 Docs or angular.io bug report

### Description
Following the discussions held yesterday during the tooling meeting we should create a documentation explaining how to load a dynamic component. 

This document should also make it clear which scenarios are supported and not. In many cases currently, users are currently using a mixture of AOT and JIT to dynamically load a component. This doesn't work with any build optimizations (ie: terser and build optimizer), among other things due to the `ngJitMode: false` guards.

Using AOT/JIT interop with build optimizations is currently not supported as the main use cases for this appears to be unit testing scenarios, that is until the Dynamic view composition project which is currently listed on ng-elephant is finalized.

Users who are concerned about performance, security and bundle sizes shouldn't use AOT+JIT interop. Compile components at runtime is a cross-site scripting (XSS) vulnerability in itself and shouldn't be used for production.


### Related issues
https://github.com/angular/angular-cli/issues/19016
https://github.com/angular/angular-cli/issues/19321
angular/angular#36255
angular/angular#37216
https://github.com/angular/angular/issues/15510
Repository: go
Issue: fmt: more doc needed for Formatter
Labels: Documentation,help wanted,NeedsInvestigation

Current (go1.15, tip) documentation of interface [`fmt.Formatter`](https://tip.golang.org/pkg/fmt/#Formatter):
> Formatter is implemented by any value that has a Format method. The implementation controls how State and rune are interpreted, and may call Sprint(f) or Fprint(f) etc. to generate its output.

This is insufficient to tell how one must implement this interface:
- which verbs should be handled for each type?
- how to handle unhandled verbs?
- how to forward unhandled verbs to `Printf`?
- how to handle unhandled width?
- how to handle unhandled precision?
- lack of example
Repository: godot
Issue: UI inconsistencies in exported variables
Labels: enhancement,topic:editor,usability

<!-- Please search existing issues for potential duplicates before filing yours:
https://github.com/godotengine/godot/issues?q=is%3Aissue
-->

**Godot version:**
3.2.3


**OS/device including version:**
NA

**Issue description:**
There are several inconsistencies in how Godot displays exported variables that make the UI hard to parse and uneven looking.

1. String fields background colour is light. This means they look more like empty UI space rather than fields for the user to interact with.
2. Some buttons are light. Like the NodePath "Assign..." button and the "FILE" and "DIR" folder icon button, whereas the expand icon button on the "MULTILINE" and the clear icon button on the NodePath are dark.
3. A dark line ends up showing next to the light folder icon.
4. The drop down arrow next to enum drop down is another size and allignment from the arrow on the dropdown on a resource.
4. The title of a multiline variable is too close to the variable title above it by 2 pixels.
5. Ease variables title is vertically center alligned, causing two uneven spacings, if it were top alligned it would only cause one.
6. Ease variables value is not vertically alligned the same as int and float vars values.

![image](https://user-images.githubusercontent.com/4955051/98649432-8236da00-232f-11eb-9cfd-ab982534fe84.png)

**Steps to reproduce:**
NA

**Minimal reproduction project:**
NA
Repository: vscode
Issue: Adopt Linux Repo publishing v3
Labels: feature-request,linux,engineering

> Currently our Publishing system has a limitation that if there are a lot of publishing activity to that repository, the repository is in a corrupted state until all ongoing publishing gets completed to that repository. Usually it gets auto resolved once all publishing to that repository is completed.
> If you are using “V2” version of our API which is pretty old, I suggest to use our “V3” API’s to publish.

cc @Tyriar
Repository: flutter
Issue: [PlatformViews] iOS fontweight renders incorrectly
Labels: platform-ios,engine,a: typography,a: platform-views,has reproducible steps,P2,found in release: 3.3,found in release: 3.7,team-ios,triaged-ios

I make the method swzzile for UIFont's system API to change custom font for my App, just like : +systemFontOfSize:, +boldSystemFontOfSize:, +italicSystemFontOfSize:, +systemFontOfSize:weight:
Then the flutter render text by my custom font, but the fontweight is wrong, w500 will render to w400, that's why???


flutter doctor
Doctor summary (to see all details, run flutter doctor -v):
[✓] Flutter (Channel stable, v1.17.5, on Mac OS X 10.15.7 19H15, locale
    zh-Hans-CN)

[✓] Android toolchain - develop for Android devices (Android SDK version 29.0.2)
[✓] Xcode - develop for iOS and macOS (Xcode 12.1)
[✓] Android Studio (version 4.0)
[✓] VS Code (version 1.50.1)
[✓] Connected device (1 available)

• No issues found!
Repository: go
Issue: net/http/httputil: DumpResponse return error when ContentLength=2 with Body length 0, but it's a response for http.MethodHead request
Labels: 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 go1.15.4 linux/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
GO111MODULE="on"
GOARCH="amd64"
GOBIN=""
GOCACHE="/root/.cache/go-build"
GOENV="/root/.config/go/env"
GOEXE=""
GOFLAGS=""
GOHOSTARCH="amd64"
GOHOSTOS="linux"
GOINSECURE=""
GOMODCACHE="/root/go/pkg/mod"
GONOPROXY="*.ucloudadmin.com"
GONOSUMDB="*.ucloudadmin.com"
GOOS="linux"
GOPATH="/root/go"
GOPRIVATE="*.ucloudadmin.com"
GOPROXY="https://goproxy.cn,direct"
GOROOT="/root/sdk/go1.15.4"
GOSUMDB="sum.golang.org"
GOTMPDIR=""
GOTOOLDIR="/root/sdk/go1.15.4/pkg/tool/linux_amd64"
GCCGO="gccgo"
AR="ar"
CC="gcc"
CXX="g++"
CGO_ENABLED="1"
GOMOD="/dev/null"
CGO_CFLAGS="-g -O2"
CGO_CPPFLAGS=""
CGO_CXXFLAGS="-g -O2"
CGO_FFLAGS="-g -O2"
CGO_LDFLAGS="-g -O2"
PKG_CONFIG="pkg-config"
GOGCCFLAGS="-fPIC -m64 -pthread -fmessage-length=0 -fdebug-prefix-map=/tmp/go-build737726766=/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.
-->

```main_test.go
package main

import (
	"net/http"
	"net/http/httptest"
	"net/http/httputil"
	"testing"
)

func serveHTTP(w http.ResponseWriter, r *http.Request) {
	w.Header().Add("Content-Length", "2")
	switch r.Method {
	case http.MethodHead:
	default:
		w.Write([]byte("{}"))
	}
}

func TestDumpResponse(t *testing.T) {
	t.Run("Get", func(t *testing.T) {
		rw := httptest.NewRecorder()
		r := httptest.NewRequest(http.MethodGet, "/", nil)

		serveHTTP(rw, r)
		raw, err := httputil.DumpResponse(rw.Result(), true)
		if err != nil {
			t.Errorf("DumpResponse: (%v)\nRaw: %s", err, string(raw))
		}

	})
	t.Run("Head", func(t *testing.T) {
		rw := httptest.NewRecorder()
		r := httptest.NewRequest(http.MethodHead, "/", nil)

		serveHTTP(rw, r)
		raw, err := httputil.DumpResponse(rw.Result(), true)
		if err != nil {
			t.Errorf("DumpResponse: (%v)\nRaw: %s", err, string(raw))
		}

	})
}
```

```shell
go test main_test.go 
```

### What did you expect to see?

<pre>
--- FAIL: TestDumpResponse (0.00s)
    --- FAIL: TestDumpResponse/Head (0.00s)
        main_test.go:38: DumpResponse: (http: ContentLength=2 with Body length 0)
            Raw: 
FAIL
FAIL    command-line-arguments  0.003s
FAIL
</pre>

### What did you see instead?

```text
ok      command-line-arguments  0.003s
```
Repository: svelte
Issue: Duplicated <meta> tags on initial page using <svelte:head>
Labels: stale-bot,temp-stale

Using component to compose head contents from an object as Head.svelte:

```
<svelte:head>
  {#if title}
    <title>{title}</title>
  {/if}
  {#if meta}
    {#each Object.entries(meta) as [ name, content ]}
      <meta {name} {content} />
    {/each}
  {/if}
</svelte:head>
```

By including this component on any page as:

```
<Head {props} />
```

The initial page loaded by the user has duplicated meta tags. 
Interesting thing is, by navigating to other pages where such component is present, the second batch of duplicated tags are updated as expected. Title tag is not duplicated, but all meta tags has duplicate of initial page's load and persists forever.

I am using sapper, but I think it is the Svelte related issue.

Versions I use:
 -  "sapper": "^0.28.10",
 - "svelte": "^3.29.4".

Same thing as [#4533](https://github.com/sveltejs/svelte/issues/4533), but <title> tag works fine.
Repository: pytorch
Issue: Pytorch 1.7.0 with cuda 11.1.1 and cudnn 8.0.5
Labels: module: cuda,oncall: releng,module: ci,triaged,enhancement

Hi, currently cuda 11.1.1 and cudnn 8.0.5 are both available, according to former replies from Nvidia engineers, they will bring performance improvement to 3080/3090 GPUs.
The requested feature is when will PyTorch officially support them?
Thanks

cc @ezyang @seemethere @malfet @walterddr @pytorch/pytorch-dev-infra @ngimel
Repository: scrcpy
Issue: Menu items would be welcome
Labels: feature request

**Is your feature request related to a problem? Please describe.**
No.

**Describe the solution you'd like**
That in the menu of the desktop scrcpy app the actions are available, e.g. zoom, screen off, rotate, pull notifications, etc.
Now I have to remember keyboard shortcuts which is very 'msdos' like.
Repository: storybook
Issue: Module not found: Error: Can't resolve on Windows. Virtual file does not account for windows path sep. 
Labels: bug,compatibility with other tools,has workaround,core

**Describe the bug**
https://github.com/storybookjs/storybook/blob/next/lib/core/src/server/preview/iframe-webpack.config.ts#L111
String replacement does not account for Windows path separator. 

**To Reproduce**
Use windows style file paths. 

```
module.exports = {
  stories: [
    path.join(__dirname, "../../../components/**/*.stories.@(ts|tsx|mdx)")
  ],
};
```

**Workaround**
Add a string replacement to paths to be safe. 
```
module.exports = {
  stories: [
    path.join(__dirname, "../../../components/**/*.stories.@(ts|tsx|mdx)").replace(/\\/g, '/')
  ],
};
```

**Expected behavior**
Either escaping of the `\` or conversion to `/`

**Code snippets**
Contents of virtual `./.storybook/generated-stories-entry.js`

```
"use strict";
var _frameworkImportPath = require("@storybook/react");
/* eslint-disable import/no-unresolved */
(0, _frameworkImportPath.configure)([require.context('C:\Users\PHawx\Documents\GitHub\design-system\components', true, /^\.\/(?:\*[^\\/]*?\*\.stories\.(ts|tsx|mdx))$/)], module, false);
```

**System**
```
  System:
    OS: Windows 10 10.0.19042
    CPU: (16) x64 AMD Ryzen 7 1700 Eight-Core Processor
  Binaries:
    Node: 12.19.0 - C:\Program Files\nodejs\node.EXE
    Yarn: 1.22.4 - C:\Program Files (x86)\Yarn\bin\yarn.CMD      
    npm: 6.14.8 - C:\Program Files\nodejs\npm.CMD
  Browsers:
    Chrome: 86.0.4240.111
    Edge: Spartan (44.19041.423.0), Chromium (86.0.622.63)       
  npmPackages:
    @storybook/addon-essentials: ^6.0.21 => 6.0.21
    @storybook/addon-links: ^6.0.21 => 6.0.21
    @storybook/react: ^6.0.21 => 6.0.21

```

**Additional context**
Console output, notice the file path missing separators. 
```
[storybook] ERROR in ./.storybook/generated-stories-entry.js
[storybook] Module not found: Error: Can't resolve 'C:UsersPHawxDocumentsGitHubdesign-systemcomponents' in 'C:\Users\PHawx\Documents\GitHub\design-system\tools\storybook\.storybook'
[storybook]  @ ./.storybook/generated-stories-entry.js 7:37-161
```
Repository: flutter
Issue: [flutter_tools] support custom flutter build output directory
Labels: c: new feature,platform-android,tool,a: build,has reproducible steps,P2,team-tool,triaged-tool,found in release: 3.19,found in release: 3.20

Hello Guys!

I need change the android build files to other HD with more space, but after do this i got a error;

![Sem título](https://user-images.githubusercontent.com/61213009/98688251-67715f00-2349-11eb-9d9f-ea39d193821f.png)

Steps to reproduce: 


1. run > flutter create . 
2. Edit build.gradle ( android/build.gradle )
3. Change 
from 
**rootProject.buildDir = '../build'**
to 
**rootProject.buildDir = 'C:\Some\Folder\Diff\From\Default\Build'**

the apk has been generated, but in my CI, i need no errors in flutter build console

Thanks !
Repository: TypeScript
Issue: [BUG] union type generic extends child class with generic method
Labels: Needs Investigation

**TypeScript Version:**  all, tested from 3.3 to 4.2 

**Search Terms:** union type generic extends child class with generic method

**Code**

```ts
class A<GValue> {
  a<GKey extends GValue>(value: GKey): void {}
}

class B<GValue> extends A<GValue> {
  a<GKey extends GValue>(value: GKey): void {}
}


const a1: (('a' | 'b') extends any ? true : false) = true;
const a2: (('a') extends any ? true : false) = true;

const a3: (B<'a' | 'b'> extends A<any> ? true : false) = true; // error before v3.7
const a4: (B<'a'> extends A<any> ? true : false) = true; // error
const a5: (B<'a'> extends B<any> ? true : false) = true;

type Constrained<G extends A<any>> = true;

const a6: Constrained<A<'a'>> = true; // ok
const a7: Constrained<B<'a' | 'b'>> = true; // ok
const a8: Constrained<B<'a'>> = true; // error
```

**Details:**

- a1 and a2 shows us that a *string* or an *union of string* extends *any* => **legit**
- a3 shows us that it's still true, except before typescript 3.7 => true seems **legit**
- a4 creates an error because `(B<'a'> extends A<any> ? true : false)` is actually false => **bug**, true expected.
  So, an union is true, but not a single value.
- a5 is true which is correct

- a6, a7 and a8 shows the same but with a type constraint

**Notes:**

- `a3` has not the same behavior between before and after v3.7
- the bug appears only when we have a generic type on a method which extends another generic type coming from the class

**Playground Link:** [playground link](https://www.typescriptlang.org/play?ts=4.1.0-beta#code/MYGwhgzhAECCA8BxAamEBXApgPmgbwChpowkBpTAT2kwA8AXTAOwBMYU0tsAKAN08wAuaIgqUAlMN4B7AJYt8AXwLKCoSDABCSVBhw0GzNnB0DchYqVFUDjVu11c+A4dYlS5CvMtVrpTCHoSAEZhbm4AcjAI6AAfaAiAIwjxWyMYMCZqAH5oegAnLGhhADM0CExUgF48wswAbj8AoLAAJjDI6NS6O2NMnNqi0vLK6BqCrEamwJIAZjDtKJj4pIjcHvSTftxcicxi6DKQCurBhugAeguafPzpfOhEzBL7-d5ZgDoAdmmWgBYFvAlutDPYtlkdmcDkcTmMzvVLtdMLd7r8SABWQHAtJg7TbaC7OrQkanPZTeiUAAO+wAwv5AvkwLImJgWEgccYENtcOM6lNgPSWgA2YR05qM5ms+AIYE8+GI6DSADWaLAX1FgolLLZi2icQSyWwcrJCuVqoAHBrxUztfBdWtjXyFci7vkgA)

**Related Issues:** this bug is pretty hard to reach and to describe, I was not able to find any related issue.
But a good start could be to search from a fix or update from the 3.6 to the 3.7, as `a3` has not the same behavior between these versions.
Repository: pytorch
Issue: Common dunder methods fail when called directly
Labels: oncall: jit,days

## 🐛 Bug

Many common dunder methods fail when called directly. The error message is `RuntimeError: Tried to access nonexistent attribute or method ...`, which is thrown in `SimpleValue::attr` (sugared_value.cpp:83). Specifically, the issue is the failed call in `BuiltinFunction::tryCreate` (sugared_value.cpp:189). 

I've already verified the arguments we pass in to `tryCreate` are correct. I would start by investigating the call to `getAllOperatorsFor(symbol)` in `BuiltinFunction::tryCreate` (sugared_value.cpp:657). In some cases (e.g. `__len__`), the call doesn't return any operators for the given symbol. In other cases (e.g. `__contains__`), none of the returned operators have the correct schema. 

cc @gmagogsfm @eellison 

## Example Test Cases

```python
import torch

# PASS
@torch.jit.script
def fn():
    s = "abcd"
    return len(s)

# FAIL
@torch.jit.script
def fn():
    s = "abcd"
    return s.__len__()

# PASS
@torch.jit.script
def fn():
    l = [1, 2, 3]
    return 1 in l

# FAIL
@torch.jit.script
def fn():
    l = [1, 2, 3]
    return l.__contains__(1)

# PASS
@torch.jit.script
def fn():
    return 1 + 2

# FAIL
@torch.jit.script
def fn():
    # Ignore the parentheses. We have to parenthesize the `1` so 
    # it's not parsed as a float in this context. Same idea.
    return (1).__add__(2)
```

##
Repository: flutter
Issue: felt should not ask for `ENGINE_PATH`
Labels: team,engine,platform-web,P2,team-web,triaged-web,e: engine-tool

When running `felt test --integration-tests-only` the command fails with the following:

```
Please set ENGINE_PATH environment variable.
+ exit 1
ERROR: Failed to clone flutter repo. Exited with exit code 1
```

I expected it to work without specifying the path because `felt` already [resolves the engine path](https://github.com/flutter/engine/blob/d14c4a742e56fb109f6b6d975d178a2776733c35/lib/web_ui/dev/environment.dart#L23) automatically.

/cc @nturgut