helloadhavan/github_issues huggingface dataset:
Repository: ggml-org/llama.cpp
Pull request: fix: proper error handling for missing elements in messages array (OpenAI compatible backend)

Supersedes https://github.com/ggml-org/llama.cpp/pull/13521

Per discussion in that PR, implement proper logic for checking messages array elements, with meaningful error messages.

Changed files:
filename: tools/server/utils.hpp
patch: @@ -643,6 +643,18 @@ static json oaicompat_completion_params_parse(
         throw std::runtime_error("Expected 'messages' to be an array");
     }
     for (auto & msg : messages) {
+        std::string role = json_value(msg, "role", std::string());
+        if (role != "assistant" && !msg.contains("content")) {
+            throw std::runtime_error("All non-assistant messages must contain 'content'");
+        }
+        if (role == "assistant") {
+            if (!msg.contains("content") && !msg.contains("tool_calls")) {
+                throw std::runtime_error("Assistant message must contain either 'content' or 'tool_calls'!");
+            }
+            if (!msg.contains("content")) {
+                continue; // avoid errors with no content
+            }
+        }
         json & content = msg.at("content");
         if (content.is_string() || content.is_null()) {
             continue;
Repository: facebook/react
Pull request: Update @next version

Now that 18.0 is out, the next minor is 18.1

Changed files:
filename: ReactVersions.js
patch: @@ -18,26 +18,26 @@
 //
 //   0.0.0-experimental-241c4467e-20200129
 
-const ReactVersion = '18.0.0';
+const ReactVersion = '18.1.0';
 
 // The label used by the @next channel. Represents the upcoming release's
 // stability. Could be "alpha", "beta", "rc", etc.
 const nextChannelLabel = 'next';
 
 const stablePackages = {
   'create-subscription': ReactVersion,
-  'eslint-plugin-react-hooks': '4.4.0',
-  'jest-react': '0.12.1',
+  'eslint-plugin-react-hooks': '4.5.0',
+  'jest-react': '0.13.1',
   react: ReactVersion,
   'react-art': ReactVersion,
   'react-dom': ReactVersion,
   'react-is': ReactVersion,
-  'react-reconciler': '0.27.0',
-  'react-refresh': '0.12.0',
+  'react-reconciler': '0.28.0',
+  'react-refresh': '0.13.0',
   'react-test-renderer': ReactVersion,
-  'use-subscription': '1.6.0',
-  'use-sync-external-store': '1.0.0',
-  scheduler: '0.21.0',
+  'use-subscription': '1.7.0',
+  'use-sync-external-store': '1.1.0',
+  scheduler: '0.22.0',
 };
 
 // These packages do not exist in the @next or @latest channel, only
Repository: huggingface/transformers
Pull request: TransfoXL is deprecated, don't keep it in tested examples!


Changed files:
filename: examples/pytorch/text-generation/run_generation.py
patch: @@ -38,8 +38,6 @@
     OpenAIGPTLMHeadModel,
     OpenAIGPTTokenizer,
     OPTForCausalLM,
-    TransfoXLLMHeadModel,
-    TransfoXLTokenizer,
     XLMTokenizer,
     XLMWithLMHeadModel,
     XLNetLMHeadModel,
@@ -62,7 +60,6 @@
     "ctrl": (CTRLLMHeadModel, CTRLTokenizer),
     "openai-gpt": (OpenAIGPTLMHeadModel, OpenAIGPTTokenizer),
     "xlnet": (XLNetLMHeadModel, XLNetTokenizer),
-    "transfo-xl": (TransfoXLLMHeadModel, TransfoXLTokenizer),
     "xlm": (XLMWithLMHeadModel, XLMTokenizer),
     "gptj": (GPTJForCausalLM, AutoTokenizer),
     "bloom": (BloomForCausalLM, BloomTokenizerFast),
@@ -368,10 +365,7 @@ def main():
         prepare_input = PREPROCESSING_FUNCTIONS.get(args.model_type)
         preprocessed_prompt_text = prepare_input(args, model, tokenizer, prompt_text)
 
-        if model.__class__.__name__ in ["TransfoXLLMHeadModel"]:
-            tokenizer_kwargs = {"add_space_before_punct_symbol": True}
-        else:
-            tokenizer_kwargs = {}
+        tokenizer_kwargs = {}
 
         encoded_prompt = tokenizer.encode(
             preprocessed_prompt_text, add_special_tokens=False, return_tensors="pt", **tokenizer_kwargs
Repository: denoland/deno
Pull request: fix(add): error when config file contains importMap field

The "imports" field has higher precedence than "importMap", so we should error when `deno add` goes to add an `"imports"` field.

Closes https://github.com/denoland/deno/issues/24264
Closes https://github.com/denoland/deno/pull/24478

Changed files:
filename: cli/tools/registry/pm.rs
patch: @@ -289,6 +289,17 @@ pub async fn add(
     _ => bail!("Failed updating config file due to no object."),
   };
 
+  if obj.get_string("importMap").is_some() {
+    bail!(
+      concat!(
+        "`deno add` is not supported when configuration file contains an \"importMap\" field. ",
+        "Inline the import map into the Deno configuration file.\n",
+        "    at {}",
+      ),
+      config_specifier
+    );
+  }
+
   let mut existing_imports = config_file.existing_imports()?;
 
   let is_npm = config_file.is_npm();

filename: tests/specs/add/error_import_map_field/__test__.jsonc
patch: @@ -0,0 +1,5 @@
+{
+  "args": "add jsr:@denotest/add",
+  "output": "add.out",
+  "exitCode": 1
+}

filename: tests/specs/add/error_import_map_field/add.out
patch: @@ -0,0 +1,2 @@
+error: `deno add` is not supported when configuration file contains an "importMap" field. Inline the import map into the Deno configuration file.
+    at file:///[WILDLINE]/deno.json

filename: tests/specs/add/error_import_map_field/deno.json
patch: @@ -0,0 +1,3 @@
+{
+  "importMap": "./import_map.json"
+}

filename: tests/specs/add/error_import_map_field/import_map.json
patch: @@ -0,0 +1 @@
+{}
Repository: nodejs/node
Pull request: src: use starts_with in fs_permission.cc

Use `starts_with` from C++20 instead of `substr` in  fs_permission.cc

Changed files:
filename: src/permission/fs_permission.cc
patch: @@ -58,16 +58,16 @@ bool is_tree_granted(
   std::string resolved_param = node::PathResolve(env, {param});
 #ifdef _WIN32
   // Remove leading "\\?\" from UNC path
-  if (resolved_param.substr(0, 4) == "\\\\?\\") {
+  if (resolved_param.starts_with("\\\\?\\")) {
     resolved_param.erase(0, 4);
   }
 
   // Remove leading "UNC\" from UNC path
-  if (resolved_param.substr(0, 4) == "UNC\\") {
+  if (resolved_param.starts_with("UNC\\")) {
     resolved_param.erase(0, 4);
   }
   // Remove leading "//" from UNC path
-  if (resolved_param.substr(0, 2) == "//") {
+  if (resolved_param.starts_with("//")) {
     resolved_param.erase(0, 2);
   }
 #endif
Repository: huggingface/transformers
Pull request: [CI] add back `sacrebleu` (and document why)

# What does this PR do?

Reverts the removed dep in #37676 , and documents why

(TL;DR: `sacrebleu` is not in present `transformers`. However, calling `evaluate.load("sacrebleu")` requires it, and our `Trainer` tests use it under the hood, through the `run_translation.py` example)

Changed files:
filename: setup.py
patch: @@ -163,6 +163,10 @@
     "rjieba",
     "rouge-score!=0.0.7,!=0.0.8,!=0.1,!=0.1.1",
     "ruff==0.11.2",
+    # `sacrebleu` not used in `transformers`. However, it is needed in several tests, when a test calls
+    # `evaluate.load("sacrebleu")`. This metric is used in the examples that we use to test the `Trainer` with, in the
+    # `Trainer` tests (see references to `run_translation.py`).
+    "sacrebleu>=1.4.12,<2.0.0",
     "sacremoses",
     "safetensors>=0.4.3",
     "sagemaker>=2.31.0",
@@ -352,6 +356,7 @@ def run(self):
         "tensorboard",
         "pydantic",
         "sentencepiece",
+        "sacrebleu",  # needed in trainer tests, see references to `run_translation.py`
     )
     + extras["retrieval"]
     + extras["modelcreation"]

filename: src/transformers/dependency_versions_table.py
patch: @@ -69,6 +69,7 @@
     "rjieba": "rjieba",
     "rouge-score": "rouge-score!=0.0.7,!=0.0.8,!=0.1,!=0.1.1",
     "ruff": "ruff==0.11.2",
+    "sacrebleu": "sacrebleu>=1.4.12,<2.0.0",
     "sacremoses": "sacremoses",
     "safetensors": "safetensors>=0.4.3",
     "sagemaker": "sagemaker>=2.31.0",
Repository: vercel/next.js
Pull request: fix(turbopack): Provide full path to SWC Wasm plugins

### What?

Provide full path to the SWC Wasm plugins

### Why?

To align with other SWC Wasm plugin runtimes

### How?

 - Closes PACK-4363
 - Closes #78181

Changed files:
filename: turbopack/crates/turbopack-ecmascript-plugins/src/transform/swc_ecma_transform_plugins.rs
patch: @@ -186,7 +186,7 @@ impl CustomTransformer for SwcEcmaTransformPluginsTransformer {
                         PluginSerializedBytes::try_serialize(&module_program)?;
 
                     let transform_metadata_context = Arc::new(TransformPluginMetadataContext::new(
-                        Some(ctx.file_name_str.to_string()),
+                        Some(ctx.file_path_str.to_string()),
                         //[TODO]: Support env-related variable injection, i.e process.env.NODE_ENV
                         "development".to_string(),
                         None,
Repository: denoland/deno
Pull request: fix(ext/webgpu): allow to build on unsupported platforms


Changed files:
filename: ext/webgpu/byow.rs
patch: @@ -148,3 +148,18 @@ fn raw_window(
 
   Ok((win_handle, display_handle))
 }
+
+#[cfg(not(any(
+  target_os = "macos",
+  target_os = "windows",
+  target_os = "linux",
+  target_os = "freebsd",
+  target_os = "openbsd",
+)))]
+fn raw_window(
+  _system: &str,
+  _window: *const c_void,
+  _display: *const c_void,
+) -> Result<RawHandles, AnyError> {
+  Err(type_error("Unsupported platform"))
+}
Repository: denoland/deno
Pull request: fix: handle showing warnings while the progress bar is shown


Changed files:
filename: cli/util/draw_thread.rs
patch: @@ -40,7 +40,7 @@ struct InternalEntry {
 struct InternalState {
   // this ensures only one actual draw thread is running
   drawer_id: usize,
-  hide: bool,
+  hide_count: usize,
   has_draw_thread: bool,
   next_entry_id: u16,
   entries: Vec<InternalEntry>,
@@ -56,7 +56,7 @@ impl InternalState {
 static INTERNAL_STATE: Lazy<Arc<Mutex<InternalState>>> = Lazy::new(|| {
   Arc::new(Mutex::new(InternalState {
     drawer_id: 0,
-    hide: false,
+    hide_count: 0,
     has_draw_thread: false,
     entries: Vec::new(),
     next_entry_id: 0,
@@ -113,7 +113,7 @@ impl DrawThread {
   pub fn hide() {
     let internal_state = &*INTERNAL_STATE;
     let mut internal_state = internal_state.lock();
-    internal_state.hide = true;
+    internal_state.hide_count += 1;
 
     Self::clear_and_stop_draw_thread(&mut internal_state);
   }
@@ -122,9 +122,12 @@ impl DrawThread {
   pub fn show() {
     let internal_state = &*INTERNAL_STATE;
     let mut internal_state = internal_state.lock();
-    internal_state.hide = false;
-
-    Self::maybe_start_draw_thread(&mut internal_state);
+    if internal_state.hide_count > 0 {
+      internal_state.hide_count -= 1;
+      if internal_state.hide_count == 0 {
+        Self::maybe_start_draw_thread(&mut internal_state);
+      }
+    }
   }
 
   fn finish_entry(entry_id: u16) {
@@ -153,7 +156,7 @@ impl DrawThread {
 
   fn maybe_start_draw_thread(internal_state: &mut InternalState) {
     if internal_state.has_draw_thread
-      || internal_state.hide
+      || internal_state.hide_count > 0
       || internal_state.entries.is_empty()
       || !DrawThread::is_supported()
     {

filename: cli/util/logger.rs
patch: @@ -2,6 +2,8 @@
 
 use std::io::Write;
 
+use super::draw_thread::DrawThread;
+
 struct CliLogger(env_logger::Logger);
 
 impl CliLogger {
@@ -21,7 +23,13 @@ impl log::Log for CliLogger {
 
   fn log(&self, record: &log::Record) {
     if self.enabled(record.metadata()) {
+      // it was considered to hold the draw thread's internal lock
+      // across logging, but if outputting to stderr blocks then that
+      // could potentially block other threads that access the draw
+      // thread's state
+      DrawThread::hide();
       self.0.log(record);
+      DrawThread::show();
     }
   }
Repository: huggingface/transformers
Pull request: Add maintainers for ROCm/Intel XPU/Ascend NPU

We have a list of maintainers for various parts of the library in the issue template; this PR adds maintainers for backends like ROCm, XPU and Ascend NPU.

cc @ivarflakstad @IlyasMoutawwakil - let me know if you're okay with this!

Changed files:
filename: .github/ISSUE_TEMPLATE/bug-report.yml
patch: @@ -56,6 +56,12 @@ body:
           - ray/raytune: @richardliaw, @amogkam
           - Big Model Inference: @SunMarc
           - quantization (bitsandbytes, autogpt): @SunMarc @MekkCyber
+        
+        Devices/Backends:
+        
+          - AMD ROCm: @ivarflakstad
+          - Intel XPU: @IlyasMoutawwakil
+          - Ascend NPU: @ivarflakstad 
 
         Documentation: @stevhliu
Repository: facebook/react
Pull request: DevTools release script: Show changelog before minor/patch prompt


https://user-images.githubusercontent.com/29597/160684346-0faf9195-313e-4608-ad1d-5e5b6e18dd0e.mov



Changed files:
filename: scripts/devtools/prepare-release.js
patch: @@ -31,6 +31,16 @@ async function main() {
 
   await checkNPMPermissions();
 
+  const sha = await getPreviousCommitSha();
+  const [shortCommitLog, formattedCommitLog] = await getCommitLog(sha);
+
+  console.log('');
+  console.log(
+    'This release includes the following commits:',
+    chalk.gray(shortCommitLog)
+  );
+  console.log('');
+
   const releaseType = await getReleaseType();
 
   const path = join(ROOT_PATH, PACKAGE_PATHS[0]);
@@ -41,6 +51,10 @@ async function main() {
       ? `${major}.${minor + 1}.0`
       : `${major}.${minor}.${patch + 1}`;
 
+  updateChangelog(nextVersion, formattedCommitLog);
+
+  await reviewChangelogPrompt();
+
   updatePackageVersions(previousVersion, nextVersion);
   updateManifestVersions(previousVersion, nextVersion);
 
@@ -52,13 +66,6 @@ async function main() {
   );
   console.log('');
 
-  const sha = await getPreviousCommitSha();
-  const commitLog = await getCommitLog(sha);
-
-  updateChangelog(nextVersion, commitLog);
-
-  await reviewChangelogPrompt();
-
   await commitPendingChanges(previousVersion, nextVersion);
 
   printFinalInstructions();
@@ -89,6 +96,7 @@ async function commitPendingChanges(previousVersion, nextVersion) {
 }
 
 async function getCommitLog(sha) {
+  let shortLog = '';
   let formattedLog = '';
 
   const rawLog = await execRead(`
@@ -103,12 +111,14 @@ async function getCommitLog(sha) {
       const pr = match[2];
 
       formattedLog += `\n* ${title} ([USERNAME](https://github.com/USERNAME) in [#${pr}](${PULL_REQUEST_BASE_URL}${pr}))`;
+      shortLog += `\n* ${title}`;
     } else {
       formattedLog += `\n* ${line}`;
+      shortLog += `\n* ${line}`;
     }
   });
 
-  return formattedLog;
+  return [shortLog, formattedLog];
 }
 
 async function getPreviousCommitSha() {
Repository: facebook/react
Pull request: fix local build script for react dev tools

react-art is now a dependency of tests of react-devtools-shared (see https://github.com/facebook/react/blob/main/packages/react-devtools-shared/src/__tests__/inspectedElement-test.js#L2740)

## Test this change
`yarn build-for-devtools && yarn test-build-devtools`

Changed files:
filename: package.json
patch: @@ -108,7 +108,7 @@
   "scripts": {
     "build": "node ./scripts/rollup/build.js",
     "build-combined": "node ./scripts/rollup/build-all-release-channels.js",
-    "build-for-devtools": "cross-env RELEASE_CHANNEL=experimental yarn build react/index,react/jsx,react-dom/index,react-dom/test,react-is,react-debug-tools,scheduler,react-test-renderer,react-refresh --type=NODE && cp -r ./build/node_modules build/oss-experimental/",
+    "build-for-devtools": "cross-env RELEASE_CHANNEL=experimental yarn build react/index,react/jsx,react-dom/index,react-dom/test,react-is,react-debug-tools,scheduler,react-test-renderer,react-refresh,react-art --type=NODE && cp -r ./build/node_modules build/oss-experimental/",
     "build-for-devtools-dev": "yarn build-for-devtools --type=NODE_DEV",
     "build-for-devtools-prod": "yarn build-for-devtools --type=NODE_PROD",
     "linc": "node ./scripts/tasks/linc.js",
Repository: denoland/deno
Pull request: fix(ext/crypto): throw DataError for invalid EC key import

Fixes https://github.com/denoland/deno/issues/20931


Changed files:
filename: ext/crypto/import_key.rs
patch: @@ -689,7 +689,8 @@ fn import_key_ec(
 
         let rng = ring::rand::SystemRandom::new();
         // deserialize pkcs8 using ring crate, to VALIDATE public key
-        let _private_key = EcdsaKeyPair::from_pkcs8(signing_alg, &data, &rng)?;
+        let _private_key = EcdsaKeyPair::from_pkcs8(signing_alg, &data, &rng)
+          .map_err(|_| data_error("invalid key"))?;
 
         // 11.
         if named_curve != pk_named_curve {

filename: tests/unit/webcrypto_test.ts
patch: @@ -2045,3 +2045,24 @@ Deno.test(async function p521Generate() {
   assert(key.privateKey instanceof CryptoKey);
   assert(key.publicKey instanceof CryptoKey);
 });
+
+Deno.test(async function invalidEcPointDataError() {
+  await assertRejects(async () => {
+    await crypto.subtle
+      .importKey(
+        "pkcs8",
+        // deno-fmt-ignore
+        new Uint8Array([
+          48, 102, 2, 1, 0, 48, 19, 6, 7, 42, 134, 72, 206, 61, 2, 1, 6, 8, 42, 134,
+          72, 206, 61, 3, 1, 7, 4, 76, 48, 74, 2, 1, 1, 4, 32, 255, 255, 255, 255,
+          0, 0, 0, 0, 255, 255, 255, 255, 255, 255, 255, 255, 188, 230, 250, 173,
+          167, 23, 158, 132, 243, 185, 202, 194, 252, 99, 37, 81, 161, 35, 3, 33, 0,
+          0, 255, 255, 255, 0, 0, 0, 0, 255, 255, 255, 255, 255, 255, 255, 255, 188,
+          230, 250, 173, 167, 23, 158, 132, 243, 185, 202, 194, 252, 99, 37, 81,
+        ]),
+        { name: "ECDSA", namedCurve: "P-256" },
+        true,
+        ["sign"],
+      );
+  }, DOMException);
+});
Repository: nodejs/node
Pull request: test: check typescript loader

Refs: https://github.com/nodejs/node/issues/54645

Changed files:
filename: test/es-module/test-typescript.mjs
patch: @@ -323,3 +323,29 @@ test('expect error when executing a TypeScript file with generics', async () =>
   strictEqual(result.stdout, '');
   strictEqual(result.code, 1);
 });
+
+test('execute a TypeScript loader and a .ts file', async () => {
+  const result = await spawnPromisified(process.execPath, [
+    '--experimental-strip-types',
+    '--no-warnings',
+    '--import',
+    fixtures.fileURL('typescript/ts/test-loader.ts'),
+    fixtures.path('typescript/ts/test-typescript.ts'),
+  ]);
+  strictEqual(result.stderr, '');
+  match(result.stdout, /Hello, TypeScript!/);
+  strictEqual(result.code, 0);
+});
+
+test('execute a TypeScript loader and a .js file', async () => {
+  const result = await spawnPromisified(process.execPath, [
+    '--experimental-strip-types',
+    '--no-warnings',
+    '--import',
+    fixtures.fileURL('typescript/ts/test-loader.ts'),
+    fixtures.path('typescript/ts/test-simple.js'),
+  ]);
+  strictEqual(result.stderr, '');
+  match(result.stdout, /Hello, TypeScript!/);
+  strictEqual(result.code, 0);
+});

filename: test/fixtures/typescript/ts/hook.ts
patch: @@ -0,0 +1,11 @@
+import type { ResolveHook } from 'node:module';
+
+// Pass through
+export const resolve: ResolveHook = async function resolve(specifier, context, nextResolve) {
+    if(false){
+        // https://github.com/nodejs/node/issues/54645
+        // A bug in the typescript parsers swc causes
+        // the next line to not be parsed correctly
+    }
+    return nextResolve(specifier, context);
+};

filename: test/fixtures/typescript/ts/test-loader.ts
patch: @@ -0,0 +1,4 @@
+import { register } from 'node:module';
+import * as fixtures from '../../../common/fixtures.mjs';
+
+register(fixtures.fileURL('typescript/ts/hook.ts'));

filename: test/fixtures/typescript/ts/test-simple.js
patch: @@ -0,0 +1,2 @@
+const str = "Hello, TypeScript!";
+console.log(str);
Repository: facebook/react
Pull request: Update CHANGELOG.md

Fixes 
- https://github.com/reactjs/reactjs.org/issues/4522

Changed files:
filename: CHANGELOG.md
patch: @@ -95,7 +95,6 @@ The existing `renderToString` method keeps working but is discouraged.
 * Fix a crash when document is set to `null` in tests. ([#22695](https://github.com/facebook/react/pull/22695)  by [@SimenB](https://github.com/SimenB))
 * Fix `onLoad` not triggering when concurrent features are on. ([#23316](https://github.com/facebook/react/pull/23316)  by [@gnoff](https://github.com/gnoff))
 * Fix a warning when a selector returns `NaN`.  ([#23333](https://github.com/facebook/react/pull/23333)  by [@hachibeeDI](https://github.com/hachibeeDI))
-* Fix a crash when document is set to `null` in tests. ([#22695](https://github.com/facebook/react/pull/22695) by [@SimenB](https://github.com/SimenB))
 * Fix the generated license header. ([#23004](https://github.com/facebook/react/pull/23004)  by [@vitaliemiron](https://github.com/vitaliemiron))
 * Add `package.json` as one of the entry points. ([#22954](https://github.com/facebook/react/pull/22954)  by [@Jack](https://github.com/Jack-Works))
 * Allow suspending outside a Suspense boundary. ([#23267](https://github.com/facebook/react/pull/23267)  by [@acdlite](https://github.com/acdlite))
Repository: huggingface/transformers
Pull request: [cleanup] remove `/model_cards` 🧹 🧹 

# What does this PR do?

As also discussed with @LysandreJik -- `/model_cards` holds a README regarding the old model cards, which used to live in `transformers`. We have long moved away from them :)

Changed files:
filename: model_cards/README.md
patch: @@ -1,22 +0,0 @@
-## 🔥 Model cards now live inside each huggingface.co model repo 🔥
-
-
-For consistency, ease of use and scalability, `README.md` model cards now live directly inside each model repo on the HuggingFace model hub.
-
-### How to update a model card
-
-You can directly update a model card inside any model repo you have **write access** to, i.e.:
-- a model under your username namespace
-- a model under any organization you are a part of.
-
-You can either:
-- update it, commit and push using your usual git workflow (command line, GUI, etc.)
-- or edit it directly from the website's UI.
-
-**What if you want to create or update a model card for a model you don't have write access to?**
-
-In that case, you can open a [Hub pull request](https://huggingface.co/docs/hub/repositories-pull-requests-discussions)! Check out the [announcement](https://huggingface.co/blog/community-update) of this feature for more details 🤗.
-
-### What happened to the model cards here?
-
-We migrated every model card from the repo to its corresponding huggingface.co model repo. Individual commits were preserved, and they link back to the original commit on GitHub.
Repository: vercel/next.js
Pull request: remove `draft.isEnabled` setter from exotic draftMode wrappers

For some reason `createExoticDraftMode[WithDevWarnings]` defines a setter for `draft.isEnabled`. As far as i can tell, this setter is unnecessary.

It doesn't seem like we ever allowed this:
```js
const draft = await draftMode()
draft.isEnabled = false
```
The `DraftMode` class had `isEnabled` as a pure getter from the start, see #49096. You can also see that the previous implementation did the same.

(also, the setter wasn't doing anything useful anyway, and arguably was misleading -- it was defining the `isEnabled` property on the promise itself, without actually performing `enable()/disable()`, so i can't see how anyone could be relying on this)

Changed files:
filename: packages/next/src/server/request/draft-mode.ts
patch: @@ -131,13 +131,6 @@ function createExoticDraftMode(
     get() {
       return instance.isEnabled
     },
-    set(newValue) {
-      Object.defineProperty(promise, 'isEnabled', {
-        value: newValue,
-        writable: true,
-        enumerable: true,
-      })
-    },
     enumerable: true,
     configurable: true,
   })
@@ -160,13 +153,6 @@ function createExoticDraftModeWithDevWarnings(
       syncIODev(route, expression)
       return instance.isEnabled
     },
-    set(newValue) {
-      Object.defineProperty(promise, 'isEnabled', {
-        value: newValue,
-        writable: true,
-        enumerable: true,
-      })
-    },
     enumerable: true,
     configurable: true,
   })