helloadhavan/github_issues huggingface dataset:
Repository: denoland/deno
Pull request: fix(ext/http): gracefully handle Response.error responses

Fixes #14371

Changed files:
filename: ext/http/00_serve.ts
patch: @@ -511,9 +511,15 @@ function mapToCallback(context, callback, onError) {
         );
       }
 
+      if (response.type === "error") {
+        throw new TypeError(
+          "Return value from serve handler must not be an error response (like Response.error())",
+        );
+      }
+
       if (response.bodyUsed) {
         throw new TypeError(
-          "The body of the Response returned from the serve handler has already been consumed.",
+          "The body of the Response returned from the serve handler has already been consumed",
         );
       }
     } catch (error) {

filename: tests/unit/serve_test.ts
patch: @@ -678,6 +678,40 @@ Deno.test(
   },
 );
 
+Deno.test(
+  { permissions: { net: true } },
+  async function httpServerReturnErrorResponse() {
+    const ac = new AbortController();
+    const { promise, resolve } = Promise.withResolvers<void>();
+    let hadError = false;
+    const server = Deno.serve({
+      handler: () => {
+        return Response.error();
+      },
+      port: servePort,
+      signal: ac.signal,
+      onListen: onListen(resolve),
+      onError: () => {
+        hadError = true;
+        return new Response("Internal Server Error", { status: 500 });
+      },
+    });
+
+    await promise;
+
+    const resp = await fetch(`http://127.0.0.1:${servePort}/`, {
+      headers: { "connection": "close" },
+    });
+    assertEquals(resp.status, 500);
+    const text = await resp.text();
+    assertEquals(text, "Internal Server Error");
+    assert(hadError);
+
+    ac.abort();
+    await server.finished;
+  },
+);
+
 Deno.test({ permissions: { net: true } }, async function httpServerOverload1() {
   const ac = new AbortController();
   const deferred = Promise.withResolvers<void>();
Repository: facebook/react
Pull request: [Transition Tracing] Add Offscreen Test

Add a test to make sure offscreen trees don't stop transitions from completing.

Changed files:
filename: packages/react-reconciler/src/__tests__/ReactTransitionTracing-test.js
patch: @@ -16,6 +16,7 @@ let act;
 let getCacheForType;
 let useState;
 let Suspense;
+let Offscreen;
 let startTransition;
 
 let caches;
@@ -34,6 +35,7 @@ describe('ReactInteractionTracing', () => {
     useState = React.useState;
     startTransition = React.startTransition;
     Suspense = React.Suspense;
+    Offscreen = React.unstable_Offscreen;
 
     getCacheForType = React.unstable_getCacheForType;
 
@@ -1362,4 +1364,74 @@ describe('ReactInteractionTracing', () => {
       ]);
     });
   });
+
+  // @gate enableTransitionTracing
+  it('offscreen trees should not stop transition from completing', async () => {
+    const transitionCallbacks = {
+      onTransitionStart: (name, startTime) => {
+        Scheduler.unstable_yieldValue(
+          `onTransitionStart(${name}, ${startTime})`,
+        );
+      },
+      onTransitionComplete: (name, startTime, endTime) => {
+        Scheduler.unstable_yieldValue(
+          `onTransitionComplete(${name}, ${startTime}, ${endTime})`,
+        );
+      },
+      onMarkerComplete: (transitioName, markerName, startTime, endTime) => {
+        Scheduler.unstable_yieldValue(
+          `onMarkerComplete(${transitioName}, ${markerName}, ${startTime}, ${endTime})`,
+        );
+      },
+    };
+
+    function App() {
+      return (
+        <React.unstable_TracingMarker name="marker">
+          <Suspense fallback={<Text text="Loading..." />}>
+            <AsyncText text="Text" />
+          </Suspense>
+          <Offscreen mode="hidden">
+            <Suspense fallback={<Text text="Hidden Loading..." />}>
+              <AsyncText text="Hidden Text" />
+            </Suspense>
+          </Offscreen>
+        </React.unstable_TracingMarker>
+      );
+    }
+
+    const root = ReactNoop.createRoot({
+      unstable_transitionCallbacks: transitionCallbacks,
+    });
+    await act(() => {
+      startTransition(() => root.render(<App />), {name: 'transition'});
+      ReactNoop.expire(1000);
+      advanceTimers(1000);
+    });
+    expect(Scheduler).toHaveYielded([
+      'Suspend [Text]',
+      'Loading...',
+      'Suspend [Hidden Text]',
+      'Hidden Loading...',
+      'onTransitionStart(transition, 0)',
+    ]);
+
+    await act(() => {
+      resolveText('Text');
+      ReactNoop.expire(1000);
+      advanceTimers(1000);
+    });
+    expect(Scheduler).toHaveYielded([
+      'Text',
+      'onMarkerComplete(transition, marker, 0, 2000)',
+      'onTransitionComplete(transition, 0, 2000)',
+    ]);
+
+    await act(() => {
+      resolveText('Hidden Text');
+      ReactNoop.expire(1000);
+      advanceTimers(1000);
+    });
+    expect(Scheduler).toHaveYielded(['Hidden Text']);
+  });
 });
Repository: denoland/deno
Pull request: fix: error on unsupported compiler options

Update the config schema to error when adding unsupported `compilerOptions`.

Fixes https://github.com/denoland/deno/issues/25696

Changed files:
filename: cli/schemas/config-file.v1.json
patch: @@ -9,6 +9,7 @@
     "compilerOptions": {
       "type": "object",
       "description": "Instructs the TypeScript compiler how to compile .ts files.",
+      "additionalProperties": false,
       "properties": {
         "allowJs": {
           "description": "Allow JavaScript files to be a part of your program. Use the `checkJS` option to get errors from these files.",
Repository: denoland/deno
Pull request: fix(flags): don't treat empty run command as task subcommand


Changed files:
filename: cli/args/flags.rs
patch: @@ -4679,7 +4679,7 @@ fn repl_parse(
 fn run_parse(
   flags: &mut Flags,
   matches: &mut ArgMatches,
-  app: Command,
+  mut app: Command,
   bare: bool,
 ) -> clap::error::Result<()> {
   runtime_args_parse(flags, matches, true, true)?;
@@ -4701,11 +4701,16 @@ fn run_parse(
       "[SCRIPT_ARG] may only be omitted with --v8-flags=--help, else to use the repl with arguments, please use the `deno repl` subcommand",
     ));
   } else {
-    flags.subcommand = DenoSubcommand::Task(TaskFlags {
-      cwd: None,
-      task: None,
-      is_run: true,
-    });
+    return Err(
+      app
+        .get_subcommands_mut()
+        .find(|subcommand| subcommand.get_name() == "run")
+        .unwrap()
+        .error(
+          clap::error::ErrorKind::MissingRequiredArgument,
+          "[SCRIPT_ARG] may only be omitted with --v8-flags=--help",
+        ),
+    );
   }
 
   Ok(())
@@ -5927,7 +5932,7 @@ mod tests {
     );
 
     let r = flags_from_vec(svec!["deno", "run", "--v8-flags=--expose-gc"]);
-    assert!(r.is_ok());
+    assert!(r.is_err());
   }
 
   #[test]

filename: cli/tools/task.rs
patch: @@ -36,19 +36,7 @@ pub async fn execute_script(
   let cli_options = factory.cli_options()?;
   let start_dir = &cli_options.start_dir;
   if !start_dir.has_deno_or_pkg_json() {
-    if task_flags.is_run {
-      bail!(
-        r#"deno run couldn't find deno.json(c).
-If you meant to run a script, specify it, e.g., `deno run ./script.ts`.
-To run a task, ensure the config file exists.
-Examples:
-- Script: `deno run ./script.ts`
-- Task: `deno run dev`
-See https://docs.deno.com/go/config"#
-      )
-    } else {
-      bail!("deno task couldn't find deno.json(c). See https://docs.deno.com/go/config")
-    }
+    bail!("deno task couldn't find deno.json(c). See https://docs.deno.com/go/config")
   }
   let force_use_pkg_json =
     std::env::var_os(crate::task_runner::USE_PKG_JSON_HIDDEN_ENV_VAR_NAME)

filename: tests/specs/run/run_task/__test__.jsonc
patch: @@ -1,5 +1,10 @@
 {
   "tests": {
+    "deno_run_empty": {
+      "args": "run",
+      "output": "empty.out",
+      "exitCode": 1
+    },
     "deno_run_task": {
       "args": "run main",
       "output": "main.out"

filename: tests/specs/run/run_task/empty.out
patch: @@ -0,0 +1,4 @@
+error: [SCRIPT_ARG] may only be omitted with --v8-flags=--help
+
+Usage: deno run [OPTIONS] [SCRIPT_ARG]...
+
Repository: huggingface/transformers
Pull request: [Temporary] Log some information in some pytest/pluggy internal places

# What does this PR do?

We get 

> Too long with no output (exceeded 10m0s): context deadline exceeded

from time to time. It's very unclear how could this happen. It might be pytest, pytest's plugin, our code, or even the `tee` command.

This time, let's monitor some progresses in pytest and see if we can get more information when this happens again.

Changed files:
filename: .circleci/create_circleci_config.py
patch: @@ -110,6 +110,7 @@ def __post_init__(self):
             print(f"Using {self.docker_image} docker image")
         if self.install_steps is None:
             self.install_steps = ["uv venv && uv pip install ."]
+        self.install_steps.append("uv venv && uv pip install git+https://github.com/ydshieh/pytest.git@8.3.5-ydshieh git+https://github.com/ydshieh/pluggy.git@1.5.0-ydshieh")
         if self.pytest_options is None:
             self.pytest_options = {}
         if isinstance(self.tests_to_run, str):
Repository: ggml-org/llama.cpp
Pull request: ggml: check if non-native endian model is being loaded

This PR adds more descriptive error messages for when a non-native endian model is being loaded on the host system.

### Verification
To ensure that this implementation did not break anything, this PR has been tested on the following systems:
1. IBM z15 Mainframe (16 IFLs / 160 RAIM / NOSMT / LPAR)
2. M3 MacBook Air (8 Cores / 16 GB / SMT)
3. Kindly request additional systems to be tested in this PR

| System                        | Granite 3.1 2B Instruct LE Model | Granite 3.1 2B Instruct BE Model |
|-------------------------------|----------------------------------|----------------------------------|
| IBM z15 Mainframe (BE System) | ❌ Does not load (Expected)       | ✅ Loads (Expected)               |
| M3 MacBook Air (LE System)    | ✅ Loads (Expected)               | ❌ Does not load (Expected)       |

Changed files:
filename: ggml/src/gguf.cpp
patch: @@ -347,6 +347,20 @@ struct gguf_context * gguf_init_from_file_impl(FILE * file, struct gguf_init_par
     int64_t n_tensors = 0;
 
     if (ok && gr.read(ctx->version)) {
+        /*
+         * bit layout is different when reading non-native endian models.
+         * assuming that the GGUF version is 3, the non-native endian model
+         * would read it as 0x30000000. we can use the AND operation against
+         * the last 4 hexadecimal digits to check if the model is the same
+         * endianness as the host system.
+        */
+        if ((ctx->version & 0x0000FFFF) == 0x00000000) {
+            GGML_LOG_ERROR("%s: failed to load model: this GGUF file version %" PRIu32 " is extremely large, is there a mismatch between the host and model endianness?\n", __func__, ctx->version);
+            gguf_free(ctx);
+            return nullptr;
+        }
+
+        GGML_ASSERT(ctx->version > 0 && ctx->version <= 65535);
         if (ctx->version == 1) {
             GGML_LOG_ERROR("%s: GGUFv1 is no longer supported, please use a more up-to-date version\n", __func__);
             ok = false;
Repository: vercel/next.js
Pull request: [build-sourcemaps] Remove unused static workers

These workers are spawned without actually doing something. Should be safe to remove. Or have a comment why they're needed still.

Became unused in https://github.com/vercel/next.js/pull/68546

Changed files:
filename: packages/next/src/build/index.ts
patch: @@ -783,9 +783,6 @@ async function writeFullyStaticExport(
   const exportApp = require('../export')
     .default as typeof import('../export').default
 
-  const pagesWorker = createStaticWorker(config)
-  const appWorker = createStaticWorker(config)
-
   await exportApp(
     dir,
     {
@@ -798,9 +795,6 @@ async function writeFullyStaticExport(
     },
     nextBuildSpan
   )
-
-  pagesWorker.end()
-  appWorker.end()
 }
 
 async function getBuildId(
Repository: denoland/deno
Pull request: tests: fix upgrade canary test

<!--
Before submitting a PR, please read https://docs.deno.com/runtime/manual/references/contributing

1. Give the PR a descriptive title.

  Examples of good title:
    - fix(std/http): Fix race condition in server
    - docs(console): Update docstrings
    - feat(doc): Handle nested reexports

  Examples of bad title:
    - fix #7123
    - update docs
    - fix bugs

2. Ensure there is a related issue and it is referenced in the PR text.
3. Ensure there are tests that cover the changes.
4. Ensure `cargo test` passes.
5. Ensure `./tools/format.js` passes without changing files.
6. Ensure `./tools/lint.js` passes.
7. Open as a draft PR if your work is still in progress. The CI won't run
   all steps, but you can add '[ci]' to a commit message to force it to.
8. If you would like to run the benchmarks on the CI, add the 'ci-bench' label.
-->


Changed files:
filename: tests/specs/upgrade/canary/__test__.jsonc
patch: @@ -8,7 +8,7 @@
     },
     {
       "commandName": "./deno_copy",
-      "args": "upgrade --canary",
+      "args": "upgrade --canary --force",
       "output": "upgrade.out",
       "exitCode": 0,
       "flaky": true
Repository: vercel/next.js
Pull request: Turbopack: remove unused `EcmascriptInputTransform::CommonJs`

Remove dead code

Shouldn't be needed anymore as Turbopack handles ESM and CJS explicitly now, no need to transpile beforehand

Closes PACK-4603

Changed files:
filename: turbopack/crates/turbopack-ecmascript/src/transform/mod.rs
patch: @@ -29,7 +29,6 @@ use turbopack_core::{
 #[turbo_tasks::value(serialization = "auto_for_input")]
 #[derive(Debug, Clone, Hash)]
 pub enum EcmascriptInputTransform {
-    CommonJs,
     Plugin(ResolvedVc<TransformPlugin>),
     PresetEnv(ResolvedVc<Environment>),
     React {
@@ -209,22 +208,6 @@ impl EcmascriptInputTransform {
                     }
                 }
             }
-            EcmascriptInputTransform::CommonJs => {
-                // Explicit type annotation to ensure that we don't duplicate transforms in the
-                // final binary
-                program.mutate(swc_core::ecma::transforms::module::common_js(
-                    swc_core::ecma::transforms::module::path::Resolver::Default,
-                    unresolved_mark,
-                    swc_core::ecma::transforms::module::util::Config {
-                        allow_top_level_this: true,
-                        import_interop: Some(
-                            swc_core::ecma::transforms::module::util::ImportInterop::Swc,
-                        ),
-                        ..Default::default()
-                    },
-                    swc_core::ecma::transforms::base::feature::FeatureFlag::all(),
-                ));
-            }
             EcmascriptInputTransform::PresetEnv(env) => {
                 let versions = env.runtime_versions().await?;
                 let config = swc_core::ecma::preset_env::Config {
Repository: nodejs/node
Pull request: tools: do not throw on missing `create-release-proposal.sh`

<!--
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/workflows/create-release-proposal.yml
patch: @@ -71,9 +71,11 @@ jobs:
           git config --local user.name "Node.js GitHub Bot"
 
       - name: Start git node release prepare
+        # `git update-index` tells git to ignore future changes to the `.sh` file,
+        # `|| true` is there to ignore the error if such file doesn't exist yet.
         # The curl command is to make sure we run the version of the script corresponding to the current workflow.
         run: |
-          git update-index --assume-unchanged tools/actions/create-release-proposal.sh
+          git update-index --assume-unchanged tools/actions/create-release-proposal.sh || true
           curl -fsSLo tools/actions/create-release-proposal.sh https://github.com/${GITHUB_REPOSITORY}/raw/${GITHUB_SHA}/tools/actions/create-release-proposal.sh
           ./tools/actions/create-release-proposal.sh "${RELEASE_DATE}" "${RELEASE_LINE}" "${GITHUB_ACTOR}"
         env:
Repository: vercel/next.js
Pull request: [test] Add `debug-brk` package script

Just like `pnpm debug` but instead of `--inspect` we pass `--inspect-brk` to Node.js.

Changed files:
filename: package.json
patch: @@ -62,6 +62,7 @@
     "next-no-sourcemaps": "echo 'No longer supported. Use `pnpm next --disable-source-maps` instead'; exit 1;",
     "clean-trace-jaeger": "node scripts/rm.mjs test/integration/basic/.next && TRACE_TARGET=JAEGER pnpm next build test/integration/basic",
     "debug": "cross-env NEXT_PRIVATE_LOCAL_DEV=1 NEXT_TELEMETRY_DISABLED=1 node --inspect --trace-deprecation --enable-source-maps packages/next/dist/bin/next",
+    "debug-brk": "cross-env NEXT_PRIVATE_LOCAL_DEV=1 NEXT_TELEMETRY_DISABLED=1 node --inspect-brk --trace-deprecation --enable-source-maps packages/next/dist/bin/next",
     "postinstall": "node scripts/git-configure.mjs && node scripts/install-native.mjs",
     "version": "pnpm install --no-frozen-lockfile && IS_PUBLISH=yes ./scripts/check-pre-compiled.sh && git add .",
     "prepare": "husky",

filename: test/lib/create-next-install.js
patch: @@ -152,6 +152,7 @@ async function createNextInstall({
 
       const scripts = {
         debug: `NEXT_PRIVATE_SKIP_CANARY_CHECK=1 NEXT_TELEMETRY_DISABLED=1 NEXT_TEST_NATIVE_DIR=${process.env.NEXT_TEST_NATIVE_DIR} node --inspect --trace-deprecation --enable-source-maps node_modules/next/dist/bin/next`,
+        'debug-brk': `NEXT_PRIVATE_SKIP_CANARY_CHECK=1 NEXT_TELEMETRY_DISABLED=1 NEXT_TEST_NATIVE_DIR=${process.env.NEXT_TEST_NATIVE_DIR} node --inspect-brk --trace-deprecation --enable-source-maps node_modules/next/dist/bin/next`,
         ...packageJson.scripts,
       }
Repository: denoland/deno
Pull request: tests: re-enable WebGPU tests on macOS aarch64

The reason for disabling on macOS x64 is not relevant for macOS aarch64.

Changed files:
filename: tests/unit/webgpu_test.ts
patch: @@ -10,15 +10,15 @@ try {
 }
 
 // Skip these tests on linux CI, because the vulkan emulator is not good enough
-// yet, and skip on macOS CI because these do not have virtual GPUs.
-const isLinuxOrMacCI =
-  (Deno.build.os === "linux" || Deno.build.os === "darwin") && isCI;
+// yet, and skip on macOS x86 CI because these do not have virtual GPUs.
+const isCIWithoutGPU = (Deno.build.os === "linux" ||
+  (Deno.build.os === "darwin" && Deno.build.arch === "x86_64")) && isCI;
 // Skip these tests in WSL because it doesn't have good GPU support.
 const isWsl = await checkIsWsl();
 
 Deno.test({
   permissions: { read: true, env: true },
-  ignore: isWsl || isLinuxOrMacCI,
+  ignore: isWsl || isCIWithoutGPU,
 }, async function webgpuComputePass() {
   const adapter = await navigator.gpu.requestAdapter();
   assert(adapter);
@@ -104,7 +104,7 @@ Deno.test({
 
 Deno.test({
   permissions: { read: true, env: true },
-  ignore: isWsl || isLinuxOrMacCI,
+  ignore: isWsl || isCIWithoutGPU,
 }, async function webgpuHelloTriangle() {
   const adapter = await navigator.gpu.requestAdapter();
   assert(adapter);
@@ -216,7 +216,7 @@ Deno.test({
 });
 
 Deno.test({
-  ignore: isWsl || isLinuxOrMacCI,
+  ignore: isWsl || isCIWithoutGPU,
 }, async function webgpuAdapterHasFeatures() {
   const adapter = await navigator.gpu.requestAdapter();
   assert(adapter);
@@ -226,7 +226,7 @@ Deno.test({
 });
 
 Deno.test({
-  ignore: isWsl || isLinuxOrMacCI,
+  ignore: isWsl || isCIWithoutGPU,
 }, async function webgpuNullWindowSurfaceThrows() {
   const adapter = await navigator.gpu.requestAdapter();
   assert(adapter);
@@ -249,7 +249,7 @@ Deno.test(function getPreferredCanvasFormat() {
 });
 
 Deno.test({
-  ignore: isWsl || isLinuxOrMacCI,
+  ignore: isWsl || isCIWithoutGPU,
 }, async function validateGPUColor() {
   const adapter = await navigator.gpu.requestAdapter();
   assert(adapter);
@@ -312,7 +312,7 @@ Deno.test({
 });
 
 Deno.test({
-  ignore: isWsl || isLinuxOrMacCI,
+  ignore: isWsl || isCIWithoutGPU,
 }, async function validateGPUExtent3D() {
   const adapter = await navigator.gpu.requestAdapter();
   assert(adapter);
@@ -412,7 +412,7 @@ Deno.test({
 });
 
 Deno.test({
-  ignore: isWsl || isLinuxOrMacCI,
+  ignore: isWsl || isCIWithoutGPU,
 }, async function validateGPUOrigin3D() {
   const adapter = await navigator.gpu.requestAdapter();
   assert(adapter);
@@ -505,7 +505,7 @@ Deno.test({
 });
 
 Deno.test({
-  ignore: isWsl || isLinuxOrMacCI,
+  ignore: isWsl || isCIWithoutGPU,
 }, async function beginRenderPassWithoutDepthClearValue() {
   const adapter = await navigator.gpu.requestAdapter();
   assert(adapter);