sharjeelyunus/github-issues-dataset huggingface dataset:
Repository: flutter
Issue: [proposal][in_app_purchase_android] return billing response code in queryProductDetails
Labels: c: new feature,platform-android,p: in_app_purchase,package,c: proposal,P2,team-android,triaged-android

### Is there an existing issue for this?

- [X] I have searched the [existing issues](https://github.com/flutter/flutter/issues)
- [X] I have read the [guide to filing a bug](https://flutter.dev/docs/resources/bug-reports)

### Use case

Upon examining the implementation of the queryProductDetails method in in_app_purchase_android_platform, it was found that there is no judgment for ProductDetailsResponseWrapper.billingResult.getResponseCode() without throwing an exception. It is recommended that when billingResult.getResponseCode() != BillingResponse.ok, the error message should be carried in the ProductDetailsResponse.error field.

### Proposal

    for (final ProductDetailsResponseWrapper response in productResponses) {
      if (response.billingResult.responseCode != BillingResponse.ok) {
        // set error
      }
    }
Repository: flutter
Issue: Performance profiling support for web
Labels: c: new feature,c: performance,platform-web,c: proposal,P3,customer: dent,team-tool,triaged-tool

### Is there an existing issue for this?

- [X] I have searched the [existing issues](https://github.com/flutter/flutter/issues)
- [X] I have read the [guide to filing a bug](https://flutter.dev/docs/resources/bug-reports)

### Use case

We are primarily targeting the web platform with Flutter. While other platforms benefit from the very helpful [Performance View](https://docs.flutter.dev/tools/devtools/performance), it states that developers targeting web should be happy with the Chrome dev tools (and stops there).

The Chrome dev tools will not give you any insights specific to Flutter, or at least not without manual digging. This includes many things listed in the docs for the Performance View, like quickly seeing the most problematic phase (Build/Layout/Raster) and finding out what widget is (most) responsible for it. It's all just "Scripting".

Flutter web typically performs less than native apps. I would say that makes good performance analysis tools _more_ important than for native platforms.

### Proposal

Can we make performance analysis for web easier? Ideally, the same tools you have for native apps are made available. Failing that, we need guidance on how to use the Chrome dev tools to achieve the same.
Repository: stable-diffusion-webui
Issue: [Feature Request]: Accurate Image Restoration with Attention Retractable Transformer
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 ?

Paper: https://arxiv.org/abs/2210.01427
Official implementation: https://github.com/gladzhang/ART
Proposal: Adapt dense and sparse attention on U-Net backbone for Stable Diffusion

What's the context? Self-Attention and Cross-Attention Layer are commonly used in backbone architecture for Diffusion Model. The aforementioned paper used ViT which **combined dense and sparse attention to allow global and local interactions while being tractable**. One reason is because the proposed sparse attention can allow token interactions in sparse image regions and thus enlarge the receptive field of the module. 

This paper was published in Oct 2022 but still beat one of the latest DM (published in June 2023) by a small margin for x4 Super Resolution task on Urban100 testset: Check table 2 of this paper vs table 1 in https://arxiv.org/abs/2307.00781 

What's the caveat? 
1. Another latest DM published some mad result on x4 Super Resolution on a different dataset: CAVE instead of Urban100.
2. Token interaction is not what Attention Block doing in U-Net backbone

### Proposed workflow

1. Go to Attention Block within U-Net backbone
2. Replace the self-attention with the combine (dense and sparse attention) to your liking 
3. ????
4. Profit


### Additional information

_No response_
Repository: ant-design
Issue: 动态修改Select组件的options，选中后的值不会改变
Labels: Inactive,improvement

### Reproduction link

[![Edit on CodeSandbox](https://codesandbox.io/static/img/play-codesandbox.svg)](https://codesandbox.io/s/duo-xuan-antd-5-6-2-forked-ktglz7?file=/demo.tsx:281-288)

### Steps to reproduce

第一步：先默认选中案例里面的 a1；
第二步：文本框里面随便输入内容；
第三步：再次选中Select，可以看到options已经修改了，但是已选的值还是选中时候的值，没有更新成最新的。

### What is expected?

希望改变options，已选中的也跟着变

### What is actually happening?

暂时没有实现期望的效果

| Environment | Info |
| --- | --- |
| antd | 5.6.4 |
| React | react 18 |
| System | Windows 10 |
| Browser | Chrome 104.0.5112.102 |

---
//Url不能看的话可以用这段代码
import { useState } from "react";
import { Select, Space, Input } from "antd";
let options = [
  {
    label: "a1",
    value: "1"
  },
  {
    label: "a2",
    value: "2"
  },
  {
    label: "a3",
    value: "3"
  }
];
const App: React.FC = () => {
  const [op, setOp] = useState(options);
  const onClick = (key) => {
    let o = [...op];
    o[0].label = key.target.value;
    setOp(o);
  };
  return (
    <Space style={{ width: "100%" }} direction="vertical">
      <Input onChange={onClick} />
      <Select
        mode="multiple"
        allowClear
        style={{ width: "100%" }}
        placeholder="Please select"
        options={op}
      />
    </Space>
  );
};

export default App;

<!-- generated by ant-design-issue-helper. DO NOT REMOVE -->
Repository: TypeScript
Issue: getLeadingCommentRanges misses comment in call expression
Labels: Help Wanted,Possible Improvement

# Bug Report

`getLeadingCommentRanges` misses comments that are in front of arguments passed to a call expression.

Comments being missed is a known issue when comments are within a node between tokens not stored in the tree: https://github.com/Microsoft/TypeScript/wiki/FAQ#why-some-comments-are-not-preserved-in-emitted-javascript-even-when---removecomments-is-not-specified

However that is not the case here and in fact `tsc` will preserve that particular comment.

Note: here I refer to getLeadingCommentRanges but in reality the bug is present inside of iterateCommentRanges (what getLeadingCommentRanges uses under the hood)

### 🔎 Search Terms

* leading, trailing comment undefined
* getLeadingCommentRanges, getTrailingCommentRanges
* Call expression, function call, method call

### 🕗 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:
-->

- This is the behavior in every version I tried (`4.3.5` (the oldest version on ts-ast-viewer.com), `5.1.6`, `@next (5.2.0-dev.20230706)`)

### ⏯ Playground Link

https://ts-ast-viewer.com/#code/MYewdgziA2CmB00QHMAUB6AVAAgBa2iW03WwCIB3EAJ2gBMyBKIA

### 💻 Code

<!-- Please post the relevant code sample here as well. This code and the Playground code should be the same, do not use separate examples -->
```ts
console.log(/* hello */ "world")
```

Calling getLeadingCommentRanges on the string literal returns undefined.

### 🙁 Actual behavior

```
ts.getLeadingCommentRanges('console.log(/* hello */ "world")', 12)
```

returns `undefined`
<!-- What happened, and why it was wrong -->

### 🙂 Expected behavior

```
ts.getLeadingCommentRanges('console.log(/* hello */ "world")', 12)
```

returns `[ { kind: 3, start: 12, end: 23, hasTrailingNewLine: false } ]`

<!-- What you expected to happen instead, and why -->
Repository: flutter
Issue: Curvature wrong in CupertinoDatepicker
Labels: framework,f: date/time picker,a: fidelity,f: cupertino,has reproducible steps,P2,found in release: 3.10,team-design,triaged-design

### Is there an existing issue for this?

- [X] I have searched the [existing issues](https://github.com/flutter/flutter/issues)
- [X] I have read the [guide to filing a bug](https://flutter.dev/docs/resources/bug-reports)

### Steps to reproduce

Set dateOrder: DatePickerDateOrder.dmy, in CupertinoDatePicker Widget

```
import 'package:flutter/cupertino.dart';

SizedBox(
                height: 300,
                child: CupertinoDatePicker(
                  dateOrder: DatePickerDateOrder.dmy,
                  mode: CupertinoDatePickerMode.date,
                  initialDateTime: DateTime.now(),
                  onDateTimeChanged: (DateTime newDateTime) {
                    // Do something
                  },
                ),
              ),
```

### Expected results

Expected the curve to match with its position like this:


![IMG_3231](https://github.com/flutter/flutter/assets/92431441/1cda08fe-bc65-4d6e-b19e-4fb5664f0fc8)


### Actual results

Right now it curves as three seperate columns, instead of making the whole datepicker unit curve like one piece

<img width="318" alt="Screenshot 2023-07-07 at 14 02 06" src="https://github.com/flutter/flutter/assets/92431441/e221896d-a7b3-4c75-a4f1-670e53bbe69e">


### Code sample

<details><summary>Code sample</summary>

```dart
import 'package:flutter/material.dart';
import 'package:flutter/cupertino.dart';

void main() {
  runApp(const MyApp());
}

class MyApp extends StatelessWidget {
  const MyApp({super.key});

  @override
  Widget build(BuildContext context) {
    return MaterialApp(
      title: 'Flutter Demo',
      theme: ThemeData(
        colorScheme: ColorScheme.fromSeed(seedColor: Colors.deepPurple),
        useMaterial3: true,
      ),
      home: const MyHomePage(),
    );
  }
}

class MyHomePage extends StatefulWidget {
  const MyHomePage({super.key});

  @override
  State<MyHomePage> createState() => _MyHomePageState();
}

class _MyHomePageState extends State<MyHomePage> {
  @override
  Widget build(BuildContext context) {
    return Scaffold(
      appBar: AppBar(
        title: Text('Test'),
      ),
      body: SizedBox(
        height: 300,
        child: CupertinoDatePicker(
          dateOrder: DatePickerDateOrder.dmy,
          mode: CupertinoDatePickerMode.date,
          initialDateTime: DateTime.now(),
          onDateTimeChanged: (DateTime newDateTime) {
            // Do something
          },
        ),
      ),
    );
  }
}

```

</details>


### Screenshots or Video

<details>
<summary>Screenshots / Video demonstration</summary>

[Upload media here]

</details>


### Logs

<details><summary>Logs</summary>

```console
[Paste your logs here]
```

</details>


### Flutter Doctor output

<details><summary>Doctor output</summary>

```console
[Paste your output here]
```

</details>
Repository: ant-design
Issue: 可以提供功能类似 Angular 中的 FormGroup 的组件吗。
Labels: 💡 Feature Request,Inactive

### What problem does this feature solve?

1. 在描述嵌套的表单结构时，必须使用数组或者带点号的字符串赋值给 Form.Item 的 name 属性，如果属性较多就需要反复书写重复的 name 前缀，使用起来就不是很方便；
2. 将嵌套的表单结构抽象到子组件中时，必须传入 namePath  前缀（为了使 Form.Item 的校验生效，必须使用 name 属性），这种使用方式太过丑陋。目前也没有找到合适的替代方案。

例如现在有这样的数据结构

```json
{
  "a": {
    "prop": 1,
   },
 "b": {
    "prop": 1
   }
}
```

目前的用法：

```jsx
const ChildComponent = ({namePath}) =>  {
  return <Form.Item name={[...namePath, 'prop']}><Input/></Form.Item>
}

const ParentComponent  = ()=> {
  return <Form>
    <ChildComponent namePath={["a"]}/>
    <ChildComponent namePath={["b"]}/>
  </Form>
}
```

可否直接在父组件声明 Form.Group，子组件的 Form.Item 自动挂载到 Form.Group 的 name 下呢。例如这样：

```jsx
const ChildComponent = () =>  {
  return <Form.Item name={'prop'}><Input/></Form.Item>
}

const ParentComponent  = ()=> {
  return <Form>
      <Form.Group name="a">
         <ChildComponent />
      </Form.Group>
      <Form.Group name="b">
         <ChildComponent />
      </Form.Group>
  </Form>
}
```

### What does the proposed API look like?

期望的 API：
```jsx
<Form.Group name="info">
  <Form.Item name="name">
  </Form.Item>
  <Form.Item name="age">
  </Form.Item>
</Form.Group>
```
如上的代码等同于下面的代码片段：

```jsx
<Form.Item name={["info", "name"]}>
  </Form.Item>
  <Form.Item name={["info", "age"]}>
</Form.Item>
```

可以看到这样的 API 也能使表单 DOM 节点的结构与表单模型的数据结构保持一致，使表单书写和维护起来更加清晰。
<!-- generated by ant-design-issue-helper. DO NOT REMOVE -->
Repository: tensorflow
Issue: Tensorflow profiler is not showing anything. Gives "No profile data was found" text on selecting Profile in Tensorboard
Labels: stat:awaiting tensorflower,type:bug,comp:apis,TF 2.13

### Issue type

Bug

### Have you reproduced the bug with TensorFlow Nightly?

Yes

### Source

source

### TensorFlow version

tf 2.12, tf 2.13, tf-nightly

### Custom code

No

### OS platform and distribution

_No response_

### Mobile device

_No response_

### Python version

_No response_

### Bazel version

_No response_

### GCC/compiler version

_No response_

### CUDA/cuDNN version

_No response_

### GPU model and memory

_No response_

### Current behavior?

I was learning how to use TensorFlow Profiler according to the [guide](https://www.tensorflow.org/tensorboard/tensorboard_profiling_keras). I ran the same notebook without altering anything in Google Colab and it does now show Profile tab. Moreover on selecting the Profile option from the right hand side drop down list, It shows 

```
No profile data was found.
If you have a model running on CPU, GPU, or Google Cloud TPU, you may be able to use the above button to capture a profile.

If you're a CPU or GPU user, please use the IP address option. You may want to check out the [tutorial](https://colab.research.google.com/github/tensorflow/tensorboard/blob/master/docs/tensorboard_profiling_keras.ipynb) on how to start a TensorFlow profiler server and profile a Keras model on a GPU.

If you're a TPU user, please use the TPU name option and you may want to check out the [tutorial](https://cloud.google.com/tpu/docs/cloud-tpu-tools) on how to interpreting the profiling results.

If you think profiling is done properly, please see the page of [Google Cloud TPU Troubleshooting and FAQ](https://cloud.google.com/tpu/docs/troubleshooting) and consider filing an issue on GitHub.

```

Instead it should have shown the Profile

### Standalone code to reproduce the issue

```shell
Kindly use the official [tensorflow profiler guide](https://www.tensorflow.org/tensorboard/tensorboard_profiling_keras)
```


### Relevant log output

```shell
No profile data was found.
If you have a model running on CPU, GPU, or Google Cloud TPU, you may be able to use the above button to capture a profile.

If you're a CPU or GPU user, please use the IP address option. You may want to check out the [tutorial](https://colab.research.google.com/github/tensorflow/tensorboard/blob/master/docs/tensorboard_profiling_keras.ipynb) on how to start a TensorFlow profiler server and profile a Keras model on a GPU.

If you're a TPU user, please use the TPU name option and you may want to check out the [tutorial](https://cloud.google.com/tpu/docs/cloud-tpu-tools) on how to interpreting the profiling results.

If you think profiling is done properly, please see the page of [Google Cloud TPU Troubleshooting and FAQ](https://cloud.google.com/tpu/docs/troubleshooting) and consider filing an issue on GitHub.

```
```
Repository: transformers
Issue: Initialize Flax model params on CPU 
Labels: Good Second Issue,Flax

### Feature request

Currently, the `from_pretrained` method of Flax models automatically puts model parameters on a single GPU device, if available. For very large models, this is not great, as the model parameters may just not fit on GPU memory. 

In contrast, when passing `_do_init=False` to `from_pretrained`, the parameters are returned on CPU, outside the model.

I would love to have a feature that allows me to initialize model parameters on the device I want - in this case, on CPU - but at the same time initialize the model parameters within the model. Right now I have to call `_do_init=False` to avoid out-of-memory, but this causes inconsistencies with my API.

The feature could be either implemented as just another type (if we detect a numpy type, we initialize on CPU; otherwise on GPU) or as an additional argument, e.g. `initialize_on_cpu: bool = False`.

### Motivation

Described above. Another reason is to be more consistent with the PyTorch behaviour, where parameters are initialized (as a generator) on CPU.

### Your contribution

If we agree on on the design, I am happy to add this myself.
Repository: TypeScript
Issue: Apply recursive mapped type to nested literal object types 
Labels: Help Wanted,Possible Improvement

# Suggestion

## 🔍 Search Terms

- alias
- recursive mapped type
- resolve mapped type

## ✅ Viability Checklist

My suggestion meets these guidelines:

* [x] This wouldn't be a breaking change in existing TypeScript/JavaScript code
* [x] This wouldn't change the runtime behavior of existing JavaScript code
* [x] This could be implemented without emitting different JS based on the types of the expressions
* [x] This isn't a runtime feature (e.g. library functionality, non-ECMAScript syntax with JavaScript output, new syntax sugar for JS, etc.)
* [x] This feature would agree with the rest of [TypeScript's Design Goals](https://github.com/Microsoft/TypeScript/wiki/TypeScript-Design-Goals).

## ⭐ Suggestion

Given the following code:

```ts
type DeepReadonly<T> = {
  readonly [K in keyof T]: DeepReadonly<T[K]>;
}

type A = {
  num: number
  array: A[]
  object: {
    inner: A
  }
}

type B = DeepReadonly<A>
```

If I request the shape of B to the LSP, I get the following shape:

```ts
{
  readonly num: number
  readonly array: readonly DeepReadonly<A>[]
  readonly object: DeepReadonly<{
    inner: number
  }>
}
```

I suggest applying any mapped type to nested literal object types to get the following shape instead:

```ts
{
  readonly num: number
  readonly array: readonly DeepReadonly<A>[]
  readonly object: {
    readonly inner: number
  }
}
```

This greatly improve readability and this is consistent with other non-named types: `DeepReadonly<number>` -> `number`, `DeepReadonly<A[]>` -> `readonly DeepReadonly<A>[]`, ...
Repository: next.js
Issue: %40 for escaping @ in route name doesn't work in the app router
Labels: linear: next

### Verify canary release

- [X] I verified that the issue exists in the latest Next.js canary release

### Provide environment information

```bash
Operating System:
      Platform: darwin
      Arch: arm64
      Version: Darwin Kernel Version 22.5.0: Thu Jun  8 22:21:34 PDT 2023; root:xnu-8796.121.3~7/RELEASE_ARM64_T8112
    Binaries:
      Node: 20.3.1
      npm: 9.6.7
      Yarn: 1.22.19
      pnpm: 8.6.5
    Relevant Packages:
      next: 13.4.10-canary.0
      eslint-config-next: N/A
      react: 18.2.0
      react-dom: 18.2.0
      typescript: 5.1.6
    Next.js Config:
      output: N/A
```


### Which area(s) of Next.js are affected? (leave empty if unsure)

App Router

### Link to the code that reproduces this issue or a replay of the bug

N/A

### To Reproduce

Couldn't find a similar issue, but I feel like this problem should've already been reported somewhere. If you find an issue of which this issue is a duplicate, do tell.

I want to add `/@test` to my website. But `@` is already taken by parallel routing, so I need to find a way to escape it. Attempts (all are in dev mode):

1. `app/@test/page.tsx` → not working, for obvious reasons

2. `app/%40test/page.tsx`

    I tried to escape `@` using URL encoding (similar to the `_` case), but this doesn't work either. `/%40test` does work, but `/@test` doesn't.

3. `app/[dynamic]/page.tsx` with `generateStaticParams` to `{ dynamic: "@test" }` and `dynamicParams = false`

    This works, but why do I need to do so much just to get `/@test`?

4. `app/some/route/page.tsx` then rewrite `/@test` to it

    This works, but again, this is too much work.

[Related question in the Next.js Discord server](https://nextjs-forum.com/post/1126818180279578714).

### Describe the Bug

Too much effort is needed for something as trivial as adding a route with `@` in the path.

### Expected Behavior

(2) above should work.

### Which browser are you using? (if relevant)

_No response_

### How are you deploying your application? (if relevant)

In this issue, only `next dev`. I didn't try prod mode.

<sub>[DX-1763](https://linear.app/vercel/issue/DX-1763/it-is-apparently-impossible-to-create-a-route-in-the-app-router-with)</sub>
Repository: PowerToys
Issue: Bug with Keyboard Manager and Remote Desktop
Labels: Issue-Bug,Product-Keyboard Shortcut Manager,Needs-Triage

### Microsoft PowerToys version

0.71.0

### Installation method

GitHub

### Running as admin

Yes

### Area(s) with issue?

Keyboard Manager

### Steps to reproduce

Local Machine
- Windows 10 Pro - 22H2
- PowerToys 0.71.0

Remote Machine (not virtual)
- Windows 10 Pro - 22H2
- PowerToys 0.71.0

Steps to Reproduce:
- Install PowerToys on local and remote machines and execute it with admin rights and autostartup;
- Deactive everything else, only active Keyboard Manager;
- Configure Remap as following:
  - Caps Lock to Ctrl (Left);
  - Ctrl (Left) to Caps Lock;
- Access the remote desktop with Remote Desktop Connection;
- Open a notepad on remote desktop;
- Copy any text on local machine and try to paste it inside a notepad on remote desktop;

### ✔️ Expected Behavior

- "**PowerToys 0.71.0**" copied to clipboard (Caps Lock + c) on local machine;
- "**PowerToys 0.71.0**" pasted from clipboard (Caps Lock + v) to Notepad on remote machine;

### ❌ Actual Behavior

- "**PowerToys 0.71.0**" copied to clipboard (Caps Lock + c) on local machine;
- "**VVvVVvvVVVvVVVvVvVvVVvvVvVVvVvVvvvVVvVvVvVvVVVVvvVvvvVvVvvvVVvvVvVvvVvVvVvVvVvvPowerToys 0.71.0PowerToys 0.71.0PowerToys 0.71.0VVVvVvVvvVVVvvvv**" pasted from clipboard (Caps Lock + v) to Notepad on remote machine;
  - this after Caps Lock + v pressed several times;

Aditional note:
- deactivating Keyboard Manager on local machine makes Caps Lock+v works properly on remote desktop;

### Other Software

My Remote Desktop Connections settings:
- screen mode id:i:1
- use multimon:i:0
- desktopwidth:i:2560
- desktopheight:i:1025
- session bpp:i:32
- winposstr:s:0,1,-2560,-393,0,657
- compression:i:1
- keyboardhook:i:1
- audiocapturemode:i:0
- videoplaybackmode:i:1
- connection type:i:7
- networkautodetect:i:1
- bandwidthautodetect:i:1
- displayconnectionbar:i:1
- enableworkspacereconnect:i:0
- disable wallpaper:i:0
- allow font smoothing:i:0
- allow desktop composition:i:0
- disable full window drag:i:1
- disable menu anims:i:1
- disable themes:i:0
- disable cursor setting:i:0
- bitmapcachepersistenable:i:1
- full address:s:<ipv4 address>
- audiomode:i:0
- redirectprinters:i:1
- redirectcomports:i:0
- redirectsmartcards:i:1
- redirectclipboard:i:1
- redirectposdevices:i:0
- autoreconnection enabled:i:1
- authentication level:i:2
- prompt for credentials:i:0
- negotiate security layer:i:1
- remoteapplicationmode:i:0
- alternate shell:s:
- shell working directory:s:
- gatewayhostname:s:
- gatewayusagemethod:i:4
- gatewaycredentialssource:i:4
- gatewayprofileusagemethod:i:0
- promptcredentialonce:i:0
- gatewaybrokeringtype:i:0
- use redirection server name:i:0
- rdgiskdcproxy:i:0
- kdcproxyname:s:
- smart sizing:i:1
- drivestoredirect:s: