helloadhavan/github_issues huggingface dataset:
Repository: denoland/deno
Pull request: fix(bundle): parse the allow-import flag, fix example in help text

Closes #29729.

Changed files:
filename: cli/args/flags.rs
patch: @@ -1944,11 +1944,11 @@ fn bundle_subcommand() -> Command {
     "bundle",
     "Output a single JavaScript file with all dependencies.
 
-  deno bundle https://deno.land/std/examples/colors.ts colors.bundle.js
+  deno bundle jsr:@std/http/file-server -o file-server.bundle.js
 
 If no output file is given, the output is written to standard output:
 
-  deno bundle https://deno.land/std/examples/colors.ts
+  deno bundle jsr:@std/http/file-server
 ",
     UnstableArgsConfig::ResolutionOnly,
   )
@@ -4850,6 +4850,7 @@ fn bundle_parse(
   let outdir = matches.remove_one::<String>("outdir");
   compile_args_without_check_parse(flags, matches)?;
   unstable_args_parse(flags, matches, UnstableArgsConfig::ResolutionAndRuntime);
+  allow_import_parse(flags, matches)?;
   flags.subcommand = DenoSubcommand::Bundle(BundleFlags {
     entrypoints: file.collect(),
     output_path: output,

filename: tests/specs/bundle/allow_imports/__test__.jsonc
patch: @@ -0,0 +1,10 @@
+{
+  "tempDir": true,
+  "steps": [{
+    "args": "bundle --allow-import main.ts -o bundle.js",
+    "output": "[WILDCARD]"
+  }, {
+    "args": "run bundle.js",
+    "output": "3\n"
+  }]
+}

filename: tests/specs/bundle/allow_imports/main.ts
patch: @@ -0,0 +1,3 @@
+import { add } from "http://localhost:4545/add.ts";
+
+console.log(add(1, 2));
Repository: huggingface/transformers
Pull request: Update object_detection.md

# What does this PR do?

fix code snippet error in object detection docs.

## Before submitting
- [✓] This PR fixes a typo or improves the docs (you can dismiss the other checks if that's the case).
- [✓] 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?

@stevhliu 

Changed files:
filename: docs/source/en/tasks/object_detection.md
patch: @@ -146,7 +146,7 @@ To get an even better understanding of the data, visualize an example in the dat
 >>> annotations = cppe5["train"][2]["objects"]
 >>> draw = ImageDraw.Draw(image)
 
->>> categories = cppe5["train"].features["objects"].feature["category"].names
+>>> categories = cppe5["train"].features["objects"]["category"].feature.names
 
 >>> id2label = {index: x for index, x in enumerate(categories, start=0)}
 >>> label2id = {v: k for k, v in id2label.items()}
Repository: facebook/react
Pull request: Fix jest inline snapshots

Prettier 3 is not supported for jest inline snapshots: https://jestjs.io/docs/configuration#prettierpath-string

Changed files:
filename: package.json
patch: @@ -81,6 +81,7 @@
     "mkdirp": "^0.5.1",
     "ncp": "^2.0.0",
     "prettier": "3.0.3",
+    "prettier-2": "npm:prettier@^2",
     "pretty-format": "^29.4.1",
     "prop-types": "^15.6.2",
     "random-seed": "^0.3.0",

filename: scripts/jest/config.base.js
patch: @@ -10,6 +10,7 @@ module.exports = {
   transform: {
     '.*': require.resolve('./preprocessor.js'),
   },
+  prettierPath: require.resolve('prettier-2'),
   setupFiles: [require.resolve('./setupEnvironment.js')],
   setupFilesAfterEnv: [require.resolve('./setupTests.js')],
   // Only include files directly in __tests__, not in nested folders.

filename: yarn.lock
patch: @@ -12591,6 +12591,11 @@ prepend-http@^2.0.0:
   resolved "https://registry.yarnpkg.com/prepend-http/-/prepend-http-2.0.0.tgz#e92434bfa5ea8c19f41cdfd401d741a3c819d897"
   integrity sha1-6SQ0v6XqjBn0HN/UAddBo8gZ2Jc=
 
+"prettier-2@npm:prettier@^2":
+  version "2.8.8"
+  resolved "https://registry.yarnpkg.com/prettier/-/prettier-2.8.8.tgz#e8c5d7e98a4305ffe3de2e1fc4aca1a71c28b1da"
+  integrity sha512-tdN8qQGvNjw4CHbY+XXk0JgCXn9QiF21a55rBe5LJAU+kDyC4WQn4+awm2Xfk2lQMk5fKup9XgzTZtGkjBdP9Q==
+
 prettier@*, prettier@3.0.3:
   version "3.0.3"
   resolved "https://registry.yarnpkg.com/prettier/-/prettier-3.0.3.tgz#432a51f7ba422d1469096c0fdc28e235db8f9643"
Repository: vercel/next.js
Pull request: [backport]: fix(next/image): fix image-optimizer.ts headers (#82114)

Backports:
- #82114

Changed files:
filename: packages/next/src/server/image-optimizer.ts
patch: @@ -634,7 +634,6 @@ export async function fetchInternalImage(
     const mocked = createRequestResponseMocks({
       url: href,
       method: _req.method || 'GET',
-      headers: _req.headers,
       socket: _req.socket,
     })
 

filename: test/integration/image-optimizer/app/pages/api/conditional-cookie.js
patch: @@ -0,0 +1,11 @@
+const pixel =
+  'iVBORw0KGgoAAAANSUhEUgAAAAEAAAABCAYAAAAfFcSJAAAADUlEQVR42mNkYPj/HwADBwIAMCbHYQAAAABJRU5ErkJggg=='
+
+export default function handler(req, res) {
+  if (req.headers['cookie']) {
+    res.setHeader('content-type', 'image/png')
+    res.end(Buffer.from(pixel, 'base64'))
+  } else {
+    res.status(401).end('cookie was not found')
+  }
+}

filename: test/integration/image-optimizer/test/util.ts
patch: @@ -308,6 +308,13 @@ export function runTests(ctx: RunTestsCtx) {
     expect(ctx.nextOutput).toContain(animatedWarnText)
   })
 
+  it('should not forward cookie header', async () => {
+    const query = { w: ctx.w, q: 30, url: '/api/conditional-cookie' }
+    const opts = { headers: { accept: 'image/webp', cookie: '1' } }
+    const res = await fetchViaHTTP(ctx.appPort, '/_next/image', query, opts)
+    expect(res.status).toBe(400)
+  })
+
   if (ctx.nextConfigImages?.dangerouslyAllowSVG) {
     it('should maintain vector svg', async () => {
       const query = { w: ctx.w, q: 90, url: '/test.svg' }
Repository: denoland/deno
Pull request: test(ext/node): enable parallel/test-crypto-dh-odd-key.js

This test seems able to be updated to the latest without particular changes

Changed files:
filename: tests/node_compat/config.jsonc
patch: @@ -44,7 +44,6 @@
       "test-console-instance.js",
       "test-console-tty-colors.js",
       "test-crypto-dh-errors.js",
-      "test-crypto-dh-odd-key.js",
       "test-crypto-dh.js",
       "test-crypto-hash.js",
       "test-crypto-hkdf.js",

filename: tests/node_compat/test/parallel/test-crypto-dh-odd-key.js
patch: @@ -2,7 +2,7 @@
 // deno-lint-ignore-file
 
 // Copyright Joyent and Node contributors. All rights reserved. MIT license.
-// Taken from Node 20.11.1
+// Taken from Node 23.9.0
 // This file is automatically generated by `tests/node_compat/runner/setup.ts`. Do not modify this file manually.
 
 // Copyright Joyent, Inc. and other Node contributors.
@@ -28,22 +28,24 @@
 
 'use strict';
 const common = require('../common');
-if (!common.hasCrypto)
+if (!common.hasCrypto) {
   common.skip('missing crypto');
+}
 
 const assert = require('assert');
 const crypto = require('crypto');
+const { hasOpenSSL3 } = require('../common/crypto');
 
 function test() {
   const odd = Buffer.alloc(39, 'A');
 
-  const c = crypto.createDiffieHellman(common.hasOpenSSL3 ? 1024 : 32);
+  const c = crypto.createDiffieHellman(hasOpenSSL3 ? 1024 : 32);
   c.setPrivateKey(odd);
   c.generateKeys();
 }
 
 // FIPS requires a length of at least 1024
-if (!common.hasFipsCrypto) {
+if (!crypto.getFips()) {
   test();
 } else {
   assert.throws(function() { test(); }, /key size too small/);
Repository: nodejs/node
Pull request: meta: add CODEOWNERS for SQLite

<!--
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: .github/CODEOWNERS
patch: @@ -200,3 +200,11 @@
 /lib/url.js @nodejs/url
 /src/node_url.* @nodejs/url
 /test/fixtures/wpt/url @nodejs/url
+
+# SQLite
+/deps/sqlite/ @nodejs/sqlite
+/doc/api/sqlite.md @nodejs/sqlite
+/src/node_sqlite.* @nodejs/sqlite
+/test/parallel/test-sqlite* @nodejs/sqlite
+/test/sqlite/ @nodejs/sqlite
+/tools/dep_updaters/update-sqlite.sh @nodejs/sqlite
Repository: huggingface/transformers
Pull request: run model debugging with forward arg

# What does this PR do?
Integrate the amazing model_debugging utils directly in all models that have `check_model_inputs` to just need to pass `debug_io` and `debug_io_dir` and `prune_layers` 

Changed files:
filename: src/transformers/model_debugging_utils.py
patch: @@ -21,26 +21,23 @@
 from io import StringIO
 from typing import Optional
 
-from safetensors.torch import save_file
-
-from transformers.utils.import_utils import requires
-
-from .utils import is_torch_available
+from .utils.import_utils import is_torch_available, requires
 
 
 if is_torch_available():
     import torch
     import torch.distributed.tensor
+    from safetensors.torch import save_file
 
-
+    # Note to code inspectors: this toolbox is intended for people who add models to `transformers`.
+    _torch_distributed_available = torch.distributed.is_available()
+else:
+    _torch_distributed_available = False
 from .utils import logging
 
 
 logger = logging.get_logger(__name__)
 
-# Note to code inspectors: this toolbox is intended for people who add models to `transformers`.
-_torch_distributed_available = torch.distributed.is_available()
-
 
 def _is_rank_zero():
     """Return True if rank=0 or we aren't running distributed."""

filename: src/transformers/utils/generic.py
patch: @@ -52,6 +52,8 @@
     # required for @can_return_tuple decorator to work with torchdynamo
     import torch  # noqa: F401
 
+    from ..model_debugging_utils import model_addition_debugger_context
+
 
 class cached_property(property):
     """
@@ -1032,7 +1034,13 @@ def make_capture_wrapper(module, orig_forward, key, index):
             def wrapped_forward(*args, **kwargs):
                 if key == "hidden_states" and len(collected_outputs[key]) == 0:
                     collected_outputs[key] += (args[0],)
-                output = orig_forward(*args, **kwargs)
+                if kwargs.get("debug_io", False):
+                    with model_addition_debugger_context(
+                        module, kwargs.get("debug_io_dir", "~/model_debug"), kwargs.get("prune_layers")
+                    ):
+                        output = orig_forward(*args, **kwargs)
+                else:
+                    output = orig_forward(*args, **kwargs)
                 if not isinstance(output, tuple):
                     collected_outputs[key] += (output,)
                 elif output[index] is not None:
Repository: denoland/deno
Pull request: fix(bundle): enable sloppy imports by default when bundling

It's more permissive, aligns more with typical bundler behavior, and runtime perf is not as much of a concern

Changed files:
filename: cli/tools/bundle/mod.rs
patch: @@ -45,9 +45,13 @@ use crate::resolver::CliResolver;
 use crate::tools::bundle::externals::ExternalsMatcher;
 
 pub async fn bundle(
-  flags: Arc<Flags>,
+  mut flags: Arc<Flags>,
   bundle_flags: BundleFlags,
 ) -> Result<(), AnyError> {
+  {
+    let flags_mut = Arc::make_mut(&mut flags);
+    flags_mut.unstable_config.sloppy_imports = true;
+  }
   let factory = CliFactory::from_flags(flags);
 
   let installer_factory = factory.npm_installer_factory()?;

filename: tests/specs/bundle/sloppy_imports/__test__.jsonc
patch: @@ -0,0 +1,9 @@
+{
+  "steps": [{
+    "args": "bundle main.ts -o bundled.js",
+    "output": "[WILDCARD]"
+  }, {
+    "args": "run bundled.js",
+    "output": "foo\n"
+  }]
+}

filename: tests/specs/bundle/sloppy_imports/bundled.js
patch: @@ -0,0 +1,5 @@
+// foo.js
+var foo_default = "foo";
+
+// main.ts
+console.log(foo_default);

filename: tests/specs/bundle/sloppy_imports/foo.js
patch: @@ -0,0 +1 @@
+export default "foo";

filename: tests/specs/bundle/sloppy_imports/main.ts
patch: @@ -0,0 +1,3 @@
+import foo from "./foo";
+
+console.log(foo);
Repository: vercel/next.js
Pull request: [backport v14]: fix(next/image): fix image-optimizer.ts headers (#82114)

Backports:
- #82114

Changed files:
filename: packages/next/src/server/image-optimizer.ts
patch: @@ -594,7 +594,6 @@ export async function fetchInternalImage(
     const mocked = createRequestResponseMocks({
       url: href,
       method: _req.method || 'GET',
-      headers: _req.headers,
       socket: _req.socket,
     })
 

filename: test/integration/image-optimizer/app/pages/api/conditional-cookie.js
patch: @@ -0,0 +1,11 @@
+const pixel =
+  'iVBORw0KGgoAAAANSUhEUgAAAAEAAAABCAYAAAAfFcSJAAAADUlEQVR42mNkYPj/HwADBwIAMCbHYQAAAABJRU5ErkJggg=='
+
+export default function handler(req, res) {
+  if (req.headers['cookie']) {
+    res.setHeader('content-type', 'image/png')
+    res.end(Buffer.from(pixel, 'base64'))
+  } else {
+    res.status(401).end('cookie was not found')
+  }
+}

filename: test/integration/image-optimizer/test/util.ts
patch: @@ -264,6 +264,13 @@ export function runTests(ctx) {
     expect(ctx.nextOutput).toContain(animatedWarnText)
   })
 
+  it('should not forward cookie header', async () => {
+    const query = { w: ctx.w, q: 30, url: '/api/conditional-cookie' }
+    const opts = { headers: { accept: 'image/webp', cookie: '1' } }
+    const res = await fetchViaHTTP(ctx.appPort, '/_next/image', query, opts)
+    expect(res.status).toBe(400)
+  })
+
   if (ctx.dangerouslyAllowSVG) {
     it('should maintain vector svg', async () => {
       const query = { w: ctx.w, q: 90, url: '/test.svg' }
Repository: ggml-org/llama.cpp
Pull request: sync : ggml


Changed files:
filename: ggml/CMakeLists.txt
patch: @@ -4,7 +4,7 @@ project("ggml" C CXX ASM)
 ### GGML Version
 set(GGML_VERSION_MAJOR 0)
 set(GGML_VERSION_MINOR 9)
-set(GGML_VERSION_PATCH 3)
+set(GGML_VERSION_PATCH 4)
 set(GGML_VERSION_BASE "${GGML_VERSION_MAJOR}.${GGML_VERSION_MINOR}.${GGML_VERSION_PATCH}")
 
 find_program(GIT_EXE NAMES git git.exe NO_CMAKE_FIND_ROOT_PATH)

filename: scripts/sync-ggml.last
patch: @@ -1 +1 @@
-83a15e113b130337a892fb6575c337754557d56f
+72632094336524a9c809e129e8b1c52154543a5a
Repository: nodejs/node
Pull request: build: fix zstd pkgname

When trying to build Node.js with `--shared-zstd`, I'm getting the following:

```
Package zstd was not found in the pkg-config search path.
Perhaps you should add the directory containing `zstd.pc'
to the PKG_CONFIG_PATH environment variable
Package 'zstd' not found
```

I've tried passing `--shared-zstd-libname=libzstd` without success, however this patch does make the error go away.

<!--
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: configure.py
patch: @@ -2268,7 +2268,7 @@ def make_bin_override():
 configure_library('ngtcp2', output, pkgname='libngtcp2')
 configure_library('sqlite', output, pkgname='sqlite3')
 configure_library('uvwasi', output, pkgname='libuvwasi')
-configure_library('zstd', output)
+configure_library('zstd', output, pkgname='libzstd')
 configure_v8(output, configurations)
 configure_openssl(output)
 configure_intl(output)
Repository: vercel/next.js
Pull request: Turbopack: write tasks doesn't need to be session dependent, as effects will restore

### What?

Filesystem write task don't need to be session dependent. We don't need to reexecute them for that reason. We already emit an "effect" and that is still emitted after restoring from cache.

Not making them session dependent avoids dirty updates and also tracking the task as dirty in the aggregated graph. 

But the "effect" is not-serializeable, so the write task will be recomputed to recompute the value of the effect, when trying to apply the effect.

Closes PACK-5137

Changed files:
filename: turbopack/crates/turbo-tasks-fs/src/lib.rs
patch: @@ -717,7 +717,10 @@ impl FileSystem for DiskFileSystem {
 
     #[turbo_tasks::function(fs)]
     async fn write(&self, fs_path: FileSystemPath, content: Vc<FileContent>) -> Result<()> {
-        mark_session_dependent();
+        // You might be tempted to use `mark_session_dependent` here, but
+        // `write` purely declares a side effect and does not need to be reexecuted in the next
+        // session. All side effects are reexecuted in general.
+
         let full_path = self.to_sys_path(fs_path).await?;
         let content = content.await?;
         let inner = self.inner.clone();
@@ -848,7 +851,10 @@ impl FileSystem for DiskFileSystem {
 
     #[turbo_tasks::function(fs)]
     async fn write_link(&self, fs_path: FileSystemPath, target: Vc<LinkContent>) -> Result<()> {
-        mark_session_dependent();
+        // You might be tempted to use `mark_session_dependent` here, but
+        // `write_link` purely declares a side effect and does not need to be reexecuted in the next
+        // session. All side effects are reexecuted in general.
+
         let full_path = self.to_sys_path(fs_path).await?;
         let content = target.await?;
         let inner = self.inner.clone();
Repository: nodejs/node
Pull request: src: fix node_config_file.h compilation error in GN build

Fix the same compilation error of https://github.com/nodejs/node/pull/57173, without breaking building after https://github.com/nodejs/node/pull/57170.

Changed files:
filename: src/node_config_file.h
patch: @@ -6,6 +6,7 @@
 #include <map>
 #include <string>
 #include <variant>
+#include "node_internals.h"
 #include "simdjson.h"
 #include "util-inl.h"
Repository: facebook/react
Pull request: Add jsx-runtime.react-server.js to file allowlist

https://github.com/facebook/react/pull/28217 doesn't work without this since it's not included in the files list.

See https://github.com/dai-shi/waku/pull/467#issuecomment-1936965080.

This should fix that.

Changed files:
filename: packages/react/package.json
patch: @@ -15,6 +15,7 @@
     "cjs/",
     "umd/",
     "jsx-runtime.js",
+    "jsx-runtime.react-server.js",
     "jsx-dev-runtime.js",
     "react.react-server.js"
   ],
Repository: denoland/deno
Pull request: fix(install): infer name from @scope/cli pattern

Quite common, for example:
- @slidev/cli
- @vue/cli
- @nestjs/cli
- @angular/cli
- @expo/cli

came across this while opening https://github.com/slidevjs/slidev/pull/2201

Changed files:
filename: cli/tools/installer.rs
patch: @@ -190,6 +190,14 @@ pub async fn infer_name_from_url(
     if !npm_ref.req.name.contains('/') {
       return Some(npm_ref.req.name.into_string());
     }
+    if let Some(scope_and_pkg) = npm_ref.req.name.strip_prefix('@') {
+      if let Some((scope, package)) = scope_and_pkg.split_once('/') {
+        if package == "cli" {
+          return Some(scope.to_string());
+        }
+      }
+    }
+
     return None;
   }
 
@@ -902,6 +910,14 @@ mod tests {
       .await,
       None
     );
+    assert_eq!(
+      infer_name_from_url(
+        &http_client,
+        &Url::parse("npm:@slidev/cli@1.2").unwrap()
+      )
+      .await,
+      Some("slidev".to_string())
+    );
   }
 
   #[tokio::test]
Repository: nodejs/node
Pull request: meta: set nodejs/config as codeowner

If you are interested in joining @nodejs/config please add yourself to the team.
@anonrig if you see files missing please commit into

Changed files:
filename: .github/CODEOWNERS
patch: @@ -208,3 +208,11 @@
 /test/parallel/test-sqlite* @nodejs/sqlite
 /test/sqlite/ @nodejs/sqlite
 /tools/dep_updaters/update-sqlite.sh @nodejs/sqlite
+
+# Config
+/doc/node-config-schema.json @nodejs/config
+/src/node_config.* @nodejs/config
+/src/node_dotenv.* @nodejs/config
+/src/node_options.* @nodejs/config
+/test/parallel/test-config-* @nodejs/config
+/test/parallel/test-dotenv-* @nodejs/config