sharjeelyunus/github-issues-dataset huggingface dataset:
Repository: pytorch
Issue: Compilation on Power fails with clang due to vec_xl
Labels: module: build,triaged,module: POWER

## 🐛 Bug

When compiling PyTorch with Clang on Power the compilation fails with

```
../aten/src/TH/vector/VSX.cpp:130:24: error: no matching function for call to 'vec_xl'
        x11_fp64vec2 = vec_xl(0, x+(i+22))
```

The reason is clear by inspection of clangs `altivec.h`: Their `vec_xl` function take non-const pointers as their 2nd argument. See e.g. https://github.com/llvm-mirror/clang/blob/master/lib/Headers/altivec.h

I opened a bug report with llvm but don't expect it to be fixed soon: https://bugs.llvm.org/show_bug.cgi?id=46817

Possible solution to workaround is to conditionally (on clang only) add code like this (untested):

```
template<typename T>
auto vec_xl_wrapped(signed long offset, const T* ptr){
  return vec_xl(offset, (T*) ptr);
}
#define vec_xl vec_xl_wrapped
```

So basically introduce a wrapper function which removes the const. Also note that the above requires C++14 for the auto return type. For C++11 a trailing return type is required. This would also work on GCC as `T*` implicitly converts to `const T*` IIRC

cc @malfet
Repository: godot
Issue: AudioStreamPlayer high-freq artifact, pops, stereo channel corruption
Labels: bug,needs testing,topic:audio

<!-- Please search existing issues for potential duplicates before filing yours:	
https://github.com/godotengine/godot/issues?q=is%3Aissue	
-->

**Godot version:**
3.2.2 Stable


**OS/device including version:**
Windows 10


**Issue description:**
- High-frequency artifact in both WAV and OGG sample playback. (Related: [#23544](https://github.com/godotengine/godot/issues/23544))
- Pops/thumps in both WAV and OGG sample playback
- One stereo channel is messed up on playback of mono OGG sample

**Video example:**
https://youtu.be/PQQmKecHrec

**Steps to reproduce:**
_(See video example)_
In the provided project, drop the samples onto the AudioStreamPlayer, and run the project.
Listen to the output sound.

**Minimal reproduction project:**
[AudioStreamPlayerBug.zip](https://github.com/godotengine/godot/files/4965925/AudioStreamPlayerBug.zip)
Repository: pytorch
Issue: Failure to compile Eigen on Power with clang
Labels: module: build,triaged,module: third_party

## 🐛 Bug

With clang on power I get
```
../cmake/../third_party/eigen/Eigen/src/Core/arch/AltiVec/PacketMath.h:455:10: error: call to 'vec_sel' is ambiguous
  return vec_sel(b, a, mask);
```

This issue seems to be known and solved by  https://github.com/eigenteam/eigen-git-mirror/commit/c925dd8630175bc0e303594459c7cfc00917e617

Could you update the referenced Eigen library to after that please?

cc @malfet
Repository: go
Issue: x/pkgsite: local setup - tracking issue
Labels: help wanted,NeedsInvestigation,pkgsite,pkgsite/cmd

Today, users can run pkgsite locally without setting up a local database by running:

`go run cmd/frontend/main.go -direct_proxy -proxy_url=<your proxy URL>`

See [flags](https://github.com/golang/pkgsite/blob/master/cmd/frontend/main.go#L43) in `cmd/frontend/main.go`, and [doc/frontend.md](https://github.com/golang/pkgsite/blob/master/doc/frontend.md) for docs.

Doing so allows users to view the package documentation, overview, imports, and licenses tabs. Search and other tabs on the package page are not supported in direct proxy mode.

However, there are cases when a user might want to run pkgsite on their local machine, and be able to view a private repository that is not available via a proxy.

Tasks related to this topic:

- [x] #40159: run locally to view documentation of a pending CL 
- [x] https://github.com/golang/go/issues/54479
- [ ] render the standard library for GOROOT
- [ ] link to github documentation when possible?
- [ ] #59542: add support for rendering vendor directories
- [ ] Display unexported symbols on request. (https://github.com/golang/go/issues/12092 https://github.com/golang/go/issues/59056#issuecomment-1518609724 )

Maybe:
- only render documentation for packages / units when they are accessed

This is an umbrella issue to discuss what features are needed for this to happen, so please comment on your use cases below. For discussions about hosting a private instance of pkgsite, including your own internal proxy, see #39827.
Repository: pytorch
Issue: torch.exp() cannot be modified by an inplace operation
Labels: module: docs,module: autograd,triaged

## 📚 Documentation

The original question was posted [here](https://discuss.pytorch.org/t/torch-exp-is-modified-by-an-inplace-operation/90216). As `torch.exp()` leverages its output for calculating its gradient while most other functions use their input, `torch.exp()` has a different behavior when its output is inplaced, which is not natural to users. I understand that this implementation is beneficial to the code efficiency. The description of `torch.exp()` in the document should emphasize this property.

<!-- A clear and concise description of what content in https://pytorch.org/docs is an issue. If this has to do with the general https://pytorch.org website, please file an issue at https://github.com/pytorch/pytorch.github.io/issues/new/choose instead. If this has to do with https://pytorch.org/tutorials, please file an issue at https://github.com/pytorch/tutorials/issues/new -->


cc @ezyang @albanD @zou3519 @gqchen @pearu @nikitaved @jlin27 @mruberry
Repository: go
Issue: path/filepath: Join is susceptible to SlipZip
Labels: NeedsInvestigation

Edit: moved from issue title to body for hyperlink: https://snyk.io/research/zip-slip-vulnerability

---

The u-root project has several programs that unarchive files -- cpio, tar, zip, etc. 

A few weeks ago we were notified that we are vulnerable to something called ZipSlip. It's a simple enough problem: archives containing paths with .. can end up in unexpected places. 

e.g., I am in /bin, and I unpack a cpio, I expect things to end up /bin, and they end up in /home/rminnich/bin/wildthing

This is an easy thing to fix: given a root, base, and a path, p: filepath.Join("/some/place", filepath.Join("/", p))
I can contain the files to base. 

The bigger question: do people in general expect that for filepath.Join, things won't creep out of the first directory argument to other places? 3 different people wrote 3 different tools on u-root and missed this, I think because they assumed that everything stayed under path. 

This seems like an accident waiting to happen, save that it already did.

Should filepath.Join be changed, or maybe we need a filepath.BaseJoin which guarantees things stay inside the base? 

I can fix this for the 3 programs in question, but I'm wondering if it really belongs in the go runtime instead.

### What version of Go are you using (`go version`)?

<pre>
go version go1.14.3 darwin/amd64

</pre>

### Does this issue reproduce with the latest release?

Repros on every release since filepath.Join was written.

### What operating system and processor architecture are you using (`go env`)?

Does not matter -- it's a filepath question

### What did you do?

```
package main

import "fmt"
import "path/filepath"

func main() {
	fmt.Println(filepath.Join("/bin", "../../cat"))
	fmt.Println(filepath.Join("/bin", filepath.Join("/", "../../cat")))
}
```


### What did you expect to see?

people don't expect to see files creep out of the target directory. Arguably it's a defect of the program, and a bad assumption on the part of the author(s), but still ...

### What did you see instead?
We got a CVE ;-)
Repository: pytorch
Issue: Installing pytorch from source on Power9 (PPC64LE) + CUDA 10.2 + RHLE7 
Labels: module: build,triaged,module: POWER

Steps to reproduce the behavior:

After following instructions on https://github.com/pytorch/pytorch#get-the-pytorch-source
1. export CMAKE_PREFIX_PATH=${CONDA_PREFIX:-"$(dirname $(which conda))/../"}
2. python setup.py install --cmake
<!-- If you have a code sample, error messages, stack traces, please provide it here as well -->

## Expected behavior
A successful build of pytorch

## Environment
 - PyTorch Version (e.g., 1.0): Trying to install 1.5
 - OS (e.g., Linux): RHLE7
 - How you installed PyTorch (`conda`, `pip`, source): source
 - Build command you used (if compiling from source):  `python setup.py install --cmake`
 - Python version: `3.6.10`
 - CUDA/cuDNN version: `10.2`
 - GPU models and configuration: `4 x V100`
 - Any other relevant information: `PPC64LE`

## Additional context
This is the log that was generated from my failed build. Any types of help would be greatly appreciated
[build.log](https://gist.github.com/ypsoh/e5d2906dec20212969abf2f481477293)



cc @malfet
Repository: rust
Issue: Add a spell checker for libcore/libstd documentation
Labels: C-enhancement,E-help-wanted,T-bootstrap,A-docs

From #74141:

> @pickfire: Did you go through this with some kind of type checkers like cargo-spellcheck?
> @euclio: I made a super hacky custom rustdoc pass that ran a spellchecker over markdown compiled to plain text.

It would be great to have a tool that automated spell-checking for the docs. @pickfire suggested `cargo spellcheck` which [had some trouble](https://github.com/rust-lang/rust/pull/74141#issuecomment-663113306) with bootstrap. Maybe we could somehow modify it to work with bootstrap so it runs as part of `tidy`?
Repository: vscode
Issue: Preserve open documents word wrap settings on restart
Labels: feature-request,editor-wrapping

<!-- ⚠️⚠️ Do Not Delete This! feature_request_template ⚠️⚠️ -->
<!-- Please read our Rules of Conduct: https://opensource.microsoft.com/codeofconduct/ -->
<!-- Please search existing issues to avoid creating duplicates. -->

<!-- Describe the feature you'd like. -->
Currently, when VS Code is restarted (e.g. for extension update, or version update), open documents would lose their word wrap settings after restart. It would be very helpful, if word wrap state for an open documents is preserved.
Repository: pytorch
Issue: [docs] Clarify behavior of torch.cuda.device_count() when torch compiled without CUDA (cpu-only) or when CUDA is not available
Labels: module: docs,module: cuda,triaged

It would be nice to have this in docs directly, since loops like `for device in range(torch.cuda.device_count())` are simpler if it is known to return 0 when no CUDA is compiled or it is not available

In https://discuss.pytorch.org/t/torch-cuda-device-count-with-no-cuda-compiled-available/90328 it seems so!

cc @ngimel @jlin27
Repository: flutter
Issue: Make it clear from where in the theme does each widget get their default style
Labels: framework,f: material design,d: api docs,c: proposal,team-design,triaged-design

## Use case

For instance, when I create a RaisedButton, where are all the default styling coming from the theme?

Now for a RaisedButton, it's possible to change any styling from the widget properties and also it's sometimes possible to intuitively figure it out, but widgets like datePicker, timePicker and Scrollbar don't have styling properties and don't tell you where from the theme they get their color from. 

The process of finding this information can be very cumbersome and time consuming. I've sometimes resolved this by searching google for the info and when that's not possible, digging into the underlying code of the widget.

## Proposal

In the docs, have a section where it mentions all styling and theme info for every widget.

I understand that for some widgets it could need "if then" clauses to know exactly where the default style comes from, but that is the exact point. Developers need to know this info and there's no good way to know as far as I know.
Repository: pytorch
Issue: can not use nn::Functional(torch::softmax(-1)) in Sequential
Labels: module: cpp,module: nn,triaged

nn::Sequential(nn::Linear(dim_states, h_neurons),
							nn::Functional(torch::tanh),
							nn::Linear(h_neurons, h_neurons),
	                        nn::Functional(torch::tanh),
							nn::Linear(h_neurons, dim_acts),
							nn::Functional(torch::softmax(-1)));

compile error
../src/actorcritic.cpp:13:40: error: no matching function for call to ‘softmax(int)’

nn::Functional(torch::softmax((int64_t)-1)  
error: no matching function for call to ‘softmax(int64_t)’

cc @yf225 @glaringlee @albanD @mruberry
Repository: angular
Issue: Warn or error when `setComponentScope()` is necessary
Labels: feature,workaround3: complex,area: compiler,P4,feature: in backlog

# 🚀 feature request

### Relevant Package
<!-- Can you pin-point one or more @angular/* packages the are relevant for this feature request? -->
This feature request is for `@angular/compiler`


### Description
When an `NgModule` includes components/directives/pipes with circular references, the scope for Angular components cannot be determined, as creating the relevant imports would cause a cycle that would fail Closure compilations. To work around this, the compiler defers this task to run time with `setComponentScope()`, effective setting the component template to use the entire module as a scope. This is a deoptimization which comes from a circular reference in source code. Missing this optimization means that tree shaking is less effective. For example, `RouterModule` appears to generate `setComponentScope()` and as a result, `routerLinkActive` can not be tree shaken even if it is never used.


### Describe the solution you'd like
The compiler should warn or error when such a case occurs (probably only if the user set a particular flag). This would allow performance sensitive code (such as `@angular/core`) to restrict itself to not include circular references to allow better tree shaking. Ideally this would print out the full path of the cycle so users could attempt to fix it.

### Describe alternatives you've considered
Currently the best workaround is to grep output deobfuscated code for `setComponentScope()` and identify the modules it was used with. You then just have to "figure out" exactly how the circular dependency was introduced and what the best way of fixing it is.

I made https://github.com/angular/angular/pull/38210, which is a patch to the compiler which prints out any cycled identified and then fails the build. This is a hacky means of figuring out exactly what cycle is causing `setComponentScope()`. For `RouterModule` this prints:

```
/home/dparker/Source/ng/packages/router/src/components/empty_outlet.ts
/home/dparker/Source/ng/packages/router/src/directives/router_outlet.ts
/home/dparker/Source/ng/packages/router/src/config.ts
/home/dparker/Source/ng/packages/router/src/components/empty_outlet.ts
```

Also see http://b/162019906 for more investigative information.
Repository: pytorch
Issue: torch.random.fork tries to initialize cuda even when no cuda devices are available
Labels: module: cuda,triaged,module: random

## 🐛 Bug

When I try to fork_rng in a context, while only having a cpu available, torch tries to initialize cuda and raises an exception

## To Reproduce run this code in a script
```python
import os
os.environ["CUDA_VISIBLE_DEVICES"]=""

import torch
print(torch.__version__) # I have "1.5.1"

device="cpu"

torch.random.fork_rng(devices=(device,))
print("This Works")

with torch.random.fork_rng():
    print("This also works")

with torch.random.fork_rng(devices=(device,)):
    print("But this fails")
```


## Expected behavior

I expect this would not raise an exception.
Workarounds are quite easy but ugly:
```python
if torch.cuda.count_devices()==0:
     with torch.random.fork_rng():
          pass
     else:
         with torch.random.fork_rng(devices=(device,)):
```

## Environment

PyTorch version: 1.5.1
Is debug build: No
CUDA used to build PyTorch: 10.2

OS: Ubuntu 18.04.4 LTS
GCC version: (Ubuntu 7.5.0-3ubuntu1~18.04) 7.5.0
CMake version: Could not collect

Python version: 3.6
Is CUDA available: Yes
CUDA runtime version: Could not collect
GPU models and configuration: 
GPU 0: TITAN V
GPU 1: GeForce GTX 980 Ti

Nvidia driver version: 440.100
cuDNN version: /usr/lib/x86_64-linux-gnu/libcudnn.so.7.6.5

Versions of relevant libraries:
[pip3] numpy==1.19.0
[pip3] pytorch-transformers==1.2.0
[pip3] torch==1.5.1
[pip3] torch-scatter==2.0.5
[pip3] torchvision==0.6.1
[conda] Could not collect


## Additional context



cc @ngimel @pbelevich
Repository: flutter
Issue: flutter build aar failed with NPE
Labels: c: crash,platform-android,tool,t: gradle,a: existing-apps,P2,team-android,triaged-android

run ./gradlew assembleRelease command is OK

but run `flutter build aar` failed

Log : 

```
FAILURE: Build failed with an exception.

* Where:
Initialization script 'xxxxx/Flutter-Stable-1.12.13/packages/flutter_tools/gradle/aar_init_script.gradle' line: 164

* What went wrong:
java.lang.NullPointerException (no error message)

* Try:
Run with --stacktrace option to get the stack trace. Run with --info or --debug option to get more log output. Run with --scan to get full insights.

* Get more help at https://help.gradle.org

BUILD FAILED in 1s
```




flutter doctor

```
Doctor summary (to see all details, run flutter doctor -v):
[✓] Flutter (Channel stable, v1.12.13+hotfix.5, on Mac OS X 10.15.2 19C57, locale zh-Hans-CN)
 
[✓] Android toolchain - develop for Android devices (Android SDK version 29.0.2)
[!] Xcode - develop for iOS and macOS (Xcode 11.3)
    ✗ CocoaPods installed but not working.
        You appear to have CocoaPods installed but it is not working.
        This can happen if the version of Ruby that CocoaPods was installed with is different from the one being used to invoke it.
        This can usually be fixed by re-installing CocoaPods. For more info, see https://github.com/flutter/flutter/issues/14293.
      To re-install CocoaPods, run:
        sudo gem install cocoapods
[✓] Android Studio (version 4.0)
[!] IntelliJ IDEA Ultimate Edition (version 2019.2.3)
    ✗ Flutter plugin not installed; this adds Flutter specific functionality.
    ✗ Dart plugin not installed; this adds Dart specific functionality.
[✓] VS Code (version 1.47.2)
[✓] Connected device (1 available)

! Doctor found issues in 2 categories.
```

if I  comment out the problematic code in aar_init_script.gradle， it can be built successfully，
But because it needs to be deployed in CI，，，，，，

```
 modulePlugins.each { pluginProject ->
        configureProject(pluginProject, moduleProject.property("output-dir"))
        moduleProject.android.libraryVariants.all { variant ->
            // Configure the `assembleAar<variantName>` task for each plugin's projects and make
            // the module's equivalent task depend on the plugin's task.
            String variantName = variant.name.capitalize()
            moduleProject.tasks.findByPath("assembleAar$variantName")
                .dependsOn(pluginProject.tasks.findByPath("assembleAar$variantName"))
        }
    }
```
Repository: opencv
Issue: [DNN] Error when read ResNet101_DUC_HDC  model for semantic segmentation
Labels: category: dnn

##### System information (version)

- OpenCV => 4.3.0
- Operating System / Platform => ubuntu 18.04 64bit
- Compiler => python

##### Detailed description
I'm trying to write an semantic segmentation with dnn module in opencv. I tried the models mentioned in the [wiki](https://github.com/opencv/opencv/wiki/Deep-Learning-in-OpenCV), but the ResNet101_DUC_HDC can't be read correctly by dnn module.

##### Steps to reproduce

1. Download [ResNet101_DUC_HDC.tar.gz](https://s3.amazonaws.com/onnx-model-zoo/duc/ResNet101_DUC_HDC.tar.gz) and untar the file to get ResNet101_DUC_HDC.onnx

2. Launch python and execute ` import cv2 as cv`

3. Try read the net by `cv.dnn.readNet('ResNet101_DUC_HDC.onnx')`

The error message:

```
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
cv2.error: OpenCV(4.3.0) /home/zzm/software/opencv/modules/dnn/src/onnx/onnx_importer.cpp:527: error: (-2:Unspecified error) in function 'void cv::dnn::dnn4_v20200310::ONNXImporter::populateNet(cv::dnn::dnn4_v20200310::Net)'
>  (expected: 'node_proto.input_size() == 2'), where
>     'node_proto.input_size()' is 4
> must be equal to
>     '2' is 2
```

I'm wondering if you have any suggestion to solve thie error. Thanks for your attention.
Repository: rust
Issue: Suggest reborrowing mutable reference when move error ocurrs
Labels: C-enhancement,A-borrow-checker,T-compiler,A-suggestion-diagnostics

The following code:

```rust
struct Foo;
struct Wrapper<T>(T);

fn use_val<T>(_: &mut T) {}

impl Foo {
    fn call_it(&mut self) {
        use_val(&mut Wrapper(self));
        self;
    }
}
```

produces the following error:

```
error[E0382]: use of moved value: `self`
 --> src/lib.rs:9:9
  |
7 |     fn call_it(&mut self) {
  |                --------- move occurs because `self` has type `&mut Foo`, which does not implement the `Copy` trait
8 |         use_val(&mut Wrapper(self));
  |                              ---- value moved here
9 |         self;
  |         ^^^^ value used here after move

error: aborting due to previous error
```

When `self` is passed directly to `use_val` (e.g. `use_val(self`), a reborrow will automatically be inserted, allowing the code to compile. However, the fact that `use_val` takes an `&mut T` means that the compiler won't adjust the inferred type in any way (in this case, `&mut Wrapper<&mut Foo>`), leading to the move error.

The solution is to add an explicit reborrow (`&mut Wrapper(&mut *self)`), however, this wasn't obvious to me. It would be useful if the compiler could suggest inserting a reborrow in this situation.
Repository: nvm
Issue: Installing custom Node build
Labels: installing node,feature requests

I'm in the process of trying out a Node feature I'm working on. In this context, I'd like to try my build in "real life" by using nvm to install it and manage it (I don't plan to make nvm build from sources - just to use a preexisting tarball on install). Is nvm capable of this? Would that be a PR you'd consider?
Repository: rust
Issue: Do not build nightly-only tools on beta/stable CI
Labels: T-bootstrap,T-infra

Currently, we build nightly-only tools such as Miri even on beta/stable CI, only to then ignore whether they build or not. That seems like a waste. We certainly do that for the tools builders (that also run the tests); I do not know if we also do it for dist builders (that just build the tools to put them into rustup packages).

https://github.com/rust-lang/rust/pull/74389 is the beginning of fixing that, but I got stuck due to not knowing enough about rustbuild.