sharjeelyunus/github-issues-dataset huggingface dataset:
Repository: TypeScript
Issue: Error in module-plugin.d.ts template
Labels: Docs

<!-- 🚨 STOP 🚨 𝗦𝗧𝗢𝗣 🚨 𝑺𝑻𝑶𝑷 🚨

Half of all issues filed here are duplicates, answered in the FAQ, or not appropriate for the bug tracker. Even if you think you've found a *bug*, please read the FAQ first, especially the Common "Bugs" That Aren't Bugs section!

Please help us by doing the following steps before logging an issue:
  * Search: https://github.com/Microsoft/TypeScript/search?type=Issues
  * Read the FAQ: https://github.com/Microsoft/TypeScript/wiki/FAQ

Please fill in the *entire* template below.
-->

<!-- Please try to reproduce the issue with `typescript@next`. It may have already been fixed. -->
**TypeScript Version:**  3.4.5

<!-- Search terms you tried before logging this (so others can find this issue more easily) -->
**Search Terms:** module-plugin.d.ts template Module Plugin or UMD Plugin Cannot augment module 'jquery' because it resolves to a non-module entity.

**Code**

```ts
// This is a copy from https://www.typescriptlang.org/docs/handbook/declaration-files/templates/module-plugin-d-ts.html
// Put this file in node_modules/@types/jquery-plugin/index.d.ts
// will get an error:
// Cannot augment module 'jquery' because it resolves to a non-module entity.



// Type definitions for [~THE LIBRARY NAME~] [~OPTIONAL VERSION NUMBER~]
// Project: [~THE PROJECT NAME~]
// Definitions by: [~YOUR NAME~] <[~A URL FOR YOU~]>

/*~ This is the module plugin template file. You should rename it to index.d.ts
 *~ and place it in a folder with the same name as the module.
 *~ For example, if you were writing a file for "super-greeter", this
 *~ file should be 'super-greeter/index.d.ts'
 */

/*~ On this line, import the module which this module adds to */
import * as m from 'jquery';

/*~ Here, declare the same module as the one you imported above */
declare module 'jquery' {
    /*~ Inside, add new function, classes, or variables. You can use
     *~ unexported types from the original module if needed. */
    export function theNewMethod(): string;

    /*~ You can also add new properties to existing interfaces from
     *~ the original module by writing interface augmentations */
    export interface SomeModuleOptions {
        someModuleSetting?: string;
    }

    /*~ New types can also be declared and will appear as if they
     *~ are in the original module */
    export interface MyModulePluginOptions {
        size: number;
    }
}
```

**Expected behavior:** No errors and have code hint for this plugin

**Actual behavior:** Have errors

**Playground Link:** <!-- A link to a TypeScript Playground "Share" link which demonstrates this behavior -->

**Related Issues:** <!-- Did you find other bugs that looked similar? -->
Repository: go
Issue: cmd/compile: suboptimal assembly for a + b + 1
Labels: Performance,NeedsInvestigation,compiler/runtime

```go
package p

func f(a, b uint64) uint64 {
	return a + b + 1
}
```

On amd64, this assembles to:

```
"".f STEXT nosplit size=24 args=0x18 locals=0x0
	0x0000 00000 (x.go:4)	MOVQ	"".a+8(SP), AX
	0x0005 00005 (x.go:4)	MOVQ	"".b+16(SP), CX
	0x000a 00010 (x.go:4)	LEAQ	(CX)(AX*1), AX
	0x000e 00014 (x.go:4)	LEAQ	1(AX), AX
	0x0012 00018 (x.go:4)	MOVQ	AX, "".~r2+24(SP)
	0x0017 00023 (x.go:4)	RET
```

I believe the two LEAQs should instead be `ADDQ CX, AX`, `INC AX`. This would be six bytes of instructions instead of 8.

I need to double-check, but I believe that this happens because we optimize `a + b + const` to `LEAQ const(a)(b*1), dst`, but then break apart the three-part LEAQ.

We can't fix this when lowering to instructions, because LEAQ doesn't clobber flags and ADD and INC do. So we need to somehow catch this in the rewrite rules. I wonder whether we should reconsider the previous strategy of breaking apart "slow" LEAQs at the last minute (for https://github.com/golang/go/issues/21735).

cc @martisch @randall77
Repository: flutter
Issue: Flutter on iOS should support semantic autofilling of text fields
Labels: a: text input,c: new feature,platform-ios,framework,engine,a: fidelity,P2,team-ios,triaged-ios

See https://github.com/flutter/flutter/issues/32265 for some context

We currently support password autofill, but not as nicely as we could.  In a native iOS app, autofill works if there's a password box anywhere on the screen.  After a bug fix for the linked issue, we only support it if the box has focus.  We also only support passwords right now, but could be supporting other types of auto filled input (like user names, emails, etc.).

On issue with fixing this is that the framework currently increments the client id for a text input on each attach - and the engine has no knowledge of whether that client ID is for a new or existing text editing state.  The framework also does not pass semantic information for the type of text entry wanted (beyond keyboard types anyway).

Another issue is that the engine reuses the backing fields that the OS can interact with for autofilling for multiple fields. It would need to have a way to track (and free) those backing objects per text field on the framework side.
Repository: TypeScript
Issue: Unable to add generic function overload for module default export
Labels: Bug,Domain: JSDoc,checkJs,Domain: Type Inference

<!-- 🚨 STOP 🚨 𝗦𝗧𝗢𝗣 🚨 𝑺𝑻𝑶𝑷 🚨

Half of all issues filed here are duplicates, answered in the FAQ, or not appropriate for the bug tracker. Even if you think you've found a *bug*, please read the FAQ first, especially the Common "Bugs" That Aren't Bugs section!

Please help us by doing the following steps before logging an issue:
  * Search: https://github.com/Microsoft/TypeScript/search?type=Issues
  * Read the FAQ: https://github.com/Microsoft/TypeScript/wiki/FAQ

Please fill in the *entire* template below.
-->

<!-- Please try to reproduce the issue with `typescript@next`. It may have already been fixed. -->
**TypeScript Version:**  3.5.0-dev.20190508

<!-- Search terms you tried before logging this (so others can find this issue more easily) -->
**Search Terms:** module add overload

**Code**

```ts
// nanohtml.d.ts
export default function<T extends HTMLElement = HTMLElement>(strings: TemplateStringsArray, ...keys: any[]): T;
```

```js
// @ts-check
// index.js
// install nanohtml@1.6.1
const nanohtml = require("nanohtml");

/** @type {HTMLAnchorElement} */
const a = nanohtml`<a href="example.com">Example</a>`;
```

**Expected behavior:**

`a` should be `HTMLAnchorElement`.

**Actual behavior:**

Error: Type 'HTMLElement' is missing the following properties from type 'HTMLAnchorElement': ...
Repository: puppeteer
Issue: Can't use getDisplayMedia (and then start recording) in headless mode
Labels: feature,confirmed

<!--
STEP 1: Are you in the right place?

- For general technical questions or "how to" guidance, please search StackOverflow for questions tagged "puppeteer" or create a new post.

https://stackoverflow.com/questions/tagged/puppeteer

- For issues or feature requests related to the DevTools Protocol (https://chromedevtools.github.io/devtools-protocol/), file an issue there:

https://github.com/ChromeDevTools/devtools-protocol/issues/new.

- Problem in Headless Chrome? File an issue against Chromium's issue tracker:

https://bugs.chromium.org/p/chromium/issues/entry?components=Internals%3EHeadless&blocking=705916

For issues, feature requests, or setup troubles with Puppeteer, file an issue right here!
-->

### Steps to reproduce

**Tell us about your environment:**

* Puppeteer version: 1.15.0
* Platform / OS version: Ubuntu 16.04
* URLs (if applicable):
* Node.js version: v10.15.3

**What steps will reproduce the problem?**

_Please include code that reproduces the issue._

1. Run the following code, set headless to `true` or `false` and see the difference.
```
const puppeteer = require('puppeteer')

;(async () => {
  const url = 'https://www.google.com'
  const browser = await puppeteer.launch({
    headless: false,
    args: [
      `--window-size=1920,1080`,
      '--enable-experimental-web-platform-features',
      '--disable-infobars',
      '--enable-usermedia-screen-capturing',
      '--allow-http-screen-capture',
      '--auto-select-desktop-capture-source=webclip',
      '--ignore-certificate-errors', 
       '--unsafely-treat-insecure-origin-as-secure=' + url
    ]
  });
  const page = await browser.newPage()
  await page.setViewport({
    width: 1920,
    height: 1080,
  })
  await page.goto(url)
  page.evaluate(async () => {
    document.title = 'webclip'
    const stream = await navigator.mediaDevices.getDisplayMedia({ video: true })
    const recorder = new window.MediaRecorder(stream, { mimeType: 'video/webm' })
    recorder.start(10)
    const chunks = []
    recorder.addEventListener('dataavailable', event => {
      if (event.data && event.data.size) {
        chunks.push(event.data)
      }
    })
  })
})()
```
**What is the expected result?**
Maybe it should start recording (I don't know whether this behavior is intended and I haven't found percisely related information).

**What happens instead?**
Throw exceptions.
Repository: vue
Issue: this.$nextTick don't work fine in (android 5.1.1)android webview 55.0.2883.91.
Labels: need repro,browser quirks

### Version
2.6.10

### Reproduction link
[https://codesandbox.io/embed/k36zj3z5o7](https://codesandbox.io/embed/k36zj3z5o7)

### Browser info
android 5.1.1
android system webview 55.0.2883.91.

### Steps to reproduce
input phone number more than 3.

### What is expected?
when i input phone number more than 3 ,the position of cursor will be the last .

### What is actually happening?
when i input phone number more than 3 ,the position of cursor is not  on the last.I suppose the reason is the bug of microtask in this version of android webview.

<!-- generated by vue-issues. DO NOT REMOVE -->
Repository: PowerToys
Issue: Shortcuts for numbered virtual desktops
Labels: Idea-New PowerToy,Product-Virtual Desktop

Desktops are already numbered, would be useful to have some sort of indicator of the current desktop number in the taskbar and to add a shortcut to jump between desktops, something like WinKey + Ctrl + 1..9 to go to desktop 1... all the way to 9
Repository: go
Issue: internal/poll: transparently support new linux io_uring interface
Labels: OS-Linux,NeedsInvestigation,compiler/runtime

A document on the latest linux IO syscall has made the rounds of discussion forums on the internet:

http://kernel.dk/io_uring.pdf

I wanted to open a discussion on whether we could (and should) add transparent support for this on supported linux kernels.

LWN article: https://lwn.net/Articles/776703/
Repository: pytorch
Issue: [Caffe2] Convert caffe to caffe2 with solverstate
Labels: caffe2

Can I convert  a caffemodel and a solverstate file to caffe2 training file?

I have used below code to convert caffemodel, but it only convert the weight.
I want to get the momentum information which is in solverstate.

`python -m caffe2.python.caffe_translator XXX.prototxt XXX.caffemodel`
Repository: flutter
Issue: flutter channel command output
Labels: c: new feature,tool,P3,team-tool,triaged-tool

## Use case

When Dart 2.3 was announced I started to use it on flutter master channel because I really needed that. After some while, I needed to go back to the stable channel that didn't support Dart 2.3 at that time. So every time that I would like to know if Dart 2.3 was already on the stable channel, I had to change the channel to stable, upgrade it, and see my project breaks because Dart 2.3 was missing, and then go back to master channel.

## Proposal

The output of `flutter channel` command could be a table showing the version numbers and details of each channel instead of a list of names
Repository: go
Issue: runtime: no examples for LockOSThread and UnlockOSThread
Labels: Documentation,help wanted,NeedsInvestigation,compiler/runtime

<!-- Please answer these questions before submitting your issue. Thanks! -->

### What version of Go are you using (`go version`)?

<pre>
$ go version

</pre>

### Does this issue reproduce with the latest release?



### What operating system and processor architecture are you using (`go env`)?

<details><summary><code>go env</code> Output</summary><br><pre>
$ go env

</pre></details>

### What did you do?

<!--
If possible, provide a recipe for reproducing the error.
A complete runnable program is good.
A link on play.golang.org is best.
-->



### What did you expect to see?



### What did you see instead?
Repository: pytorch
Issue: Redundantly saving sizes of SavedVariables in autograd Function
Labels: module: bootcamp,module: autograd,low priority,triaged

I was reading some autograd code and I noticed this:

```
struct MmBackward : public TraceableFunction {
  using TraceableFunction::TraceableFunction;
  variable_list apply(variable_list&& grads) override;
  std::string name() const override { return "MmBackward"; }
  void release_variables() override {
    self_.reset_data();
    self_.reset_grad_function();
    mat2_.reset_data();
    mat2_.reset_grad_function();
  }

  SavedVariable self_;
  std::vector<int64_t> mat2_sizes;
  SavedVariable mat2_;

};
```

The `mat2_sizes` here is pointless; we can trivially reconstruct it from `mat2_`. So it's just a waste of space.

Marked as low priority as I don't think is actually affecting anything.
Repository: rust
Issue: Inlining + target_feature broken in powerpc64
Labels: A-LLVM,T-compiler,O-PowerPC,A-SIMD,C-bug

[godbolt](https://godbolt.org/z/FsNj8l)

```rust
#![feature(repr_simd, powerpc_target_feature)]
#![allow(non_camel_case_types)]

#[repr(simd)] pub struct u32x4(u32, u32, u32, u32);

impl u32x4 {
    #[inline]
    // #[inline(always)]
    fn splat(x: u32) -> Self {
        u32x4(x, x, x, x)
    }
}

#[target_feature(enable = "altivec")]
pub unsafe fn splat_u32x4(x: u32) -> u32x4 {
    u32x4::splat(x)
}
```

with `#[inline]` that code produces a function call within `splat_u32x4` (`b example::u32x4::splat`) to `u32x4::splat`, which is not eliminated, even though this method is module private. With `#[inline(always)]`, `u32x4::splat` is inlined into `splat_u32x4`, and no code for `u32x4::splat` is generated. 

`#[inline]` should not be needed here, much less `#[inline(always)]`, yet without `#[inline(always)]` this produces bad codegen.

Removing the `#[target_feature]` attribute from `splat_u32x4` fixes the issue, no `#[inline]` necessary: [godbolt](https://godbolt.org/z/NeA-2w). So there must be some interaction between inlining and target features going on here.
Repository: PowerToys
Issue: Disable first click handling in inactive window
Labels: Idea-New PowerToy

instead only bring the window to front.
Example of problem to be solved: only a piece of a browser window is visible. Clicking onto a link (by accident) to bring it into the foreground will also change the page shown within that browser window.
As long this isn't going to be a official Windows mouse settings option it would be nice to have an option via PowerToys..
But its more tricky to implement then it sounds: the first click should be handled if that Window is completely visible...
Repository: PowerToys
Issue: "Jump to target" in Open/Save dialogs on Drop
Labels: Idea-New PowerToy

Just like the MacOS handles it...
For those who never experienced it: dragging a file into an open/save file dialog will jump to the enclosing folder and select the dropped file/folder.
Its one of those features missing that gets (Ex-) Mac users crazy...
Repository: PowerToys
Issue: Assign Applications to Specific Desktops
Labels: Idea-Enhancement,Product-Window Manager,Product-Virtual Desktop

Currently, very easy to open multiple versions of an app, that if on the wrong desktop, creates chaos. This especially true for apps such as Microsoft Outlook.  Also not being able to assign a specific desktop for VMWare Horizon Client can cause strange behavior. 

This should persist across docking and undocking a laptop. Would be a nice tie in to the other laptop related ones.
Repository: PowerToys
Issue: SyncToy and Robocopy
Labels: Idea-New PowerToy

Please bring back Synctoy for a Robocopy like function....and/or open source Robocopy

https://en.wikipedia.org/wiki/SyncToy
Repository: godot
Issue: XMLParser get_node_name only works on NODE_ELEMENTs
Labels: enhancement,topic:core,confirmed,documentation

<!-- Please search existing issues for potential duplicates before filing yours:
https://github.com/godotengine/godot/issues?q=is%3Aissue
-->

**Godot version:**
3.1.1


**Issue description:**
`get_node_name` doesn't work on any nodes other than `NODE_ELEMENT` and `NODE_ELEMENT_END`. Sometimes I want to get the name of a `NODE_TEXT`, which isn't possible. This is probably to avoid trying to get the names of `NODE_NONE` or maybe `NODE_UNKNOWN`. The docs state
```
Get the name of the current element node. This will raise an error if the current node type is not NODE_ELEMENT nor NODE_ELEMENT_END
```

**Steps to reproduce:**
Create a new `XMLParser`, load in an `xml` file with the first element being a simple text node, call `read()` and then `get_name()`.
Example text element:
```xml
<description>
	Vector3 is one of the core classes of the engine.
</description>
```

**Workaround:**
Since the end of an element is always `NODE_ELEMENT_END`, you can get the name from that element.
Repository: rust
Issue: unused_mut warning gives bad suggestion in a macro
Labels: A-lints,T-compiler,A-NLL,C-bug,D-incorrect

The following gives a suggestion to remove the `mut` which will cause the code to fail to compile.

```rust
macro_rules! array {
    ($($element:expr),*) => {{
        let mut array = Vec::new();
        $(
            array.push($element);
        )*
        array
    }};
}

fn main() {
    let _x: Vec<i32> = array![];
    let _y: Vec<i32> = array![1,2,3];
}
```

```
warning: variable does not need to be mutable
  --> src/main.rs:3:13
   |
3  |         let mut array = Vec::new();
   |             ----^^^^^
   |             |
   |             help: remove this `mut`
...
12 |     let _x: Vec<i32> = array!{};
   |                        -------- in this macro invocation
   |
   = note: #[warn(unused_mut)] on by default
```

This causes `cargo fix` to fail.

(Sorry if this is a dupe, I went hunting but couldn't find any issues that were the same.)
Repository: TypeScript
Issue: Recognize properties introduced by jQuery extend
Labels: Suggestion,Awaiting More Feedback

The old VS JS language service used to make runtime types available at design-time, allowing it to support jQuery's `extend` function for adding properties dynamically.  The new one uses static types and so does not offer these symbols during completion, navigate-to, etc.  We've had some customer inquiries about the possibility of supporting this functionality in the TS language service.

https://developercommunity.visualstudio.com/content/problem/529989/aspnet-在html-文件-js-智能提示失效.html
https://developercommunity.visualstudio.com/content/problem/560277/javascript-go-to-members-doesnt-work-with-property.html

The latter provided this example:

```js
(function ($) {

    mynamespace.myClass = Class.extend({
      init: function (options) {
        // unless you specifically type this.testProperty = "abc" in JS, the 'Go to Members' will not find the below property even though it's explicitely defined.
      },
       __properties: {

       'testProperty': {
                /// <summary>
                /// Gets or sets the test property
                /// </summary>
                /// <value type="String"></value>

                get: function () {
                    return this._testProperty;
                },

                set: function (value) {
                    this._testProperty = value;
                }
            }
       }
   });

})(jQuery);
```
Repository: TypeScript
Issue: GTD not working between ES5-style classes
Labels: Suggestion,Awaiting More Feedback,Domain: JavaScript

Reported in VS, repros in VS Code.

https://developercommunity.visualstudio.com/content/problem/556364/javascript-go-to-definition-or-f12-doesnt-work-wit.html

```js
(function () {

    my.namepsace.myclass = function () {
        something: function something() {

        };
    };

    my.namespace.mystaticmethod = function () {
        return false;
    };

})();

(function () {

    another.namespace.class = function () {
        init: function init() {
            var myclass = new my.namepsace.myclass(); // GTD on myclass
            var result = my.namespace.mystaticmethod(); // GTD on mystaticmethod
        }
    };

})();
```

GTD does not work on the references to `myclass` and `mystaticmethod`.
Repository: PowerToys
Issue: Apps remember virtual desktops between reboots and location
Labels: Idea-Enhancement,Product-Window Manager,Product-Virtual Desktop

Preserve application and virtual desktop layout between reboots! :)
Repository: go
Issue: go/build: inconsistency on whether NoGoError includes test files
Labels: NeedsInvestigation

The code & documentation disagree about whether `go/build.NoGoError` includes tests.

Code says:

```go
        if len(p.GoFiles)+len(p.CgoFiles)+len(p.TestGoFiles)+len(p.XTestGoFiles) == 0 {
                return p, &NoGoError{p.Dir}
        }
```

But docs say:

```go
// NoGoError is the error used by Import to describe a directory                                                                                                                                                                        
// containing no buildable Go source files. (It may still contain                                                                                                                                                                       
// test files, files hidden by build tags, and so on.)                                                                                                                                                                                  
type NoGoError struct {
        Dir string
}
```

(Notably, the "it may still contain test files" part, implying that a directory with only `foo_test.go` should be NoGoError).

/cc @bcmills @jayconrod @rsc @ianlancetaylor
Repository: terminal
Issue: More complete tab sizing configurations
Labels: Issue-Feature,Area-UserInterface,Product-Terminal

Initially brought up in #444, the ability to enable/disable a configurable min-width for tabs when you have many of them, similar to:
![](https://i.imgur.com/UYtiZE3.png)
If disabled, it would be chrome-like with tabs getting ever smaller, and if enabled, it would be firefox-like with a user-defined min-width before it starts either scrolling or being paginated.