sharjeelyunus/github-issues-dataset huggingface dataset:
Repository: pytorch
Issue: Checkpointing Support for Modularized Optimizers
Labels: module: optimizer,triaged,needs design

### 🚀 The feature, motivation and pitch

Hi, I'm currently working on an implementation of distributed Shampoo in PyTorch (https://github.com/facebookresearch/optimizers/tree/main/distributed_shampoo). Because of the complexity of the optimizer, it is necessary to modularize the optimizer by creating additional classes that may also contain Tensor objects (i.e., Preconditioner objects). However, `torch.optim.Optimizer`'s checkpointing functionality (`state_dict` / `load_state_dict`) does not natively support this kind of modularization, which requires us to override the `load_state_dict` function to support other custom classes. This is in order to ensure that the tensors contained within these custom state objects are appropriately moved by the `cast` function after loading from checkpoint.

Rather than requiring the user to override and support this additional checkpointing functionality, would it be possible to create an `OptimizerModule` (similar to `nn.Module`) that contains a `load_state_dict` that recursively calls this function within other `OptimizerModule` objects and is compatible with `torch.optim.Optimizer`? Developers can then build their new classes on top of this `OptimizerModule` to ensure that the cast automatically supports new classes.

Thanks in advance!

CC'ing collaborators and TorchRec folks since we are also interested in making distributed Shampoo also compatible with TorchRec's `KeyedOptimizer`.

cc: @tsunghsienlee, @dmudiger, @mikerabbat, @YLGH, @albanD

### Alternatives

In order to currently support checkpointing for Shampoo, we created `.to` functions for all custom classes in our optimizer that enable us to move all Tensor objects within all of our custom classes to a different device. We then modified the `cast` function within `torch.optim.optimizer`'s `load_state_dict` function by including an additional case for our `Preconditioner` class. While this works, it is not ideal since it requires us to maintain the `.to` functions for each class or (non-Iterable or dict) data structure we create, which can be bug-prone. 

### Additional context

Related to this issue on Distributed Shampoo: https://github.com/facebookresearch/optimizers/issues/3.

cc @vincentqb @jbschlosser @albanD @janeyx99 @crcrpar
Repository: node
Issue: Support file globs with `--watch-path`
Labels: feature request,never-stale,watch-mode

### What is the problem this feature will solve?

The new experimental watch feature is awesome, but sometimes apps depend on non-imported files or data. For example, if your app has a set of templates that are read/cached at server start, updating an HTML file won't restart the process.

### What is the feature you are proposing to solve the problem?

It would be extremely useful to provide an optional list of file globs that would also trigger a process restart.  For example:

```bash
# current
$ node --watch app.mjs

# proposed
$ node --watch app.mjs views/*.html
```

Note: this syntax is just to illustrate the idea.

### What alternatives have you considered?

Some template engines/libraries have caching logic built in so it's disabled during local development, but supporting this in a more generic way would open up a lot of additional use cases without having to explicitly code against `NODE_ENV` or enabling/disabling caching.  Since the watch feature already seems to do exactly what would be needed to make this work, it would simply have to accept an optional glob or list of globs to also watch along with any imports.
Repository: PowerToys
Issue: Win+ESC not being allowed for Settings keystroke picker
Labels: Issue-Bug,FancyZones-Hotkeys,Area-User Interface,Priority-2

        Win+ESC is one shortcut that worked in a previous release but stopped working quite some time ago.

_Originally posted by @skst in https://github.com/microsoft/PowerToys/issues/6812#issuecomment-1287428325_

I can validate this on 0.63
Repository: stable-diffusion-webui
Issue: [Feature Request]: add image to webui after each batch_count
Labels: enhancement

Right now it waits until batch_counts are completed until it populates the images on the WebUI. 

add the images when each batch completes, so you could see the generated images while the rest of the batch is working?
Repository: rust
Issue: bootstrap: Document that setting `description` changes the version hash
Labels: T-bootstrap,A-docs

If I change `description = ` in `config.toml`, the Crate IDs change, which leads to different name mangling. In particular this means it's not possible to use PGO profiles produced by a compiler with one description to build a compiler with a different description. Is this intentional?

I'm not sure if v0 mangling actually has anything to do with this, but that's where it was convenient for me to insert the code to print IDs. 

To see this, apply this patch:
```
From 705dac4190d0e1c67a848b5af4ba6fc51e3aaa56 Mon Sep 17 00:00:00 2001
From: Michael Benfield <mbenfield@google.com>
Date: Wed, 26 Oct 2022 01:11:29 +0000
Subject: [PATCH] print

---
 compiler/rustc_symbol_mangling/src/v0.rs | 3 +++
 1 file changed, 3 insertions(+)

diff --git a/compiler/rustc_symbol_mangling/src/v0.rs b/compiler/rustc_symbol_mangling/src/v0.rs
index ecfe6861e84..ee21131970f 100644
--- a/compiler/rustc_symbol_mangling/src/v0.rs
+++ b/compiler/rustc_symbol_mangling/src/v0.rs
@@ -739,6 +739,9 @@ fn path_crate(self, cnum: CrateNum) -> Result<Self::Path, Self::Error> {
         let stable_crate_id = self.tcx.def_path_hash(cnum.as_def_id()).stable_crate_id();
         self.push_disambiguator(stable_crate_id.to_u64());
         let name = self.tcx.crate_name(cnum);
+        if name.as_str().contains("rustc_serialize") {
+            println!("XXX {} : {:X}", name.as_str(), stable_crate_id.to_u64());
+        }
         self.push_ident(name.as_str());
         Ok(self)
     }
-- 
```

and make these two files:

```
% cat configA.toml 
[rust]
description = "A"
new-symbol-mangling = true
~/Code/rust3  [ mbenfield ]
% cat configB.toml 
[rust]
description = "B"
new-symbol-mangling = true
```

then do 
```
./x.py build --stage 2 --config configA.toml | grep XXX
```
and
```
./x.py build --stage 2 --config configB.toml | grep XXX
```

and you'll get different outputs.
Repository: TypeScript
Issue: TSDoc `@typeParam` is not supported in VSCode/TSDoc playground while `@template` works
Labels: Suggestion,Awaiting More Feedback

# Bug Report

<!--
  Please fill in each section completely. Thank you!
-->

### 🔎 Search Terms

<!--
  What search terms did you use when trying to find an existing bug report?
  List them here so people in the future can find this one more easily.
-->

TSDoc @typeParam Vscode

### 🕗 Version & Regression Information

<!-- When did you start seeing this bug occur?

"Bugs" that have existed in TS for a long time are very likely to be FAQs; refer to
  https://github.com/Microsoft/TypeScript/wiki/FAQ#common-bugs-that-arent-bugs

If possible, please try testing the nightly version of TS to see if it's already been fixed.
For npm: `typescript@next`
This is also the 'Nightly' version in the playground: http://www.typescriptlang.org/play/?ts=Nightly

Note: The TypeScript Playground can be used to try older versions of TypeScript.

Please keep and fill in the line that best applies:
-->

### ⏯ Playground Link

<!--
  A link to a TypeScript Playground "Share" link which shows this behavior

  The TypeScript Workbench can be used for more complex setups, try
  https://www.typescriptlang.org/dev/bug-workbench/

  As a last resort, you can link to a repo, but these will be slower for us to investigate.
-->

https://tsdoc.org/play

TSDoc does not support share code links.

### 💻 Code

<!-- Please post the relevant code sample here as well-->
```ts
/**
 * @typeParam T - Description
 * @template U Description
 */
interface Foo<T, U> {
  bar: T;
  baz: U;
}
```



### 🙁 Actual behavior

<!-- What happened, and why it was wrong -->

![image](https://user-images.githubusercontent.com/29478770/197913483-22652ee8-25e2-46a9-8f0b-1826bcd13c0e.png)
![image](https://user-images.githubusercontent.com/29478770/197913504-c618174e-a717-4b52-b758-e089ff342f7a.png)


### 🙂 Expected behavior

<!-- What you expected to happen instead, and why -->

Both should work.
Repository: stable-diffusion-webui
Issue: [Feature Request]: Add waifu2x as upscaler?
Labels: enhancement,extension-request

### Is there an existing issue for this?

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

### What would your feature do ?

ability to choose waifu2x upscaler in extra

### Proposed workflow

1. Go to extra 
2. choose waifu2x upscaler, set parameters
3. profits(?


### Additional information

_No response_
Repository: terminal
Issue: Simplified Chinese translation recommendation of Settings UI
Labels: Issue-Bug,Product-Terminal,Tracking-External,Area-Localization

|                   Key                    |                    Recommendation                     |                           Comment                            |
| :--------------------------------------: | :---------------------------------------------------: | :----------------------------------------------------------: |
| Actions_DeleteConfirmationButton.Content |                   是，删除此快捷键                    | The current translation "密钥" means an encryption key, should use "快捷键" instead. |
|  Actions_DeleteConfirmationMessage.Text  |                 确定要删除此快捷键吗                  |                        Same as above.                        |
|     Globals_DefaultProfile.HelpText      | 单击 '+' 图标或按下新建选项卡快捷键时打开的配置文件。 | Same as above. And the "新的" is an adjective, should use "新建" instead. Using "按下" instead of "键入" is more typical. |
Repository: rust
Issue: Check for validity of next few tokens before suggesting adding missing `in` in for loop
Labels: A-diagnostics,T-compiler,D-confusing,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: [link](https://play.rust-lang.org/?version=nightly&mode=debug&edition=2021&gist=f18a8693aefa1e56d820fd2f1e51cfa4)

```rust
fn main() {
    for i i in 0..10 {

    }
}
```

The current output is:

```
   Compiling playground v0.0.1 (/playground)
error: missing `in` in `for` loop
 --> src/main.rs:2:10
  |
2 |     for i i in 0..10 {
  |          ^ help: try adding `in` here

error: expected `{`, found keyword `in`
 --> src/main.rs:2:13
  |
2 |     for i i in 0..10 {
  |             ^^ expected `{`

error: could not compile `playground` due to 2 previous errors
```

<!-- The following is not always necessary. -->
Ideally the compiler should check the validity of next few tokens in the source code before emitting an error of ( missing `in` in `for` loop ). If wanted we can even suggest adding a `_` to delimit the identifier, though if might not be worth the effort. Thanks.

@rustbot label +D-invalid-suggestion +D-confusing

<!--
If the problem is not self-explanatory, please provide a rationale for the
change.
-->

<!--
If dramatically different output is caused by small changes, consider also
adding them here.

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. The output might also be
different depending on the Edition.
-->
Repository: vscode
Issue: "Replace (Enter)" button breaks
Labels: bug,editor-find

Type: <b>Bug</b>

"editor.find.cursorMoveOnType": false breaks the behaviour of the "Replace (Enter)" button (or pressing Enter in the Replace field). It now has to be clicked/"entered" twice before a replace is made. The first input merely performs a Next Match.

All I wanted to do is prevent this program from automatically leaving the view while I'm typing in the search field. :(

VS Code version: Code 1.72.2 (d045a5eda657f4d7b676dedbfa7aab8207f8a075, 2022-10-12T22:15:18.074Z)
OS version: Windows_NT x64 10.0.19044
Modes:
Sandboxed: No

<details>
<summary>System Info</summary>

|Item|Value|
|---|---|
|CPUs|Intel(R) Core(TM) i5-8365U CPU @ 1.60GHz (8 x 1896)|
|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: enabled_on<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)|undefined|
|Memory (System)|15.81GB (8.38GB free)|
|Process Argv|--disable-gpu --enable-use-zoom-for-dsf --crash-reporter-id 05c61087-ca98-4d16-9b3c-01f4053cbdb7|
|Screen Reader|no|
|VM|0%|
</details><details><summary>Extensions (8)</summary>

Extension|Author (truncated)|Version
---|---|---
vscode-docker|ms-|1.22.2
python|ms-|2022.16.1
vscode-pylance|ms-|2022.10.30
jupyter|ms-|2022.9.1202862440
jupyter-keymap|ms-|1.0.0
jupyter-renderers|ms-|1.0.10
vscode-jupyter-cell-tags|ms-|0.1.6
vscode-jupyter-slideshow|ms-|0.1.5


</details><details>
<summary>A/B Experiments</summary>

```
vsliv368:30146709
vsreu685:30147344
python383:30185418
vspor879:30202332
vspor708:30202333
vspor363:30204092
vswsl492:30256859
vslsvsres303:30308271
pythonvspyl392:30443607
vserr242:30382549
pythontb:30283811
vsjup518:30340749
pythonptprofiler:30281270
vshan820:30294714
vstes263cf:30335440
vscorecescf:30445987
pythondataviewer:30285071
vscod805cf:30301675
binariesv615:30325510
bridge0708:30335490
bridge0723:30353136
cmake_vspar411:30581797
vsaa593cf:30376535
pythonvs932:30410667
cppdebug:30492333
vsclangdc:30486549
c4g48928:30535728
dsvsc012:30540252
azure-dev_surveyone:30548225
pyindex848:30577860
nodejswelcome1:30587005
fc301958:30595537

```

</details>

<!-- generated by issue reporter -->
Repository: pytorch
Issue: Improvements to fuse optimization
Labels: oncall: quantization,low priority,triaged,module: fx

### 🚀 The feature, motivation and pitch

Some optimization packages call pytorch's fuse function to try optimization without knowing much about the model, notably ipex and packages which call ipex.
This operation relies on symbolic tracing, which fails frequently due to the limitations on conditional statements.

A possible improvement here is before tracing, filter the patterns by those that could work given the submodules, i.e. if there is no conv or batch norm, there is no reason to include the pattern. If there are none left after this step, just return the model.


### Alternatives

Alternatively or additionally, symbolic tracing (or its use in fuse) could be improved.
The points of failure in symbolic tracing are outlined in the ipex issue and are mainly:

* input checking on optional arguments, which could be resolved by allowing concrete_args in fuse
* dimension checks, which could be improved by allowing a proxy to have a dimension or even a shape (although this goes quite far, and I can see the potential for some strange bugs here)

### Additional context

[this issue](https://github.com/intel/intel-extension-for-pytorch/issues/250) contains some examples of typical failures.


cc @jerryzh168 @jianyuh @raghuramank100 @jamesr66a @vkuzo @jgong5 @Xia-Weiwen @leslie-fang-intel @ezyang @SherlockNoMad @EikanWang @wenzhe-nrv @vincentqb @jbschlosser @soumith
Repository: stable-diffusion-webui
Issue: [Feature Request]: Script reload button beside every script selection
Labels: enhancement

### Is there an existing issue for this?

- [X] I have searched the existing issues and checked the recent builds/commits

### What would your feature do ?

I tried moving the script reload from settings to img2img but I failed. I am not an experienced coder and dont have the time to look further into it.

It would be very nice if the "script reload button" could be placed directly next to the script selection, so reloading is very fast. It doesnt take up much space.

Or can someone tell me how I can make it work? Just copying the gradio button into the img2img area in ui.py, and clicking Reload in the UI doesnt have an effect

### Proposed workflow

Just a small UI change

### Additional information

_No response_
Repository: vscode
Issue: browser password auto complete function working unexpectedly on Quick Pick Input
Labels: bug,help wanted,quick-pick,upstream-issue-pending

<!-- ⚠️⚠️ Do Not Delete This! bug_report_template ⚠️⚠️ -->
<!-- Please read our Rules of Conduct: https://opensource.microsoft.com/codeofconduct/ -->
<!-- 🕮 Read our guide about submitting issues: https://github.com/microsoft/vscode/wiki/Submitting-Bugs-and-Suggestions -->
<!-- 🔎 Search existing issues to avoid creating duplicates. -->
<!-- 🧪 Test using the latest Insiders build to see if your issue has already been fixed: https://code.visualstudio.com/insiders/ -->
<!-- 💡 Instead of creating your report here, use 'Report Issue' from the 'Help' menu in VS Code to pre-fill useful information. -->
<!-- 🔧 Launch with `code --disable-extensions` to check. -->
Does this issue occur when all extensions are disabled?: Yes/No

<!-- 🪓 If you answered No above, use 'Help: Start Extension Bisect' from Command Palette to try to identify the cause. -->
<!-- 📣 Issues caused by an extension need to be reported directly to the extension publisher. The 'Help > Report Issue' dialog can assist with this. -->
- VS Code Version: Remote Version(Code-Server, I tested with scripts/code-server.bat)
- OS Version: All versions

Steps to Reproduce:

1. Open a terminal and use git fetch with a http git url like (should need password authentication)
git clone https://xxxxx/test.git
2. Then vscode prompt input box on the top of window which help you input username and password, just input username and password as usual
![image](https://user-images.githubusercontent.com/85340915/202142648-a3ec46c4-48d4-4ae5-a8fc-dabb71109bb7.png)
![image](https://user-images.githubusercontent.com/85340915/202142788-73a750e4-f3c0-435a-8459-a1f59bd5232c.png)
3. Then sometimes chrome prompt this to let you save authentication info (or you can click the key icon on the right side of address bar), save the same username as you use on git
![image](https://user-images.githubusercontent.com/85340915/197969761-a7bd4021-887f-4928-8962-6e1a4e0bbd9d.png)
4.Then all input box on vscode window will prompt password autocomplete, even this input has nothing to do with password, like
![image](https://user-images.githubusercontent.com/85340915/197970588-c230dd4d-99d7-425f-996a-d4e495aedeb9.png)
![image](https://user-images.githubusercontent.com/85340915/197970688-b25a4fff-7132-42df-9962-38d7bbe79ea0.png)


Maybe this is an issue with chrome but would be appreciated if your team can give me some suggestions to deal with this. Thank you!
Repository: bitcoin
Issue: Stuck in Endless Pre-Syncing Headers Loop
Labels: Feature,Brainstorming,P2P

**Expected behavior**
Pre-Sync Headers Like Normal.

**Actual behavior**
```
2022-10-26T07:34:14Z Pre-synchronizing blockheaders, height: 748853 (~98.55%)
2022-10-26T07:34:16Z Pre-synchronizing blockheaders, height: 226853 (~31.00%)
```

Unaffected by restating program.

```
2022-10-26T07:34:14Z Pre-synchronizing blockheaders, height: 748853 (~98.55%)
2022-10-26T07:34:16Z Pre-synchronizing blockheaders, height: 226853 (~31.00%)
```

**To reproduce**

I think that this is a one-off sort of error:

Here is a backup of my .bitcoin folder.
https://drive.proton.me/urls/V04QAGG998#GlCnfHpkWW7F

~The files before `blk00047.dat` and `rev00047.dat` are omitted, and need to be copied in from another source.~
As sipa says, the blk files are not deterministic.  - Will upload the full .bitcoin folder so people can reproduce...

Here is the 4.6gb full backup of my .bitcoin folder:
https://drive.proton.me/urls/JA11NDEA14#GeG83qrpmvtt

**System information**

Fedora 37 Silverblue Running in Toolbox.

Bitcoin Core: 28cf75697186ea8e473e120a643994bdf8237d6c
Repository: create-react-app
Issue: this function that "loaderUtils.getHashDigest" might get a wrong hash value.
Labels: needs triage,issue: bug report

### description
计算出来的className包含“/”会导致样式无法正常加载
定位到特定参数下loaderUtils.getHashDigest计算的结果会包含“/”
<img width="257" alt="image" src="https://user-images.githubusercontent.com/33385963/197983074-2556bec2-0b08-48d7-b0a4-edc3468933d5.png">
<img width="575" alt="image" src="https://user-images.githubusercontent.com/33385963/197983259-039acb40-7995-4cd7-b60c-0f7d1d27fba2.png">
即使两个名称匹配，header标签也无法加载此样式
### Environment
react-dev-utils@12.0.1
Chrome 106.0.5249.119
### Expected behavior
计算出的className结果中过滤掉“/”

### Reproducible demo
const hash = loaderUtils.getHashDigest(
    "defaultUI/layouts/layout.lessstyle-header",
    'md5',
    'base64',
    5
  )
// hash === '/M5ZU'
// className === "'layout_style-header__/M5ZU'"
//
Repository: vscode
Issue: Uninstalling VS Code takes a long time, when enabling the Windows 11 context menu action
Labels: bug,help wanted,install-update,windows 11,system-context-menu

Testing #164465

When uninstalling VS Code with enabled Open menu entry the uninstaller seems to hang at the beginning and it takes quite some time until it finishes. I never experienced this when testing the final Windows bits during endgame.
Repository: vscode
Issue: Remove duplicate context menu entries
Labels: bug,help wanted,install-update,windows 11

Testing #164465

- VS Code User install
- I already installed VS Code with `Open With` but deinstalled as well.

<img width="981" alt="image" src="https://user-images.githubusercontent.com/1931590/197988642-9428e071-b8c9-48fe-bfdd-537c51666f2b.png">

After install

<img width="522" alt="image" src="https://user-images.githubusercontent.com/1931590/197988838-40e4a7a5-4257-4e89-9b6a-482ecb89dfb4.png">
Repository: node
Issue: crypto Cipher/Decipher validation issues
Labels: confirmed-bug,crypto

This also affects Decipher methods.

Here's an example:

```js
const { createCipheriv, randomBytes } = require('crypto');

const cipher = createCipheriv('aes-256-cbc', randomBytes(32), randomBytes(16));

cipher.update('test', 'utf-8', 'bad');
```

Gives an internal assertion:

```
Error [ERR_INTERNAL_ASSERTION]: Cannot change encoding
This is caused by either a bug in Node.js or incorrect usage of Node.js internals.
Please open an issue with this stack trace at https://github.com/nodejs/node/issues
```

`final` has the same issue:

```js
const { createCipheriv, randomBytes } = require('crypto');

const cipher = createCipheriv('aes-256-cbc', randomBytes(32), randomBytes(16));

cipher.update('test', 'utf-8', 'utf-8');
cipher.final('bad');
```

Other issue:

```js
const { createCipheriv, randomBytes } = require('crypto');

const cipher = createCipheriv('aes-256-cbc', randomBytes(32), randomBytes(16));

let result = cipher.update('test', 'bad', 'hex');
result += cipher.final('hex');
console.log(result);
```

Gives no error at all for the wrong input encoding.

@nodejs/crypto