sharjeelyunus/github-issues-dataset huggingface dataset:
Repository: storybook
Issue: [Bug]:  Error [ERR_REQUIRE_ESM]: require() of ES Module at @storybook/addon-docs
Labels: bug,addon: docs

### Describe the bug

We are trying to upgrade the internal usage of storybooks from v6 into v8 and we are now facing an issue that was introduced by https://github.com/storybookjs/storybook/pull/25615. 

We launch the storybook builds through a Node.js script that uses the `buildStandalone` function from `@storybook/react/standalone`. During the node resolution phase we got the following error:

```
Error [ERR_REQUIRE_ESM]: require() of ES Module /node_modules/rehype-external-links/index.js from /node_modules/@storybook/addon-docs/dist/preset.js not supported.
      Instead change the require of index.js in /node_modules/@storybook/addon-docs/dist/preset.js to a dynamic import() which is available in all CommonJS modules.
          at Object.newLoader [as .js] 
```

The cause seems to be related with the fact that the cjs build of `@storybook/addon-docs` is requiring an ESM module. It feels to me this PR should be reverted until a better alternative to replace those packages is found or the interop for esm and require is better supported on node (initial interop was released on node v22 but has limitations and it is still experimental).

\cc @JReinhold 

### Reproduction link

https://github.com/elastic/kibana/pull/195148

### Reproduction steps

1. Checkout the PR
2. `yarn kbn bootstrap` && `yarn storybook esql_editor`

### System

Storybook v8

### Additional context

_No response_
Repository: pytorch
Issue: DISABLED test_like_channels_last_cpu (__main__.CpuTritonTests)
Labels: triaged,module: flaky-tests,skipped,oncall: pt2,module: inductor

Platforms: inductor

This test was disabled because it is failing in CI. See [recent examples](https://hud.pytorch.org/flakytest?name=test_like_channels_last_cpu&suite=CpuTritonTests&limit=100) and the most recent trunk [workflow logs](https://github.com/pytorch/pytorch/runs/32192945395).

Over the past 3 hours, it has been determined flaky in 3 workflow(s) with 3 failures and 3 successes.

**Debugging instructions (after clicking on the recent samples link):**
DO NOT ASSUME THINGS ARE OKAY IF THE CI IS GREEN. We now shield flaky tests from developers so CI will thus be green but it will be harder to parse the logs.
To find relevant log snippets:
1. Click on the workflow logs linked above
2. Click on the Test step of the job so that it is expanded. Otherwise, the grepping will not work.
3. Grep for `test_like_channels_last_cpu`
4. There should be several instances run (as flaky tests are rerun in CI) from which you can study the logs.



<details><summary>Sample error message</summary>

```
Traceback (most recent call last):
  File "/var/lib/jenkins/workspace/test/inductor/test_torchinductor.py", line 280, in tearDown
    super().tearDown()
  File "/opt/conda/envs/py_3.12/lib/python3.12/site-packages/torch/_inductor/test_case.py", line 35, in tearDown
    self._inductor_test_stack.close()
  File "/opt/conda/envs/py_3.12/lib/python3.12/contextlib.py", line 618, in close
    self.__exit__(None, None, None)
  File "/opt/conda/envs/py_3.12/lib/python3.12/contextlib.py", line 610, in __exit__
    raise exc_details[1]
  File "/opt/conda/envs/py_3.12/lib/python3.12/contextlib.py", line 595, in __exit__
    if cb(*exc_details):
       ^^^^^^^^^^^^^^^^
  File "/opt/conda/envs/py_3.12/lib/python3.12/contextlib.py", line 144, in __exit__
    next(self.gen)
  File "/opt/conda/envs/py_3.12/lib/python3.12/site-packages/torch/_inductor/utils.py", line 840, in fresh_inductor_cache
    shutil.rmtree(inductor_cache_dir)
  File "/opt/conda/envs/py_3.12/lib/python3.12/shutil.py", line 759, in rmtree
    _rmtree_safe_fd(stack, onexc)
  File "/opt/conda/envs/py_3.12/lib/python3.12/shutil.py", line 703, in _rmtree_safe_fd
    onexc(func, path, err)
  File "/opt/conda/envs/py_3.12/lib/python3.12/shutil.py", line 662, in _rmtree_safe_fd
    os.rmdir(name, dir_fd=dirfd)
OSError: [Errno 39] Directory not empty: '/tmp/tmp2hw5svc6/triton/e2e6M7GExdkt3KOwV3ySCJv7sdokoqxC2TFBC2o6VOk'
```

</details>


Test file path: `inductor/test_triton_cpu_backend.py`

cc @clee2000 @wdvr @chauhang @penguinwu @voznesenskym @EikanWang @jgong5 @Guobing-Chen @XiaobingSuper @zhuhaozhe @blzheng @wenzhe-nrv @jiayisunx @ipiszy @yf225 @chenyang78 @kadeng @muchulee8 @ColinPeppler @amjames @desertfire @aakhundov @ezyang @gchanan @zou3519 @msaroufim
Repository: ollama
Issue: smollm got cuda error
Labels: bug

### What is the issue?

Run [smollm](https://ollama.com/library/smollm:135m) got cuda error

Step:
1. ollama run smollm:135m
2. Input any text

```
Error: an unknown error was encountered while running the model CUDA error: CUBLAS_STATUS_NOT_SUPPORTED
  current device: 0, in function ggml_cuda_mul_mat_batched_cublas at /go/src/github.com/ollama/ollama/llm/llama.cpp/ggml/src/ggml-cuda.cu:1896
  cublasGemmBatchedEx(ctx.cublas_handle(), CUBLAS_OP_T, CUBLAS_OP_N, ne01, ne11, ne10, alpha, (const void **) (ptrs_src.get() + 0*ne23), CUDA_R_16F, nb01/nb00, (const void **) (ptrs_src.get() + 1*ne23), CUDA_R_16F, nb11/nb10, beta, ( void **) (ptrs_dst.get() + 0*ne23), cu_data_type, ne01, ne23, cu_compute_type, CUBLAS_GEMM_DEFAULT_TENSOR_OP)
/go/src/github.com/ollama/ollama/llm/llama.cpp/ggml/src/ggml-cuda.cu:106: CUDA error
```

Screen shot:
![image](https://github.com/user-attachments/assets/40d5bacb-d6a3-4bf9-9799-16a6e2149ee7)

GPU:
nvidia RTX 3060ti
cuda version: 12.0

![image](https://github.com/user-attachments/assets/7e00958b-0a55-4ebf-a407-307e2b62a180)


### OS

WSL2

### GPU

Nvidia

### CPU

_No response_

### Ollama version

0.3.14
Repository: rust
Issue: Tracking issue for way to express intraprocedural finite state machines
Labels: T-lang,C-tracking-issue

This is a tracking issue for some form of:

- https://github.com/rust-lang/rfcs/pull/3720

The feature gate for the issue is TBD.

### About tracking issues

Tracking issues are used to record the overall progress of implementation.  They are also used as hubs connecting to other relevant issues, e.g., bugs or open design questions.  A tracking issue is however *not* meant for large scale discussion, questions, or bug reports about a feature.  Instead, open a dedicated issue for the specific matter and add the relevant feature gate label.

### Steps

- [ ] Approve as lang experiment.
- [ ] Accept an RFC.
  - https://github.com/rust-lang/rfcs/pull/3720
- [ ] Implement in nightly.
- [ ] Add documentation to the [dev guide][].
  - See the [instructions][doc-guide].
- [ ] Add documentation to the [reference][].
  - See the [instructions][reference-instructions].
- [ ] Add formatting for new syntax to the [style guide][].
  - See the [nightly style procedure][].
- [ ] Stabilize.
  - See the [instructions][stabilization-instructions].

[dev guide]: https://github.com/rust-lang/rustc-dev-guide
[doc-guide]: https://rustc-dev-guide.rust-lang.org/stabilization_guide.html#documentation-prs
[edition guide]: https://github.com/rust-lang/edition-guide
[nightly style procedure]: https://github.com/rust-lang/style-team/blob/master/nightly-style-procedure.md
[reference]: https://github.com/rust-lang/reference
[reference-instructions]: https://github.com/rust-lang/reference/blob/master/CONTRIBUTING.md
[stabilization-instructions]: https://rustc-dev-guide.rust-lang.org/stabilization_guide.html#stabilization-pr
[style guide]: https://github.com/rust-lang/rust/tree/master/src/doc/style-guide

### Unresolved Questions

TODO.

### Related

TODO.

cc @bjorn3 @folkertdev @rust-lang/lang
Repository: transformers
Issue: Expand AcceleratorConfig to accommodate other features such as NCCL timeout etc
Labels: Feature request

### Feature request

Expand `AcceleratorConfig` and corresponding transformers trainer args to allow transformer users to use full feature set of accelerate through the config arguments supported by `Accelerator()`. The args are being materialized here for use - https://github.com/huggingface/transformers/blob/a769ed45e17c44fd17b85c025863c4e4f2f73634/src/transformers/trainer.py#L5000


### Motivation

When using `HF/transformers` or `HF/trl SFTTrainer` with accelerate under the hood, its sad that only a limited set of arguments are exposed in `AcceleratorConfig` thereby not having control over using other features of the `Accelerator` such modifying the NCCL timeout. 

### Your contribution

I will be glad to raise a PR to expand AcceleratorConfig to enable wide array of arguments supported by `Accelerator`.
Repository: rust
Issue: compiletest: add a proper `supports-crate-type: xxx` directive 
Labels: C-enhancement,T-bootstrap,E-medium,A-compiletest

Apparently `needs-dynamic-linking` is not equivalent to checking if dylib or cdylib crate types are supported.

- In compiletest, `needs-dynamic-linking` performs a check based on target cfg's `dynamic_linking` field + `--print=cfg --target $TARGET`.
- However, target cfg has an additional field `only_cdylib` which, if `dynamic_linking` is `true`, indicates that only `cdylib` crate type is supported and not `dylib`. https://github.com/rust-lang/rust/blob/f2becdff0496003217e7fc6fbfcaf2640e162775/compiler/rustc_target/src/spec/mod.rs#L2148-L2153
    - This is the case for `wasm` base, dynamic linking is supported but not `dylib` crate type, only `cdylib` is supported. https://github.com/rust-lang/rust/blob/f2becdff0496003217e7fc6fbfcaf2640e162775/compiler/rustc_target/src/spec/base/wasm.rs#L58-L62

_Originally posted by @jieyouxu in https://github.com/rust-lang/rust/issues/130860#issuecomment-2376713633_
Repository: react
Issue: [DevTools Bug] Could not find commit data for root "1"
Labels: Type: Bug,Status: Unconfirmed,Component: Developer Tools

### Website or app

Shadow

### Repro steps

Steps:-

1.Rendering the FlatList with my below code - 
<FlatList
          data={numbersArray}
          keyExtractor={item => item.toString()}
          renderItem={({item}) => (
            <SquircleView
              style={{width: 300, height: 200}}
              squircleParams={{
                cornerSmoothing: 0.7,
                cornerRadius: 30,
                fillColor: 'green',
              }}
            />
          )}
        />  // data length is 1000
2. Start Scrolling Continuously in the flatlist, then this error happens
![Screenshot 2024-10-29 at 11 51 15 AM](https://github.com/user-attachments/assets/e835ad91-d8fa-4382-97aa-2c5eb4677e45)
![Screenshot 2024-10-29 at 11 51 15 AM](https://github.com/user-attachments/assets/b0cf7f5a-6342-4bc6-821e-bc11141ae069)


### How often does this bug happen?

Sometimes

### DevTools package (automated)

react-devtools-core

### DevTools version (automated)

6.0.1-c7c68ef842

### Error message (automated)

Could not find commit data for root "1"

### Error call stack (automated)

_No response_

### Error component stack (automated)

```text
at v_ (/Users/sunaina/.npm/_npx/8ea6ac5c50576a3b/node_modules/react-devtools-core/dist/standalone.js:2:1368389)
    at div (<anonymous>)
    at div (<anonymous>)
    at div (<anonymous>)
    at ts (/Users/sunaina/.npm/_npx/8ea6ac5c50576a3b/node_modules/react-devtools-core/dist/standalone.js:2:1157861)
    at /Users/sunaina/.npm/_npx/8ea6ac5c50576a3b/node_modules/react-devtools-core/dist/standalone.js:2:1376165
    at Ks (/Users/sunaina/.npm/_npx/8ea6ac5c50576a3b/node_modules/react-devtools-core/dist/standalone.js:2:1173575)
    at /Users/sunaina/.npm/_npx/8ea6ac5c50576a3b/node_modules/react-devtools-core/dist/standalone.js:2:1176231
    at div (<anonymous>)
    at div (<anonymous>)
    at div (<anonymous>)
    at Ys (/Users/sunaina/.npm/_npx/8ea6ac5c50576a3b/node_modules/react-devtools-core/dist/standalone.js:2:1176065)
    at Zc (/Users/sunaina/.npm/_npx/8ea6ac5c50576a3b/node_modules/react-devtools-core/dist/standalone.js:2:1247244)
    at Lc (/Users/sunaina/.npm/_npx/8ea6ac5c50576a3b/node_modules/react-devtools-core/dist/standalone.js:2:1239735)
    at xt (/Users/sunaina/.npm/_npx/8ea6ac5c50576a3b/node_modules/react-devtools-core/dist/standalone.js:2:1079120)
    at ca (/Users/sunaina/.npm/_npx/8ea6ac5c50576a3b/node_modules/react-devtools-core/dist/standalone.js:2:1106654)
    at Ec (/Users/sunaina/.npm/_npx/8ea6ac5c50576a3b/node_modules/react-devtools-core/dist/standalone.js:2:1227871)
    at Y_ (/Users/sunaina/.npm/_npx/8ea6ac5c50576a3b/node_modules/react-devtools-core/dist/standalone.js:2:1382695)
```


### GitHub query string (automated)

```text
https://api.github.com/search/issues?q=Could not find commit data for root  in:title is:issue is:open is:public label:"Component: Developer Tools" repo:facebook/react
```
Repository: electron
Issue: Use Writing Tools in macOS 15.1
Labels: enhancement :sparkles:

### Preflight Checklist

- [x] I have read the [Contributing Guidelines](https://github.com/electron/electron/blob/main/CONTRIBUTING.md) for this project.
- [x] I agree to follow the [Code of Conduct](https://github.com/electron/electron/blob/main/CODE_OF_CONDUCT.md) that this project adheres to.
- [x] I have searched the [issue tracker](https://www.github.com/electron/electron/issues) for a feature request that matches the one I want to file, without success.

### Problem Description

Are there plans to support apple intelligence's [`Writing Tools`](https://developer.apple.com/documentation/updates/apple-intelligence/) in electron?

The option is available in Chromium (tested on v128). Digging through the source code I found [`render_view_context_menu_mac.mm`](https://github.com/chromium/chromium/blob/main/chrome/browser/ui/cocoa/renderer_context_menu/render_view_context_menu_mac.mm) and [`text_services_context_menu.mm`](https://github.com/chromium/chromium/blob/main/ui/menus/cocoa/text_services_context_menu.mm), but I'm honestly none the wiser how it's implemented 🫠

![Image](https://github.com/user-attachments/assets/072e02db-f586-4502-b7e3-d2fc90d6c144)


### Proposed Solution

`Writing Tools` could be exposed as a context menu `role`, added to the menu only if it's available. 

Also need to expose [`isWritingToolsActive`](https://developer.apple.com/documentation/appkit/nstextview/4431696-iswritingtoolsactive/) for UI/UX reasons, but I guess that can be of a lower priority.

### Alternatives Considered

nil

### Additional Information

Requirements to use apple intelligence:

- macOS 15.1+
- M-series Mac
- [Enable apple intelligence in settings](https://support.apple.com/en-sg/guide/mac-help/mchl46361784/mac)
Repository: vscode
Issue: Error window when accessing Settings
Labels: bug,settings-editor,confirmation-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

<!-- 🪓 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: VSCode-win32-x64-1.94.2
- OS Version: Windows 11

When accessing Settings, I get the error:
![Image](https://github.com/user-attachments/assets/a366928a-ca88-4414-a24a-b1a6fd03a670)

Tried reporting this using 'Report Issue' from the 'Help' menu, as recommended by the template. Getting the same error again.

Launched with `code --disable-extensions`, the same problems.

Steps to Reproduce: always.
Repository: kubernetes
Issue: liveness or readiness probes timeout does not work
Labels: kind/bug,sig/node,triage/needs-information,needs-triage

### What happened?

When executing livenessProbe exec command, timeoutSeconds does not work.
timeoutSeconds: 5
periodSeconds: 30
exec command: /opt/entrypoint.sh healthcheck ,healthcheck will request a url without timeout. When this URL does not respond, a liveness request is received approximately every 2 minutes.


### What did you expect to happen?

When this URL does not respond, liveness request timed out after 5 seconds.

### How can we reproduce it (as minimally and precisely as possible)?

Maybe sleep 120s in command, timeoutSeconds: 5, periodSeconds: 30

### Anything else we need to know?

livenessProbe config:
```
  livenessProbe:
        exec:
          command:
            - /opt/entrypoint.sh
            - healthcheck
        initialDelaySeconds: 30
        timeoutSeconds: 5
        periodSeconds: 30
        successThreshold: 1
        failureThreshold: 12
      readinessProbe:
        exec:
          command:
            - /opt/entrypoint.sh
            - healthcheck
        initialDelaySeconds: 30
        timeoutSeconds: 5
        periodSeconds: 30
        successThreshold: 1
        failureThreshold: 12
```

### Kubernetes version

<details>

```
Server Version: version.Info{Major:"1", Minor:"29+", GitVersion:"v1.29.8-eks-a737599", GitCommit:"3277d87d88d0bf66b6368ce57e49b2f2aab01b0d", GitTreeState:"clean", BuildDate:"2024-08-26T21:27:41Z", GoVersion:"go1.22.5", Compiler:"gc", Platform:"linux/amd64"}
```

</details>


### Cloud provider

<details>
AWS eks
</details>


### OS version

<details>

```console
# On Linux:
$ cat /etc/os-release
# paste output here
$ uname -a
# paste output here

# On Windows:
C:\> wmic os get Caption, Version, BuildNumber, OSArchitecture
# paste output here
```

</details>


### Install tools

<details>

</details>


### Container runtime (CRI) and version (if applicable)

<details>

</details>


### Related plugins (CNI, CSI, ...) and versions (if applicable)

<details>

</details>
Repository: pytorch
Issue: `pkg_resources` module is deprecated by setuptools
Labels: module: build,triaged

### 🐛 Describe the bug

As noted on <https://setuptools.pypa.io/en/latest/pkg_resources.html>:

> Use of pkg_resources is deprecated in favor of [importlib.resources](https://docs.python.org/3.11/library/importlib.resources.html#module-importlib.resources), [importlib.metadata](https://docs.python.org/3.11/library/importlib.metadata.html#module-importlib.metadata) and their backports ([importlib_resources](https://pypi.org/project/importlib_resources), [importlib_metadata](https://pypi.org/project/importlib_metadata)). Some useful APIs are also provided by [packaging](https://pypi.org/project/packaging) (e.g. requirements and version parsing). Users should refrain from new usage of pkg_resources and should work to port to importlib-based solutions.

The only use of `pkg_resources` in PyTorch is:

https://github.com/pytorch/pytorch/blob/e201460f8aa1510b4c4686627d57b69756c4b916/test/run_test.py#L1756-L1762

And it's easy to replace it with something like:

```python
from importlib_metadata import Distribution, PackageNotFoundError

def check_pip_packages() -> None:
    packages = [
        "pytest-rerunfailures",
        "pytest-flakefinder",
        "pytest-xdist",
    ]
    for package in packages:
        try:
            Distribution.from_name(package)
        except PackageNotFoundError:
            print_to_stderr(
                f"Missing pip dependency: {package}, please run `pip install -r .ci/docker/requirements-ci.txt`"
            )
            sys.exit(1)
```

I'm not using `[d.name for d in importlib_metadata.distributions]`, since the names given are not canonicalized (e.g. case, underscore, etc.). In contrast `from_name` can handle canonicalization.

### Versions

PyTorch 2.5.0

cc @malfet @seemethere
Repository: next.js
Issue: SWC plugin runner no longer provides full file path to metadata
Labels: SWC,Pages Router,linear: next

### Link to the code that reproduces this issue

https://github.com/serg-and/nextjs-minimal-swc-plugin-issue

### To Reproduce

```sh
npm i
cd swc_plugin
npm run prepublish
cd ..
npm run dev
```
Logs will show that the provided filename in the metadata no longer includes the file path, only the filename.

### Current vs. Expected behavior

Next's pluggin runner no longer provides the known file path to the metadata for a SWC plugin, only providing the file name.

This is conflict with SWC, saying: [swc docs](https://rustdoc.swc.rs/swc_common/plugin/metadata/struct.TransformPluginMetadataContext.html#structfield.filename)

```rust
/// Host side metadata context plugin may need to access.
/// This is a global context - any plugin in single transform will have same
/// values.
pub struct TransformPluginMetadataContext {
    /// The path of the file being processed. This includes all of the path as
    /// much as possible.
    pub filename: Option<String>,

    ...
}
```

This breaks several packages such as [next-superjson-plugin](https://github.com/blitz-js/next-superjson-plugin) which rely on the path to determine whether some files are page or app router based.

### Provide environment information

```bash
Operating System:
  Platform: linux
  Arch: arm64
  Version: #1 SMP Wed Jul 17 10:51:09 UTC 2024
  Available memory (MB): 7185
  Available CPU cores: 8
Binaries:
  Node: 20.11.1
  npm: 10.2.4
  Yarn: 1.22.19
  pnpm: N/A
Relevant Packages:
  next: 15.0.1 // Latest available version is detected (15.0.1).
  eslint-config-next: 15.0.1
  react: 18.3.1
  react-dom: 18.3.1
  typescript: 5.0.4
Next.js Config:
  output: N/A
```


### Which area(s) are affected? (Select all that apply)

Pages Router, SWC

### Which stage(s) are affected? (Select all that apply)

next dev (local)

### Additional context


I believe the issue originates from here https://github.com/vercel/next.js/blob/v15.0.1/turbopack/crates/turbopack-ecmascript-plugins/src/transform/swc_ecma_transform_plugins.rs#L189

`Some(ctx.file_name_str.to_string())` could simply be changed to `Some(ctx.file_path_str.to_string())`