sharjeelyunus/github-issues-dataset huggingface dataset:
Repository: TypeScript
Issue: Related error spans for derived members in interfaces/classes
Labels: Suggestion,Help Wanted,Domain: Related Error Spans,Experience Enhancement

Now that we support multiple related spans for errors (#10489, #22789, #24548), we'd like to improve an existing error message.

Currently, we provide certain errors for when a derived type incorrectly overrides/implements a member from the base type:

```
Class '{0}' defines instance member function '{1}', but extended class '{2}' defines it as instance member accessor.
Class '{0}' defines instance member function '{1}', but extended class '{2}' defines it as instance member property.
Class '{0}' defines instance member property '{1}', but extended class '{2}' defines it as instance member function.
Class '{0}' defines instance member accessor '{1}', but extended class '{2}' defines it as instance member function.
Property '{0}' in type '{1}' is not assignable to the same property in base type '{2}'.
```

We can actually provide the base type's member as a related span location for some extra context.

```
'{0}' redefines '{1}' in an incompatible way.
```

Where

* `0` is the derived type
* `1` is the member name

and this gets reported on the base type member.
Repository: flutter
Issue: [request] Provide static libraries for Custom Flutter Engine Embedders
Labels: engine,e: embedder,c: proposal,P2,team-engine,triaged-engine

https://github.com/flutter/flutter/wiki/Custom-Flutter-Engine-Embedders currently provides dynamic libraries for the flutter engine.

It would be incredibly useful if static libraries were also provided!
Repository: rust
Issue: Wrong lifetime is inferred in the argument of closure when given more specific type.
Labels: A-lifetimes,A-closures,T-compiler,A-inference,A-impl-trait,C-bug

I have lifetime bounds to a closure through a trait like this.
```rust
trait Closure<'t> {}
impl<'t, F: Fn(&'t ())> Closure<'t> for F {}

fn restrict_trait(_: impl Closure<'static>) {}
```
When I call `restrict_trait(|r| ...)`, I'll get `r: &'static ()` inside the closure. But when using `restrict_trait(|r: &_| ...)`, the lifetime of `r` inferred is not `'static` anymore.

Here is the [detailed example](https://play.rust-lang.org/?gist=2bdd08b5d0a1ad2512afcad18426a4b7&version=nightly&mode=debug)
Repository: neovim
Issue: termguicolors: fallback to cterm if gui is not set (Vim patches)
Labels: enhancement,has:vim-patch,needs:discussion,highlight

`:hi SpellBad cterm=undercurl ctermfg=1 gui=undercurl guisp=Red` does not get displayed as red (ctermfg 1).

This is supported in Vim since:
```
vim-patch:8.0.1544: when using 'termguicolors' SpellBad doesn't show

Problem:    When using 'termguicolors' SpellBad doesn't show.
Solution:   When the GUI colors are not set fall back to the cterm colors.
```
https://github.com/vim/vim/commit/d4fc577e60d325777d38c00bd78fb9a32c7b1dfa

The patch is not trivial, and requires at least 8.0.0754 and 8.0.0760 before.
Repository: TypeScript
Issue: in typescript 2.8, a common definition of Omit causes declarations that don't compile to be generated
Labels: Bug

**TypeScript Version:**
Reproduces with 3.0.0-dev.201xxxxx, 2.9.2, 2.8.4

**Search terms**
omit, declaration, pick, undefined

**Example**
```
export type Omit<T, K extends keyof T> = Pick<T, 
    ({ [P in keyof T]: P } & { [P in K]: never } )[keyof T]>;

export interface IOmitTest {
	(): { notSupposedToHappen: Omit<IXProps, "unwantedProp"> }
}

export interface IXProps {
    optionalProp?: string
    unwantedProp: string
}

const Y: IOmitTest = null as any;
export const Z = Y();

export interface IMouseOver {
    wrong: Omit<IXProps, "unwantedProp">
}
```

generates

```
export declare type Omit<T, K extends keyof T> = Pick<T, ({
    [P in keyof T]: P;
} & {
    [P in K]: never;
})[keyof T]>;
export interface IOmitTest {
    (): {
        notSupposedToHappen: Omit<IXProps, "unwantedProp">;
    };
}
export interface IXProps {
    optionalProp?: string;
    unwantedProp: string;
}
export declare const Z: {
    notSupposedToHappen: Pick<IXProps, "optionalProp" | undefined>;
};
export interface IMouseOver {
    wrong: Omit<IXProps, "unwantedProp">;
}
```

The interface returning a function seems to be required to get typescript to collapse the Omit to a Pick statement (otherwise you just get Omit<IXProps, "unwatedProp"> in the declaration file).

I think this is a bug in typescript because it's produced a declaration file with syntax errors in it.

**Expected behavior:**
undefined should not be present in the Pick statement

**Playground Link:** 
the playground does not provide the ability to generate declartions

**Related Issues:**
https://github.com/Microsoft/TypeScript/issues/12215

note that if the definition of Omit is replaced with the newer declaration possible in typescript 2.9
```
export type Omit<T, K extends keyof T> = Pick<T, Exclude<keyof T, K>>
```

then

```
export declare const Z: {
    notSupposedToHappen: Pick<IXProps, "optionalProp">;
};
```

results as expected.

I actually encountered this issue using when using connect() in react-redux with a component with an optional property, where the definition of Omit is:

```
type Omit<T, K extends keyof T> = Pick<T, ({ [P in keyof T]: P } & { [P in K]: never } & { [x: string]: never, [x: number]: never })[keyof T]>;
```
Repository: kubernetes
Issue: Provide an update-boilerplate script
Labels: sig/contributor-experience,kind/feature,lifecycle/frozen

**Is this a BUG REPORT or FEATURE REQUEST?**:
/kind feature

**What happened**:
Part of the tests that run once a PR is submitted is `pull-kubernetes-verify`. Right now, contributors have to manually copy and paste boilerplate headers so that any new files they add as part of a PR pass the `hack/verify-boilerplate.sh` validation.

**What you expected to happen**:
Offer a way to update the boilerplate content of files in an automatic way. This would improve the contributor experience.

**How to reproduce it (as minimally and precisely as possible)**:
Add files, forget to add headers, see your PR fail `pull-kubernetes-verify`.

**Environment**:
Not applicable

**Additional/Future related work**:
The same script could be reused to keep licence headers up to date, i.e. refresh the year on licence headers when it's executed.

@kubernetes/sig-contributor-experience-feature-requests

cc @hoegaarden @totherme
Repository: vscode
Issue: Add prompt to "test on insiders" to issue reporter
Labels: feature-request,good first issue,issue-reporter

In the issue reporter, add a prompt the test using the latest insiders build. Many issues reported against stable have already been fixed in insiders
Repository: neovim
Issue: Windows: "E138: main.shada.tmp.X files exist, cannot write ShaDa" on close
Labels: bug,platform:windows,has:plan,filesystem,editor-state

- `nvim --version`:
```
NVIM v0.3.0
Build type: RelWithDebInfo
LuaJIT 2.0.5
Compilation: C:/msys64/mingw64/bin/gcc.exe -Wconversion -DNVIM_MSGPACK_HAS_FLOAT32 -DNVIM_UNIBI_HAS_VAR_FROM -O2 -g -DMI
N_LOG_LEVEL=3 -Og -g -Wall -Wextra -pedantic -Wno-unused-parameter -Wstrict-prototypes -std=gnu99 -Wimplicit-fallthrough
 -D__USE_MINGW_ANSI_STDIO -D_WIN32_WINNT=0x0600 -Wvla -fdiagnostics-color=auto -Wno-array-bounds -DINCLUDE_GENERATED_DEC
LARATIONS -IC:/projects/neovim/build/config -IC:/projects/neovim/src -IC:/projects/neovim/.deps/usr/include -IC:/msys64/
mingw64/include -IC:/projects/neovim/build/src/nvim/auto -IC:/projects/neovim/build/include
Compiled by appveyor@APPVYR-WIN


Features: -acl +iconv -jemalloc +tui
See ":help feature-compile"

   system vimrc file: "$VIM\sysinit.vim"
  fall-back for $VIM: "C:/Program Files (x86)/nvim/share/nvim"

Run :checkhealth for more info
```
- Operating system/version: Windows 10 Pro 1703 15063.1115
- Terminal name/version:
- `$TERM`:

### Steps to reproduce using `nvim -u NORC`

```
nvim -u NORC
:q
```

### Actual behaviour
![nvime138repro](https://user-images.githubusercontent.com/2086176/41547037-614b1a5a-72dc-11e8-8d70-e1ed595e3d9e.gif)

### Expected behaviour
Close without error.
Repository: pytorch
Issue: [Caffe2] Wrong prediction with simple FF
Labels: caffe2

Hello,
I am new to Caffe2.
For my first attempts with Caffe2 I am trying a simple Feed Forward, but I don't get a correct prediction.
Could please somebody explain my mistake?

It's a simple net to solve a XOR


```
data = np.array([[0, 0],[0, 1], [1, 0], [1, 1]]).astype(np.float32)
label = np.array([[0],[1],[1],[0]]).astype(np.float32)

workspace.FeedBlob("data", data)
workspace.FeedBlob("label", label)

print(workspace.FetchBlob("data"))

m = model_helper.ModelHelper(name="my first net")

weight = m.param_init_net.XavierFill([], 'fc_w', shape=[2, 2])
bias = m.param_init_net.ConstantFill([], 'fc_b', shape=[2, ])

fc_1 = m.net.FC(["data", "fc_w", "fc_b"], "fc1")
pred = m.net.Sigmoid(fc_1, "pred")


weight2 = m.param_init_net.XavierFill([], 'fc_w2', shape=[1, 2])
bias2 = m.param_init_net.ConstantFill([], 'fc_b2', shape=[1, ])

fc_2 = m.net.FC(["pred", "fc_w2", "fc_b2"], "fc2")
pred2 = m.net.Sigmoid(fc_2, "pred2")

xent = m.net.SigmoidCrossEntropyWithLogits([pred2,"label"], "xent")
loss = m.net.AveragedLoss(xent, "loss")

# learning
gradient_map = m.AddGradientOperators([loss])
ITER = m.param_init_net.ConstantFill([], "ITER", shape=[1], value=0)
m.net.Iter(ITER, ITER)
LR = m.net.LearningRate(ITER, "LR", base_lr=-0.1, policy="step", stepsize=1, gamma=0.999 )
ONE = m.param_init_net.ConstantFill([], "ONE", shape=[1], value=1.0)

# update weights
m.net.WeightedSum([weight, ONE, gradient_map[weight], LR], weight)
m.net.WeightedSum([bias, ONE, gradient_map[bias], LR], bias)

m.net.WeightedSum([weight2, ONE, gradient_map[weight2], LR], weight2)
m.net.WeightedSum([bias2, ONE, gradient_map[bias2], LR], bias2)


workspace.RunNetOnce(m.param_init_net)

workspace.CreateNet(m.net)

workspace.RunNet(m.name, 1) 

print(workspace.FetchBlob("pred2"))
print(workspace.FetchBlob("loss"))

for i in range(100000):
    r = randint(0, 3)
    inp = np.array([data[r]])
    inplbl = np.array([label[r]])

    workspace.FeedBlob("data", inp)
    workspace.FeedBlob("label", inplbl)
    workspace.RunNet(m.name, 10) 
    
print "------------------"
print(workspace.FetchBlob("pred2"))
print(workspace.FetchBlob("loss"))

print "------------------"
workspace.FeedBlob("data", data)
workspace.FeedBlob("label", label)

workspace.RunNet(m.name, 1) 

print(workspace.FetchBlob("pred2"))
print(workspace.FetchBlob("loss"))
```
Repository: go
Issue: x/tools/go/ssa: wrong ssa referrers with ifstmt
Labels: Tools

Please answer these questions before submitting your issue. Thanks!


### What version of Go are you using (`go version`)?
go version go1.10.2 linux/amd64

### Does this issue reproduce with the latest release?
yes

### What operating system and processor architecture are you using (`go env`)?
GOARCH="amd64"
GOBIN=""
GOCACHE="/home/nabice/.cache/go-build"
GOEXE=""
GOHOSTARCH="amd64"
GOHOSTOS="linux"
GOOS="linux"
GOPATH="/home/nabice/go:/home/nabice/skygo/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-build010669814=/tmp/go-build -gno-record-gcc-switches"

### What did you do?
Package: golang.org/x/tools/go/ssa
ok.Referrers do not contains Ifstmt
https://play.golang.org/p/wkERfEjeSu1

I found it is replaced here:
https://github.com/golang/tools/blob/e10d6c9a84802dced65cb0278773be159bb7ed07/go/ssa/blockopt.go#L89
### What did you expect to see?
ok.Referrers contain Ifstmt's cond -- "ok"

### What did you see instead?
wrong
Repository: go
Issue: proposal: testing: add a flag to detect unnecessary skips
Labels: Proposal,Proposal-Hold

**Motivation**

We often use `(*testing.T).Skip` to skip tests that fail due to known bugs in the Go toolchain, the standard library, or a specific platform where the test runs.

When the underlying bugs are fixed, it is important that we remove the skips to prevent regressions.

However, bugs are sometimes fixed without us noticing — especially if they are platform bugs. In such cases, it would be helpful to have some way to detect that situation short of editing and recompiling all of the tests in a project.

[Here](https://github.com/golang/go/blob/964639cc338db650ccadeafb7424bc8ebb2c0f6c/misc/cgo/test/issue17065.go#L24) is a concrete example in the standard library: a `t.Skip` call that references an issue that was marked closed back in 2016 (#17065). Given how easy that call was to find, I expect that similarly outdated skips are pervasive.

**Proposal**

A new boolean flag for the `testing` package, tentatively named `-test.unskip`, with the corresponding `go test` flag `-unskip`. `-test.unskip` takes a regular expression, which is matched against the formatted arguments of `t.Skip` or `t.Skipf` or the most recent test log entry before `t.SkipNow`.

If a `Skip` matches the regular expression, the test does not stop its execution as usual: instead, it continues to run. **If the skipped test passes, the test is recorded as unnecessarily-skipped and the binary will exit with a nonzero exit code.** If the skipped test fails, the test log (and the exit code of the test binary) ignores the failure and proceeds as usual.

**Comparison**

Test frameworks in a few other languages provide an explicit mechanism for expecting a test to fail. For example, Python has [`@unittest.expectedFailure`](http://go/pylib/unittest.html#skipping-tests-and-expected-failures); Boost has an [`expected_failures`](https://www.boost.org/doc/libs/1_67_0/libs/test/doc/html/boost_test/testing_tools/expected_failures.html#l_expected_failure) decorator; RSpec has the [pending](https://relishapp.com/rspec/rspec-core/v/3-7/docs/pending-and-skipped-examples) keyword.
Repository: flutter
Issue: Build interactive reports of engine, APK & IPA sizes on each build.
Labels: team,platform-ios,engine,P3,team-ios,triaged-ios

This issue tracks the creation of reproducible reports generated by @goderbauer in [his preliminary document](https://docs.google.com/document/d/1hZUIKCPsUSfZ0Nt7_b9CE0izlteeHmOf2PzrlGZ_chk/edit?disco=AAAAB6lPw9Y&ts=5b27f6f2#heading=h.byyqjskjk9nl) investigating engine and APK sizes.
Repository: flutter
Issue: LongPressDraggable doesn't have accessibility semantics for its long press action in iOS
Labels: platform-ios,framework,a: accessibility,has reproducible steps,P2,found in release: 3.3,found in release: 3.6,team-ios,triaged-ios

cc @jonahwilliams
Repository: rust
Issue: The locally-installed docs try to load non-local assets, causing them to fail on a bad connection. 
Labels: C-enhancement,A-docs

The locally-installed docs that open when you use `rustup docs` try to load a few assets from a CDN. This is fine if you have no network connection at all, because they will fail quickly and the page will render.

However, if you have a very poor/slow network connection, they will try to load, and nothing on the page will render.

Please make the locally-installed docs not depend on non-local resources at all.
Repository: angular
Issue: Post strictPropertyInitialization flag flip cleanup
Labels: type: bug/fix,freq2: medium,area: core,P4


## I'm submitting a...

[x] Other... Please describe: Tracking issue for internal cleanup.
</code></pre>

## What needs to be done

In order to quickly turn on strictPropertyInitialization flag in the whole code base, we introduced `!` on every non-initialized class field. Each one of those fields needs to be individually checked and decided whether:

- the field should be initialized. Thus `foo!: string`, should become `foo = 'default'`.
- the field should be marked as optional. Thus `foo!: string`, should become `foo?: string`. 
- the field is reliably initialized, but TS cannot infer that (initialization can occur outside the ctor, for example), so `!` should be kept.
Repository: flutter
Issue: Flutter Engine should consider banning static initializers
Labels: engine,P3,team-engine,triaged-engine

See Chromium's policy and reasoning:
https://chromium.googlesource.com/chromium/src/+/lkcr/docs/static_initializers.md
http://neugierig.org/software/chromium/notes/2011/08/static-initializers.html

Unless maybe already our build rules do?  @chinmaygarde might know.
Repository: rust
Issue: Trait bounds are not checked on type aliases until they are used
Labels: A-diagnostics,A-trait-system,P-medium,T-compiler,C-bug

Consider the following code:

```rust
#![crate_type = "lib"]

pub trait Trait {}

pub struct Foo<T: Trait>(T);

pub struct Qux;

pub type Bar<T=Qux> = Foo<T>;
```

This builds without an error although `Qux` doesn't respect the trait bound.

Build failure only occurs when one actually uses the type alias, like the following:

```rust
fn foo(_: Bar) {}
```
Repository: pytorch
Issue: Cannot allocate memory Error from operator
Labels: caffe2

https://caffe2.ai/docs/tutorial-MNIST.html
Finally, we can plot the results using pyplot.
```
# The parameter initialization network only needs to be run once.
workspace.RunNetOnce(train_model.param_init_net)
# creating the network
workspace.CreateNet(train_model.net, overwrite=True)
# set the number of iterations and track the accuracy & loss
total_iters = 200
accuracy = np.zeros(total_iters)
loss = np.zeros(total_iters)
# Now, we will manually run the network for 200 iterations.
for i in range(total_iters):
    workspace.RunNet(train_model.net)
    accuracy[i] = workspace.FetchBlob('accuracy')
    loss[i] = workspace.FetchBlob('loss')
# After the execution is done, let's plot the values.
pyplot.plot(loss, 'b')
pyplot.plot(accuracy, 'r')
pyplot.legend(('Loss', 'Accuracy'), loc='upper right')
```
---------------------------------------------------------------------------
RuntimeError                              Traceback (most recent call last)
<ipython-input-19-aad356a03a21> in <module>()
      1 # The parameter initialization network only needs to be run once.
----> 2 workspace.RunNetOnce(train_model.param_init_net)
      3 # creating the network
      4 workspace.CreateNet(train_model.net, overwrite=True)
      5 # set the number of iterations and track the accuracy & loss

/usr/local/lib/python2.7/dist-packages/caffe2/python/workspace.pyc in RunNetOnce(net)
    197         C.Workspace.current._last_failed_op_net_position,
    198         GetNetName(net),
--> 199         StringifyProto(net),
    200     )
    201 

/usr/local/lib/python2.7/dist-packages/caffe2/python/workspace.pyc in CallWithExceptionIntercept(func, op_id_fetcher, net_name, *args, **kwargs)
    176 def CallWithExceptionIntercept(func, op_id_fetcher, net_name, *args, **kwargs):
    177     try:
--> 178         return func(*args, **kwargs)
    179     except Exception:
    180         op_id = op_id_fetcher()

RuntimeError: [enforce fail at lmdb.cc:20] mdb_status == MDB_SUCCESS. 12 vs 0. Cannot allocate memory Error from operator: 
output: "dbreader_/home/kylin/\344\270\213\350\275\275/caffe2_notebooks/tutorial_data/mnist/mnist-train-nchw-lmdb" name: "" type: "CreateDB" arg { name: "db_type" s: "lmdb" } arg { name: "db" s: "/home/kylin/\344\270\213\350\275\275/caffe2_notebooks/tutorial_data/mnist/mnist-train-nchw-lmdb" }



- CUDA/cuDNN version: none
- 
- GPU models and configuration: none
Repository: flutter
Issue: Flutter doctor does not detect all installs of the Android SDK
Labels: tool,t: flutter doctor,P2,team-tool,triaged-tool

Flutter Doctor can't tell the difference between Android SDK not installed and sdkmanager pieces not instaled. To reporoduce:

```
$ flutter doctor -v.
[✗] Android toolchain - develop for Android devices
    ✗ ANDROID_HOME = /usr/local/share/android-sdk/
      but Android SDK not found at this location.
```

OK, let's try this:

```
$ sdkmanager "tools"
$ sdkmanager "platform-tools"
$ sdkmanager "build-tools;27.0.3"
$ sdkmanager "platforms;android-27"
$ sdkmanager "extras;android;m2repository"
$ sdkmanager "extras;google;m2repository"
$ sdkmanager "patcher;v4"

...

$ flutter doctor -v.
[✓] Android toolchain - develop for Android devices (Android SDK 27.0.3)

```

Before that I went down a rabbit hole chasing SDK setup and env vars, when it wasn't that at all :-( I think hundreds of of others have too.
Repository: rust
Issue: Add impl<T: Unsize<U>, U: ?Sized> From<T> for Box<U>
Labels: C-enhancement,T-lang

Consider adding this implementation into `stdcore` if it possible: 

```rust
impl<T: Unsize<U>, U: ?Sized> From<T> for Box<U> {
    fn from(t: T) -> Box<U> {
        Box::new(t) as Box<U>
    }
}
```

This implementation will allow conversions like:
```rust
let x: Box<Fn(u32) -> u32> = {|x|x}.into();
```
Repository: go
Issue: encoding/json: eof error of NewDecoder().Decode() should be same with Unmarshal()
Labels: help wanted,NeedsDecision

Please answer these questions before submitting your issue. Thanks!


### What version of Go are you using (`go version`)?
go version go1.10.1 darwin/amd64

### Does this issue reproduce with the latest release?
yes

### What operating system and processor architecture are you using (`go env`)?
GOARCH="amd64" GOOS="darwin"

### What did you do?
https://play.golang.org/p/gr5cHhrpmbK

### What did you expect to see?
shown in previous link

### What did you see instead?
shown in previous link
Repository: godot
Issue: Android sensor lag
Labels: enhancement,discussion,platform:android,topic:xr

Hey All, 

As I was playing around trying to make #19170 work, I stumbled upon some info that solves the lag issue I've been experiencing on Android. But before I change this, it requires some discussion to do this right.

The problem lies in the code here:
https://github.com/godotengine/godot/blob/master/platform/android/java/src/org/godotengine/godot/Godot.java#L618

We're using SENSOR_DELAY_GAME in all 4 sensors, this setting defines how fast the sensor data is processed and how much smoothing is applied. The longer this delay, the more lag, but the more stable the sensor data.

SENSOR_DELAY_GAME introduces a 0.02 second lag. Seems negligible and it is for normal game applications (whats in a constants name),  for VR applications however that is a lifetime.

I changed the setting to SENSOR_DELAY_FASTEST which basically just gives you raw sensor data. Shaky but fast, perfect for VR.

Now this is only important for our native driver, cardboard and gearvr do their own sensor readings.

At the very least however, I think this should be made settable but not knowing enough about the android platform, I'm not sure what the best way to achieve this is.

More info on the sensors:
https://developer.android.com/guide/topics/sensors/sensors_overview
Repository: go
Issue: all: decide on the hyphenation of pseudorandom vs pseudo-random?
Labels: Documentation,NeedsDecision

The docs for crypto/rand contain both "pseudorandom" and "pseudo-random" for the same part of speech.

Decide which to use.

Also, the package doc says:

> Package rand implements a cryptographically secure pseudorandom number generator.

But the Reader says:

> Reader is a global, shared instance of a cryptographically strong pseudo-random generator.

Is it cryptographically "strong" or is it "secure"? Can we pick a word there too?

Or can we just remove "pseudorandom" altogether? I feel like it makes it sound too much like math/rand.

Can we just say "cryptographically secure random number generator"?

/cc @FiloSottile @agl @ianlancetaylor