helloadhavan/github_issues huggingface dataset:
Repository: huggingface/transformers
Pull request: fix: Fixed `pydantic` required version in Dockerfiles to make it compatible with DeepSpeed

# What does this PR do?
The `DeepSpeed` module now requires `pydantic vesrion >=2.0.0`. 
https://github.com/microsoft/DeepSpeed/blob/e2654bfd1ab431bde088a7501ed01b503daa5ab1/requirements/requirements.txt#L6

This is why the following docker builds are failing
https://github.com/huggingface/transformers/actions/runs/10534132397/job/29191315906#
https://github.com/huggingface/transformers/actions/runs/10534132397/job/29191315906

Fixes # (issue)


## Before submitting
- [ ] This PR fixes a typo or improves the docs (you can dismiss the other checks if that's the case).
- [x] Did you read the [contributor guideline](https://github.com/huggingface/transformers/blob/main/CONTRIBUTING.md#create-a-pull-request),
      Pull Request section?
- [ ] Was this discussed/approved via a Github issue or the [forum](https://discuss.huggingface.co/)? Please add a link
      to it if that's the case.
- [ ] Did you make sure to update the documentation with your changes? Here are the
      [documentation guidelines](https://github.com/huggingface/transformers/tree/main/docs), and
      [here are tips on formatting docstrings](https://github.com/huggingface/transformers/tree/main/docs#writing-source-documentation).
- [ ] Did you write any new necessary tests?


## Who can review?
@ydshieh @amyeroberts 

Changed files:
filename: docker/transformers-pytorch-deepspeed-amd-gpu/Dockerfile
patch: @@ -22,7 +22,7 @@ RUN apt update && \
     apt clean && \
     rm -rf /var/lib/apt/lists/*
 
-RUN python3 -m pip install --no-cache-dir --upgrade pip ninja "pydantic<2"
+RUN python3 -m pip install --no-cache-dir --upgrade pip ninja "pydantic>=2.0.0"
 RUN python3 -m pip uninstall -y apex torch torchvision torchaudio
 RUN python3 -m pip install torch==$PYTORCH torchvision==$TORCH_VISION torchaudio==$TORCH_AUDIO --index-url https://download.pytorch.org/whl/rocm$ROCM --no-cache-dir
 

filename: docker/transformers-pytorch-deepspeed-latest-gpu/Dockerfile
patch: @@ -49,5 +49,5 @@ RUN DS_BUILD_CPU_ADAM=1 DS_BUILD_FUSED_ADAM=1 python3 -m pip install deepspeed -
 RUN cd transformers && python3 setup.py develop
 
 # The base image ships with `pydantic==1.8.2` which is not working - i.e. the next command fails
-RUN python3 -m pip install -U --no-cache-dir "pydantic<2"
+RUN python3 -m pip install -U --no-cache-dir "pydantic>=2.0.0"
 RUN python3 -c "from deepspeed.launcher.runner import main"
Repository: denoland/deno
Pull request: fix(unstable): lint plugin child combinator not working with groups

Internally, we use a group node for array-like children, which is hidden from the user. When we're asking for a parent of a node we need to take group nodes into account and walk over them.

Fixes one issue reported in https://github.com/denoland/deno/issues/28355

Changed files:
filename: cli/js/40_lint.js
patch: @@ -782,7 +782,14 @@ class MatchCtx {
    * @returns {number}
    */
   getParent(idx) {
-    return readParent(this.ctx.buf, idx);
+    const parent = readParent(this.ctx.buf, idx);
+
+    const parentType = readType(this.ctx.buf, parent);
+    if (parentType === AST_GROUP_TYPE) {
+      return readParent(this.ctx.buf, parent);
+    }
+
+    return parent;
   }
 
   /**

filename: cli/js/40_lint_selector.js
patch: @@ -919,7 +919,7 @@ function matchDescendant(next) {
 function matchChild(next) {
   return (ctx, id) => {
     const parent = ctx.getParent(id);
-    if (parent < 0) return false;
+    if (parent === 0) return false;
 
     return next(ctx, parent);
   };

filename: tests/unit/lint_plugin_test.ts
patch: @@ -154,6 +154,12 @@ Deno.test("Plugin - visitor child combinator", () => {
   );
   assertEquals(result[0].node.name, "foo");
 
+  result = testVisit(
+    "class Foo { foo = 2 }",
+    "ClassBody > PropertyDefinition",
+  );
+  assertEquals(result[0].node.type, "PropertyDefinition");
+
   result = testVisit(
     "if (false) foo; foo()",
     "IfStatement IfStatement",
Repository: ggml-org/llama.cpp
Pull request: eval-callback : stop on first NaN

Update `llama-eval-callback` to stop on first tensor with a NaN. I think this is always useful when debugging - don't see a reason not to stop.

Changed files:
filename: examples/eval-callback/eval-callback.cpp
patch: @@ -7,6 +7,7 @@
 #include <cstdio>
 #include <string>
 #include <vector>
+#include <numeric>
 
 /**
  * This the arbitrary data which will be passed to each callback.
@@ -77,6 +78,12 @@ static void ggml_print_tensor(uint8_t * data, ggml_type type, const int64_t * ne
         LOG("                                     ]\n");
         LOG("                                     sum = %f\n", sum);
     }
+
+    // TODO: make this abort configurable/optional?
+    if (std::isnan(sum)) {
+        LOG_ERR("encountered NaN - aborting\n");
+        exit(0);
+    }
 }
 
 /**
Repository: electron/electron
Pull request: fix: potential crash in `chrome.tabs.update()`

Backport of #45276

See that PR for details.


Notes: Fixed a potential crash in `chrome.tabs.update()`.


Changed files:
filename: shell/browser/extensions/api/tabs/tabs_api.cc
patch: @@ -648,7 +648,16 @@ bool TabsUpdateFunction::UpdateURL(const std::string& url_string,
   // will stay in the omnibox - see https://crbug.com/1085779.
   load_params.transition_type = ui::PAGE_TRANSITION_FROM_API;
 
-  web_contents_->GetController().LoadURLWithParams(load_params);
+  base::WeakPtr<content::NavigationHandle> navigation_handle =
+      web_contents_->GetController().LoadURLWithParams(load_params);
+  // Navigation can fail for any number of reasons at the content layer.
+  // Unfortunately, we can't provide a detailed error message here, because
+  // there are too many possible triggers. At least notify the extension that
+  // the update failed.
+  if (!navigation_handle) {
+    *error = "Navigation rejected.";
+    return false;
+  }
 
   DCHECK_EQ(url,
             web_contents_->GetController().GetPendingEntry()->GetVirtualURL());
Repository: vercel/next.js
Pull request: [devtools] Hide issue count on empty state

Closes https://linear.app/vercel/issue/NEXT-4554/

Matches design on Figma. Alternative would be a more demure "0". Before we had the same colors as with one or more issues which is distracting.

Changed files:
filename: packages/next/src/next-devtools/dev-overlay/components/devtools-panel/devtools-panel.tsx
patch: @@ -165,9 +165,13 @@ export function DevToolsPanel({
                       onClick={() => setActiveTab('issues')}
                     >
                       Issues
-                      <span data-nextjs-devtools-panel-header-tab-issues-badge>
-                        {issueCount}
-                      </span>
+                      {issueCount > 0 ? (
+                        <span
+                          data-nextjs-devtools-panel-header-tab-issues-badge
+                        >
+                          {issueCount}
+                        </span>
+                      ) : null}
                     </button>
                     <button
                       data-nextjs-devtools-panel-header-tab={
Repository: huggingface/transformers
Pull request: skip some `test_sdpa_can_dispatch_on_flash`

# What does this PR do?

Let's skip, and if the community ask for the support of this for some models, we can allocate the time then, or let the community to open the PRs.

Changed files:
filename: tests/test_modeling_common.py
patch: @@ -3748,7 +3748,24 @@ def test_sdpa_can_dispatch_on_flash(self):
                 self.skipTest(
                     "PaliGemma-like models currently (transformers==4.41.0) requires an attention_mask input"
                 )
-            if config.model_type in ["modernbert", "gemma3", "t5gemma"]:
+            if config.model_type in [
+                "modernbert",
+                "gemma3",
+                "t5gemma",
+                "diffllama",
+                "dpr",
+                "eomt",
+                "gpt_bigcode",
+                "jamba",
+                "kosmos-2",
+                "mllama",
+                "pixtral",
+                "sam",
+                "sam_hq",
+                "zamba2",
+                "sam_vision_model",
+                "sam_hq_vision_model",
+            ]:
                 self.skipTest(
                     reason=f"{config.model_type} currently (transformers==4.52.0) automatically adds an attention_mask input"
                 )
Repository: facebook/react
Pull request: [Fizz][Float] emit viewport meta before preloads

Fixes: #27200 

preloads for images that appear before the viewport meta may be loaded twice because the proper device image information is not used with the preload but is with the image itself. The viewport meta should be emitted earlier than all preloads to avoid this.

this change moves the queue for the viewport meta to preconnects which already has the right priority for this tag

Changed files:
filename: packages/react-dom-bindings/src/server/ReactFizzConfigDOM.js
patch: @@ -1920,6 +1920,9 @@ function pushMeta(
 
       if (typeof props.charSet === 'string') {
         return pushSelfClosing(responseState.charsetChunks, props, 'meta');
+      } else if (props.name === 'viewport') {
+        // "viewport" isn't related to preconnect but it has the right priority
+        return pushSelfClosing(responseState.preconnectChunks, props, 'meta');
       } else {
         return pushSelfClosing(responseState.hoistableChunks, props, 'meta');
       }
Repository: nodejs/node
Pull request: tools: remove unused `osx-pkg-postinstall.sh`

According to https://github.com/nodejs/node/issues/4635#issuecomment-170956761, it's no longer in use, IIUC it was replaced with `tools/macos-installer/pkgbuild/npm/scripts/postinstall` in 03954f778ec491fe5a4f8e42996e3edbe35554d9 – you can see it removed `tools/osx-pkg.pmdoc/02npm.xml` which was the only mention of this script:

https://github.com/nodejs/node/blob/6975c490d11d4aa937c9df6835f4e75ac8c72cee/tools/osx-pkg.pmdoc/02npm.xml#L22

/cc @nodejs/build @nodejs/platform-macos 


<!--
Before submitting a pull request, please read:

- the CONTRIBUTING guide at https://github.com/nodejs/node/blob/HEAD/CONTRIBUTING.md
- the commit message formatting guidelines at
  https://github.com/nodejs/node/blob/HEAD/doc/contributing/pull-requests.md#commit-message-guidelines

For code changes:
1. Include tests for any bug fixes or new features.
2. Update documentation if relevant.
3. Ensure that `make -j4 test` (UNIX), or `vcbuild test` (Windows) passes.

If you believe this PR should be highlighted in the Node.js CHANGELOG
please add the `notable-change` label.

Developer's Certificate of Origin 1.1

By making a contribution to this project, I certify that:

(a) The contribution was created in whole or in part by me and I
    have the right to submit it under the open source license
    indicated in the file; or

(b) The contribution is based upon previous work that, to the best
    of my knowledge, is covered under an appropriate open source
    license and I have the right under that license to submit that
    work with modifications, whether created in whole or in part
    by me, under the same open source license (unless I am
    permitted to submit under a different license), as indicated
    in the file; or

(c) The contribution was provided directly to me by some other
    person who certified (a), (b) or (c) and I have not modified
    it.

(d) I understand and agree that this project and the contribution
    are public and that a record of the contribution (including all
    personal information I submit with it, including my sign-off) is
    maintained indefinitely and may be redistributed consistent with
    this project or the open source license(s) involved.
-->


Changed files:
filename: tools/osx-pkg-postinstall.sh
patch: @@ -1,9 +0,0 @@
-#!/bin/sh
-# TODO Can this be done inside the .pmdoc?
-# TODO Can we extract $PREFIX from the installer?
-cd /usr/local/bin || exit
-
-ln -sf ../lib/node_modules/npm/bin/npm-cli.js npm
-ln -sf ../lib/node_modules/npm/bin/npx-cli.js npx
-
-ln -sf ../lib/node_modules/corepack/dist/corepack.js corepack
Repository: ggml-org/llama.cpp
Pull request: llama : add 18-layer model type for Gemma 3-270m

This commit adds support for the 18-layer model type in the Gemma3 series, which is the size of the Gemma3-270m model.

The motivation for this commit is was the only change required for Gemma3-270m to be converted to GGUF format and used with llama.cpp.

Once the model has been converted and uploaded to Huggingface it can be used like this:
```console
$ ./build/bin/llama-cli -hf ggml-org/gemma-3-270m-GGUF:Q8_0
```


Changed files:
filename: src/llama-model.cpp
patch: @@ -1095,6 +1095,7 @@ void llama_model::load_hparams(llama_model_loader & ml) {
                 ml.get_key(LLM_KV_ATTENTION_LAYERNORM_RMS_EPS, hparams.f_norm_rms_eps);
 
                 switch (hparams.n_layer) {
+                    case 18: type = LLM_TYPE_537M; break;
                     case 26: type = LLM_TYPE_1B; break;
                     case 34: type = LLM_TYPE_4B; break;
                     case 48: type = LLM_TYPE_12B; break;

filename: src/llama-model.h
patch: @@ -39,6 +39,7 @@ enum llm_type {
     LLM_TYPE_410M,
     LLM_TYPE_450M,
     LLM_TYPE_475M,
+    LLM_TYPE_537M,
     LLM_TYPE_700M,
     LLM_TYPE_770M,
     LLM_TYPE_780M,
Repository: vercel/next.js
Pull request: test(codspeed): Make codspeed concurrent on `canary` branch

### What?

Apply same changes as https://github.com/swc-project/swc/pull/10711 to next.js/turbopack. We now run benchmark on `canary` branch in parallel.

### Why?

`codspeed` says `New benchmark` quite frequently, but it's not. This PR should fix it

Closes PACK-4909

Changed files:
filename: .github/workflows/turbopack-benchmark.yml
patch: @@ -13,7 +13,8 @@ on:
       - '**/Cargo.lock'
 
 concurrency:
-  group: ${{ github.workflow }}-${{ github.sha }}
+  # Limit concurrent runs to 1 per PR, but allow concurrent runs on canary branch
+  group: ${{ github.event_name == 'pull_request' && format('{0}-{1}', github.workflow, github.event.pull_request.number) || format('{0}-{1}-{2}', github.workflow, github.ref_name, github.run_id) }}
   cancel-in-progress: ${{ github.event_name == 'pull_request' }}
 
 env:
Repository: electron/electron
Pull request: fix: `webContents.print()` with OOP printing

Backport of #45266

See that PR for details.


Notes: Fixed `webContents.print()` after switch to OOP printing on macOS and Linux. 


Changed files:
filename: patches/chromium/printing.patch
patch: @@ -604,6 +604,19 @@ index 402be34ab888cdf834d0fb65de0832e9a8021ced..82ddc92a35d824926c30279e660cc4e8
  }
  
  #if BUILDFLAG(IS_CHROMEOS)
+diff --git a/chrome/browser/printing/printer_query_oop.cc b/chrome/browser/printing/printer_query_oop.cc
+index e271d17b3261c47f3dbeaf9be0b3c4229ee27181..00b906660580aca7d5aabcde54d68c2161ea71dd 100644
+--- a/chrome/browser/printing/printer_query_oop.cc
++++ b/chrome/browser/printing/printer_query_oop.cc
+@@ -127,7 +127,7 @@ void PrinterQueryOop::OnDidAskUserForSettings(
+     std::unique_ptr<PrintSettings> new_settings,
+     mojom::ResultCode result) {
+   DCHECK_CURRENTLY_ON(content::BrowserThread::UI);
+-  if (result == mojom::ResultCode::kSuccess) {
++  if (result == mojom::ResultCode::kSuccess && query_with_ui_client_id_) {
+     // Want the same PrintBackend service as the query so that we use the same
+     // device context.
+     print_document_client_id_ =
 diff --git a/components/printing/browser/print_manager.cc b/components/printing/browser/print_manager.cc
 index 21c81377d32ae8d4185598a7eba88ed1d2063ef0..0767f4e9369e926b1cea99178c1a1975941f1765 100644
 --- a/components/printing/browser/print_manager.cc
Repository: electron/electron
Pull request: fix: `webContents.print()` with OOP printing

#### Description of Change

Ref CL:6032774

Fixes `webContents.print()` after switch to OOP printing on macOS and Linux. We need to make sure that `query_with_ui_client_id_.has_value()` is true, which isnt a scenario upstream hits since we use the update print settings pathway by default when we pass custom settings via `webContents.print()`.

Tested with https://gist.github.com/codebytere/0f0e776b138452d6815ef4efc16aa0d1

✅ A print job can be sent
✅ Two print jobs can be sent consecutively
✅ A print job can be cancelled and a successful print job sent afterwards

#### Checklist
<!-- Remove items that do not apply. For completed items, change [ ] to [x]. -->

- [x] PR description included and stakeholders cc'd
- [x] `npm test` passes
- [x] [PR release notes](https://github.com/electron/clerk/blob/main/README.md) describe the change in a way relevant to app developers, and are [capitalized, punctuated, and past tense](https://github.com/electron/clerk/blob/main/README.md#examples).

#### Release Notes

Notes: Fixed `webContents.print()` after switch to OOP printing on macOS and Linux. 


Changed files:
filename: patches/chromium/printing.patch
patch: @@ -604,6 +604,19 @@ index 402be34ab888cdf834d0fb65de0832e9a8021ced..82ddc92a35d824926c30279e660cc4e8
  }
  
  #if BUILDFLAG(IS_CHROMEOS)
+diff --git a/chrome/browser/printing/printer_query_oop.cc b/chrome/browser/printing/printer_query_oop.cc
+index e271d17b3261c47f3dbeaf9be0b3c4229ee27181..00b906660580aca7d5aabcde54d68c2161ea71dd 100644
+--- a/chrome/browser/printing/printer_query_oop.cc
++++ b/chrome/browser/printing/printer_query_oop.cc
+@@ -127,7 +127,7 @@ void PrinterQueryOop::OnDidAskUserForSettings(
+     std::unique_ptr<PrintSettings> new_settings,
+     mojom::ResultCode result) {
+   DCHECK_CURRENTLY_ON(content::BrowserThread::UI);
+-  if (result == mojom::ResultCode::kSuccess) {
++  if (result == mojom::ResultCode::kSuccess && query_with_ui_client_id_) {
+     // Want the same PrintBackend service as the query so that we use the same
+     // device context.
+     print_document_client_id_ =
 diff --git a/components/printing/browser/print_manager.cc b/components/printing/browser/print_manager.cc
 index 21c81377d32ae8d4185598a7eba88ed1d2063ef0..0767f4e9369e926b1cea99178c1a1975941f1765 100644
 --- a/components/printing/browser/print_manager.cc
Repository: facebook/react
Pull request: [ESLint] Disallow hooks in async functions

Hooks cannot be called in async functions, on either the client or the server. This mistake sometimes happens when using Server Components, especially when refactoring a Server Component to a Client Component.

React logs a warning at runtime, but it's even better to catch this with a lint rule since it will show immediate inline feedback in the editor.

I added this to the existing "Rules of Hooks" ESLint rule.

Changed files:
filename: packages/eslint-plugin-react-hooks/__tests__/ESLintRulesOfHooks-test.js
patch: @@ -1042,6 +1042,22 @@ const tests = {
       `,
       errors: [classError('useState')],
     },
+    {
+      code: normalizeIndent`
+        async function AsyncComponent() {
+          useState();
+        }
+      `,
+      errors: [asyncComponentHookError('useState')],
+    },
+    {
+      code: normalizeIndent`
+        async function useAsyncHook() {
+          useState();
+        }
+      `,
+      errors: [asyncComponentHookError('useState')],
+    },
   ],
 };
 
@@ -1300,6 +1316,14 @@ if (__EXPERIMENTAL__) {
       `,
       errors: [classError('use')],
     },
+    {
+      code: normalizeIndent`
+        async function AsyncComponent() {
+          use();
+        }
+      `,
+      errors: [asyncComponentHookError('use')],
+    },
   ];
 }
 
@@ -1368,6 +1392,12 @@ function useEffectEventError(fn) {
   };
 }
 
+function asyncComponentHookError(fn) {
+  return {
+    message: `React Hook "${fn}" cannot be called in an async function.`,
+  };
+}
+
 // For easier local testing
 if (!process.env.CI) {
   let only = [];

filename: packages/eslint-plugin-react-hooks/src/RulesOfHooks.js
patch: @@ -485,6 +485,17 @@ export default {
             // Pick a special message depending on the scope this hook was
             // called in.
             if (isDirectlyInsideComponentOrHook) {
+              // Report an error if the hook is called inside an async function.
+              const isAsyncFunction = codePathNode.async;
+              if (isAsyncFunction) {
+                context.report({
+                  node: hook,
+                  message:
+                    `React Hook "${context.getSource(hook)}" cannot be ` +
+                    'called in an async function.',
+                });
+              }
+
               // Report an error if a hook does not reach all finalizing code
               // path segments.
               //
Repository: electron/electron
Pull request: fix: consume the file permission callback when used

#### Description of Change

When consuming a callback that lives in `callback_map_`, remove it from the map to prevent dangling references. Fixes a 0e5fe3f issue.

#### Checklist

- [x] PR description included and stakeholders cc'd
- [x] `npm test` passes
- [x] [PR release notes](https://github.com/electron/clerk/blob/main/README.md) describe the change in a way relevant to app developers, and are [capitalized, punctuated, and past tense](https://github.com/electron/clerk/blob/main/README.md#examples).

#### Release Notes

Notes: none

Changed files:
filename: shell/browser/file_system_access/file_system_access_permission_context.cc
patch: @@ -594,7 +594,7 @@ void FileSystemAccessPermissionContext::ConfirmSensitiveEntryAccess(
     content::GlobalRenderFrameHostId frame_id,
     base::OnceCallback<void(SensitiveEntryResult)> callback) {
   DCHECK_CALLED_ON_VALID_SEQUENCE(sequence_checker_);
-  callback_map_[path_info.path] = std::move(callback);
+  callback_map_.try_emplace(path_info.path, std::move(callback));
 
   auto after_blocklist_check_callback = base::BindOnce(
       &FileSystemAccessPermissionContext::DidCheckPathAgainstBlocklist,
@@ -640,8 +640,8 @@ void FileSystemAccessPermissionContext::PerformAfterWriteChecks(
 void FileSystemAccessPermissionContext::RunRestrictedPathCallback(
     const base::FilePath& file_path,
     SensitiveEntryResult result) {
-  if (base::Contains(callback_map_, file_path))
-    std::move(callback_map_[file_path]).Run(result);
+  if (auto val = callback_map_.extract(file_path))
+    std::move(val.mapped()).Run(result);
 }
 
 void FileSystemAccessPermissionContext::OnRestrictedPathResult(
Repository: ggml-org/llama.cpp
Pull request: fix compile bug when the BASE_CUDA_DEV_CONTAINER is based on Ubuntu 2…

…4.04

fixes #15004

*Make sure to read the [contributing guidelines](https://github.com/ggml-org/llama.cpp/blob/master/CONTRIBUTING.md) before submitting a PR*


Changed files:
filename: .devops/cuda.Dockerfile
patch: @@ -60,8 +60,7 @@ RUN apt-get update \
     git \
     python3 \
     python3-pip \
-    && pip install --upgrade pip setuptools wheel \
-    && pip install -r requirements.txt \
+    && pip install --break-system-packages -r requirements.txt \
     && apt autoremove -y \
     && apt clean -y \
     && rm -rf /tmp/* /var/tmp/* \