sharjeelyunus/github-issues-dataset huggingface dataset:
Repository: rust
Issue: Improve mechanism to separate unit and integration tests
Labels: A-libtest

# Proposal

## Problem statement

There is no simple way to run unit tests only, without understanding of the crate content (i.e. `cargo test --bins`, `cargo test --lib`, `cargo test --bins --lib`).

## Motivation, use-cases

For complex systems integration tests can be time consuming and do not always add value during all aspects of the development cycle, it is favorable to be able to select between only running integration tests and not running integrations tests as part of the normal test suite.

It is currently possible to select integration tests using:

`cargo test --test '*'`

And for a bin only crate the following works to select unit tests:

`cargo test --bins`

And for a lib only crate the following works:

`cargo test --lib`

If you use `cargo test --lib` on a bin only crate, you get a warning. But if you use `cargo test --bins` on a lib crate you get an error.

So there isn't a consistent mechanism to select unit tests only.

## Solution sketches

The simplest solution would be to make `cargo test --bins` emit a warning when there are no bins to test. However...

I would like to add `--exclude-integration` and `--integration` to the test lib, this would keep consistency with the `ignored` and `include-ignored` commands. i.e.

```
cargo test -- --exclude-integration
cargo test -- --integration
```

## Links and related work

I have a first pass at the code here:

https://github.com/rust-lang/rust/commit/da004f7ee5bd24ec01bc88423a9b4f7f204d85a9
Repository: PowerToys
Issue: Task: Update MS Store info
Labels: Idea-Enhancement

### Provide a description of requested docs changes

![image](https://user-images.githubusercontent.com/65828559/204861412-50fe6484-fefa-491d-9906-e0c57b94bd66.png)

- [ ] functions
- [ ] about
- [ ] what's new
- [ ] OS version
- [ ] images

Link: https://apps.microsoft.com/store/detail/XP89DCGQ3K6VLD
Repository: rust
Issue: Iterating on an array of ranges looks syntactically plausible but is not, and the error message is nonsense to a beginner
Labels: A-diagnostics,T-compiler

<!--
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.

If you cannot produce a minimal reproduction case (something that would work in
isolation), please provide the steps or even link to a repository that causes
the problematic output to occur.
-->

Given the following code: https://play.rust-lang.org/?version=stable&mode=debug&edition=2021&gist=52eead7828aab2c2e36ac25556a721ff

```rust
fn main() {
    let mut x = [[0; 3]; 3];
    x[0][0] = 7; // works
    for i in [0..3] {
        for j in [0..3] {
            x[i][j] = 7; // complains
        }
    }
    dbg!(x);
}
```

The current output (on stable & nightly) is:

```
Compiling playground v0.0.1 (/playground)
error[[E0308]](https://doc.rust-lang.org/nightly/error-index.html#E0308): mismatched types
 --> src/main.rs:6:23
  |
6 |             x[i][j] = 7; // complains
  |             -------   ^ expected slice `[[{integer}; 3]]`, found integer
  |             |
  |             expected due to the type of this binding

error[[E0277]](https://doc.rust-lang.org/nightly/error-index.html#E0277): the size for values of type `[[{integer}; 3]]` cannot be known at compilation time
 --> src/main.rs:6:13
  |
6 |             x[i][j] = 7; // complains
  |             ^^^^^^^ doesn't have a size known at compile-time
  |
  = help: the trait `Sized` is not implemented for `[[{integer}; 3]]`
  = note: the left-hand-side of an assignment must have a statically known size

Some errors have detailed explanations: E0277, E0308.
For more information about an error, try `rustc --explain E0277`.
error: could not compile `playground` due to 2 previous errors
```
Ideally the output could recognize that what they *probably* meant was to iterate the range directly. I'm not sure why you would ever iterate over a temp array with a single element that's a range and then index using that. If you want the ranges, you won't be indexing. If you want the indexing, it would be nice for the compiler to suggest removing the `[` `]` around the range.

I feel that the current error message confuses new developers, because while they're trying to figure out indexing in Rust, the error message is talking about a trait named `Size`, slices, and how something doesn't have compile-time known sizes. Totally out of their depth. In practice, this gets caught as soon as they ask for help but I was surprised at how unhelpful the error message here is.
Repository: rust
Issue: The PartialEq implementation for tuples isn't general enough
Labels: T-libs-api,C-bug

A coworker recently ran into a situation where tuples aren't comparable even when their individual elements are. I was able to boil it down to the following code snippet:

```rust
fn main() {
    assert_partial_eq::<A, B>();
    assert_partial_eq::<C, D>();
    assert_partial_eq::<(A, C), (B, D)>();
}

fn assert_partial_eq<A, B>() where A: PartialEq<B> {}

#[derive(Debug, PartialEq)] struct A;
#[derive(Debug, PartialEq)] struct B;
#[derive(Debug, PartialEq)] struct C;
#[derive(Debug, PartialEq)] struct D;

impl PartialEq<A> for B { fn eq(&self, other: &A) -> bool { true } }
impl PartialEq<B> for A { fn eq(&self, other: &B) -> bool { true } }

impl PartialEq<C> for D { fn eq(&self, other: &C) -> bool { true } }
impl PartialEq<D> for C { fn eq(&self, other: &D) -> bool { true } }

```

[(playground)](https://play.rust-lang.org/?version=stable&mode=debug&edition=2021&gist=611fb57671c62a1114880a2a0b2f5073)

I expected the above snippet to compile and run successfully, but the code fails to compile.

```
Compiling playground v0.0.1 (/playground)
error[[E0277]](https://doc.rust-lang.org/stable/error-index.html#E0277): can't compare `(A, C)` with `(B, D)`
  --> src/main.rs:19:25
   |
19 |     assert_partial_eq::<(A, C), (B, D)>();
   |                         ^^^^^^ no implementation for `(A, C) == (B, D)`
   |
   = help: the trait `PartialEq<(B, D)>` is not implemented for `(A, C)`
   = help: the following other types implement trait `PartialEq<Rhs>`:
             ()
             (A, Z, Y, X, W, V, U, T)
             (B, A, Z, Y, X, W, V, U, T)
             (C, B, A, Z, Y, X, W, V, U, T)
             (D, C, B, A, Z, Y, X, W, V, U, T)
             (E, D, C, B, A, Z, Y, X, W, V, U, T)
             (T,)
             (U, T)
           and 5 others
note: required by a bound in `assert_partial_eq`
  --> src/main.rs:22:39
   |
22 | fn assert_partial_eq<A, B>() where A: PartialEq<B> {}
   |                                       ^^^^^^^^^^^^ required by this bound in `assert_partial_eq`
```

I always thought the standard library would have something like this:

```rust
impl<LHS1, LHS2, RHS1, RHS2> PartialEq<(RHS1, RHS2)> for (LHS1, LHS2)
where 
  LHS1: PartialEq<RHS1>,
  LHS2: PartialEq<RHS2>,
{
  ...
}
```

But it seems like it only implements `PartialEq` when the left-hand side tuple and right-hand side tuple have the exact same type.

### Meta

This is reproducible on the Rust playground using stable (1.65.0).
Repository: vscode
Issue: Run code on wayland mode result on broken ibus connection
Labels: bug,upstream,electron,editor-input-IME,confirmed,wayland

Type: <b>Bug</b>


- OS Version:
  - ubuntu 20.04
  - ubuntu 22.04
  - fedora 36
  - fedora 37

- VS Code Version: 
  - [code-insiders_1.74.0-1669787647](https://code.visualstudio.com/insiders/)
  - [code_1.73.1-1667967334](https://code.visualstudio.com/Download)

Steps to Reproduce:
1. start with:
```
code-insiders --ozone-platform-hint=auto --enable-features=WaylandWindowDecorations --ozone-platform=wayland
```
or
```
code --ozone-platform-hint=auto --enable-features=WaylandWindowDecorations --ozone-platform=wayland
```
Then try to type some Japanese chars only result on standard English chars.

When you run code on xwayland or x11 you can use ibus to write non-ascii characters without any problem.

VS Code version: Code - Insiders 1.74.0-insider (9908b3d5ae12691da5adc2f18e21a100ee8eeb58, 2022-11-30T05:33:53.125Z)
OS version: Linux x64 5.15.0-53-generic
Modes:
Sandboxed: Yes

<details>
<summary>System Info</summary>

|Item|Value|
|---|---|
|CPUs|AMD Ryzen 5 3600X 6-Core Processor (2 x 3799)|
|GPU Status|2d_canvas: unavailable_software<br>canvas_oop_rasterization: disabled_off<br>direct_rendering_display_compositor: disabled_off_ok<br>gpu_compositing: disabled_software<br>multiple_raster_threads: disabled_off<br>opengl: disabled_off<br>rasterization: disabled_software<br>raw_draw: disabled_off_ok<br>skia_renderer: enabled_on<br>video_decode: disabled_software<br>video_encode: disabled_software<br>vulkan: disabled_off<br>webgl: unavailable_software<br>webgl2: unavailable_software<br>webgpu: disabled_off|
|Load (avg)|1, 0, 0|
|Memory (System)|15.63GB (13.89GB free)|
|Process Argv|--ozone-platform-hint=auto --enable-features=WaylandWindowDecorations --ozone-platform=wayland --crash-reporter-id 898eeabe-6c40-44ae-a4ba-537d37586078|
|Screen Reader|no|
|VM|0%|
|DESKTOP_SESSION|ubuntu|
|XDG_CURRENT_DESKTOP|Unity|
|XDG_SESSION_DESKTOP|ubuntu|
|XDG_SESSION_TYPE|wayland|
</details>Extensions: none<details>
<summary>A/B Experiments</summary>

```
vsliv695:30137379
vsins829:30139715
vsliv368cf:30146710
vsreu685:30147344
python383:30185418
vspor879:30202332
vspor708:30202333
vspor363:30204092
vslsvsres303:30308271
pythonvspyl392:30422396
pythontb:30258533
pythonptprofiler:30281269
vsdfh931:30280409
vshan820:30294714
pythondataviewer:30285072
vscod805:30301674
bridge0708:30335490
bridge0723:30353136
cmake_vspar411:30581797
vsaa593:30376534
pythonvs932:30404738
cppdebug:30492333
vsclangdf:30492506
c4g48928:30535728
dsvsc012:30540252
pynewext54:30618038
pylantcb52:30590116
pyindex848:30611229
nodejswelcome1:30587009
pyind779:30611226
dbltrim-noruby:30604474

```

</details>

<!-- generated by issue reporter -->
Repository: godot
Issue: `Image.fill_rect()` unlocks image
Labels: bug,topic:core,confirmed

### Godot version

3.5.1

### System information

Windows 11

### Issue description

I locked the image. I used `Image.fill_rect()`. Then I tried using `Image.get_pixel()` and it gave me an error.

```
E 0:00:00.503   get_pixel: Image must be locked with 'lock()' before using get_pixel().
  <C++ Error>   Condition "!ptr" is true. Returned: Color()
  <C++ Source>  core/image.cpp:2604 @ get_pixel()
  <Stack Trace> test.gd:9 @ _ready()
```


### Steps to reproduce

1. Lock image.
2. Fill rect.
3. Get pixel.

### Minimal reproduction project

[test.zip](https://github.com/godotengine/godot/files/10126469/test.zip)
Repository: pytorch
Issue: Random K compression hook in PyTorch DDP
Labels: feature,triaged,module: ddp

### 🚀 The feature, motivation and pitch

Currently Pytorch DDP supports a few default compression hooks, namely fp16, bf16, and PowerSGD. However, there are a myraid of other compression types that exist in literature with various degrees of success. Often in literature these methods are rewritten by each research team leading to a lot of duplicate work, increased difficulty of reproducibility, and also increasing the barrier for others to experiment with the same techniques.

A common and simple compression method is Random-K, which all reduces only some percent (to be determined by the user) of tensor elements. We have implemented Random-K as a DDP hook and would like to contribute it back to PyTorch so there can be a standard, reusable Random-K compression method available to all. Our implementation is based upon the implementation in [GRACE](https://github.com/sands-lab/grace).

[EDIT]: We are also interested in adding other compression hooks, such as Top-K and [Deep Gradient Compression](https://github.com/synxlin/deep-gradient-compression) to the DDP library if the maintainers are interested.

Let me know what you think!

Best,
Harrison

### Alternatives

_No response_

### Additional context

_No response_
Repository: angular
Issue: Angular Elements: Can't access input property's value inside ngOnInit() after compiling the web component
Labels: area: elements

### Which @angular/* package(s) are the source of the bug?

elements

### Is this a regression?

No

### Description
I am creating a web component using Angular Elements 15, and it seems that when I pass a property to my web component, the property returns undefined in the ngOnInit and ngAfterViewInit hooks. I also noticed that ngAfterViewChecked() runs several times (for the very basic component in the reproduction link below) with the value of the property being undefined. I am wondering if this is expected behavior and if so, when do we know for sure that we can access a custom element's Input() properties.

### Please provide a link to a minimal reproduction of the bug
[https://codesandbox.io/s/amazing-butterfly-dwdwi9?file=/src/app/app.component.html](https://codesandbox.io/s/amazing-butterfly-dwdwi9?file=/src/app/app.component.html
)

### Please provide the environment you discovered this bug in (run `ng version`)

Reproduced the problem on Angular 15 / 14 / 13
Repository: flutter
Issue: `NavigationRailDestination` in selected mode doesn't shift in M3
Labels: framework,f: material design,a: quality,found in release: 3.3,found in release: 3.6,team-design,triaged-design

#91605
#116108 

The first NavigationRailDestination on the panel in the example does not rise or fall when selected or unselected. Instead, it replaces other elements in the panel below it. This was not the case in M2, and this can be seen in the example https://api.flutter.dev/flutter/material/NavigationRail-class.html

https://user-images.githubusercontent.com/48603081/204319415-bf908286-d3d4-4eaa-b723-6c5323c0e5ae.mov

https://user-images.githubusercontent.com/102767277/204891568-d328383f-9508-41c6-a45c-ec811e047783.mp4
Repository: rust
Issue: unused_variables syntax error with box patterns / box syntax
Labels: A-diagnostics,T-compiler,D-invalid-suggestion

<!--
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.

If you cannot produce a minimal reproduction case (something that would work in
isolation), please provide the steps or even link to a repository that causes
the problematic output to occur.
-->

Given the following code: <!-- Please provide a link to play.rust-lang.org -->

```rust
#![feature(box_patterns)]
#![feature(box_syntax)]

enum E {
    StructVar { boxed: Box<i32> },
}

fn main() {
    let a = E::StructVar { boxed: box 3 };
    match a {
        E::StructVar { box boxed } => {}
    }
}
```

`cargo fix`
````
warning: build failed, waiting for other jobs to finish...
warning: failed to automatically apply fixes suggested by rustc to crate `g`

after fixes were automatically applied the compiler reported errors within these files:

  * src/main.rs

This likely indicates a bug in either rustc or cargo itself,
and we would appreciate a bug report! You're likely to see
a number of compiler warnings after this message which cargo
attempted to fix but failed. If you could open an issue at
https://github.com/rust-lang/rust/issues
quoting the full output of this command we'd be very appreciative!
Note that you may be able to make some more progress in the near-term
fixing code with the `--broken-code` flag

The following errors were reported:
error[E0026]: variant `E::StructVar` does not have a field named `_boxed`
  --> src/main.rs:11:28
   |
11 |         E::StructVar { box _boxed } => { }
   |                            ^^^^^^
   |                            |
   |                            variant `E::StructVar` does not have this field
   |                            help: a field with a similar name exists: `boxed`

error: aborting due to previous error

For more information about this error, try `rustc --explain E0026`.
Original diagnostics will follow.

warning: unused variable: `boxed`
  --> src/main.rs:11:28
   |
11 |         E::StructVar { box boxed } => { }
   |                            ^^^^^ help: if this is intentional, prefix it with an underscore: `_boxed`
   |
   = note: `#[warn(unused_variables)]` on by default
````
Repository: stable-diffusion-webui
Issue: SD 2.0 on Macbook M1 - Input type (MPSFloatType) and weight type (torch.FloatTensor) should be the same 
Labels: bug-report,platform:mac

### Is there an existing issue for this?

- [X] I have searched the existing issues and checked the recent builds/commits

### What happened?

Got this error when trying to run SD 2.0 on Macbook M1:
RuntimeError: Input type (MPSFloatType) and weight type (torch.FloatTensor) should be the same


### Steps to reproduce the problem

1. Im running Web UI from this commit: https://github.com/AUTOMATIC1111/stable-diffusion-webui/commit/4b3c5bc24bffdf429c463a465763b3077fe55eb8. 
2. Loaded SD 2: 768-v-ema.ckpt


### What should have happened?

Should have ran the model.

### Commit where the problem happens

4b3c5bc24bffdf429c463a465763b3077fe55eb8

### What platforms do you use to access UI ?

MacOS

### What browsers do you use to access the UI ?

Apple Safari

### Command Line Arguments

```Shell
python3 webui.py --precision full --no-half
```


### Additional information, context and logs

_No response_
Repository: rust
Issue: enabling a only a single lint is not intuitive
Labels: A-diagnostics,T-compiler,C-bug,WG-diagnostics

https://rust-lang.zulipchat.com/#narrow/stream/131828-t-compiler/topic/.E2.9C.94.20silencing.20all.20but.20one.20rustc.20lint

I wanted to do a simple task: silence all but one particular rustc lint.
`rustc -Awarnings` "allows" all the warnings, easy so we only need to re-warn a single lint:
`rustc -Awarnings -Wdead-code`
As it turns out this does not work, `-Awarnings` does silence all lints, even the ones enabled again after the flag (order does not matter it seems).
Similar thing  works just fine with clippy: `clippy-driver  -Aclippy::all -Wclippy::redundant_clone` only warns about redundant clones`

I found out I can archive this for rustc by passing `force-warn` with every lint manually, so
`rustc/clippy-driver -Awarnings --force-warn dead-code --force-warn clippy::redundant_clone`  but this is kinda horribly UX imo.

Can we just make `-Awarnings -Wunused_variables` work intuitively?
Repository: pytorch
Issue: Calling item() on symbolic shape fake tensor should give more clear error message
Labels: triaged,module: fakeTensor

### 🐛 Describe the bug

Right now it says `RuntimeError: Cannot call numel() on tensor with symbolic sizes/strides` which is bad

### Versions

master

cc @eellison @voznesenskym @penguinwu @EikanWang @jgong5 @Guobing-Chen @XiaobingSuper @zhuhaozhe @blzheng @wenzhe-nrv @jiayisunx @peterbell10 @ipiszy @yf225 @chenyang78 @kadeng @muchulee8 @aakhundov @ColinPeppler @mlazos @soumith @yanboliang @anijain2305 @chunyuan-w @Xia-Weiwen @desertfire
Repository: godot
Issue: PWA ERR_FAILED on refresh
Labels: platform:web,topic:porting,needs testing

### Godot version

3.5.1 stable

### System information

Androids and W10

### Issue description

I think that the culprit may be on the Cloudflare Pages, but i may only be pointing finger cus the "Workers" tag is a common theme.

Well, when exporting HTML5 with PWA enabled, i can install it on Android phones, and W10 machines.

But, when trying to acess the app, for the second, something third or forth time, i get the unescapable error, that only recovers after i purge the cache of the app.
![image](https://user-images.githubusercontent.com/32851924/204909205-5bf659db-8ec7-4360-82b6-870f998820e2.png)


Thats on windows, but on android phones it happens the same error, and when tring to load from browser it happens as well sometimes.(if the PWA is already installed)


There are several factors:
Overall, this is a know bug, from 2019, but it seens to be fixed in the atual webview implementation of chromium.

There is the fact that the PWA architecture of godot was recently modified to adequate to some more networky sane behaviour.

There is even the Cloudflare Pages, that i am using to host the export, that, -Maybe- is causing the conflict.


Thanks for any insights.




### Steps to reproduce

I think this is reproductible in a whole manner if someone using G3.5.1S exports a HTML5 page with PWA and host it on Cloudflare Pages, and set a custom domain. Thas my setup that is generating the error.

### Minimal reproduction project

N/A
Repository: flutter
Issue: [web] Add MacOS and Linux support for running Edge Flutter Engine tests
Labels: a: tests,engine,platform-web,browser: edge,P2,team-web,triaged-web,e: engine-tool

We can run Flutter Engine tests using Microsoft Edge via `felt test --browser=edge`, however only Windows is a supported platform for running these tests.  We should consider supporting MacOS and Linux as well.

## Steps to Reproduce

1. Execute `felt test --browser=edge` on a Mac machine.

**Expected results:** For tests to run using Edge as a browser

**Actual results:** Tests don't run, following error is received: `Tests for Edge on macos is not supported`

Relevant files:
- https://github.com/flutter/engine/blob/main/lib/web_ui/dev/edge.dart
- https://github.com/flutter/engine/blob/main/lib/web_ui/dev/edge_installation.dart
Repository: flutter
Issue: Support iOS style swipable table cells
Labels: c: new feature,framework,a: fidelity,f: cupertino,f: gestures,customer: chalk (g3),team-design,triaged-design

Given that table / list item swipe is a common part of the iOS design language

![Transition-Reveal](https://user-images.githubusercontent.com/156888/204916281-7277e22a-7223-4ea6-8875-2c2b6e910ea8.gif)

and also part of the standard UIKit APIs through https://developer.apple.com/documentation/uikit/uiswipeactionsconfiguration and https://developer.apple.com/documentation/uikit/uicontextualaction, we should support them in Cupertino. 

We should also be consistent about affordance of these Cupertino functionalities. Either all Cupertino widgets are in individual Flutter Favorite packages or all Cupertino widgets (part of the UIKit API) are in the Cupertino package itself.
Repository: flutter
Issue: Deprecate child property in CupertinoContextMenu
Labels: framework,f: cupertino,a: quality,c: tech-debt,team-design,triaged-design

With the move to supporting a builder property on CupertinoContextMenu, there's an opportunity to move all of the default animation properties to one builder, and remove the need to internally reference the child property. A way to gracefully handle previewBuilder will need to be figured out however.