helloadhavan/github_issues huggingface dataset:
Repository: vercel/next.js
Pull request: Revert "fix(router): support BigInt in query parameters"

Reverts vercel/next.js#89213

vercel/next.js#89213 is missing the deserialization part which has security (DoS) implications: Deserializing BigInts needs to be limited since unreasonably large numbers (500+ digits) take a lot of blocking CPU time (upwards of 50ms).

If people really want to put BigInt into their search params, they can call .toString themselves and deserialize it. But since this makes a DDoS pretty trivial, we don't want to encourage BigInt for search params unless Next.js can make deserialization safe.

Changed files:
filename: packages/next/src/shared/lib/router/utils/querystring.ts
patch: @@ -24,8 +24,7 @@ function stringifyUrlQueryParam(param: unknown): string {
 
   if (
     (typeof param === 'number' && !isNaN(param)) ||
-    typeof param === 'boolean' ||
-    typeof param === 'bigint'
+    typeof param === 'boolean'
   ) {
     return String(param)
   } else {
Repository: huggingface/transformers
Pull request: Fix `make_batched_video` with 5D arrays

# What does this PR do?

As per title, it was not working when input was a batched 5D array

Fixes https://github.com/huggingface/transformers/issues/43450

Changed files:
filename: src/transformers/video_utils.py
patch: @@ -200,7 +200,9 @@ def make_batched_videos(videos) -> list[Union[np.ndarray, "torch.Tensor", "URL",
     except (IndexError, TypeError):
         pass
 
-    if isinstance(videos, str) or is_valid_video(videos):
+    if is_batched_video(videos):
+        return convert_pil_frames_to_video(list(videos))
+    elif isinstance(videos, str) or is_valid_video(videos):
         return convert_pil_frames_to_video([videos])
     # only one frame passed, thus we unsqueeze time dim
     elif is_valid_image(videos):

filename: tests/utils/test_video_utils.py
patch: @@ -101,10 +101,20 @@ def test_make_batched_videos_numpy(self):
         video = get_random_video(16, 32)
         videos_list = make_batched_videos(video)
         self.assertIsInstance(videos_list, list)
+        self.assertTrue(len(videos_list), 1)
         self.assertIsInstance(videos_list[0], np.ndarray)
         self.assertEqual(videos_list[0].shape, (8, 16, 32, 3))
         self.assertTrue(np.array_equal(videos_list[0], video))
 
+        # Test a 5d array of batch videos is converted to a list of videos
+        video = video[None, ...].repeat(4, 0)
+        videos_list = make_batched_videos(video)
+        self.assertIsInstance(videos_list, list)
+        self.assertTrue(len(videos_list), 4)
+        self.assertIsInstance(videos_list[0], np.ndarray)
+        self.assertEqual(videos_list[0].shape, (8, 16, 32, 3))
+        self.assertTrue(np.array_equal(videos_list[0], video[0]))
+
         # Test a list of videos is converted to a list of videos
         video = get_random_video(16, 32)
         videos = [video, video]
@@ -130,6 +140,16 @@ def test_make_batched_videos_torch(self):
         torch_video = torch.from_numpy(video)
         videos_list = make_batched_videos(torch_video)
         self.assertIsInstance(videos_list, list)
+        self.assertTrue(len(videos_list), 1)
+        self.assertIsInstance(videos_list[0], torch.Tensor)
+        self.assertEqual(videos_list[0].shape, (8, 16, 32, 3))
+        self.assertTrue(np.array_equal(videos_list[0], video))
+
+        # Test a 5d array of batch videos is converted to a list of videos
+        torch_video = torch_video[None, ...].repeat(4, 1, 1, 1, 1)
+        videos_list = make_batched_videos(torch_video)
+        self.assertIsInstance(videos_list, list)
+        self.assertTrue(len(videos_list), 4)
         self.assertIsInstance(videos_list[0], torch.Tensor)
         self.assertEqual(videos_list[0].shape, (8, 16, 32, 3))
         self.assertTrue(np.array_equal(videos_list[0], video))
Repository: ollama/ollama
Pull request: server: send 405 instead of 404 for unallowed methods

Fixes: #5483

Changed files:
filename: server/routes.go
patch: @@ -1170,6 +1170,7 @@ func (s *Server) GenerateRoutes(rc *ollama.Registry) (http.Handler, error) {
 	corsConfig.AllowOrigins = envconfig.AllowedOrigins()
 
 	r := gin.Default()
+	r.HandleMethodNotAllowed = true
 	r.Use(
 		cors.New(corsConfig),
 		allowedHostsMiddleware(s.addr),

filename: server/routes_test.go
patch: @@ -485,6 +485,16 @@ func TestRoutes(t *testing.T) {
 				}
 			},
 		},
+		{
+			Name:   "Method Not Allowed",
+			Method: http.MethodGet,
+			Path:   "/api/show",
+			Expected: func(t *testing.T, resp *http.Response) {
+				if resp.StatusCode != 405 {
+					t.Errorf("expected status code 405, got %d", resp.StatusCode)
+				}
+			},
+		},
 	}
 
 	modelsDir := t.TempDir()
Repository: vuejs/vue
Pull request: fix(types): allow string for watch handlers

**What kind of change does this PR introduce?** (check at least one)

- [x] Bugfix
- [ ] Feature
- [ ] Code style update
- [ ] Refactor
- [ ] Build-related changes
- [ ] Other, please describe:

**Does this PR introduce a breaking change?** (check one)

- [ ] Yes
- [x] No

If yes, please describe the impact and migration path for existing applications:

**The PR fulfills these requirements:**

- [x] It's submitted to the `dev` branch for v2.x (or to a previous version branch), _not_ the `master` branch
- [ ] When resolving a specific issue, it's referenced in the PR's title (e.g. `fix #xxx[,#xxx]`, where "xxx" is the issue number)
- [x] All tests are passing: https://github.com/vuejs/vue/blob/dev/.github/CONTRIBUTING.md#development-setup
- [x] New/updated tests are included

If adding a **new feature**, the PR's description includes:
- [ ] A convincing reason for adding this feature (to avoid wasting your time, it's best to open a suggestion issue first and wait for approval before working on it)

**Other information:**

Adds missing TypeScript type info allowing watcher handler to be of `string` type

Changed files:
filename: types/options.d.ts
patch: @@ -76,7 +76,7 @@ export interface ComponentOptions<
   propsData?: object;
   computed?: Accessors<Computed>;
   methods?: Methods;
-  watch?: Record<string, WatchOptionsWithHandler<any> | WatchHandler<any> | string>;
+  watch?: Record<string, WatchOptionsWithHandler<any> | WatchHandler<any>>;
 
   el?: Element | string;
   template?: string;
@@ -169,7 +169,7 @@ export interface ComputedOptions<T> {
   cache?: boolean;
 }
 
-export type WatchHandler<T> = (val: T, oldVal: T) => void;
+export type WatchHandler<T> = string | ((val: T, oldVal: T) => void);
 
 export interface WatchOptions {
   deep?: boolean;

filename: types/test/options-test.ts
patch: @@ -168,6 +168,10 @@ Vue.component('component', {
         this.a = val
       },
       deep: true
+    },
+    d: {
+      handler: 'someMethod',
+      immediate: true
     }
   },
   el: "#app",
Repository: nodejs/node
Pull request: doc: `sea.getRawAsset(key)` always returns an ArrayBuffer

`sea.getRawAsset(key)` always returns ArrayBuffer, not string. The return type in the documentation is wrong.

https://github.com/nodejs/node/blob/bd3c25cf31282f101196c0808cbf9267fb3f9bcd/src/node_sea.cc#L600

https://github.com/nodejs/node/blob/bd3c25cf31282f101196c0808cbf9267fb3f9bcd/lib/sea.js#L15-L35

cc @nodejs/single-executable

Changed files:
filename: doc/api/single-executable-applications.md
patch: @@ -352,7 +352,7 @@ writes to the returned array buffer is likely to result in a crash.
 
 * `key`  {string} the key for the asset in the dictionary specified by the
   `assets` field in the single-executable application configuration.
-* Returns: {string|ArrayBuffer}
+* Returns: {ArrayBuffer}
 
 ### `require(id)` in the injected main script is not file based
Repository: vercel/next.js
Pull request: fix(build): format runAfterProductionCompile duration as human-readable time

This change should unifiy the runAfterProductionCompile output to follow the same style as other times printed in the build logs. 

Currently build logs look like
```
✓ Compiled successfully in 89s
  Running next.config.js provided runAfterProductionCompile ...
✓ Finished writing to filesystem cache in 18.5s
✓ Completed runAfterProductionCompile in 36134ms
  Skipping validation of types
```

I hope they will now look like
```
✓ Compiled successfully in 89s
  Running next.config.js provided runAfterProductionCompile ...
✓ Finished writing to filesystem cache in 18.5s
✓ Completed runAfterProductionCompile in 36.1s
  Skipping validation of types
```

(and yes i know 36s is shameful thats my next problem but this irked me enough to want the build output looking nicer ahhaha)

It feels like adding a test for this would be semi counter productive without basically ending up adding sleeps and then in reality its testing more the logic of `durationToStringWithNanoseconds`.

Changed files:
filename: packages/next/src/build/after-production-compile.ts
patch: @@ -6,6 +6,7 @@ import createSpinner from './spinner'
 import isError from '../lib/is-error'
 import type { Telemetry } from '../telemetry/storage'
 import { EVENT_BUILD_FEATURE_USAGE } from '../telemetry/events/build'
+import { hrtimeBigIntDurationToString } from './duration-to-string'
 
 // TODO: refactor this to account for more compiler lifecycle events
 // such as beforeProductionBuild, but for now this is the only one that is needed
@@ -41,14 +42,14 @@ export async function runAfterProductionCompile({
   )
 
   try {
-    const startTime = performance.now()
+    const startTime = process.hrtime.bigint()
     await buildSpan
       .traceChild('after-production-compile')
       .traceAsyncFn(async () => {
         await run(metadata)
       })
-    const duration = performance.now() - startTime
-    const formattedDuration = `${Math.round(duration)}ms`
+    const duration = process.hrtime.bigint() - startTime
+    const formattedDuration = hrtimeBigIntDurationToString(duration)
     Log.event(`Completed runAfterProductionCompile in ${formattedDuration}`)
   } catch (err) {
     // Handle specific known errors differently if needed
Repository: facebook/react
Pull request: [DevTools] Clean up Virtual Instances from id map

This was a pretty glaring memory leak. 🙈

I forgot to clean up the VirtualInstances from the id map so the Server Component instances always leaked in DEV.

Changed files:
filename: packages/react-devtools-shared/src/backend/fiber/renderer.js
patch: @@ -2749,6 +2749,8 @@ export function attach(
 
     const id = instance.id;
     pendingRealUnmountedIDs.push(id);
+
+    idToDevToolsInstanceMap.delete(instance.id);
   }
 
   function getSecondaryEnvironmentName(
Repository: ollama/ollama
Pull request: discover: fix compiler warnings


Changed files:
filename: discover/gpu_info.h
patch: @@ -27,12 +27,14 @@
 
 #endif
 
+#ifndef LOG
 #define LOG(verbose, ...) \
   do { \
     if (verbose) { \
       fprintf(stderr, __VA_ARGS__); \
     } \
   } while (0)
+#endif
 
 #ifdef __cplusplus
 extern "C" {

filename: discover/gpu_info_cudart.c
patch: @@ -1,6 +1,7 @@
 #ifndef __APPLE__  // TODO - maybe consider nvidia support on intel macs?
 
 #include <string.h>
+#include <inttypes.h>
 #include "gpu_info_cudart.h"
 
 void cudart_init(char *cudart_lib_path, cudart_init_resp_t *resp) {
@@ -168,9 +169,9 @@ void cudart_bootstrap(cudart_handle_t h, int i, mem_info_t *resp) {
   resp->free = memInfo.free;
   resp->used = memInfo.used;
 
-  LOG(h.verbose, "[%s] CUDA totalMem %llu\n", resp->gpu_id, resp->total);
-  LOG(h.verbose, "[%s] CUDA freeMem %llu\n", resp->gpu_id, resp->free);
-  LOG(h.verbose, "[%s] CUDA usedMem %llu\n", resp->gpu_id, resp->used);
+  LOG(h.verbose, "[%s] CUDA totalMem %" PRId64 "\n", resp->gpu_id, resp->total);
+  LOG(h.verbose, "[%s] CUDA freeMem %" PRId64 "\n", resp->gpu_id, resp->free);
+  LOG(h.verbose, "[%s] CUDA usedMem %" PRId64 "\n", resp->gpu_id, resp->used);
   LOG(h.verbose, "[%s] Compute Capability %d.%d\n", resp->gpu_id, resp->major, resp->minor);
 }
 
@@ -180,4 +181,4 @@ void cudart_release(cudart_handle_t h) {
   h.handle = NULL;
 }
 
-#endif  // __APPLE__
\ No newline at end of file
+#endif  // __APPLE__

filename: discover/gpu_info_nvcuda.c
patch: @@ -1,6 +1,7 @@
 #ifndef __APPLE__  // TODO - maybe consider nvidia support on intel macs?
 
 #include <string.h>
+#include <inttypes.h>
 #include "gpu_info_nvcuda.h"
 
 void nvcuda_init(char *nvcuda_lib_path, nvcuda_init_resp_t *resp) {
@@ -193,8 +194,8 @@ void nvcuda_bootstrap(nvcuda_handle_t h, int i, mem_info_t *resp) {
   resp->total = memInfo.total;
   resp->free = memInfo.free;
 
-  LOG(h.verbose, "[%s] CUDA totalMem %llu mb\n", resp->gpu_id, resp->total / 1024 / 1024);
-  LOG(h.verbose, "[%s] CUDA freeMem %llu mb\n", resp->gpu_id, resp->free / 1024 / 1024);
+  LOG(h.verbose, "[%s] CUDA totalMem %" PRId64 "mb\n", resp->gpu_id, resp->total / 1024 / 1024);
+  LOG(h.verbose, "[%s] CUDA freeMem %" PRId64 "mb\n", resp->gpu_id, resp->free / 1024 / 1024);
   LOG(h.verbose, "[%s] Compute Capability %d.%d\n", resp->gpu_id, resp->major, resp->minor);
 
   
@@ -247,4 +248,4 @@ void nvcuda_release(nvcuda_handle_t h) {
   h.handle = NULL;
 }
 
-#endif  // __APPLE__
\ No newline at end of file
+#endif  // __APPLE__
Repository: nodejs/node
Pull request:  tools: move Quic dependencies behind ad-hoc flag

Refs: https://github.com/nodejs/node/commit/853277a9e22a88307ca7b9fde0025635e368253c
<!--
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: shell.nix
patch: @@ -12,12 +12,14 @@
   # Build options
   icu ? pkgs.icu,
   withAmaro ? true,
+  withQuic ? false,
   withSQLite ? true,
   withSSL ? true,
   withTemporal ? false,
   sharedLibDeps ? import ./tools/nix/sharedLibDeps.nix {
     inherit
       pkgs
+      withQuic
       withSQLite
       withSSL
       withTemporal
@@ -80,6 +82,7 @@ pkgs.mkShell {
     ]
     ++ extraConfigFlags
     ++ pkgs.lib.optional (!withAmaro) "--without-amaro"
+    ++ pkgs.lib.optional withQuic "--experimental-quic"
     ++ pkgs.lib.optional (!withSQLite) "--without-sqlite"
     ++ pkgs.lib.optional (!withSSL) "--without-ssl"
     ++ pkgs.lib.optional withTemporal "--v8-enable-temporal-support"

filename: tools/nix/sharedLibDeps.nix
patch: @@ -1,5 +1,6 @@
 {
   pkgs ? import ./pkgs.nix { },
+  withQuic ? false,
   withSQLite ? true,
   withSSL ? true,
   withTemporal ? false,
@@ -11,8 +12,6 @@
     gtest
     libuv
     nbytes
-    nghttp3
-    ngtcp2
     simdjson
     simdutf
     uvwasi
@@ -33,6 +32,12 @@
     ];
   };
 }
+// (pkgs.lib.optionalAttrs withQuic {
+  inherit (pkgs)
+    nghttp3
+    ngtcp2
+    ;
+})
 // (pkgs.lib.optionalAttrs withSQLite {
   inherit (pkgs) sqlite;
 })
Repository: nodejs/node
Pull request: tools: fix linter warning in `test-shared.yml`

Fixes: https://github.com/nodejs/node/pull/60766#issuecomment-3546358893
<!--
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/test-shared.yml
patch: @@ -131,7 +131,7 @@ jobs:
         with:
           extra_nix_config: sandbox = true
 
-      - uses: cachix/cachix-action@0fc020193b5a1fa3ac4575aa3a7d3aa6a35435ad # v16
+      - uses: cachix/cachix-action@0fc020193b5a1fa3ac4575aa3a7d3aa6a35435ad  # v16
         with:
           name: nodejs
           authToken: ${{ secrets.CACHIX_AUTH_TOKEN }}
Repository: ggml-org/llama.cpp
Pull request: ci : add action for finding duplicate issues

When a new issue is opened, a Github Action searches for similar issues and links them in a comment.

The idea is the same as the one in [OpenCode](https://github.com/anomalyco/opencode/blob/5a0bfa70616a55e4d3ffcfd74fddbe02abcb46c7/.github/workflows/duplicate-issues.yml). However this implementation runs the inference locally on self-hosted runners.

Here is an example: https://github.com/ggml-org/tmp/issues/8

Changed files:
filename: .github/workflows/ai-issues.yml
patch: @@ -0,0 +1,71 @@
+name: AI review (issues)
+
+on:
+  issues:
+    types: [opened]
+
+jobs:
+  find-duplicates:
+    if: github.event.action == 'opened'
+    runs-on: [self-hosted, opencode]
+
+    permissions:
+      contents: read
+      issues: write
+
+    steps:
+      - name: Checkout repository
+        uses: actions/checkout@v6
+        with:
+          fetch-depth: 1
+
+      - name: Find duplicates
+        env:
+          GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
+          OPENCODE_PERMISSION: |
+            {
+              "bash": {
+                "*": "deny",
+                "gh issue*": "allow"
+              },
+              "webfetch": "deny"
+            }
+        run: |
+          opencode run -m llama.cpp-dgx/gpt-oss-120b-hf-low "A new issue has been created:
+
+          Issue number: ${{ github.event.issue.number }}
+
+          Lookup this issue with gh issue view ${{ github.event.issue.number }}.
+
+          Perform the following task and then post a SINGLE comment (if needed).
+
+          ---
+
+          TASK : DUPLICATE CHECK
+
+          Search through existing issues (excluding #${{ github.event.issue.number }}) to find potential duplicates.
+          Consider:
+          1. Similar titles or descriptions
+          2. Same error messages or symptoms
+          3. Related functionality or components
+          4. Similar feature requests
+
+          ---
+
+          POSTING YOUR COMMENT:
+
+          Based on your findings, post a SINGLE comment on issue #${{ github.event.issue.number }}. Build the comment as follows:
+
+          If no duplicates were found, do NOT comment at all.
+
+          If duplicates were found, include a section about potential duplicates with links using the following format:
+
+          [comment]
+          This issue might be a duplicate of:
+          - #[issue_number]: [brief description of similarity]
+
+          _This comment was auto-generated locally using **$GA_ENGINE** on **$GA_MACHINE**_
+          [/comment]
+
+          Remember: Do not include the comment tags in your actual comment. Post at most ONE comment combining all findings. If everything is fine, post nothing.
+          "
Repository: ollama/ollama
Pull request: ggml: Reduce log level of "key not found"

Most of the time this is not an error.

Changed files:
filename: fs/ggml/ggml.go
patch: @@ -149,7 +149,7 @@ func keyValue[T valueTypes | arrayValueTypes](kv KV, key string, defaultValue ..
 		return val.(T)
 	}
 
-	slog.Warn("key not found", "key", key, "default", defaultValue[0])
+	slog.Debug("key not found", "key", key, "default", defaultValue[0])
 	return defaultValue[0]
 }
Repository: nodejs/node
Pull request: doc: restore @ChALkeR to collaborators

Hi

Per [Governance](https://github.com/nodejs/node/blob/main/GOVERNANCE.md), this needs TSC approval.

Changed files:
filename: README.md
patch: @@ -305,6 +305,8 @@ For information about the governance of the Node.js project, see
   **Ruben Bridgewater** <<ruben@bridgewater.de>> (he/him)
 * [cclauss](https://github.com/cclauss) -
   **Christian Clauss** <<cclauss@me.com>> (he/him)
+* [ChALkeR](https://github.com/ChALkeR) -
+  **Сковорода Никита Андреевич** <<chalkerx@gmail.com>> (he/him)
 * [cjihrig](https://github.com/cjihrig) -
   **Colin Ihrig** <<cjihrig@gmail.com>> (he/him)
 * [codebytere](https://github.com/codebytere) -
@@ -499,8 +501,6 @@ For information about the governance of the Node.js project, see
   **Bartosz Sosnowski** <<bartosz@janeasystems.com>>
 * [calvinmetcalf](https://github.com/calvinmetcalf) -
   **Calvin Metcalf** <<calvin.metcalf@gmail.com>>
-* [ChALkeR](https://github.com/ChALkeR) -
-  **Сковорода Никита Андреевич** <<chalkerx@gmail.com>> (he/him)
 * [chrisdickinson](https://github.com/chrisdickinson) -
   **Chris Dickinson** <<christopher.s.dickinson@gmail.com>>
 * [claudiorodriguez](https://github.com/claudiorodriguez) -
Repository: ollama/ollama
Pull request: win: lint fix


Changed files:
filename: llm/llm_windows.go
patch: @@ -7,7 +7,7 @@ import (
 const (
 	CREATE_DEFAULT_ERROR_MODE   = 0x04000000
 	ABOVE_NORMAL_PRIORITY_CLASS = 0x00008000
-       CREATE_NO_WINDOW            = 0x08000000
+	CREATE_NO_WINDOW            = 0x08000000
 )
 
 var LlamaServerSysProcAttr = &syscall.SysProcAttr{