helloadhavan/github_issues huggingface dataset:
Repository: ollama/ollama
Pull request: runner: always truncate embeddings requests

Fixes https://github.com/ollama/ollama/issues/12710

Truncation currently happens in two places: in `routes.go` in the `server` package and also in the `runner` packages. However, the truncation logic isn't completely aligned, causing an error when truncation does occur. This change defaults the runner to always truncate (as it should have in https://github.com/ollama/ollama/pull/12582) until we remove truncation from the `server` package in order to only rely on truncation in the runner.

Changed files:
filename: integration/embed_test.go
patch: @@ -258,6 +258,19 @@ func TestAllMiniLMEmbedTruncate(t *testing.T) {
 				}
 			},
 		},
+		{
+			name: "boundary truncation",
+			request: api.EmbedRequest{
+				Model:   "all-minilm",
+				Input:   "why is the sky blue? Why is the sky blue? hi there my",
+				Options: map[string]any{"num_ctx": 16},
+			},
+			check: func(res *api.EmbedResponse, err error) {
+				if err != nil {
+					t.Fatal(err)
+				}
+			},
+		},
 	}
 
 	for _, req := range cases {

filename: runner/llamarunner/runner.go
patch: @@ -697,7 +697,14 @@ func (s *Server) embeddings(w http.ResponseWriter, r *http.Request) {
 
 	w.Header().Set("Content-Type", "application/json")
 
-	seq, err := s.NewSequence(req.Content, nil, NewSequenceParams{embedding: true})
+	seq, err := s.NewSequence(req.Content, nil, NewSequenceParams{
+		embedding: true,
+
+		// TODO (jmorganca): this should be provided by the server via the
+		// request options and truncated here in the runner, instead of relying on
+		// the server's truncate logic
+		truncate: true,
+	})
 	if err != nil {
 		http.Error(w, fmt.Sprintf("Failed to create new sequence: %v", err), http.StatusInternalServerError)
 		return

filename: runner/ollamarunner/runner.go
patch: @@ -946,7 +946,14 @@ func (s *Server) embeddings(w http.ResponseWriter, r *http.Request) {
 	}
 
 	w.Header().Set("Content-Type", "application/json")
-	seq, err := s.NewSequence(req.Content, nil, NewSequenceParams{embedding: true})
+	seq, err := s.NewSequence(req.Content, nil, NewSequenceParams{
+		embedding: true,
+
+		// TODO (jmorganca): this should be provided by the server via the
+		// request options and truncated here in the runner, instead of relying on
+		// the server's truncate logic
+		truncate: true,
+	})
 	if err != nil {
 		http.Error(w, fmt.Sprintf("failed to create new sequence: %v", err), http.StatusInternalServerError)
 		return
Repository: vercel/next.js
Pull request: Allow `reset()` from user's global-error

User's `global-error.js` is within the router. There's no reason it shouldn't have access to the options available to the `error.js` component. It was already available on prod. This PR syncs dev behavior to prod.

For the follow-up feature, `retry()` will also be available in `global-error.js`.

Changed files:
filename: packages/next/src/client/components/builtin/global-error.tsx
patch: @@ -5,6 +5,7 @@ import { errorStyles, errorThemeCss, ErrorIcon } from './error-styles'
 
 export type GlobalErrorComponent = React.ComponentType<{
   error: any
+  reset: () => void
 }>
 
 function DefaultGlobalError({ error }: { error: any }) {

filename: packages/next/src/client/components/error-boundary.tsx
patch: @@ -12,9 +12,7 @@ const isBotUserAgent =
 
 export type ErrorComponent = React.ComponentType<{
   error: Error
-  // global-error, there's no `reset` function;
-  // regular error boundary, there's a `reset` function.
-  reset?: () => void
+  reset: () => void
 }>
 
 export interface ErrorBoundaryProps {

filename: packages/next/src/next-devtools/userspace/app/app-dev-overlay-error-boundary.tsx
patch: @@ -18,9 +18,11 @@ type AppDevOverlayErrorBoundaryState = {
 function ErroredHtml({
   globalError: [GlobalError, globalErrorStyles],
   error,
+  reset,
 }: {
   globalError: GlobalErrorState
   error: unknown
+  reset: () => void
 }) {
   if (!error) {
     return (
@@ -33,7 +35,7 @@ function ErroredHtml({
   return (
     <ErrorBoundary errorComponent={DefaultGlobalError}>
       {globalErrorStyles}
-      <GlobalError error={error} />
+      <GlobalError error={error} reset={reset} />
     </ErrorBoundary>
   )
 }
@@ -62,12 +64,20 @@ export class AppDevOverlayErrorBoundary extends PureComponent<
     dispatcher.openErrorOverlay()
   }
 
+  reset = () => {
+    this.setState({ reactError: null })
+  }
+
   render() {
     const { children, globalError } = this.props
     const { reactError } = this.state
 
     const fallback = (
-      <ErroredHtml globalError={globalError} error={reactError} />
+      <ErroredHtml
+        globalError={globalError}
+        error={reactError}
+        reset={this.reset}
+      />
     )
 
     return reactError !== null ? fallback : children
Repository: ollama/ollama
Pull request: model/parsers: remove warning for missing <think> tag for qwen3-vl

The model does not output `<think>`, and so don't warn on this

Changed files:
filename: model/parsers/qwen3vl.go
patch: @@ -181,9 +181,6 @@ func (p *Qwen3VLParser) eat() ([]qwenEvent, bool) {
 			split := strings.SplitN(p.buffer.String(), thinkingCloseTag, 2)
 			// before := split[0]
 			before := strings.TrimRightFunc(split[0], unicode.IsSpace)
-			if len(before) == 0 {
-				slog.Warn("qwen tool call closing tag found but no content before it")
-			}
 			after := strings.TrimLeftFunc(split[1], unicode.IsSpace)
 			if len(before) > 0 {
 				events = append(events, qwenEventThinkingContent{content: before})
Repository: facebook/react
Pull request: [ci] Fix runtime_prereleases


When using the "only" or "skip" option in the workflow, we were adding the `--skipTests` param, but that isn't an actual option: https://github.com/facebook/react/blob/1de32a5e75fe96ac3c1b728a117010e11673f6ed/scripts/release/publish-commands/parse-params.js


Changed files:
filename: .github/workflows/runtime_prereleases.yml
patch: @@ -82,7 +82,6 @@ jobs:
         run: |
           scripts/release/publish.js \
             --ci \
-            --skipTests \
             --tags=${{ inputs.dist_tag }} \
             --onlyPackages=${{ inputs.only_packages }} ${{ (inputs.dry && '') || '\'}}
             ${{ inputs.dry && '--dry' || '' }}
@@ -91,7 +90,6 @@ jobs:
         run: |
           scripts/release/publish.js \
             --ci \
-            --skipTests \
             --tags=${{ inputs.dist_tag }} \
             --skipPackages=${{ inputs.skip_packages }} ${{ (inputs.dry && '') || '\'}}
             ${{ inputs.dry && '--dry' || '' }}
Repository: ollama/ollama
Pull request: rocm: give it more time to bootstrap

Some users are hitting timeouts.  We'd like to make this faster, but for now make sure we don't timeout too aggressively.

Changed files:
filename: discover/runner.go
patch: @@ -88,6 +88,7 @@ func GPUDevices(ctx context.Context, runners []FilteredRunnerDiscovery) []ml.Dev
 		// times concurrently leading to memory contention
 		// TODO refactor so we group the lib dirs and do serial per version, but parallel for different libs
 		for dir := range libDirs {
+			bootstrapTimeout := 30 * time.Second
 			var dirs []string
 			if dir != "" {
 				if requested != "" && filepath.Base(dir) != requested {
@@ -102,11 +103,16 @@ func GPUDevices(ctx context.Context, runners []FilteredRunnerDiscovery) []ml.Dev
 			} else {
 				dirs = []string{LibOllamaPath, dir}
 			}
+
+			// ROCm can take a long time on some systems, so give it more time before giving up
+			if dir != "" && strings.Contains(filepath.Base(dir), "rocm") {
+				bootstrapTimeout = 60 * time.Second
+			}
 			// Typically bootstrapping takes < 1s, but on some systems, with devices
 			// in low power/idle mode, initialization can take multiple seconds.  We
 			// set a long timeout just for bootstrap discovery to reduce the chance
 			// of giving up too quickly
-			ctx1stPass, cancel := context.WithTimeout(ctx, 30*time.Second)
+			ctx1stPass, cancel := context.WithTimeout(ctx, bootstrapTimeout)
 			defer cancel()
 
 			// For this pass, we retain duplicates in case any are incompatible with some libraries
Repository: rust-lang/rust
Pull request: diagnostics: avoid ICE in confusable_method_name for associated functions

Avoid unconditionally slicing `inputs()[1..]`, which assumes a `self` parameter. Use `is_method()` to conditionally skip the receiver, preventing out-of-bounds access and fixing suggestions for associated functions.

<!-- homu-ignore:start -->
<!--
If this PR is related to an unstable feature or an otherwise tracked effort,
please link to the relevant tracking issue here. If you don't know of a related
tracking issue or there are none, feel free to ignore this.

This PR will get automatically assigned to a reviewer. In case you would like
a specific user to review your work, you can assign it to them by using

    r? <reviewer name>
-->
<!-- homu-ignore:end -->


Changed files:
filename: compiler/rustc_hir_typeck/src/method/suggest.rs
patch: @@ -2291,8 +2291,11 @@ impl<'a, 'tcx> FnCtxt<'a, 'tcx> {
                             fn_sig,
                         );
                         let name = inherent_method.name();
+                        let inputs = fn_sig.inputs();
+                        let expected_inputs =
+                            if inherent_method.is_method() { &inputs[1..] } else { inputs };
                         if let Some(ref args) = call_args
-                            && fn_sig.inputs()[1..]
+                            && expected_inputs
                                 .iter()
                                 .eq_by(args, |expected, found| self.may_coerce(*expected, *found))
                         {

filename: tests/ui/attributes/rustc_confusables_assoc_fn.rs
patch: @@ -0,0 +1,22 @@
+#![feature(rustc_attrs)]
+
+struct S;
+
+impl S {
+    #[rustc_confusables("bar")]
+    fn foo() {}
+
+    #[rustc_confusables("baz")]
+    fn qux(&self, x: i32) {}
+}
+
+fn main() {
+    S::bar();
+    //~^ ERROR no function or associated item named `bar`
+    //~| HELP you might have meant to use `foo`
+
+    let s = S;
+    s.baz(10);
+    //~^ ERROR no method named `baz`
+    //~| HELP you might have meant to use `qux`
+}

filename: tests/ui/attributes/rustc_confusables_assoc_fn.stderr
patch: @@ -0,0 +1,33 @@
+error[E0599]: no function or associated item named `bar` found for struct `S` in the current scope
+  --> $DIR/rustc_confusables_assoc_fn.rs:14:8
+   |
+LL | struct S;
+   | -------- function or associated item `bar` not found for this struct
+...
+LL |     S::bar();
+   |        ^^^ function or associated item not found in `S`
+   |
+help: you might have meant to use `foo`
+   |
+LL -     S::bar();
+LL +     S::foo();
+   |
+
+error[E0599]: no method named `baz` found for struct `S` in the current scope
+  --> $DIR/rustc_confusables_assoc_fn.rs:19:7
+   |
+LL | struct S;
+   | -------- method `baz` not found for this struct
+...
+LL |     s.baz(10);
+   |       ^^^ method not found in `S`
+   |
+help: you might have meant to use `qux`
+   |
+LL -     s.baz(10);
+LL +     s.qux(10);
+   |
+
+error: aborting due to 2 previous errors
+
+For more information about this error, try `rustc --explain E0599`.
Repository: ollama/ollama
Pull request: fix gemma3n on vulkan

Resolves the assert seen on vulkan backends:
```
GGML_ASSERT(op_supports_incontiguous || (ggml_is_contiguous(src0) && (src1 == nullptr || ggml_is_contiguous(src1)))) failed
```



Changed files:
filename: model/models/gemma3n/model_text.go
patch: @@ -65,7 +65,7 @@ func (m *TextModel) Forward(ctx ml.Context, batch input.Batch, cache kvcache.Cac
 		cache.(*kvcache.WrapperCache).SetLayerType(layerType)
 
 		// inputPerLayer = inputsPerLayer[:, i, :]
-		inputPerLayer := inputsPerLayer.View(ctx, i*inputsPerLayer.Stride(1), inputsPerLayer.Dim(0), inputsPerLayer.Stride(2), inputsPerLayer.Dim(2))
+		inputPerLayer := inputsPerLayer.View(ctx, i*inputsPerLayer.Stride(1), inputsPerLayer.Dim(0), inputsPerLayer.Stride(2), inputsPerLayer.Dim(2)).Contiguous(ctx)
 		hiddenStates = layer.Forward(ctx, hiddenStates, inputPerLayer, positions, one, cache, i >= firstSharedKeyValue, ropeBase, float64(m.activationSparsityScale[i]), &m.TextOptions)
 	}
Repository: nodejs/node
Pull request: test_runner: replace native methods with primordials

Replace native methods with primordials.


Changed files:
filename: lib/internal/test_runner/snapshot.js
patch: @@ -9,6 +9,7 @@ const {
   SafeMap,
   String,
   StringPrototypeReplaceAll,
+  StringPrototypeSlice,
 } = primordials;
 const {
   codes: {
@@ -291,7 +292,7 @@ function validateFunctionArray(fns, name) {
 }
 
 function escapeSnapshotKey(str) {
-  let result = JSONStringify(str, null, 2).slice(1, -1);
+  let result = StringPrototypeSlice(JSONStringify(str, null, 2), 1, -1);
   result = StringPrototypeReplaceAll(result, '`', '\\`');
   result = StringPrototypeReplaceAll(result, '${', '\\${');
   return result;
Repository: electron/electron
Pull request: fix: strictly validate sender for internal IPC reply channels (#50118)

Manual backport of #50118 

See that PR for details

Notes: none

Changed files:
filename: lib/browser/ipc-main-internal-utils.ts
patch: @@ -19,8 +19,8 @@ export function invokeInWebContents<T> (sender: Electron.WebContents, command: s
     const requestId = ++nextId;
     const channel = `${command}_RESPONSE_${requestId}`;
     ipcMainInternal.on(channel, function handler (event, error: Error, result: any) {
-      if (event.type === 'frame' && event.sender !== sender) {
-        console.error(`Reply to ${command} sent by unexpected WebContents (${event.sender.id})`);
+      if (event.type !== 'frame' || event.sender !== sender) {
+        console.error(`Reply to ${command} sent by unexpected sender`);
         return;
       }
Repository: rust-lang/rust
Pull request: Add new alias for Guillaume Gomez email address

I'm switching to a new email account and slowly updating all references to the old one.

Changed files:
filename: .mailmap
patch: @@ -262,6 +262,7 @@ Guillaume Gomez <guillaume1.gomez@gmail.com>
 Guillaume Gomez <guillaume1.gomez@gmail.com> ggomez <ggomez@ggo.ifr.lan>
 Guillaume Gomez <guillaume1.gomez@gmail.com> Guillaume Gomez <ggomez@ggo.ifr.lan>
 Guillaume Gomez <guillaume1.gomez@gmail.com> Guillaume Gomez <guillaume.gomez@huawei.com>
+Guillaume Gomez <guillaume1.gomez@gmail.com> Guillaume Gomez <contact@guillaume-gomez.fr>
 gnzlbg <gonzalobg88@gmail.com> <gnzlbg@users.noreply.github.com>
 hamidreza kalbasi <hamidrezakalbasi@protonmail.com>
 Hanna Kruppe <hanna.kruppe@gmail.com> <robin.kruppe@gmail.com>
Repository: facebook/react
Pull request: Update readme for eprh


Changed files:
filename: packages/eslint-plugin-react-hooks/README.md
patch: @@ -1,8 +1,6 @@
 # `eslint-plugin-react-hooks`
 
-This ESLint plugin enforces the [Rules of Hooks](https://react.dev/reference/rules/rules-of-hooks).
-
-It is a part of the [Hooks API](https://react.dev/reference/react/hooks) for React.
+The official ESLint plugin for [React](https://react.dev) which enforces the [Rules of React](https://react.dev/reference/eslint-plugin-react-hooks) and other best practices.
 
 ## Installation
 
@@ -89,7 +87,7 @@ If you're using a version earlier than 5.2.0, the legacy config was simply `reco
 
 ### Custom Configuration
 
-If you want more fine-grained configuration, you can instead add a snippet like this to your ESLint configuration file:
+If you want more fine-grained configuration, you can instead choose to enable specific rules. However, we strongly encourage using the recommended presets — see above — so that you will automatically receive new recommended rules as we add them in future versions of the plugin.
 
 #### Flat Config (eslint.config.js|ts)
Repository: ollama/ollama
Pull request: win: more verbose load failures

When loading the dynamic libraries, if something goes wrong report some details.  Unfortunately this wont explain which dependencies are missing, but this breadcrumb in the logs should help us diagnose GPU discovery failures.


For the following example, I manually deleted one of the cuda dependency libraries and then set `$env:OLLAMA_DEBUG="2"` then during bootstrap, the following is logged:
```
time=2025-10-17T14:44:58.970-07:00 level=DEBUG source=ggml.go:94 msg="ggml backend load all from path" path=C:\Users\danie\code\ollama\dist\windows-amd64\lib\ollama\cuda_v12
dl_load_library unable to load library C:\Users\danie\code\ollama\dist\windows-amd64\lib\ollama\cuda_v12\ggml-cuda.dll: The specified module could not be found.
```

Changed files:
filename: llama/patches/0031-report-LoadLibrary-failures.patch
patch: @@ -0,0 +1,32 @@
+From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
+From: Daniel Hiltgen <daniel@ollama.com>
+Date: Fri, 17 Oct 2025 14:17:00 -0700
+Subject: [PATCH] report LoadLibrary failures
+
+---
+ ggml/src/ggml-backend-reg.cpp | 12 ++++++++++++
+ 1 file changed, 12 insertions(+)
+
+diff --git a/ggml/src/ggml-backend-reg.cpp b/ggml/src/ggml-backend-reg.cpp
+index f794d9cfa..3a855ab2e 100644
+--- a/ggml/src/ggml-backend-reg.cpp
++++ b/ggml/src/ggml-backend-reg.cpp
+@@ -118,6 +118,18 @@ static dl_handle * dl_load_library(const fs::path & path) {
+     SetErrorMode(old_mode | SEM_FAILCRITICALERRORS);
+ 
+     HMODULE handle = LoadLibraryW(path.wstring().c_str());
++    if (!handle) {
++        DWORD error_code = GetLastError();
++        std::string msg;
++        LPSTR lpMsgBuf = NULL;
++        DWORD bufLen = FormatMessageA(FORMAT_MESSAGE_ALLOCATE_BUFFER | FORMAT_MESSAGE_FROM_SYSTEM | FORMAT_MESSAGE_IGNORE_INSERTS,
++                                      NULL, error_code, MAKELANGID(LANG_NEUTRAL, SUBLANG_DEFAULT), (LPSTR)&lpMsgBuf, 0, NULL);
++        if (bufLen) {
++            msg = lpMsgBuf;
++            LocalFree(lpMsgBuf);
++            GGML_LOG_INFO("%s unable to load library %s: %s\n", __func__, path_str(path).c_str(), msg.c_str());
++        }
++    }
+ 
+     SetErrorMode(old_mode);
+ 

filename: ml/backend/ggml/ggml/src/ggml-backend-reg.cpp
patch: @@ -118,6 +118,18 @@ static dl_handle * dl_load_library(const fs::path & path) {
     SetErrorMode(old_mode | SEM_FAILCRITICALERRORS);
 
     HMODULE handle = LoadLibraryW(path.wstring().c_str());
+    if (!handle) {
+        DWORD error_code = GetLastError();
+        std::string msg;
+        LPSTR lpMsgBuf = NULL;
+        DWORD bufLen = FormatMessageA(FORMAT_MESSAGE_ALLOCATE_BUFFER | FORMAT_MESSAGE_FROM_SYSTEM | FORMAT_MESSAGE_IGNORE_INSERTS,
+                                      NULL, error_code, MAKELANGID(LANG_NEUTRAL, SUBLANG_DEFAULT), (LPSTR)&lpMsgBuf, 0, NULL);
+        if (bufLen) {
+            msg = lpMsgBuf;
+            LocalFree(lpMsgBuf);
+            GGML_LOG_INFO("%s unable to load library %s: %s\n", __func__, path_str(path).c_str(), msg.c_str());
+        }
+    }
 
     SetErrorMode(old_mode);
Repository: nodejs/node
Pull request: crypto: Fix potential null pointer dereference when BIO_meth_new() fails

This function can return null, which will make the calls to BIO_meth_set_* trigger a null deref.
Even after fixing this, there is an issue with the `BIOPointer::New(GetMethod())` call in `NodeBIO::New` because the `New` method cannot handle a null pointer despite other code already guarding for this
(e.g. the `NodeBIO::New` function already checks `bio`). This patch solves the issues by adding more null checks.

Note: this was found by a static-dynamic analyser I'm developing.

<!--
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: deps/ncrypto/ncrypto.cc
patch: @@ -1470,6 +1470,7 @@ BIOPointer BIOPointer::NewSecMem() {
 }
 
 BIOPointer BIOPointer::New(const BIO_METHOD* method) {
+  if (method == nullptr) return {};
   return BIOPointer(BIO_new(method));
 }
 

filename: src/crypto/crypto_bio.cc
patch: @@ -226,6 +226,7 @@ const BIO_METHOD* NodeBIO::GetMethod() {
   // Static initialization ensures that this is safe to use concurrently.
   static const BIO_METHOD* method = [&]() {
     BIO_METHOD* method = BIO_meth_new(BIO_TYPE_MEM, "node.js SSL buffer");
+    CHECK_NOT_NULL(method);
     BIO_meth_set_write(method, Write);
     BIO_meth_set_read(method, Read);
     BIO_meth_set_puts(method, Puts);
Repository: huggingface/transformers
Pull request: Fix special token maps BC

# What does this PR do?
Its a very small fix for #44062

Changed files:
filename: src/transformers/tokenization_utils_base.py
patch: @@ -1840,6 +1840,7 @@ def _from_pretrained(
                     if key in kwargs and kwargs[key]:
                         continue  # User-provided kwargs take precedence
                     if isinstance(value, dict) and key != "extra_special_tokens":
+                        value.pop("special", None)
                         value = AddedToken(**value, special=True)
                     elif key == "extra_special_tokens" and isinstance(value, list):
                         # Merge list tokens, converting dicts to AddedToken
Repository: nodejs/node
Pull request: test_runner: print info when test restarts

When using spec reporter and running test in watch mode, print an info message containing the current datetime when tests restart.

Fixes: https://github.com/nodejs/node/issues/57206

The issue had a lot of people trying to fix it without success, let me know if there is something I can do to make it through approval this time, this is something I'd like to land for the spec reporter.

Changed files:
filename: lib/internal/test_runner/reporter/spec.js
patch: @@ -5,6 +5,8 @@ const {
   ArrayPrototypePush,
   ArrayPrototypeShift,
   ArrayPrototypeUnshift,
+  Date,
+  DatePrototypeToLocaleString,
 } = primordials;
 const assert = require('assert');
 const Transform = require('internal/streams/transform');
@@ -101,6 +103,9 @@ class SpecReporter extends Transform {
         if (data.file === undefined) {
           return this.#formatFailedTestResults();
         }
+        break;
+      case 'test:watch:restarted':
+        return `\nRestarted at ${DatePrototypeToLocaleString(new Date())}\n`;
     }
   }
   _transform({ type, data }, encoding, callback) {

filename: test/test-runner/test-output-spec-reporter-watch-restart.mjs
patch: @@ -0,0 +1,18 @@
+import '../common/index.mjs';
+import { spec as SpecReporter } from 'node:test/reporters';
+import assert from 'node:assert';
+
+const reporter = new SpecReporter();
+let output = '';
+
+reporter.on('data', (chunk) => {
+  output += chunk;
+});
+
+reporter.write({
+  type: 'test:watch:restarted',
+});
+
+reporter.end();
+
+assert.match(output, /Restarted at .+/);