sharjeelyunus/github-issues-dataset huggingface dataset:
Repository: TypeScript
Issue: Reference to own class in static variable initialization to a decorated class references undecorated class instead of decorated class
Labels: Bug,Domain: Decorators

![image](https://cloud.githubusercontent.com/assets/666259/12038787/bf1aa860-ae0f-11e5-9fd2-656f49353713.png)

[TypeScript Playground link](http://www.typescriptlang.org/Playground#src=%0A%40ClassWrappingDecorator%0Aclass%20X%20%7B%0A%20%20%20static%20factory%20%3D%20createFactory%28X%29%0A%7D)
Repository: neovim
Issue: Windows: :edit filename inconsistencies
Labels: needs:decision,platform:windows,compatibility,has:plan

E.g. try the following

```
:e \s3go.
:w
```
- Vim/Windows - fails on `:write` with `E212: Can't open file for writing`
- Vim/Unix - succeeds, names the buffer on edit as `s3go.` and creates the file `s3go.` instead of `\s3go.`
- Neovim/Unix behaves like Vim/Unix
- Neovim/Windows behaves like Vim/Unix too (#810)

What is the desired behaviour here?
Repository: nvm
Issue: Unaliased sha1sum, sha1 or shasum not found
Labels: needs followup

> $ nvm install v0.10.29
> Downloading https://nodejs.org/dist/v0.10.29/node-v0.10.29.tar.gz...
> ###### ################################################################## 100.0%
> 
> Unaliased sha1sum, sha1, or shasum not found.
> nvm: install v0.10.29 failed!

Not sure what the issue is. I'm using nvm version 0.30.1. I installed it from the curl line in the readme. 

I'm using git bash as my cmd console on windows 10.

Here's my .bashrc file

> alias meteor="cmd //c meteor"^M
> export NVM_DIR="/c/Users/Matt/.nvm"
> [ -s "$NVM_DIR/nvm.sh" ] && . "$NVM_DIR/nvm.sh"

When running this code below I get this for the alias.

> $ nvm_is_alias sha1sum ; echo $?
> 1

Let me know if you need anything else. 

Thanks.
Repository: go
Issue: spec: clarify imprecise conversions of non-floating-point constant to floating point type
Labels: Documentation,NeedsInvestigation

... or perhaps the spec is does not convey the intention.

The spec says (https://golang.org/ref/spec#Conversions)

> A constant value x can be converted to type T in any of these cases:
> - x is representable by a value of type T.

The Go compiler allows conversion in certain cases, where an integer constant value is not representable as a value of type `float32`  as in:

``` go
package main

import "fmt"

func main() {
    // bad
    const A = 0x01ffffff
    const B = float32(A)
    fmt.Printf("%d\n%f\n", A, B)

    // ok
    const C = 0x01fffffe
    const D = float32(C)
    fmt.Printf("%d\n%f\n", C, D)

    // ok
    const E = 0x00ffffff
    const F = float32(E)
    fmt.Printf("%d\n%f\n", E, F)
}
```

I suppose there are similar cases when converting an integer constant into `float64`, `complex64`, or `complex128` type.
Repository: rust
Issue: Some `std::collections` types are unnecessarily invariant
Labels: C-enhancement,A-collections,T-libs-api

The following `std::collections` types are unnecessarily invariant in their type parameters:
- ~~`binary_heap::Drain`~~
- ~~`btree_map::{Keys, Values}`~~
- ~~`btree_set::{IntoIter, Iter, Range}`~~
- `btree_set::{Difference, Intersection, SymmetricDifference, Union}`
- ~~`hash_map::{IntoIter, Iter, Keys, Values}`~~
- `hash_map::Drain`
- ~~`hash_set::{Difference, Intersection, IntoIter, Iter, SymmetricDifference, Union}`~~
- `hash_set::Drain`
- ~~`linked_list::{IntoIter, Iter, LinkedList}`~~
- ~~`vec::Drain`~~
- ~~`vec_deque::Drain`~~

Some, like `btree_map::Keys`, are invariant due to the use of `iter::Map` with `fn(T) -> U` being invariant over `T`, while others, like `LinkedList`, are due to the ultimate use of `*mut T`, and the rest are wrappers around other invariant iterators.

Of these, the most important to fix is probably `LinkedList`, as the rest are iterators. Given the issue with `iter::Map`, it is likely that some other iterators in `std` have the same problem.
Repository: go
Issue: x/mobile/app: faster reshape callback on darwin_amd64
Labels: mobile

I write a simple 2d app with gomobile on mac.
I paint one image with fixed position and fixed size.
I found that when I resize the window quickly ,the image size on the screen is bigger or smaller proportionally to the screen size.
Sometimes,the image size remember the windows size in seconds ago.

After I comment out following code,the problem disappear:
![image](https://cloud.githubusercontent.com/assets/1107541/12066202/e428a8d0-b01e-11e5-94ae-39812f188cab.png)
src/golang.org/x/mobile/app/darwin_amd64.m:48

It looks like the reshape function is too slow.
May be we can cache same result from the system api.

```
gomobile version +0a85ca5 Fri Dec 25 00:41:33 2015 +0000 (android,ios); androidSDK=/usr/local/AndroidSdk/platforms/android-22
go version go1.5.2 darwin/amd64
```
Repository: go
Issue: crypto/aes: S-box cache timing leak
Labels: Security

The crypto/aes package uses S-boxes and thus leaks cache timing information.  Techniques to avoid this [are known](http://shiftleft.org/papers/vector_aes/) and should be used on all platforms Go supports.

If Go does not support the needed vector intrinsics, then support for them should be added.
Repository: flutter
Issue: We should have an offline-friendly and poor-network-friendly network layer
Labels: c: new feature,framework,would be a good package,P3,team-framework,triaged-framework

Most network APIs have the opinion that you make a request and it either succeeds, fails, or times out.

We should introduce a network API that never fails or times out. It just keeps retrying. If we encourage this to be used by most authors, then Flutter applications will be much more reliable. You wouldn't get "message send failed, try again", or broken images, or the like. You'd just get "still trying to send message", "still trying to load image", etc.
Repository: youtube-dl
Issue: Optimize metadata support for OS X
Labels: request

# Metadata functions in youtube-dl

youtube-dl comes with these metadata related arguments: `--add-metadata` and `--xattrs`.

`--add-metadata` writes into the metadata section of the container format where possible/supported whereas `--xattrs` into the filesystem's metadata section.
# Metadata on OS X

Mac users' default search feature Spotlight (and its background process `mds`, the metadata server) to my research seems to index only xattr variables from the namespace com.apple.\* whereas youtube-dl writes into `user.dublincore.*` (contributor | date | description | format | title) and `user.xdg.referrer.url`.

Therefore the `--xattrs` is completely inaccessible to Spotlight, and `--add-metadata` only accessible if youtube-dl can 1) write into the container format and 2) Spotlight supports parsing the container's metadata and 3) Spotlight maps the variables correctly (to a certain degree).

Example: `kMDItemDescription` got filled by Spotlight for a 3gp file with `--add-metadata` but not for a mp4 file with `--add-metadata`.
# Feature request

It would be fine if there would be an option --spotlight which would write the metadata into the appropriate OS X specific metadata locations.
# Implementation hints

I'm no savvy developer, but would like to provide some resources at least:

1) [Apple Developer Documentation on Spotlight Metadata Attributes](https://developer.apple.com/library/archive/documentation/CoreServices/Reference/MetadataAttributesRef/Reference/CommonAttrs.html), i.e.:
`kMDItemWhereFroms` would be the ideal destination for the URL.
`kMDItemDescription` would be the ideal destination for the description.
…

2) Writing metadata seems to be done with:
`xattr -w com.apple.metadata:<properVariable> "<MetadataValueHere>" <file>`
But it [seems to be a bit tricky](http://stackoverflow.com/questions/8530825/mac-os-x-add-a-custom-meta-data-field-to-any-file), as some metadata exists in multiple places (legacy) and must thus be properly synchronized in order to show up in Spotlight as well as showing up in the Finder info windows, and it seems that the value cannot be written as plaintext, but must be encapsulated as PLIST (XML format for Apple property list) or binary PLIST.
Repository: nvm
Issue: FR: Notify on newer version of node.
Labels: feature requests

Say the current default version in the users machine is `v5.1.0` and the remote latest is `v5.2.0`, it would be nice have a notification system in place which would indicate the user that a greater version is available.

We could indicate this when the user invokes `nvm` or `node -v`.

//cc @ljharb
Repository: TypeScript
Issue: Incorrect autocomplete suggestion with dots
Labels: Bug,Help Wanted

``` ts
1;
12;
```

Add a dot.

``` ts
.1;
1.2;
```

Then Visual Studio 2015 suggests global variables.
Repository: youtube-dl
Issue: Add support for cwseed.com show pages
Labels: site-support-request

Hi, I'd like to vote to add the following site which does not appear to currently work but does list all videos on one page, etc. so given other supported sites doesn't look like it would be very different:

Site:
http://www.cwseed.com

Example of series page:
http://www.cwseed.com/shows/the-oc
Repository: go
Issue: net/http: transport MaxIdleConnsPerHost  does not work as expected
Labels: help wanted,NeedsFix

I recently had an issue which made Go consume all ephemeral ports and start failing to do requests.
The problem was triggered because I was doing 10 concurrent requests with the DefaultMaxIdleConnsPerHost so Transport was only reusing 2 connections and closing the other 8 as soon as a request was finished, just to reestablish a connection again.
This seems a really bad behavior and never happened to me on any other language or http client.
A connection is usually considered idle when it was not used for a period of inactivity, maybe a whole keepalive period or so, not after a request has been sent successfully.
The behavior one would expect is to have 10 established connections and, after say 30 seconds of not issuing any request having only 2 connections established as per DefaultMaxIdleConnsPerHost.

Here is a [gist](https://gist.github.com/sschepens/062c7dbdf29272eea4af) that triggers this behavior.

I'm running go 1.5.2 on Ubuntu Precise 12.04, kernel: Linux e-0000e768 3.8.0-44-generic #66~precise1-Ubuntu SMP Tue Jul 15 04:01:04 UTC 2014 x86_64 x86_64 x86_64 GNU/Linux
Repository: youtube-dl
Issue: --sub-lang shall accept language wildcard syntax
Labels: request

I'd welcome a language wildcard syntax, i.e. "I want 'en_' no matter what dialect" or "I want 'en-uk,en_' as in 'British English first else any English available' ") to spare the user lengthy language code guesswork/generalisation or the need for a manual --list-sub investigation prior downloading, which if resorting to somehow diminuishes youtube-dl as a batch tool.
Repository: neovim
Issue: Abort multikey commands after `timeoutlen`
Labels: bug-vim

Over the msgpack-rpc connection it is possible to send `vim_input "<C-w>"` and then to wait forever for the second part of the key sequence. Actually there should be a timeout. It would make sense to use the same value that is already used in vim, namely `timeoutlen`.
Repository: neovim
Issue: Expose window layout
Labels: enhancement,api,ui

This issue actually just repeats what is already described by @tarruda as the "[smart UI protocol](http://tarruda.github.io/articles/neovim-smart-ui-protocol/)" but I want to have it as a ticket to get feedback when it is available.

Over the last weeks, I spent a lot of time by implementing a smart UI on the client side by myself, i.e. I implemented a window manager for neovim windows, whose state can be synced with the state of neovims internal window manager. I don't have to say that it took me forever to get to this point but I want to say that I learned that such a sync is actually impossible for all possible use cases. The problem is easily described:

```
-----
| | |
-----
| | |
-----
```

These are four windows but it is ambiguous if there are two columns that each contain a row of two windows or if there are two rows that each contain two columns. It can't be detected but needs to, otherwise the client can't be correctly updated when the user moves between the windows. Instead of a list of windows, the neovim API needs to expose a tree. In Haskell, it could be described in this way:

``` haskell
data WindowTree = Rows [WindowTree] | Columns [WindowTree] | Window Int
```

A window tree is either a row, a column  or a window, where the window is represented by a number and the other twos can be arbitrarily nested and contain each a list of further window trees.

I hope the smart UI protocol gets real one day because I really need it to implement my UI correctly.
Repository: opencv
Issue: calcOpticalFlowPyrLK yields incorrect result when using OpenCL
Labels: bug,category: video,affected: 3.4,category: ocl,category: t-api

Visual Studio 2015
OpenCV 3.1.0
WITH_OPENCL enabled
WITH_OPENCL_SVM enabled/disabled (always occur)

Concise sample code:

```
cout << "useOpenCL: " << ocl::useOpenCL() << endl;

// Just the sample video shipped with OpenCV source
VideoCapture cap("D:\\work\\opencv_3.1\\opencv\\sources\\samples\\data\\768x576.avi");

UMat f0, f1, g0, g1;
cap >> f0;
cap >> f1;

cvtColor(f0, g0, COLOR_BGR2GRAY);
cvtColor(f1, g1, COLOR_BGR2GRAY);

Mat p0(8, 1, CV_32FC2), p1, status, err;
theRNG().fill(p0, RNG::UNIFORM, 0, min(f0.rows, f0.cols));

calcOpticalFlowPyrLK(g0, g1, p0, p1, status, err);

cout << "p0: " << p0 << endl;
cout << "p1: " << p1 << endl;
cout << "status: " << status << endl;
cout << "err: " << err << endl;
```

Output when OpenCL is disabled:

```
useOpenCL: 0
p0: [305.4429, 114.7733;
 231.01024, 469.08582;
 251.78859, 143.30287;
 445.30853, 438.966;
 177.28961, 404.60065;
 275.5856, 456.30145;
 49.445633, 43.234711;
 94.131866, 172.67282]
p1: [305.45264, 114.76205;
 231.08749, 469.09006;
 251.80547, 143.31331;
 445.29504, 438.96689;
 177.42975, 404.54962;
 275.69241, 456.32147;
 49.464996, 43.233234;
 94.185921, 172.67618]
status: [  1;
   1;
   1;
   1;
   1;
   1;
   1;
   1]
err: [1.2229308;
 1.2712585;
 1.2330641;
 1.5741214;
 1.2522676;
 1.2371032;
 1.4520266;
 1.9238945]
```

Output when OpenCL is enabled:

```
useOpenCL: 1
p0: [305.4429, 114.7733;
 231.01024, 469.08582;
 251.78859, 143.30287;
 445.30853, 438.966;
 177.28961, 404.60065;
 275.5856, 456.30145;
 49.445633, 43.234711;
 94.131866, 172.67282]
p1: [305.45108, 114.7645;
 14.43814, 29.317863;
 15.736787, 8.9564295;
 27.831783, 27.435375;
 11.080601, 25.28754;
 17.2241, 28.518841;
 3.0903521, 2.7021694;
 5.8832417, 10.792051]
status: [  1;
   1;
   1;
   1;
   1;
   1;
   1;
   1]
err: [1.2273066;
 -4.3160208e+08;
 -4.3160208e+08;
 -4.3160208e+08;
 -4.3160208e+08;
 -4.3160208e+08;
 -4.3160208e+08;
 -4.3160208e+08]
```

This problem occurs only if grayscale images (g0, g1) are passed, and for colored images, i.e. passing f0, f1 instead of g0, g1, it's correct in both cases.
Repository: opencv
Issue: cv::namedWindow will not spawn a new opengl window if you try to create a window that has been closed.
Labels: bug,category: highgui-gui

On windows using the current master branch, msvc2013x64. Qt5.5, OpenGL on.

If you create a window with cv::namedWindow with the OpenGL flag, and then close the window with the [X] button, subsequent calls to cv::namedWindow with the same window name and an OpenGL flag will not create a new window.

Minimal test:

int main()
{
    cv::Mat mat(100,100,CV_8UC3);
    while(cv::waitKey(1) != 27)
    {
        cv::namedWindow("test", cv::WINDOW_OPENGL);
        cv::imshow("test", mat);
    }
}

However removing the cv::WINDOW_OPENGL flag has a different behavior.
Repository: vscode
Issue: Proposal: Add mnemonics to context menu items
Labels: feature-request,menus

On Windows systems it looks like context menu items don't have accelleration characters assigned to them. Getting used to accessing context menu items by using the keyboard it would be an improvement to see the acceleration character displayed along with the context menu immediately.

So I suggest to display a context menu item's acceleration character along with the context menu.
Repository: go
Issue: crypto/tls: Set{Read,Write}Deadline implementation is surprising/ineffective
Labels: NeedsInvestigation

Bear with me, this is a little long-winded, but I'm not sure how I can explain this more succinctly..

The current implementation of these functions is to pass them directly through to c.conn. Judging by my understanding of how TLS works, I think this is wrong. Picture a TLS listener socket which has just accepted a client (which won't ever complete a handshake, say, telnet or something).

Given:

```
type aClient struct {
    conn net.Conn
}
```

On accept of an incoming connection, an aClient instance is created (with conn populated from the TLS listener) & the server is instructed to time out the client after X seconds of not sending anything (through a goroutine, a Timer, and a channel to cancel the goroutine), something like this:

```
func authTimeout(client *aClient, controlChan chan int) {
    for {
        timer := time.NewTimer(time.Second * 5)
        select {
        case <-timer.C:
            client.Write("You didn't authenticate in time.")
            client.conn.Close()
            return
        case <-controlChan:
            return
        }
    }
}
```

client.Write's implementation looks something like this:

```
func (this *aClient) Write(format string, args ...interface{}) {
    // one would expect this to time out...
    this.conn.SetWriteDeadline(time.Now().Add(10 * time.Second))
    this.conn.Write(fmsg)
    // but if the client doesn't handshake, it'll hang!
}
```

authTimeout's timer will successfully fire, Write will be called, and set the Write deadline, and attempt to write. However, because the connection hasn't been read/written previously, it needs a handshake. And as handshaking requires reading from the underlying socket, this write deadline won't ever actually trigger.

This, to me, is incorrect/surprising. I'm not entirely sure what the behaviour of deadlines should be before handshake (maybe take whichever is the lowest? Maybe offer an explicit handshake deadline?) but I'm pretty sure there needs to be _something_ done here even if that something is just a warning in the documentation. This bit me when blindly porting some code over from net/tcp to TLS.

It's worth noting, also, that net/http/transport.go tries to work around this very issue, but at least my own attempts to implement a similar pattern (handshake right after accepting, with a goroutine to time out the handshake and Close() on fail) seemed to suffer similar problems with Close() never returning unless I set both a ReadDeadline and WriteDeadline. I didn't (yet) analyze this problem, though.
Repository: kubernetes
Issue: Passing `--cert-dir` to kube-apiserver overwrites existing certs
Labels: priority/backlog,kind/documentation,sig/api-machinery,lifecycle/frozen

It seems to actually overwrite existing ones
Repository: kubernetes
Issue: Passing only `--tls-cert-file` produces cryptic error message
Labels: priority/backlog,kind/documentation,sig/api-machinery,lifecycle/frozen

It says: `E0105 14:50:09.165099      10 server.go:633] Unable to listen for secure (open : no such file or directory); will try again.`

I've also had `--cert-dir` set at the time, not sure if that somehow triggered an edge case of sorts. I've only tested this with v1.1.3 binaries.
Repository: neovim
Issue: Enable Ctrl-U Ctrl-O in completion mode
Labels: enhancement

Vim disables Ctrl-U in user defined completion mode and Ctrl-O in omni completion mode.  See https://github.com/Valloric/YouCompleteMe/issues/24 for some detail.

It seems that the these keys are hard coded in vim so that it is impossible to restore their original function through mapping.  Ctrl-O is heavily used in a lot of insert mode mapping and Ctrl-U is often used to delete an line.  I hope these keys can be mapable in completion mode.
Repository: go
Issue: runtime/pprof: CPU profiles incorrect for kernels with broken setitimer support
Labels: compiler/runtime

As of Go 1.6, pprof's CPU profiles are known to be incorrect on a few systems due to what are arguably kernel bugs. This issue documents those systems.

The text below distinguishes a profile being incomplete (missing profile samples for code that was running) from being incorrect (containing samples for code that wasn't running).
- DragonflyBSD (all known versions): Delivers a profiling signal only when a thread runs continuously for an entire clock tick (20ms). In workloads with high context-switch or garbage collection rates, this may cause profiles to be incomplete.
- Linux (without CONFIG_HIGH_RES_TIMERS=y): Delivers a profiling signal only when a thread runs continuously for an entire clock tick (often 10ms). In workloads with high context-switch or garbage collection rates, this may cause profiles to be incomplete. Most Linux kernels in use today do enable high-resolution timers and therefore do _not_ suffer from this problem.
- NetBSD (all known versions): Delivers signals to the wrong thread. On such systems, profiles are commonly very incorrect.
- OpenBSD (all known versions): Delivers a profiling signal only when a thread runs continuously for an entire clock tick (20ms). In workloads with high context-switch or garbage collection rates, this may cause profiles to be incomplete.
- OS X (fixed in OS X 10.11 El Capitan): Deliver signals to the wrong thread. On such systems, profiles are commonly very incorrect. See rsc.io/pprof_mac_fix for a workaround on those early systems.
- Solaris (fixed in Solaris 8): Delivers a profiling signal only when a thread runs continuously for an entire clock tick (10ms). In workloads with high context-switch or garbage collection rates, this may cause profiles to be incomplete. Solaris 8 fixes the problem on systems with APIC hardware (most x86 systems). On systems that continue to exhibit the problem, adding `set hires_tick = 1` to `/etc/system` can mitigate this problem somewhat by reducing the clock tick to 1ms.

Please comment on this issue only if the text above is incomplete or incorrect; we will keep this top-level comment up to date.
Repository: vscode
Issue: Add some API to support GUI customization
Labels: feature-request,api

VS Code is a great coding IDE, but developers love to customize their tools to make them feel like home and VS Code lacks those customization abilities. 

I love the sublime material theme and I wanted to implement it in VS Code but as far as I can see it's not possible now because only the coding area is customizable. So in my opinion some improvement in ui customization would be welcomed by a lot of us. In the ideal word every pixel and element of VS Code should be customizable with extensions, but for start it would be enough to start with the following things:
- ~customization of the side panel (#123)~ - marked as done in https://github.com/microsoft/vscode/issues/211#issuecomment-244362718
- ~adding support for custom tabs, the possibilities of the quick box is very limited (#710)~ - marked as done in https://github.com/microsoft/vscode/issues/710#issuecomment-385573949
- adding the ability to add and remove ui elements (e.g. a bottom panel for error listing like in Atom)

I have read about the [approach](https://code.visualstudio.com/docs/extensions/our-approach) followed by VS Code. So instead of allowing extensions to create custom ui elements, VS Code itself should provide some API for this, what allows to the developers to set the content, but the styling of the content should be based on the theme of VS Code.

So in a nutshell: VS Code core provide the bones and template of the ui elements, extension developers can set the content but not the style and theme developers can style the content.