sharjeelyunus/github-issues-dataset huggingface dataset:
Repository: vscode
Issue: Support large documents in extension host
Labels: feature-request,api,editor-textbuffer

- VSCode Version: 1.14.1
- OS Version: Windows 7 and Windows 10, likely all OSes

When editing documents with very long lines, such as lines containing data-URIs, the property `vscode.window.activeTextEditor` will be `undefined` when it should be defined.

Steps to reproduce:

1. Create a new (blank) VSCode extension, and add this command to `extension.ts`:

```
'use strict';
import * as vscode from 'vscode';

export function activate(context: vscode.ExtensionContext) {
    let disposable = vscode.commands.registerCommand('bigDocTest.runDocTest', () => {

        let hasActiveTextEditor = (vscode.window.activeTextEditor !== undefined);

        if (hasActiveTextEditor) {
            vscode.window.showInformationMessage('Success, activeTextEditor is defined.');
        } else {
            vscode.window.showErrorMessage('Oops, activeTextEditor is not defined.');
        }
    });

    context.subscriptions.push(disposable);
}

export function deactivate() {
}
```

2. Launch this extension, load any normal text file, and run this command, you see the "Success, activeTextEditor is defined" information message appear.

3. But, try loading a file with a very long line contained inside it, such as this one: [MetalRoughSpheres.gltf](https://raw.githubusercontent.com/KhronosGroup/glTF-Sample-Models/9ba6ae1352c8b59f684a11858b152615026660a4/2.0/MetalRoughSpheres/glTF-Embedded/MetalRoughSpheres.gltf).  This file has long lines due to the use of embedded data URIs in the file.  If you run the above sample extension while editing this file, you see "Oops, activeTextEditor is not defined."

This makes it difficult for VSCode extensions to work with such files.  I'm the lead dev of the GLTF extension for VSCode, and this prevents my extension from running on GLTF files that embed large images as data URIs.
Repository: TypeScript
Issue: Uncaught compiler error: Block-scoped variable from import used before its declaration.
Labels: Bug

<!-- BUGS: Please use this template. -->
<!-- QUESTIONS: This is not a general support forum! Ask Qs at http://stackoverflow.com/questions/tagged/typescript -->
<!-- SUGGESTIONS: See https://github.com/Microsoft/TypeScript-wiki/blob/master/Writing-Good-Design-Proposals.md -->

**TypeScript Version:**  2.4.0 / nightly (2.5.0-dev.201xxxxx)

**Code**

Input Typescript
```ts
namespace A {
    export namespace B {
        export class C {
            constructor()
            {
                console.log("Hello World");
            }
        }
    }
}

import myA_B = myA.B;
import myA = A;

new myA_B.C();
```

Output JavaScript from tsc
```js
var A;
(function (A) {
    var B;
    (function (B) {
        var C = (function () {
            function C() {
                console.log("Hello World");
            }
            return C;
        }());
        B.C = C;
    })(B = A.B || (A.B = {}));
})(A || (A = {}));
var myA_B = myA.B;
var myA = A;
new myA_B.C();
```

**Expected behavior:**
Expected the typescript compiler error `Block-scoped variable 'myA' used before its declaration.`

**Actual behavior:**
Runtime error of `Uncaught TypeError: Cannot read property 'B' of undefined`

**Comments**
The typescript compiler will catch this if I use `const` or `let` keywords instead, so I expected the same error handling for `import` in this case. 

My team prefers using `import` over `const` or `let` when we can for performance of not pulling in javascript code from external files when we are only referencing types.
Repository: rust
Issue: pthread_get_stacksize_np returns incorrect values for the main thread on OS X 10.9
Labels: P-medium,T-libs-api,C-bug,A-stack-probe

See:
https://github.com/robovm/robovm/issues/274
https://groups.google.com/forum/#!topic/address-sanitizer/7_abqFZ5wXw
http://mail.openjdk.java.net/pipermail/hotspot-dev/2013-October/011388.html

pthread_get_stacksize_np returns 512KB for the main thread instead of the 8MB that it's supposed to. This causes us to allocate our guard page in the middle of the stack.
Repository: go
Issue: encoding/json: unmarshal into slice reuses element data between len and cap
Labels: NeedsFix

### What version of Go are you using (`go version`)?
go1.8

### What operating system and processor architecture are you using (`go env`)?
GOOS=nacl
GOARCH=amd64p32

### What did you do?
https://play.golang.org/p/lbYUhgOe--


### What did you expect to see?
According to the [json Unmarshal docs](https://golang.org/pkg/encoding/json/#Unmarshal), Unmarshal resets the slice length to zero and then appends each element to the slice.

### What did you see instead?
Instead Unmarshal resets the slice length to zero and then modifies the elements of the underlying slice.
Repository: react-native
Issue: Oppo A77 - Some texts gets cut-off
Labels: Help Wanted :octocat:,Platform: Android,Bug

### Environment

1. `react-native -v`: 0.34 through 0.59
2. `node -v`:4.4.7
3. `npm -v`: 4.5.0
4. `yarn --version`<!-- (if you use Yarn) -->:

- Target Platform: Android
- Development Operating System: Windows
- Build tools: The issue is specific to Oppo A77 model. Note that upgrading to latest react-native version is not an option now due to breaking changes and time constraints

### Steps to Reproduce

There's no necessary steps to produce these bug. You just have to run the app either in dev or production

### Expected Behavior

<!--
  How did you expect your project to behave?
  It’s fine if you’re not sure your understanding is correct.
  Just write down what you thought would happen.
-->

Texts should not be cut-off

### Actual Behavior

<!--
  Did something go wrong?
  Is something broken, or not behaving as you expected?
  Describe this section in detail, and attach screenshots if possible.
  Don't just say "it doesn't work"!
-->

Some texts are cut-off as shown below. These cut-off issue doesnt occur in iphone and other phone models except Oppo A77

Screenshots:
![image](https://user-images.githubusercontent.com/22584900/28396742-ed4cf36a-6d2f-11e7-9fc0-d51a2885f0ca.png)

![image](https://user-images.githubusercontent.com/22584900/28396785-2f968696-6d30-11e7-8681-d992874ce9ed.png)

Those screenshots are just few of the texts that are cut-off

<!--
  Please share a project that reproduces the issue.
  There are two ways to do it:

    * Create a new app using https://snack.expo.io/ and try to reproduce the issue in it.
      This is useful if you roughly know where the problem is, or can’t share the real code.

    * Or, copy your app and remove things until you’re left with the minimal reproducible demo.
      This is useful for finding the root cause. You may then optionally create a Snack.

  This is a good guide to creating bug demos: https://stackoverflow.com/help/mcve
  Once you’re done, copy and paste the link to the Snack or a public GitHub repository below:
-->

Sorry i can't provide a link to the project

<!--
  What happens if you skip this step?

  Someone will read your bug report, and maybe will be able to help you,
  but it’s unlikely that it will get much attention from the team. Eventually,
  the issue will likely get closed in favor of issues that have reproducible demos.

  Please remember that:

    * Issues without reproducible demos have a very low priority.
    * The person fixing the bug would have to do that anyway. Please be respectful of their time.
    * You might figure out the issues yourself as you work on extracting it.

  Thanks for helping us help you!
-->
Repository: opencv
Issue: A problem about normalizeBlockHistogram() used to compute HOG descriptor
Labels: category: objdetect,RFC

##### System information (version)
- OpenCV => 2.2

##### Detailed description
when doing the first normalization of block histogram, the scale coefficient is computed as `float scale = 1.f/(std::sqrt(sum)+sz*0.1f)`, after the hysteresis thresholding and when doing the renormalization, the scale coefficient is computed as `scale = 1.f/(std::sqrt(sum)+1e-3f)` . 
`1e-3f` is used to avoid division by zero, but why `sz*0.1f` is added when doing the first normalization? is it a sloppy or something I misunderstand?
Repository: opencv
Issue: problem with linux Raspberry Pi,cv::directory
Labels: bug,priority: low,affected: 2.4

<!--
If you have a question rather than reporting a bug please go to http://answers.opencv.org where you get much faster responses.
If you need further assistance please read [How To Contribute](https://github.com/opencv/opencv/wiki/How_to_contribute).

This is a template helping you to create an issue which can be processed as quickly as possible. This is the bug reporting section for the OpenCV library.
-->

##### System information (version)
<!-- Example
- OpenCV => 3.1
- Operating System / Platform => Windows 64 Bit
- Compiler => Visual Studio 2015
-->

- OpenCV => :grey_question:2.4.13
- Operating System / Platform => :grey_question: linux Raspberry Pi
- Compiler => :grey_question:g++ cmake

##### Detailed description

<!-- your description -->i use the cv::directory,GetListFolders,compile success,but i find the GetListFolders doesnt work,the size of vector i get is zero,when i do it in vs2015 in windows10,it works,which makes me really confuse

##### Steps to reproduce

<!-- to add code example fence it with triple backticks and optional file extension
    ```.cpp
    // C++ code example
    ```
 or attach as .txt or .zip file
-->cv::Directory images_Dir;
	std::vector<std::string> images_Sub_Dirs = images_Dir.GetListFolders("/home/pi/images");
	std::cout << "size:" << images_Sub_Dirs.size() << std::endl;
Repository: vscode
Issue: [html] provide rename for embedded JavaScript
Labels: help wanted,feature-request,javascript,html,keep

<!-- Do you have a question? Please ask it on http://stackoverflow.com/questions/tagged/vscode. -->

<!-- Use Help > Report Issues to prefill these. -->
- VSCode Version: v1.14.1
- OS Version: macOS Sierra v10.12.6
- Reproduces without extensions: Yes

Steps to Reproduce:

1. Create these two files:

`my-custom-element.js`
```javascript
class MyCustomElement extends HTMLElement {
  static get is() {
    return 'my-custom-element';
  }
}

customElements.define(MyCustomElement.is, MyCustomElement);
```

`my-custom-element.html`
```html
<script>
  class MyCustomElement extends HTMLElement {
    static get is() {
      return 'my-custom-element';
    }
  }

  customElements.define(MyCustomElement.is, MyCustomElement);
</script>
```

2. Try the Rename Refactoring with `F2` in both files:

<img width="514" alt="screen shot 2017-07-20 at 17 48 44" src="https://user-images.githubusercontent.com/1007051/28426567-cabae566-6d73-11e7-99e9-d69cce38a617.png">

<img width="535" alt="screen shot 2017-07-20 at 17 48 57" src="https://user-images.githubusercontent.com/1007051/28426573-cfe49c76-6d73-11e7-9e64-573b3a8a0a83.png">

With the same code, the "Rename Refactoring" doesn't work in HTML language.
Repository: rust
Issue: Stabilize -Zunpretty=expanded
Labels: A-pretty,T-compiler,C-feature-request

`--pretty=expanded` is an incredibly useful debugging tool for macros. The change in rustc 1.19 to stop supporting unstable command-line options on the stable/beta compilers makes it all the more important to stabilize unstable options that people use, and this seems like it easily qualifies.

Much like `--emit mir`, this should not make any commitments about the *output*, only that the option should continue to exist. In particular, I'd even suggest making it explicitly clear that there's no commitment for the output to *compile*.
Repository: kubernetes
Issue: RFE: Policy on versioning e2e tests
Labels: priority/awaiting-more-evidence,kind/feature,sig/testing,sig/release,lifecycle/frozen

**FEATURE REQUEST**:
Objective: Ensure a newer build of e2e tests can run a the tests on older clusters without having failures, and ensure upgrade tests don't test deprecated features.

Currently if a new feature adds coverage to the e2es there is no version information that denotes that this feature is new and may not work on an older version.  We should ensure that the e2es in question check the server version and make certain >= to the version it was introduced in.  

Also on a similar note we should cherry-pick a check of <= on issues where we know features are going to be deprecated.  

This has caused a bunch of consternation on upgrade tests and has wasted copious amounts of time.  It should be the sig-leads responsibility to ensure that the tests are in order prior to code freeze for a given cycle.    

/kind feature 
/cc @kubernetes/sig-testing-feature-requests @kubernetes/sig-release-feature-requests
Repository: vscode
Issue: Git - Support interactive rebase
Labels: help wanted,feature-request,git

Since it is typical for projects like Code and others to have PRs with a single command
for brevity and cleanliness, this feature would be really helpful to not have to go into the
terminal.

Willing to do a PR...
Repository: rust
Issue: core::fmt fails to optimize on arm-none-eabi
Labels: I-slow,C-enhancement,T-libs-api,T-compiler,WG-embedded,I-heavy

While generating code for an Cortex-M0 I noticed that using core::fmt to generate printable output generates extremely bloated code, even when just using a plain string as format.

According to @rkruppe on IRC this is most likely due to a missed elimination of dead code by LTO.

A stripped down example can be found here:
https://gist.github.com/anonymous/7cfc8b881fcb8fdc792428dd772502cb

The generated assembly is here:
https://gist.github.com/anonymous/9cfa48e53e3b1c8ba1ddb69f8ae3ea3b

I also have an example (serial_slow_helloworld) in this repo https://github.com/therealprof/stm32f042.git . `xargo build --release --examples` will create a binary demonstrating the problem.

This happens for me with: 
```
rustc 1.20.0-nightly (8f1339af2 2017-07-16)
binary: rustc
commit-hash: 8f1339af2e5d1b33ec9ee3c8a3c531bcd61770fc
commit-date: 2017-07-16
host: x86_64-apple-darwin
release: 1.20.0-nightly
LLVM version: 4.0
```
Repository: vscode
Issue: Can I put the extensionsGallery on my vscode fork?
Labels: extensions,under-discussion,license

By default the https://github.com/Microsoft/vscode does not come with key:

    "extensionsGallery": {
        "serviceUrl": "",
        "cacheUrl": "",
        "itemUrl": ""
    }

on its https://github.com/Microsoft/vscode/blob/master/product.json file. That entry is required to install extensions from the marketplace as showed on:

1.  https://stackoverflow.com/questions/37143536/no-extensions-found-when-running-visual-studio-code-from-source

Also there are commits, where their developer putted the key.

But sequentially removed it justifying:

> Revert inadvertant change to product.json

Why they are removing it? Seems they are using it while developing, as we may see he let slip the line to the upper stream. Can I put it on my fork? Or I can only use it locally as they seem to be doing?

___

Related issues:

1. https://github.com/Microsoft/vscode/issues/60 Command "Extensions: Install Extension" missing when running vscode from source
1. https://github.com/Microsoft/vscode/issues/2647 Command "Extensions: Install Extension" missing when running vscode from source
1. https://github.com/Microsoft/vscode/issues/28253 Can't see extensions or load via command line
1. https://github.com/Microsoft/vscode/issues/23831 How do I enable extensions in the extensions dir in OSS Dev mode
1. https://github.com/Microsoft/vscode-wiki/pull/30 Add marketplace extension installation details
Repository: kubernetes
Issue: kubectl in-cluster mode conflicts with --request-timeout
Labels: kind/bug,area/kubectl,sig/cli,lifecycle/frozen

/kind bug

**What happened**:

From a container running inside of a cluster:
```
# kubectl get po --request-timeout=11s
The connection to the server localhost:8080 was refused - did you specify the right host or port?
```

**What you expected to happen**:

```
# kubectl get po --request-timeout=11s
...long list of pods here...
```

**How to reproduce it (as minimally and precisely as possible)**:

- Run a container with kubectl installed (I used an Ubuntu container)
- `kubectl get po` <- this works
- `kubectl get po --request-timeout=11s` <- this fails

**Anything else we need to know?**:

Looking through the logs -v=8, it looks like --request-timeout bypasses the part where it realizes that in-cluster mode is enabled.

**Environment**:
- Kubernetes version (use `kubectl version`): I tested v.1.6.3 through v1.7.1
- Cloud provider or hardware configuration**: Parallels hypervisor
- OS (e.g. from /etc/os-release): 
```
NAME="Ubuntu"
VERSION="16.04.2 LTS (Xenial Xerus)"
ID=ubuntu
ID_LIKE=debian
PRETTY_NAME="Ubuntu 16.04.2 LTS"
VERSION_ID="16.04"
HOME_URL="http://www.ubuntu.com/"
SUPPORT_URL="http://help.ubuntu.com/"
BUG_REPORT_URL="http://bugs.launchpad.net/ubuntu/"
VERSION_CODENAME=xenial
UBUNTU_CODENAME=xenial
```
- Kernel (e.g. `uname -a`): Linux ubuntu 4.4.0-83-generic #106-Ubuntu SMP Mon Jun 26 17:54:43 UTC 2017 x86_64 x86_64 x86_64 GNU/Linux
- Install tools: kubeadm
- Others:
Repository: go
Issue: x/text: requires explicit (old) version of icu library accidentally
Labels: NeedsInvestigation

### What version of Go are you using (`go version`)?
1.8.3

### What operating system and processor architecture are you using (`go env`)?
darwin amd64

### What did you do?

Attempt to build a project with a dependency on collate/tools/colcmp/icu.go with the icu tag.

### What did you expect to see?

Clean build.

### What did you see instead?

Failure to find icu version 57 because of the hard dependency from https://github.com/golang/text/blob/master/cases/icu.go (which as noted is only for tests but is not a test file due to the cgo). This could be changed to match the same versionless dependency like in the collate file.
Repository: go
Issue: proposal: testing: allow examples to return an error
Labels: Proposal,Proposal-Hold

Currently, all example functions must return nothing. However, it is common
for examples to call things which might possibly return errors. Printing the
error, panicking, ignoring it or calling log.Fatal is not ideal for an example where
real code would almost always just return the error. It makes the example code
less representative of the actual code and more cluttered.

I propose that example functions should be allowed to return an error,
For runnable examples, tests would fail if the example
returns a non-nil error.
Repository: pytorch
Issue: Discrepancy in BCEWithLogitsLoss and ClassNLLLoss
Labels: module: loss,module: cuda,module: cpu,triaged

In BCEWithLogitsLoss, weights are unnormalized and used, while in ClassNLLLoss weights are normalized and used. 

Some discussion around this can be found [here](https://github.com/pytorch/pytorch/commit/67968cb60b1d3021834594967d4140a36a8213e3#commitcomment-23155134). Is this discrepancy expected? Else if this is an issue I can send a PR to resolve this.
Repository: kubernetes
Issue: `kubectl get` should have a way to filter for advanced pods status
Labels: kind/feature,sig/cli

**What happened**:

I'd like to have a simple command to check for pods that are currently not ready

**What you expected to happen**:

I can see a couple of options:

* There is some magic flag I am not aware of
* Having a flag for `kubectl get` to filter the output using go/jsonpath
* Distinguish between Pod Phase `Running&Ready` and `Running`
* Flag to filter on ready status

**How to get that currently**:

```
kubectl get pods --all-namespaces -o json  | jq -r '.items[] | select(.status.phase != "Running" or ([ .status.conditions[] | select(.type == "Ready" and .state == false) ] | length ) == 1 ) | .metadata.namespace + "/" + .metadata.name'
```
Repository: kubernetes
Issue: Remove the hardcoded list of group/versions from config
Labels: priority/important-soon,kind/cleanup,sig/api-machinery,lifecycle/frozen

There is a hardcoded list of priorities that needs to be plumbed up from storage maps.

https://github.com/kubernetes/kubernetes/blob/6fb3d3a79c95f75e3f5a66b37f530fd337d6c57e/cmd/kube-apiserver/app/aggregator.go#L230
Repository: go
Issue: net/http: update DetectContentType sniff signature for MP3 without ID3
Labels: NeedsFix,FeatureRequest

This is a placeholder bug to remind me to look into updating the http.DetectContentType sniff mechanisms to accomodate an addition to whatwg/mimesniff in which MP3s can be sniffed without an ID3 tag https://mimesniff.spec.whatwg.org/#signature-for-mp3-without-id3.

This shall require updating the max buffer size from 512 to 1445 and reviewing that algorithm described in https://mimesniff.spec.whatwg.org/#signature-for-mp3-without-id3. I noticed this after seeing this tweet https://twitter.com/mimesniff/status/888665270025420800 which pointed me to PR https://github.com/whatwg/mimesniff/pull/4.

This can be discussed when the tree opens up for Go1.10.
Repository: opencv
Issue: Why CvGBTrees and GBTrees were being commented out in opencv3?
Labels: RFC

Boost and RTrees in opencv3 are very useful. After testing the previous two methods, then I want to try the GBDT method, but founded it was disappeared. I am very puzzled, anyone knows the details?
Repository: youtube-dl
Issue: Add AppStream metadata(was: Add donate to AppStream information)
Labels: request

Not sure how to do this but please incorporate: https://rg3.github.io/youtube-dl/donations.html

Once done, a donation button appears in Solus Software Center. :-)

https://dev.solus-project.com/T4148
Repository: rust
Issue: Array lengths don't support generic parameters.
Labels: T-compiler,A-const-eval,A-const-generics,A-lazy-normalization,glacier,A-array

**EDIT**: This can now be made to work on nightly compilers, although it's a bit awkward to use. See [this comment](https://github.com/rust-lang/rust/issues/43408#issuecomment-917600907).



It would seem that when using size_of in const fn context, it fails to properly compute the size of generic types.

The following function fails 

```rust
unsafe fn zeroed<T: Sized>() -> T {
    // First create an array that has the same size as T, initialized at 0
    let x = [0u8; std::mem::size_of::<T>()];
    // Then, transmute it to type T, and return it
    std::mem::transmute(x)
}
```

The error is the following : 

```
error[E0277]: the trait bound `T: std::marker::Sized` is not satisfied
 --> src/main.rs:3:19
  |
3 |     let x = [0u8; std::mem::size_of::<T>()];
  |                   ^^^^^^^^^^^^^^^^^^^^^^ `T` does not have a constant size known at compile-time
  |
  = help: the trait `std::marker::Sized` is not implemented for `T`
  = help: consider adding a `where T: std::marker::Sized` bound
  = note: required by `std::mem::size_of`
```

This is very confusing because it complains that `T` doesn't have `std::marker::Sized`, even though it does have that bound.

## Meta

rustc_version : rustc 1.20.0-nightly (ae98ebfcb 2017-07-20)