sharjeelyunus/github-issues-dataset huggingface dataset:
Repository: go
Issue: runtime: add mode for pointer-past-end testing
Labels: NeedsFix,compiler/runtime

Over time, we've had several issues involving unsafe code constructing pointers just past the end of objects, particularly in runtime and reflect. Some examples are #21717, #19724, and #9384.

These sorts of issues are very hard to write tests for. We should consider adding a testing mode to aid with this. One approach would be for the allocator to skip every other slot and to right-align all allocations (up to alignment limits), so that past-the-end pointers would always fall on a free slot.

This mode could be exposed via a GODEBUG, though for testing it should probably be adjustable at run time, perhaps via unexported runtime functions.

/cc @RLH @cherrymui @bcmills
Repository: kubernetes
Issue: Minimize impact of kubelet stats collection
Labels: area/kubelet,sig/node,kind/feature,priority/important-longterm,lifecycle/frozen,needs-triage

**Is this a BUG REPORT or FEATURE REQUEST?**:
/kind feature

Today, the kubelet runs cAdvisor to collect node, pod, and container usage stats.

The goal discussed in sig-node has been to split usage stat collection responsibilities as follows:
* kubelet collects node and pod usage stats
* container runtimes collect container usage stats

The kubelet recently added support for the CRI to optionally handle container usage stats.  In production systems, if stats are sourced from different sources, operators are paying a performance impact by having to source the stats twice (i.e. cAdvisor collects all of it, and container runtimes collect it again).  As an operator of a large cluster with dense nodes, this impact is significant.  cAdvisor itself often is the dominant user of CPU on these systems, so running an alternative stat collection agent for the same data makes no sense.

The following issues must be mitigated if the long term goal is to be met:

* kubelet must only collect the stats it cares about
* collection interval skew between node/pod level stats and the runtime must be mitigated
Repository: kubernetes
Issue: Rethink quota system
Labels: sig/api-machinery,lifecycle/frozen

Problems with current quota system:
* #51476 - invalid objects still consume quota
* #51749 - uninitialized objects still consume quota
* no way for user-supplied apis to interact with the quota system
* replenishment is slow
* doesn't track object size (unless this has been fixed?)

I'd like to see a quota system that:
* Can track user-defined quotas for aggregated APIs
* Can track/prevent uninitialized object count and size
* Can track regular object count and size
* Doesn't need multiple interactions w/ etcd during the object initialization phase
* initializer/webhook based rather than compiled-in
Repository: go
Issue: cmd/compile: avoid slow versions of LEA instructions on x86
Labels: Performance,NeedsFix,early-in-cycle

On newer x86 cpus (amd and intel) 3 operand LEA instructions with base, index and offset have a higher latency and less throughput than 2 operand LEA instructions. 

The compiler when emitting the instructions could rewrite slow leas into e.g. LEA + ADD instructions where possible (flag clobbering ok) similar how MOV $0 R is rewritten to XOR R R.

```
Intel® 64 and IA-32 Architectures Optimization Reference Manual
3.5.1.3 Using LEA

For LEA instructions with three source operands and some specific situations, instruction latency has increased to 3 cycles, and must dispatch via port 1:
— LEA that has all three source operands: base, index, and offset.
— LEA that uses base and index registers where the base is EBP, RBP, or R13.
...
```

relevant llvm optimization ticket: https://reviews.llvm.org/D32277

/cc @TocarIP @randall77 @josharian
Repository: go
Issue: spec: clarify rule 3 for selector expressions
Labels: Documentation,NeedsFix

Please answer these questions before submitting your issue. Thanks!


### What version of Go are you using (`go version`)?

go version go1.9 linux/amd64

### Does this issue reproduce with the latest release?

yes

### What did you do?

```golang
package main

type T struct {
	x int
}
type P *T
type PP *P

func main() {
	var t T
	var p P = &t
	var pp PP = &p
	
	t.x = 123 // ok
	
	(*p).x = 123 // ok
	p.x = 123 // ok
	
	(*pp).x = 123 // ok
	pp.x = 123 // not ok
}
```

### What did you expect to see?

compile okay.

Go spec says
> As an exception, if the type of x is a named pointer type and (*x).f is a valid selector expression denoting a field (but not a method), x.f is shorthand for (*x).f. 

so as `(*pp).x` is valid, `pp.x` should be also valid.

### What did you see instead?

compile failed
Repository: opencv
Issue: lack of information of the Visual Studio 2017
Labels: feature,category: documentation

##### System information (version)

- OpenCV => 3.3
- Operating System / Platform => windows 10(64 bit)
- Compiler => none

##### Detailed description
Information on visual studio on the page for windows users is stopped at VS2015.
Specifically, you can see the lack of information in VS2017 in the command column under http://docs.opencv.org/master/d3/d52/tutorial_windows_install.html#tutorial_windows_install_path . 
It is helpful to add the information of VS2017 if you can write it.

[I use google transrate]
Repository: opencv
Issue: 'OpenCV_Install_Directory.png' in 'Installation in Windows' page is old
Labels: feature,category: documentation

##### System information (version)
- OpenCV => 3.3
- Operating System / Platform => Windows 10(64 Bit)

##### Detailed description
Since I want to use OpenCV 3.3 on Windows 10, I saw http://docs.opencv.org/master/d3/d52/tutorial_windows_install.html#tutorial_windows_install_path .
However, since 'OpenCV_Install_Directory.png' is of OpenCV 2.3,
I was worried because I did not understand that what I downloaded is different and contents downloaded are correct.

If the content of the downloaded file has changed, please update the image. Or add an image of the latest case. That way, I am glad.

[I use google transrate]
Repository: go
Issue: regexp: Scan the input string backward for patterns ending in $
Labels: Performance,help wanted,NeedsFix

As [suggested](https://github.com/golang/go/issues/21463#issuecomment-326151555) by @rsc:

> It seems clear that we should handle patterns ending in $, like `\.(jpe?g|gif)$`, by scanning the string backward, which cuts the processing from O(n) to O(1) for an input of size n. That's easy to add to the existing matchers and doesn't need to be limited to fixed-size patterns.

I'm working on a CL to implement it for strings and byte slices.
Repository: puppeteer
Issue: PDF creation pixel sizes causes layout to change
Labels: bug,upstream,chromium,confirmed,P3

Hi,

When creating PDFs from a responsive web page, lets say the page has a css rule to show a narrower version below `1024` pixels screen width and we supply `width: "1024px"` to `pdf` function. The rule should not apply on this case however it does and the layout changes in generated pdf. 

Only when the width parameter is **4/3** of the actual width of viewport, then the pdf has exact same layout of given viewport width. This seems to be something related to an inches / points confusion somewhere (96 pixels per inch, 72 pixels per point. 96/72 = 4/3)

So, when I provide `1365px` as pdf width I get the exact representation of the page at `1024px` viewport width. Anything below `1365px`, page acts like the viewport is below `1024px` and applies the appropriate responsive css rules.

I'm not sure if this is an upstream bug or something else though. Margins are set to 0 btw. 

Any ideas?
Repository: rust
Issue: export_name works for msvc x86_64 toolchain, but not i686
Labels: A-linkage,T-compiler,C-bug,O-x86_32

I'm trying to build a simple dll and export a function with a pre-mangled name. I have `crate-type` set to `cdylib` and my function decorated like so:

    #[allow(non_snake_case)]
    #[export_name="?Hook@@YAXXZ"] // This is how MSVC mangles this name.
    pub fn Hook() {

I'm using MSVC 2017 Community edition v14.10.25017; toggling between these two toolchains using rustup:
`nightly-x86_64-pc-windows-msvc unchanged - rustc 1.22.0-nightly (f861b6ee4 2017-09-01)`
`nightly-i686-pc-windows-msvc unchanged - rustc 1.22.0-nightly (f861b6ee4 2017-09-01)`

The former links fine, the latter gives this error:
`mydll.dll.exp: error LNK2001: unresolved external symbol "void __cdecl Hook(void)" (?Hook@@YAXXZ)`
`fatal error LNK1120: 1 unresolved externals`
Repository: puppeteer
Issue: How can I get the raw size or content-length of the response?
Labels: feature,upstream,chromium

I mean some response is gzipped, I want to get the size, thanks
Repository: go
Issue: cmd/compile: obscure initialization loop error message due to inlining
Labels: NeedsFix,compiler/runtime

go version devel +0a4913b2d4 Wed Aug 23 11:09:11 2017 +0200 linux/amd64

https://play.golang.org/p/TW5DVv3zTk

Produces obscure:
```
tmp/sandbox278346721/main.go:3:5: initialization loop:
	prog.go:3:5 A refers to
	prog.go:3:5 A
```

If compiled with `-l` produces understandable error message:
```
/tmp/test.go:3:5: initialization loop:
	/tmp/test.go:3:5 A refers to
	/tmp/test.go:7:10 B refers to
	/tmp/test.go:11:10 C refers to
	/tmp/test.go:15:10 D refers to
	/tmp/test.go:3:5 A
```

In real scenario this is spread across files and intermixed with other code.
Repository: rust
Issue: Support coercing non-capturing closures to extern function pointers
Labels: A-closures,T-lang,T-compiler,C-feature-request

This is a followup to https://github.com/rust-lang/rust/issues/39817 . Non-capturing closures now coerce to function pointers, but not to `extern fn` pointers, as provided to C functions expecting a callback. Adding support for this would make it much simpler to call a C function and provide an appropriate callback inline.


(I'm also curious what it would take to make a *capturing* closure work as an extern function pointer, but that's a separate issue.)
Repository: vscode
Issue: Create an option to position the intellisense parameter info top or bottom.
Labels: feature-request,editor-parameter-hints

Currently the parameter info tooltip is always placed above the cursor. This is often quite annoying since it completely blocks code in the above lines and you sometimes need to look at your context to know what values to give the parameters.

Example:
![image](https://user-images.githubusercontent.com/702922/30005026-e9034dec-9096-11e7-80c0-1a23814ca15c.png)
Repository: rust
Issue: Re-exported types have confusingly different documentation
Labels: T-rustdoc,C-bug,A-cross-crate-reexports

Re-exported types seem to have more confusing documentation than the original type. I noticed this while reviewing rayon::Configuration which is re-exported from rayon-core.

---

#### original/src/lib.rs

```rust
pub trait T {}
pub struct S;

impl S {
    pub fn f<F>(_: F, _: Box<T>) -> Self
        where F: Fn()
    {
        unimplemented!()
    }
}
```

This is documented basically like what I wrote, which is what I would expect:

![selection_063](https://user-images.githubusercontent.com/1940490/30007998-d8d16a2a-90ce-11e7-95fe-0d5c68180bb9.png)

---

#### src/lib.rs

```rust
extern crate original;
pub use original::S;
```

This is documented with a couple changes, all of which are technically correct but unexpected.

- The `Box<T>` is now `Box<T + 'static>`.
- The return type has changed from `Self` to `S`.
- ~~The `where` clause gives an explicit `-> ()`.~~ fixed as of 1.50
- The parameter name placeholders are gone (which I prefer, but it is a difference).

![selection_062](https://user-images.githubusercontent.com/1940490/30008001-dd300d6a-90ce-11e7-9edc-55a3e8d53cfd.png)

I am using rustc 1.22.0-nightly (f861b6ee4 2017-09-01).

@GuillaumeGomez 

<!-- TRIAGEBOT_START -->

<!-- TRIAGEBOT_ASSIGN_START -->

<!-- TRIAGEBOT_ASSIGN_DATA_START$${"user":"fmease"}$$TRIAGEBOT_ASSIGN_DATA_END -->

<!-- TRIAGEBOT_ASSIGN_END -->
<!-- TRIAGEBOT_END -->
Repository: awesome-mac
Issue: Add open-in-buttons-for-finder-toolbar
Labels: vote

Hi can you add this tools to your list?
https://github.com/cnstntn-kndrtv/open-in-buttons-for-finder-toolbar
Repository: godot
Issue: RigidBody2D ignores set_position when switching between MODE_RIGID and MODE_STATIC/KINEMATIC
Labels: bug,confirmed,topic:physics

**Operating system or device, Godot version, GPU Model and driver (if graphics related):**

Windows 10, current master branch (6d233c651b21ecaef78fbb20d0365a22919b72b1), nVidia GeForce GTX 1080, driver version V385.41  (but probably not related to GPU)

**Issue description:**
<!-- What happened, and what was expected. -->

When switching a RigidBody2D to `MODE_STATIC` or `MODE_KINEMATIC`, changing its position, and then switching back to `MODE_RIGID` and applying an impulse, movement starts at the position where the previous movement stopped, not at the current position.

**Steps to reproduce:**

In the example project, move the ball to the green area and click LMB to launch the ball. Move to the red area and click the button again to attach the ball to the mouse. When moving the mouse the ball sticks to the mouse position as expected. Click the mouse button over the red area; the ball will launch in the green area, not from its current position.

**Link to minimal example project:**
<!-- Optional but very welcome. You can drag and drop a zip archive to upload it. -->

[2D-Physics.zip](https://github.com/godotengine/godot/files/1274695/2D-Physics.zip)
Repository: angular
Issue: Support for async rendering
Labels: feature,area: core,feature: under consideration

<!--
PLEASE HELP US PROCESS GITHUB ISSUES FASTER BY PROVIDING THE FOLLOWING INFORMATION.

ISSUES MISSING IMPORTANT INFORMATION MAY BE CLOSED WITHOUT INVESTIGATION.
-->

## I'm submitting a...
<!-- Check one of the following options with "x" -->
<pre><code>
[ ] Regression (a behavior that used to work and stopped working in a new release)
[ ] Bug report  <!-- Please search GitHub for a similar issue or PR before submitting -->
[x] Feature request
[ ] Documentation issue or request
[ ] Support request => Please do not submit support request here, instead see https://github.com/angular/angular/blob/master/CONTRIBUTING.md#question
</code></pre>

The new version of React (16.x) will introduce a core feature called async rendering.
(https://edgecoders.com/react-16-features-and-fiber-explanation-e779544bb1b7)

This allows the framework to render a lot of things at the same time without blocking the main thread.

Thanks to this feature the ui feels much more fluid. You can see it in this demo where stacked rendering (synchronous) and fibre (asynchronous) rendering are compared.
https://claudiopro.github.io/react-fiber-vs-stack-demo/

I was wondering, is this something that can also be implemented in angular? If so, are there any plans for a similar feature?

## Current behavior
<!-- Describe how the issue manifests. -->
Component rendering is happening synchronous --> blocks the main thread.

## Expected behavior
<!-- Describe what the desired behavior would be. -->
Component rendering is happening asynchronous --> doesn't block the main thread.
Repository: go
Issue: go/ast: CommentMap mishandles loose, trailing file comments
Labels: NeedsInvestigation

`go version devel +812b34efae Mon Sep 4 00:07:33 2017 +0000 linux/amd64`

Construct a comment map for:

```go
package p

func f() {
        return
}

// loose trailing comment
```

The loose trailing comment is associated in the CommentMap with the
return statement inside f. It should probably be associated with f
instead, and the NewCommentMap docs updated with new rules.

Live proof: https://play.golang.org/p/XCktcSxYl8
Repository: angular
Issue: Injected Styles don't apply to HTML modified through other libraries due to selectors scope
Labels: type: bug/fix,freq1: low,area: core,core: CSS encapsulation,P3

## I'm submitting a...
[ ] Regression 
[X] Bug report
[ ] Feature request
[ ] Documentation issue or request
[ ] Support request
## Current behavior
While injecting styles with a component, if a new element is injected by another library (for example rangy) the new element doesn't get styled even if it's inside the scoped selector.


## Expected behavior
have the element get styled


## Minimal reproduction of the problem with instructions
Open the following plunker and select a word in black, it should get wrapper in an <a> tag with the class "specialNote" however the style doesn't gets applied, other element sin the component did used the style

https://embed.plnkr.co/nDJ8jOgUsBYJX8JartXj/

I 

## What is the motivation / use case for changing the behavior?
injected styles should work consistently


## Environment
Angular version: 4.1.1

Browser:
- [X] Chrome (desktop) version 60
 
For Tooling issues:
- Node version: 8
- Platform:  Mac

Others:
If you open the developer console and modify the style from

```
.specialNote[_ngcontent-c0] {
  color: red; }
```
to 
```
.specialNote{
  color: red; }
```

the expected behavior happens


Additional test with angular 4.3

https://embed.plnkr.co/xiWBruUptjpItfWlmZrJ/
Repository: opencv
Issue: Extend CvCaptureCAM_Aravis::open( int index ) to allow for custom ROI
Labels: feature,category: videoio(camera)

Hi all,

I would like to extend CvCaptureCAM_Aravis to allow arv_camera_set_region() to take in a custom set of ROI coordinates. Basically to allow for heightMin and heightMax to be changed, and to allow for two extra paremeters x and y to be passed in (as per arv_camera_set_region(x,y,height,width) in the aravis driver.

I can make these changes myself, and issue a pull request, but would like to know is my approach is right:
- Make CV_CAP_PROP_FRAME_WIDTH and CV_CAP_PROP_FRAME_HEIGHT writable, and expose them via setProperty()
- Add two new properties to enum | cv::VideoCaptureProperties such as CV_CAP_PROP_OFFSET_X and CV_CAP_PROP_OFFSET_Y and make them available via setProperty in the cap_aravis driver
- Upon setting any of these, stop capture, issue another call to arv_camera_set_region and update the values (if any of them are not set, default to what is currently there for each), start capture.

The reason for this change is that it would significanly speed up image aquisition for applications where all you need is a smaller region rather than the full image.

Thank you,
Flaviu
Repository: pytorch
Issue: BatchNorm{1-2-3}d are redundant
Labels: module: nn,triaged

Since https://github.com/pytorch/pytorch/pull/2020, `nn.BatchNorm1d`/`nn.BatchNorm2d`/`nn.BatchNorm3d` are completely redundant, as there are no more size checks that are performed in the input tensor
I see two options here:
* add the size-checks back for each class;
* deprecate BatchNorm{1-2-3}d and use instead BatchNorm.

We already have only a single functional interface for BatchNorm, so option 2 might be worth considering.

cc. @alykhantejani who removed the size checks
Repository: rust
Issue: unused_assignments does not care about unused assignments to reference derefs
Labels: A-lints,T-compiler,C-bug

```rust
pub fn foo(b: bool, x: &mut i32) {
    if b {
        *x = 6;
    }
    *x = 7;
}
```

does not emit the `unused_assignments` lint. I understand that this is not possible for `DerefMut` in general, because every call to `deref_mut` (via desugaring `*`) can result in a different reference, but for pure references everything should be good.

A case of not linting this causing a bug was found in rustc: https://github.com/rust-lang/rust/blob/2f1ef9ef1181298d46e79d5dde6bafeb6483926f/src/librustc_mir/transform/inline.rs#L614-L620
Repository: godot
Issue: animations don't loop after importing .dae from blender in v3
Labels: bug,topic:import

**Operating system or device, Godot version, GPU Model and driver (if graphics related):**
Ubuntu 17.04 - Godot v3.0.alpha.custom_build.6d233c6

The animation loops correctly in the editor but now then the scene is played. Check out the attached project.

[godot-dbg.zip](https://github.com/godotengine/godot/files/1277958/godot-dbg.zip)
Repository: pytorch
Issue: [feature request] add pairwise ranking loss
Labels: module: loss,triaged
Repository: bitcoin
Issue: Wallet should be able to store multiple transactions with same txid
Labels: Wallet

Pre-segwit, malleated transactions would have a different txid and therefore be accepted and stored by the wallet when seen on the network.

Post-segwit, it's possible for a malleated transaction that is seen on the network to be ignored by the wallet, because we index the wallet db by txid, and we are currently only able to store one entry for a given txid (and I have no idea whether this assumption is easy to change).  This means that if a malleated transaction were mined on the network, we would only store the original version of the transaction.  While this doesn't appear to have any direct impact on our wallet's behavior, this could frustrate wallet users who expect the stored transaction to be the same as the one mined.

Within the current paradigm (of storing a single transaction per txid), we could instead store the latest seen version of any transaction, so that if a malleated version of a transaction is mined, that will get stored in our wallet and we'd forget about any previous version.  However, that isn't an ideal solution either: suppose the malleated version of the transaction violates local mempool policy, and the block containing the malleated transaction gets reorged out.  If the wallet would replace the non-malleated transaction with the malleated one when it was received, we'd have no way to rebroadcast the transaction again after such a reorg.  And since I think losing a signed transaction (which we may not be able to reproduce) is a terrible outcome, I think we should for now continue to keep whatever original signed version of a transaction that we see, and not replace.

Slightly relevant to this: #11225 adds the ability to replace a transaction that has no witness with one that has a witness, under the reasoning that this is only possible if we have upgraded a wallet that was pre-segwit, and are now receiving the full transaction post-upgrade.  Since any transaction that is valid with a witness must be invalid under segwit's rules without the witness, doing this specific replacement should put the wallet in a strictly better position (where it might now be storing a valid transaction, which is possibly the same as the version of the transaction which was/will be mined).