sharjeelyunus/github-issues-dataset huggingface dataset:
Repository: youtube-dl
Issue: Viu doesn't work
Labels: geo-restricted

- [x] I've **verified** and **I assure** that I'm running youtube-dl **2018.03.03**

### Before submitting an *issue* make sure you have:
- [x] At least skimmed through the [README](https://github.com/rg3/youtube-dl/blob/master/README.md), **most notably** the [FAQ](https://github.com/rg3/youtube-dl#faq) and [BUGS](https://github.com/rg3/youtube-dl#bugs) sections
- [x] [Searched](https://github.com/rg3/youtube-dl/search?type=Issues) the bugtracker for similar issues including closed ones
- [x] Checked that provided video/audio/playlist URLs (if any) are alive and playable in a browser

### What is the purpose of your *issue*?
- [x] Bug report (encountered problems with youtube-dl)

---

### Description of your *issue*, suggested solution and other information

Viu doesn't work while Youtube-dl lists it as supported site.

youtube-dl https://www.viu.com/ott/my/en/tag-the_precedent-playlist-22032452
[generic] tag-the_precedent-playlist-22032452: Requesting header
WARNING: Falling back on generic information extractor.
[generic] tag-the_precedent-playlist-22032452: Downloading webpage
[generic] tag-the_precedent-playlist-22032452: Extracting information
ERROR: Unsupported URL: https://www.viu.com/ott/my/en/tag-the_precedent-playlist-22032452

youtube-dl https://www.viu.com/ott/my/en/video-the_precedents_ep_1-1108985519?containerId=playlist-22032452
[generic] video-the_precedents_ep_1-1108985519?containerId=playlist-22032452: Requesting header
WARNING: Falling back on generic information extractor.
[generic] video-the_precedents_ep_1-1108985519?containerId=playlist-22032452: Downloading webpage
[generic] video-the_precedents_ep_1-1108985519?containerId=playlist-22032452: Extracting information
ERROR: Unsupported URL: https://www.viu.com/ott/my/en/video-the_precedents_ep_1-1108985519?containerId=playlist-22032452
Repository: TypeScript
Issue: Suggestion: readonly method
Labels: Suggestion,Awaiting More Feedback

**Problem:**

A method (function written with the [ES6 method syntax](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Functions/Method_definitions)) can currently be replaced with another function by a simple assignment.

As an example consider the following snippet of code:

```ts
class Person {
    constructor(...) {...}
    displayName (): string {...}
}
const x: Person = new Person(...)
x.displayName = function(this: Person): string {...} // Assignment
```
Because the `readonly` modifier is not usable for methods, this is not possible to prevent this kind of assignments.
 
**Proposal:**

A method is always readonly.

The following codes are identical:
```ts
class Person {
    displayName (): string {...}
}
```
```ts
class Person {
    readonly displayName: (this: Person) => string = function () {...}
}
```


**Compatibility:**

This is a breaking change. However, method syntax is recent and mostly used in classes. Codes which assign a function to a method are certainly rare.

**Temporary workaround:**

Do not use method syntax in your classes and interfaces. Note hat this leads to very verbose codes.

If you use an interface, the verbosity is acceptable. However you get also strict variance.
```ts
interface PersonI {
    readonly displayName: (this: Person) => string
}
```
Repository: flutter
Issue: TabPageSelector - externalize TabPageSelectorIndicator builder
Labels: c: new feature,framework,f: material design,P3,team-design,triaged-design

Would it be possible to add a callback to the `TabPageSelector` that would allow to pass in a custom widget builder that could be used instead of the default `TabPageSelectorIndicator`?
Repository: go
Issue: cmd/compile: loop optimization
Labels: Performance,NeedsInvestigation,compiler/runtime

Please answer these questions before submitting your issue. Thanks!

### What version of Go are you using (`go version`)?

master (1.11 dev)

### Does this issue reproduce with the latest release?

this is a compilation strategy proposal

### What operating system and processor architecture are you using (`go env`)?

amd64 / Darwin (macbook pro)

### What did you do?

I have code that iterates without referencing the loop variable. Changing that from:

for i := 0; i < n; i++ {
    // no access to i
}

...to...

for i := -n; i < 0; i++ {
    // no access to i
}

saves me 4%-5% in my test cases.

Looking at the .S files, I see that there are two gains (as expected): one is that the loop limit needs only be addressable and referenced at the start of the loop--which frees a register over the body of the loop; and also, because the test is against zero and there are dedicated instructions for that rather than loading immediate literals or otherwise.

It seems (from afar) that there could be a rule along the lines of:

if loop variable not referenced in body 
and  assignment has block structure (i:=) 
and type of loop variable is signed 
and incr RHS does not depend on additive offset to variable (i++ ok, i*=2 not), 
then transform "for v := low; v OP high; incr" into "for v := low-high; v OP 0; incr"

I don't have any comprehensive data about how common this situation may be, but it does help.

### What did you expect to see?

no change because i expected the compiler to be doing this.

### What did you see instead?

5% speedup
Repository: rust
Issue: Linking with `gcc` fails on Windows
Labels: A-linkage,T-compiler,O-windows-gnu,C-bug

The following code fails to link on both `stable-gnu` and `nightly-gnu` toolchains:

```rust
extern crate hound;

fn main() {
    let mut input = hound::WavReader::open("clarinet-d4.wav").unwrap();

    println!("Hello, world!");
}
```

The build fails with the following output: https://gist.github.com/suhr/2962444f16cfce13bdc7118fe658a33c. Note that `hound` is a pure Rust crate.

Strangely enough, a hello world without `hound` compiles just fine.

OS: Windows 7, toolchain: `stable-gnu` and `nightly-gnu`.
Repository: go
Issue: runtime/race: doesn't support the plugin package
Labels: RaceDetector,help wanted,NeedsInvestigation,FeatureRequest,compiler/runtime

#### What did you do?

```Go
// plugin/plugin.go

package main

import (
	"os"
	"time"
)

var counter int

func main() {
	os.Exit(Main())
}

func Main() int {
	go func() {
		counter++
	}()
	time.Sleep(500 * time.Millisecond)
	return counter
}
```

```Go
// plugin-runner.go

package main

import (
	"os"
	"plugin"
)

func main() {
	p, err := plugin.Open(os.Args[1])
	if err != nil {
		panic(err)
	}
	sym, err := p.Lookup("Main")
	if err != nil {
		panic(err)
	}
	f := sym.(func() int)
	_ = f()
}
```

```bash
$ go build -o plugin/plugin.so -race -buildmode=plugin plugin/plugin.go
$ go run -race plugin-runner.go plugin/plugin.so
```

#### What did you expect to see?
A `DATA RACE` output similar to this one:
```bash
$ go run -race plugin/plugin.go
==================
WARNING: DATA RACE
Read at 0x00000051da38 by main goroutine:
  main.Main()
      /go/src/github.com/tiborvass/goissues/plugin/race-nodetect/plugin/plugin.go:19 +0x5f
  main.main()
      /go/src/github.com/tiborvass/goissues/plugin/race-nodetect/plugin/plugin.go:11 +0x2f

Previous write at 0x00000051da38 by goroutine 6:
  main.Main.func1()
      /go/src/github.com/tiborvass/goissues/plugin/race-nodetect/plugin/plugin.go:16 +0x56

Goroutine 6 (finished) created at:
  main.Main()
      /go/src/github.com/tiborvass/goissues/plugin/race-nodetect/plugin/plugin.go:15 +0x42
  main.main()
      /go/src/github.com/tiborvass/goissues/plugin/race-nodetect/plugin/plugin.go:11 +0x2f
==================
exit status 1
```

#### What did you see instead?
No output. I reproduced it 100% on both linux and darwin.

#### System details

```
go version go1.10 linux/amd64
GOARCH="amd64"
GOBIN=""
GOCACHE="/root/.cache/go-build"
GOEXE=""
GOHOSTARCH="amd64"
GOHOSTOS="linux"
GOOS="linux"
GOPATH="/go"
GORACE=""
GOROOT="/usr/local/go"
GOTMPDIR=""
GOTOOLDIR="/usr/local/go/pkg/tool/linux_amd64"
GCCGO="gccgo"
CC="gcc"
CXX="g++"
CGO_ENABLED="1"
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-build269754766=/tmp/go-build -gno-record-gcc-switches"
GOROOT/bin/go version: go version go1.10 linux/amd64
GOROOT/bin/go tool compile -V: compile version go1.10
uname -sr: Linux 4.9.75-linuxkit-aufs
/lib/x86_64-linux-gnu/libc.so.6: GNU C Library (Debian GLIBC 2.24-11+deb9u1) stable release version 2.24, by Roland McGrath et al.
```
Repository: flutter
Issue: BuildContext docs unclear
Labels: framework,d: api docs,P2,team-framework,triaged-framework

https://twitter.com/dodyg/status/970416861161586691

"""
"In particular, this means that within a build method, the build context of the widget of the build method is not the same as the build context of the widgets returned by that build method. "

I am trying to understand this.
"""
Repository: godot
Issue: GPUParticles3D shadows don't update when the node is outside the camera frustum (and CPUParticles3D does not trigger redrawing)
Labels: bug,topic:rendering,confirmed,topic:3d,topic:particles

I set up a 3D scene with the default environment, a player with a camera attached, 3D particles that emit the default spheres, and a bouncing ball. Using the directionalLight node , the shadow for the bouncing ball updates even when out of the frame, but the particle shadows do not. 

https://imgur.com/a/rFZlT
Repository: flutter
Issue: Better way to differentiate between tap and scroll
Labels: c: new feature,framework,f: gestures,c: proposal,P3,team-framework,triaged-framework

Current value of kTouchSlop seems really big, there is a very noticeable jerk at the beginning of scrolling, which is very unlike any native iOS scrollview, where scrolling feels instantaneous while tapping still works as expected. 

As far as I can tell, iOS deals with this following way: 
* The tap gesture recognizer start is slightly delayed (optional).
* The scroll gesture recognizer starts almost immediately.
* When scrolling over certain threshold, the touch tap recognizer gets cancelled. Depending on how fast user scrolls, there might be a brief highlight visible (for the time between tap gesture recognizer start and cancellation).

So tapping and scrolling in iOS are not mutually exclusive.
Repository: rust
Issue: Provide a way to const-initialize vendor-specific vector types
Labels: T-lang,C-feature-request,A-SIMD,A-const-eval

The platform independent simd types have constructors which are const fns, so they can be used in things like lookup tables: https://raw.githubusercontent.com/sfackler/stream-vbyte64/ea0d5b0afdf97f31473fafbf33d460fbbb313785/src/tables.rs.

However, the same is not the case for the vendor-specific types like `__m256i`. There are platform intrinsics which initialize those types (e.g. `_mm256_setr_epi32` is equivalent to `i32x8::new`) but those are not const fns.

One way to work around this is by type-punning through unions:

```rust
#![feature(stdsimd)]

use std::arch::x86_64::*;

#[repr(C)]
union Pun {
    a: __m256i,
    b: [u32; 8],
}

static FOO: Pun = Pun { b: [1, 2, 3, 4, 5, 6, 7, 8] };

fn main() {
    let x = unsafe { _mm256_extract_epi32(FOO.a, 3) };
    println!("{}", x);
}
```

This kind of union is pretty common in SIMD-related C code I've seen, and I think well defined behavior from what the unions RFC describes. Is this the "right" way to do this? Can/should we make functions like `_mm256_set_epi32` const?

cc @alexcrichton
Repository: opencv
Issue: Why hard code the local size to 256 in ocl_pyramid() ? modules/imgproc/src/pyramid.cpp
Labels: category: imgproc,category: ocl,RFC

##### System information (version)
<!-- Example
- OpenCV => 3.4.0
- Operating System / Platform => Arm 64
- Compiler => GCC 
-->
##### Detailed description

in ocl_pyramid(), the local work size is hard coded to 256, I think it should query the max work group size for the device.
Repository: pytorch
Issue: [feature request] Different interpolation algos for 'grid_sample' function
Labels: hackamonth,module: docs,triaged,function request,module: interpolation

The 2D grid interpolator function 'grid_sample' only does bilinear sampling from the source image at the moment. It would be useful to have 'nearest' and other samplings available. The function call does take 'mode' as a parameter but only bilinear sampling seems to have been implemented. It would especially be useful if we have to use 'grid_sample' for class label maps for segmentation, and the grid (source indices) is a Variable.


cc @jlin27 @mruberry
Repository: flutter
Issue: Help users get flutter added to path
Labels: tool,P2,team-tool,triaged-tool

## Steps to Reproduce

We are seeing lots of upstream issues in the IDEs boiling down to the root issue of users not having flutter correctly in path (for example, https://github.com/flutter/flutter/issues/15066, https://github.com/Dart-Code/Dart-Code/issues/633).

It would be good if doctor could check for this.

It would be even better if the flutter tool could offer to add to path on behalf of the user.
Repository: kubernetes
Issue: Make pod hostname/subdomain feature compatible with Deployments
Labels: sig/network,kind/feature,sig/apps,lifecycle/frozen

**Is this a BUG REPORT or FEATURE REQUEST?**:
/kind feature

**What happened**:

Following this guide - https://kubernetes.io/docs/concepts/services-networking/dns-pod-service/#pods-hostname-and-subdomain-fields

Specifically.

> If there exists a headless service in the same namespace as the pod and with the same name as the subdomain, the cluster’s KubeDNS Server also returns an A record for the Pod’s fully qualified hostname. For example, given a Pod with the hostname set to “busybox-1” and the subdomain set to “default-subdomain”, and a headless Service named “default-subdomain” in the same namespace, the pod will see its own FQDN as “busybox-1.default-subdomain.my-namespace.svc.cluster.local”. DNS serves an A record at that name, pointing to the Pod’s IP. Both pods “busybox1” and “busybox2” can have their distinct A records.

I expect to be able to use this feature in a Deployment, as deploying individual pods is not a scalable pattern.

Specifying a subdomain in the deployment works correctly.

Specifying a hostname causes all the pods in the deployment to have the same hostname - making the feature useless.

Not specifying a hostname causes DNS registration not to occur.

**What you expected to happen**:

I expect to either:
* Specify a hostname prefix in the deployment, and have the deployment put in a unique suffix, and register it with Kube-DNS 

or
* Not specify a hostname, and K8s should use the standard hostname, and register that with KubeDNS.


**How to reproduce it (as minimally and precisely as possible)**:
```
apiVersion: v1
kind: Service
metadata:
  name: busybox
spec:
  selector:
    type: busybox
  clusterIP: None
  ports:
  - name: foo # Actually, no port is needed.
    port: 1234
    targetPort: 1234
---
apiVersion: extensions/v1beta1
kind: Deployment
metadata:
  name: busybox
spec:
  replicas: 2
  template:
    metadata:
      labels:
        name: busybox
        type: busybox
      name: busybox
    spec:
      subdomain: busybox
#     hostname: foo      # optional
      containers:
      - name: worker
        image: busybox
        command:
        - sleep
        - "3600"
```

* Exec into first created pod - try to ping/dig/host other Pod by FQDN.

**Anything else we need to know?**:

I know all about StatefulSets, and how DNS registration works with those. The workload I'm deploying is individual scale-out processing with autoscaling and a natural fit for Deployments - but it does require functional per-pod DNS records.

**Environment**:
- Kubernetes version (use `kubectl version`): v1.7.12-gke.1
- Cloud provider or hardware configuration: GKE
- OS (e.g. from /etc/os-release): busybox
- Kernel (e.g. `uname -a`): 4.4.86+
Repository: angular
Issue: RouterLinkActiveOptions – Allow activating a link on multiple routes
Labels: feature,freq2: medium,area: router,feature: under consideration

## I'm submitting a...
<!-- Check one of the following options with "x" -->
<pre><code>
[ ] Regression (a behavior that used to work and stopped working in a new release)
[ ] Bug report  <!-- Please search GitHub for a similar issue or PR before submitting -->
[x] Feature request
[ ] Documentation issue or request
[ ] Support request => Please do not submit support request here, instead see https://github.com/angular/angular/blob/master/CONTRIBUTING.md#question
</code></pre>

## Current behavior
<!-- Describe how the issue manifests. -->
Currently `routerLink` can be active only on the currently specified route

## Expected behavior
<!-- Describe what the desired behavior would be. -->
It would be nice to have an option where we can provide lets say a regex or an array of routes on which we want to make the link active.

It would be useful in the cases where a component is loaded on different routes. For example, in my case, I have a route `/dashboard` that gets loaded at `/` for the logged in users and for non logged in users we load the landing page at `/`. Now in the sidebar on dashboard, I have the router link that looks like below.

```html
<a routerLink="/" [routerLinkOptions]="{exact: true}">Dashboard</a>
```

It gets activated when the user lands on dashboard through `/` but won't work when user lands on `/dashboard`. Currently, I have a custom matcher written that activates the link for me but It would be nice if I could so something like below

```html
<a routerLink="/" [routerLinkOptions]="{match:['/', '/dashboard']}">Dashboard</a>
```
Repository: opencv
Issue: CUDA median filter behavior is broken.
Labels: category: gpu/cuda (contrib),incomplete

##### System information (version)
- OpenCV => 3.4
- Operating System / Platform => Windows 64 Bit
- Compiler => Visual Studio 2017

#### Detailed description

Applying median filtering using the CUDA filter vs the CPU filter produces dramatically different results with the CUDA version not matching the expected output.  

#### CPU:
![cpuresult](https://user-images.githubusercontent.com/14917299/36986798-bedae7ca-2068-11e8-886c-8bb46b7d89d6.png)

##### CUDA:
![cudaresult](https://user-images.githubusercontent.com/14917299/36986802-c2badc24-2068-11e8-924f-af3e092aa528.png)


##### Steps to reproduce
    median.cpp
    Ptr<cv::cuda::Filter> medianCUDA = cv::cuda::createMedianFilter(CV_8U, 3);
    cv::cuda::GpuMat img_d, filtered_d;
    cv::Mat img, filtered, cudaResult;

    img = imread("input.png", IMREAD_GRAYSCALE);

    cv::medianBlur(img.clone(), filtered, 3);

    img_d.upload(img.clone());
    medianCUDA->apply(img_d, filtered_d);
    filtered_d.download(cudaResult);

    cv::imwrite("cudaResult.png", cudaResult);
    cv::imwrite("cpuResult.png", filtered);
Repository: go
Issue: cmd/go: installed c-shared libraries receiving ".a" suffix on Linux
Labels: help wanted,NeedsFix

### What version of Go are you using (`go version`)?
`go version go1.9.4 linux/amd64`

### Does this issue reproduce with the latest release?
Yes. Reproduced with `1.10`

### What operating system and processor architecture are you using (`go env`)?
```
GOARCH="amd64"
GOEXE=""
GOHOSTARCH="amd64"
GOHOSTOS="linux"
GOOS="linux"
GORACE=""
GOROOT="/usr/local/go"
GOTOOLDIR="/usr/local/go/pkg/tool/linux_amd64"
GCCGO="gccgo"
CC="gcc"
GOGCCFLAGS="-fPIC -m64 -pthread -fmessage-length=0 -fdebug-prefix-map=/tmp/go-build706877829=/tmp/go-build -gno-record-gcc-switches"
CXX="g++"
CGO_ENABLED="1"
CGO_CFLAGS="-g -O2"
CGO_CPPFLAGS=""
CGO_CXXFLAGS="-g -O2"
CGO_FFLAGS="-g -O2"
CGO_LDFLAGS="-g -O2"
PKG_CONFIG="pkg-config"
```

### What did you do?
`go install -buildmode=c-shared -x -a ./libpa`

`libpa` contains a a C library declared in a main package.

### What did you expect to see?
I expected the output file to be labeled `libpa.so` indicating it was a shared object 

### What did you see instead?
The output was labeled `libpa.a` indicating an archive file, but in actuality it was a shared object file.
```
file $GOPATH//pkg/linux_amd64_shared/<pkg dir>/libpa.a
libpa.a: ELF 64-bit LSB shared object, x86-64, version 1 (SYSV), dynamically linked, BuildID[sha1]=31934079c8d80546780a304c28421f0d8228c9a4, not stripped
```
### Additional Information
- `go build -buildmode=c-shared -o libpa.so -x -a ./libpa` produces the expected `libpa.so` output. This is how `.so` files are generated in [cshared_test.go](https://github.com/golang/go/blob/919e85ae056a238789af6bb2d7b34fe9fdde4ebb/misc/cgo/testcshared/cshared_test.go).
- `go install  -buildmode=c-archive -x -a ./libpa` produces an archive file correctly named `libpa.a`
- [init.go](https://github.com/golang/go/blob/0c14345c9638effe6d19569b8bc75caa7c026f66/src/cmd/go/internal/work/init.go) leaves the `cfg.ExeSuffix` empty for Linux machines when the `c-shared` option is selected (sets it to "`.a`" for `c-archive`).
- Passing GOEXE=".so" does not appear to overwrite the cfg.ExeSuffix.
Repository: rust
Issue: Enum variants completely shadow inherent associated functions.
Labels: C-enhancement,A-diagnostics,T-compiler

Consider the code below:
```rust
enum Foo { Bar(i32) }

impl Foo {
    fn Bar(x: i32) -> Foo { 
        println!("I'm uncallable"); 
        Foo::Bar(x) 
    }
}

fn main() {
    Foo::Bar(0); // Variant constructor.
   <Foo>::Bar(0); // Inherent function.
}
```
It compiles successfully and terminates with no output. There is an ambiguity between the variant and the associated function, <strike>though it seems we always prefer the variant, making the associated function uncallable</strike>. Having an inherent associated function with the same name as a variant should be an error.

Edit: @petrochenkov points out that it's not actually uncallable, you can call it with `<Foo>::Bar(0)`. A deny-by-default lint then perhaps?
Repository: pytorch
Issue: [feature request] F.interpolate to support integral data types: bool, int8, int32, int16, int64 ||| support uint8 on CUDA
Labels: todo,triaged

1. Bilinear upsampling on integer types like ByteTensor and LongTensor
~~2. Nearest upsampling when target size isn't divisible by input size~~
Repository: go
Issue: cmd/compile: struct field alive too long
Labels: NeedsFix,compiler/runtime

Program 1:
```
package main

import (
	"fmt"
	"runtime"
)

func main() {
	y := make([]int, 1e6)
	runtime.GC()
	var stat runtime.MemStats
	runtime.ReadMemStats(&stat)
	fmt.Println(stat.Alloc)
	fmt.Println(len(y))
}
```
Program 2:
```
package main

import (
	"fmt"
	"runtime"
)

func main() {
	type T struct {
		x int
		y *[1e6]int
	}
	t := T{x: 7, y: new([1e6]int)}
	runtime.GC()
	var stat runtime.MemStats
	runtime.ReadMemStats(&stat)
	fmt.Println(stat.Alloc)
	fmt.Println(t.x)
}
```
In program 1, the allocation at `make` is garbage collected, so program 1 prints just ~100KB of usage.
In program 2, the allocation at `new` is not garbage collected, so it prints ~8MB.

The allocation in program 2 should be GCd, it is no longer referenced.
For some reason the compiler is keeping all of t alive even though only one field of it is alive after GC.
Strangely, if I replace `fmt.Println` with `println`, then the allocation gets GCd.
I'm not entirely sure what is going on yet, but it looks like `t` is being treated as addressable.  But it is getting decomposed correctly.  Strange.

First reported here: https://groups.google.com/forum/#!topic/golang-nuts/4qmn5gw7OBQ