sharjeelyunus/github-issues-dataset huggingface dataset:
Repository: flutter
Issue: Element should have a "design discussion" section talking about build order
Labels: framework,d: api docs,P2,team-framework,triaged-framework

We should document some of our design decisions about how widgets build:

* The framework guarantees that ancestors build before descendants.
* The framework does not guarantee anything about the order other than this.
* Some widgets might in rare cases build twice, this is considered an aberration to be avoided (layout builder that ends up dirty both at the widget layer and the layout layer is the example).
* One pass build.

Maybe point to "Inside Flutter" (https://flutter.dev/docs/resources/inside-flutter).
Repository: terminal
Issue: Pane focus movement doesn't remember where it came from
Labels: Help Wanted,Issue-Bug,Area-UserInterface,Product-Terminal,Priority-2

# Steps to reproduce

create a vertical split, then on the right pane, create a horizontal split
somewhat like this :
```
|-----------|
|    |  2   |
|  1 |______|
|    |   3  |
|____|______|
```

if you move focus from 1 to 2 by moveFocus right
then move focus from 2 to 3 by moveFocus down
then move focus from 3 to 1 by moveFocus left
then moveFocus right

# Expected behavior

The focus should go back to 3. Otherwise toggling between 1 and 3 becomes a painful, especially if 2 is ends up more complicated with more panes.

# Actual behavior

focus goes to 2
Repository: flutter
Issue: EditableText does not call onEditingComplete on focus loss (macOS)
Labels: a: text input,framework,platform-mac,a: desktop,has reproducible steps,P2,found in release: 3.3,found in release: 3.7,fyi-text-input,team-macos,triaged-macos

On desktop operating systems, it's typical for certain types of focus loss (via mouse input or keyboard navigation) to commit a text field's value, but Flutter's `EditableText` widget does not invoke the equivalent lifecycle method, `onEditingComplete`, in this situation. It appears that the only way to invoke the method on desktop is through an enter press.

I believe this to be in error, as the mobile equivalent to a tab/shift+tab press (`TextInputAction.next`, `TextInputAction.previous`) invokes `onEditingComplete`.

cc @gspencergoog
Repository: go
Issue: x/mobile: build failing when using go modules
Labels: NeedsInvestigation,mobile

### What version of Go are you using (`go version`)?

<pre>
x/mobile: build failing when using go modules #37048
</pre>

### Does this issue reproduce with the latest release?
yes


### What operating system and processor architecture are you using (`go env`)?

<details><summary><code>go env</code> Output</summary><br><pre>
x/mobile: build failing when using go modules #37048</pre></details>

### What did you do?
gomobile failed with 'nrecognized command line option '-marm'' and second run on same code gives different output ' cannot determine module path for source directory' this issue related to previous one #37048

```
gcc: error: unrecognized command line option '-marm'; did you mean '-mabm'?
```

second run (same command: gomobile bind)

```
gomobile: go build -buildmode=c-shared -o=/tmp/gomobile-work-515390264/android/src/main/jniLibs/armeabi/libgojni.so ./gobind failed: exit status 1
go: cannot determine module path for source directory /tmp/gomobile-work-515390264/src (outside GOPATH, module path must be specified)

Example usage:
	'go mod init example.com/m' to initialize a v0 or v1 module
	'go mod init example.com/m/v2' to initialize a v2 module

Run 'go help mod init' for more information.
```

commands:

```
# git clone -b dev https://gitlab.com/axet/libtorrent
# gomobile bind
```
Repository: go
Issue: x/net/http2: client can't fully utilize network resource
Labels: NeedsInvestigation

<!--
Please answer these questions before submitting your issue. Thanks!
For questions please use one of our forums: https://github.com/golang/go/wiki/Questions
-->

### What version of Go are you using (`go version`)?

<pre>
$ go version
go version go1.13.6 darwin/amd64
</pre>

### Does this issue reproduce with the latest release?
Yes


### What operating system and processor architecture are you using (`go env`)?

<details><summary><code>go env</code> Output</summary><br><pre>
$ go env
GO111MODULE=""
GOARCH="amd64"
GOBIN=""
GOCACHE="/Users/jayden/Library/Caches/go-build"
GOENV="/Users/jayden/Library/Application Support/go/env"
GOEXE=""
GOFLAGS=""
GOHOSTARCH="amd64"
GOHOSTOS="darwin"
GONOPROXY=""
GONOSUMDB=""
GOOS="darwin"
GOPATH="/Users/jayden/Workspace/GoProject"
GOPRIVATE=""
GOPROXY="https://proxy.golang.org,direct"
GOROOT="/usr/local/go"
GOSUMDB="sum.golang.org"
GOTMPDIR=""
GOTOOLDIR="/usr/local/go/pkg/tool/darwin_amd64"
GCCGO="gccgo"
AR="ar"
CC="clang"
CXX="clang++"
CGO_ENABLED="1"
GOMOD="/Users/jayden/Workspace/GoProject/src/golang.org/x/net/go.mod"
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 -fno-caret-diagnostics -Qunused-arguments -fmessage-length=0 -fdebug-prefix-map=/var/folders/j1/94761d9d49j6gz5p55375sbr0000gn/T/go-build875938892=/tmp/go-build -gno-record-gcc-switches -fno-common"
</pre></details>

### What did you do?
I ran an http2 webdav server and I made a client with golang x/net/http2 for a test.
The client uploaded a 1 MB file infinitely with a few hundred goroutine.
MaxConcurrentStreams of the server was 100 and StrictMaxConcurrentStreams of the client was false.
I measured the throughput between the server and the client on AWS.
And network bandwidth between the server and the client was 150 Gbps in the infrastructure level.

### What did you expect to see?
I expected that the throughput would be around 150 Gbps.


### What did you see instead?
The measured throughput was 90 Gbps.

### Proposal
I figured out what caused this. I modified the http2 connection pool a little as shown in the below link.
(https://github.com/ochanism/net/commit/b2cc93d427fb3b5dc0bc42be8c8943d76f35eaf3)
With the above code, I could achieve 150 Gbps throughput. 
For achieving high throughput, multiple TCP connections are needed.
But the current version of the http2 connection pool increases TCP connections only when there is no available TCP connection (CurrentMaxStreams == MaxConcurrentStreams for all the connections).
I reduced MaxConcurrentStreams value at the server-side, but the number of TCP connections wasn't increased than I expected.

So I added a MinConcurrentConns field to http2 Transport.
MinConcurrentConns is the minimum number of TCP connections and ClientConnPool tries to maintain  MinConcurrentConns TCP connections at least. If 0, ClientConnPool creates a TCP connection only when needed.

Please review my proposal.
Repository: rust
Issue: Scoping rules for tail expressions leads to unexpected compiler error
Labels: T-lang,A-maybe-future-edition

<!--
Thank you for filing a bug report! 🐛 Please provide a short summary of the bug,
along with any information you feel relevant to replicating the bug.
-->

I tried this code: [playground](https://play.rust-lang.org/?version=stable&mode=debug&edition=2018&gist=efbf3a046a8d1801cc3559ba28331368)

```rust
use tokio::sync::{Mutex, RwLock};

struct InnerUser {
    file_handle: Mutex<u64>,
}

struct Foo(RwLock<InnerUser>);

impl Foo {
    async fn try_set_lock0(&self) -> Result<(), u32> {
        let guard = self.0.read().await;
        if let Ok(_) = guard.file_handle.try_lock() {
            Ok(())
        } else {
            Err(2)
        }
    }

    async fn try_set_lock1(&self) -> Result<(), u32> {
        let guard = self.0.read().await;
        let ret = if let Ok(_) = guard.file_handle.try_lock() {
            Ok(())
        } else {
            Err(2)
        };
        ret
    }
}
```

I expected to see this happen: 

compile success

Instead, this happened:
the first function report error
```
   Compiling playground v0.0.1 (/playground)
error[E0597]: `guard` does not live long enough
  --> src/lib.rs:12:24
   |
12 |         if let Ok(_) = guard.file_handle.try_lock() {
   |                        ^^^^^-----------------------
   |                        |
   |                        borrowed value does not live long enough
   |                        a temporary with access to the borrow is created here ...
...
17 |     }
   |     -
   |     |
   |     `guard` dropped here while still borrowed
   |     ... and the borrow might be used here, when that temporary is dropped and runs the destructor for type `std::result::Result<tokio::sync::mutex::MutexGuard<'_, u64>, tokio::sync::mutex::TryLockError>`
   |
   = note: The temporary is part of an expression at the end of a block. Consider forcing this temporary to be dropped sooner, before the block's local variables are dropped. For example, you could save the expression's value in a new local variable `x` and then make `x` be the expression at the end of the block.

error: aborting due to previous error

For more information about this error, try `rustc --explain E0597`.
error: could not compile `playground`.

To learn more, run the command again with --verbose.
```

### Meta
<!--
If you're using the stable version of the compiler, you should also check if the
bug also exists in the beta or nightly versions.
-->

`rustc --version --verbose`:
```
rustc 1.43.0-nightly (8aa9d2014 2020-02-21)
binary: rustc
commit-hash: 8aa9d2014f4e5258f83b907e8431c59a33acdae7
commit-date: 2020-02-21
host: x86_64-unknown-linux-gnu
release: 1.43.0-nightly
LLVM version: 9.0

playground is stable 1.41.0
```
Repository: flutter
Issue: Textfield content disapears when text is too long
Labels: a: text input,c: regression,framework,f: material design,has reproducible steps,found in release: 3.3,found in release: 3.7,team-text-input


http://pub.waves.pw/ms/textfield.mp4

[✓] Flutter (Channel stable, v1.12.13+hotfix.8, on Linux, locale en_US.UTF-8)
    • Flutter version 1.12.13+hotfix.8 at /home/renan/code/flutter
    • Framework revision 0b8abb4724 (11 days ago), 2020-02-11 11:44:36 -0800
    • Engine revision e1e6ced81d
    • Dart version 2.7.0

 
[✓] Android toolchain - develop for Android devices (Android SDK version 29.0.3)
    • Android SDK at /home/renan/Android/Sdk
    • Android NDK location not configured (optional; useful for native profiling support)
    • Platform android-29, build-tools 29.0.3
    • Java binary at: /home/renan/code/android-studio/jre/bin/java
    • Java version OpenJDK Runtime Environment (build 1.8.0_202-release-1483-b49-5587405)
    • All Android licenses accepted.

[✓] Android Studio (version 3.5)
    • Android Studio at /home/renan/code/android-studio
    • Flutter plugin version 43.0.1
    • Dart plugin version 191.8593
    • Java version OpenJDK Runtime Environment (build 1.8.0_202-release-1483-b49-5587405)

[✓] VS Code (version 1.42.1)
    • VS Code at /usr/share/code
    • Flutter extension version 3.8.1

[✓] Connected device (1 available)
    • Pixel 3a • 9BCAY1J68Q • android-arm64 • Android 10 (API 29)

• No issues found!
Repository: flutter
Issue: Need to find how much of a long word could fit in one line before an unnatural line break
Labels: a: text input,framework,a: typography,c: proposal,P3,team-framework,triaged-framework

As described in issue #35994, there are a number of use cases for doing non rectangular LTR or RTL text layout. Although not convenient, it is possible to do custom text layout by breaking a string into short runs and measuring each run as a `Paragraph` itself before painting it at some desired location. A word/line breaker would make this easier (see issue #50171), but for general cases breaking at a space works OK.

A problem arises, though, when there is text run that is longer than the available length for the line. Take the following example:

```
aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa
```

There are no spaces to break at. That means that you have to measure every character or use some algorithm to test chunks of various lengths to see how much of it will fit. An unnatural break will be inserted at that location. The rest of the run will continue onto the next line.

A further complication is that some languages (like Mongolian and Arabic) use different size glyphs depending on the context. For example, here is a Mongolian word rendered correctly on the left, but the same word with the characters as they would look in isolation. 

![Mongolian word](https://user-images.githubusercontent.com/10300220/75090963-252da500-55a3-11ea-910b-dbd31511a16e.png)

The size is obviously different so simply taking the sum of the size of each character is not a viable option to find the length. Even taking a substring of the long word and measuring it would be different because the character at the break point would think it was at a final rather than a medial position and thus return the wrong size. A workaround would be to insert a Zero Width Joiner at the break point before measuring, but this is a lot of extra work compared to the feature request below. 

## Feature request

It would be very useful to have a feature like Android's `Paint.breakText` (see [example](https://stackoverflow.com/questions/45253574/does-paint-breaktext-include-the-character-at-the-maxwidth)). You feed it a string and a max length, and it tells you how many characters of that string will fit within the specified length.
Repository: godot
Issue: Camera near clip value can't be negative in inspector
Labels: enhancement,topic:rendering,topic:3d

**Godot version:**
3.2

**OS/device including version:**
Win 10 / Dell Precision 4700

**Issue description:**
I was unable to set the camera near clipping value to a negative number resulting in a visible clip problem. Negative values are prohibited by the inspector but are settable via .set_znear(-1000). I believe the editor should allow negative values as a negative near clip is desirable for setting up an isometric camera.

**Steps to reproduce:**
1. Add a camera to a scene
2. Set perspective to orthagonal
3. Attempt to enter a negative number in a camera's near clip field in the godot editor. The value mins at 0.01 instead of allowing a negative value

**Minimal reproduction project:**
not applicable

Thank you for your consideration of this change and thank you for a fantastic game engine.
Repository: godot
Issue: C# ToSignal() leading to possible crashes in release builds
Labels: bug,topic:dotnet

**Godot version:**
3.2 Stable (Mono)

**OS/device including version:**
Windows 10

**Issue description:**
When an instance is disposed while a function is awaiting within in, it can lead to the game crashing with a System.ObjectDisposedException.

![image](https://user-images.githubusercontent.com/7606171/75092823-fc45e980-557b-11ea-8f0c-88cefe40e9ea.png)

After looking through the source code it appears like the await call will continue executing in release builds (leading to the crash later down the road), however in debug builds it simply halts with an error message. This inconsistency has caused errors in release builds that were otherwise harder to trace during development. I believe it would be much more beneficial if ToSignal() would always stop executing in both debug and release mode, as the alternative fix to this issue would be to clutter your code with calls to `Object.IsInstanceValid()` after every `await` statement.

**Steps to reproduce:**
Simply free (or queue free) a node in which a ToSignal() call is currently awaiting. After the ToSignal() call completes, accessing any of the nodes methods will result in the game crashing in release builds.

**Minimal reproduction project:**
[project.zip](https://github.com/godotengine/godot/files/4239387/project.zip)
Repository: flutter
Issue: [google_maps_flutter] Please clarify why API KEY in source code is OK
Labels: d: stackoverflow,p: maps,package,team-ecosystem,P3,triaged-ecosystem

For those familiar with [API Key Best Practices](https://developers.google.com/maps/api-key-best-practices), the instructions for [Android](https://pub.dev/packages/google_maps_flutter#android) and [iOS](https://pub.dev/packages/google_maps_flutter#ios) make some nervous because it basically instructs them to store an API KEY in the source tree when there is an explicit rule against this practice: [Do not store API keys or signing secrets in files inside your application's source tree](https://developers.google.com/maps/api-key-best-practices#no_store_apikey).

Can the **documentation** be revised to explain why this is OK?
Repository: pytorch
Issue: torch.rand() not having same values on using torch.manual_seed(0)
Labels: triaged,module: random

```
print(torch.rand(batch_size, classes))
print(torch.rand(batch_size, classes))
```
printing it same, twice
This does not produce the same results on setting the seed `torch.manual_seed(0)`
Repository: go
Issue: cmd/go: build -o dir ./... should build (and discard) non main packages
Labels: NeedsDecision

<!-- Please answer these questions before submitting your issue. Thanks! -->

### What version of Go are you using (`go version`)?

<pre>
$ go version
go version go1.14rc1 linux/amd64
</pre>

### Does this issue reproduce with the latest release?

Yes.

### What operating system and processor architecture are you using (`go env`)?

<details><summary><code>go env</code> Output</summary><br><pre>
$ go env
GO111MODULE="on"
GOARCH="amd64"
GOBIN="/home/manlio/.local/bin"
GOCACHE="/home/manlio/.cache/go-build"
GOENV="/home/manlio/.config/go/env"
GOEXE=""
GOFLAGS=""
GOHOSTARCH="amd64"
GOHOSTOS="linux"
GOINSECURE=""
GONOPROXY=""
GONOSUMDB=""
GOOS="linux"
GOPATH="/home/manlio/.local/lib/go:/home/manlio/src/go"
GOPRIVATE=""
GOPROXY="https://proxy.golang.org,direct"
GOROOT="/home/manlio/sdk/go1.14rc1"
GOSUMDB="sum.golang.org"
GOTMPDIR=""
GOTOOLDIR="/home/manlio/sdk/go1.14rc1/pkg/tool/linux_amd64"
GCCGO="gccgo"
AR="ar"
CC="gcc"
CXX="g++"
CGO_ENABLED="1"
GOMOD="/dev/null"
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-build397314077=/tmp/go-build -gno-record-gcc-switches"
GOROOT/bin/go version: go version go1.14rc1 linux/amd64
GOROOT/bin/go tool compile -V: compile version go1.14rc1
uname -sr: Linux 5.5.4-arch1-1
/usr/lib/libc.so.6: GNU C Library (GNU libc) stable release version 2.31.
gdb --version: GNU gdb (GDB) 9.1
</pre></details>

### What did you do?

I have a module, with a *main* package in the module root directory and another package in a subdirectory.
A `.go` file in the nested package has a syntax error.

I ran the following commands
```
go build ./...
```

```
go build -o build/ ./...
```

### What did you expect to see?

Both commands to report an error
```
# github.com/perillo/go-init/internal/data
internal/data/data.go:12:25: syntax error: unexpected { after top level declaration
```

### What did you see instead?

Only the first command reports the syntax error.
Repository: godot
Issue: Editor Settings > Run > Window Placement > Screen: Doesn't Work
Labels: bug,topic:editor,confirmed

___

***Bugsquad note:** This issue has been confirmed several times already. No need to confirm it further.*

___

**Godot version:**
v3.2.stable.official

**OS/device including version:**
macOS Catalina Version 10.15.2

**Issue description:**
I want to use the "Editor Settings > Run > Window Placement > Screen" setting to make Godot run my game on a specific screen, specifically my laptop. However, no matter what I change the setting to, the game runs on my external monitor.

**Steps to reproduce:**
1. Use external monitor.
2. Change Editor Settings > Run > Window Placement > Screen to any setting.
3. Game always runs on external monitor, not laptop, when using Cmd + B shortcut.

**Minimal reproduction project:**
Any project with one scene.
Repository: vscode
Issue: Find/replace icons are not intuitive
Labels: feature-request,ux,editor-find

Issue Type: <b>Bug</b>

Related to my feedback on find/replace behavior (#91210), the dialog is also difficult to use because of its reliance on mystifying icons over labeled buttons.

* Several icons are just variants of `Aa` and `Ab` and `AB` etc. which are hard to keep straight without tool tips
* The "find in selection" icon doesn't convey selection
* Replacement options are hidden behind a generic disclosure triangle
* "Match whole word" doesn't convey much; there are 3 lines and I don't know what any of them represents
* "Replace" vs "Replace all" is reasonably intuitive but I'm not sure why "replace all" is differentiated with multiple characters being replaced rather than just multiple occurrences.

Aside from its icon, I'm not sure why "find in selection" is over to the right by the controls for navigating between occurrences, rather than an option that controls search behavior like "ignore case".

I also noticed that some button tooltips are in Title Case and others are in Sentence case, not sure if there is a reason for that.

VS Code version: Code 1.42.1 (c47d83b293181d9be64f27ff093689e8e7aed054, 2020-02-11T14:44:27.652Z)
OS version: Darwin x64 19.3.0
Repository: flutter
Issue: flutter run --profile -d chrome sourcemaps sometimes do not work?
Labels: tool,platform-web,P2,team-web,triaged-web

Apologies if I'm opening a duplicate.  I couldn't find one.

```
[✓] Flutter (Channel master, v1.15.4-pre.134, on Mac OS X 10.15.2 19C57, locale en-US)
    • Flutter version 1.15.4-pre.134 at /Users/eseidel/Projects/flutter/flutter
    • Framework revision bf8e2c1449 (26 hours ago), 2020-02-21 14:21:25 -0800
    • Engine revision f2f8c342be
    • Dart version 2.8.0 (build 2.8.0-dev.9.0 0f141be8bd)
```

@jonahwilliams mentioned to me on Friday that this was fixed.  But at least the scenario I'm trying doesn't seem to be.   This is not critical, just me attempting to come to a common understanding. :)

`flutter run -d chrome --profile` (e.g. inside flutter/samples/gallery) eseidel/samples@d51689bb7d7f93c65276a0531d19dcb87f98ced7 is a version of flutter/samples fixed to work with master.
Then record a profile from the inspector (performance tab).
Now try and click on one of the (obfuscated) names and view their source.
404s, e.g.:
Could not load content for http://localhost:54394/flutter/bin/cache/flutter_web_sdk/lib/_engine/engine/surface/surface.dart : HTTP status code: 404
Could not load content for http://localhost:54394/flutter/packages/flutter/lib/src/rendering/binding.dart : HTTP status code: 404

Browsing around the list of source files *does* work.  At least for the files in the project.

Also using examples in the flutter/flutter repository seems to work?  e.g. if you repeat the same experiment with flutter/flutter/examples/gallery those source links seem to work?  There the links are different, e.g.
http://localhost:55447/packages/flutter/lib/src/rendering/object.dart
http://localhost:55447/packages/flutter/lib/src/rendering/proxy_box.dart