helloadhavan/github_issues huggingface dataset:
Repository: electron/electron
Pull request: fix: WCO not working with some window configurations

Backport of #45422

See that PR for details.


Notes: Fixed an issue where Windows Control Overlay didn't work with some window configurations.

Changed files:
filename: shell/browser/native_window_views.cc
patch: @@ -700,6 +700,15 @@ void NativeWindowViews::Minimize() {
 }
 
 void NativeWindowViews::Restore() {
+#if BUILDFLAG(IS_WIN)
+  if (IsMaximized() && transparent()) {
+    SetBounds(restore_bounds_, false);
+    NotifyWindowRestore();
+    UpdateThickFrame();
+    return;
+  }
+#endif
+
   widget()->Restore();
 
 #if BUILDFLAG(IS_WIN)

filename: shell/browser/ui/views/win_caption_button_container.cc
patch: @@ -48,27 +48,26 @@ bool HitTestCaptionButton(WinCaptionButton* button, const gfx::Point& point) {
 WinCaptionButtonContainer::WinCaptionButtonContainer(WinFrameView* frame_view)
     : frame_view_(frame_view),
       minimize_button_(AddChildView(CreateCaptionButton(
-          base::BindRepeating(&views::Widget::Minimize,
-                              base::Unretained(frame_view_->frame())),
+          base::BindRepeating(&NativeWindow::Minimize,
+                              base::Unretained(frame_view_->window())),
           frame_view_,
           VIEW_ID_MINIMIZE_BUTTON,
           IDS_APP_ACCNAME_MINIMIZE))),
       maximize_button_(AddChildView(CreateCaptionButton(
-          base::BindRepeating(&views::Widget::Maximize,
-                              base::Unretained(frame_view_->frame())),
+          base::BindRepeating(&NativeWindow::Maximize,
+                              base::Unretained(frame_view_->window())),
           frame_view_,
           VIEW_ID_MAXIMIZE_BUTTON,
           IDS_APP_ACCNAME_MAXIMIZE))),
       restore_button_(AddChildView(CreateCaptionButton(
-          base::BindRepeating(&views::Widget::Restore,
-                              base::Unretained(frame_view_->frame())),
+          base::BindRepeating(&NativeWindow::Restore,
+                              base::Unretained(frame_view_->window())),
           frame_view_,
           VIEW_ID_RESTORE_BUTTON,
           IDS_APP_ACCNAME_RESTORE))),
       close_button_(AddChildView(CreateCaptionButton(
-          base::BindRepeating(&views::Widget::CloseWithReason,
-                              base::Unretained(frame_view_->frame()),
-                              views::Widget::ClosedReason::kCloseButtonClicked),
+          base::BindRepeating(&NativeWindow::Close,
+                              base::Unretained(frame_view_->window())),
           frame_view_,
           VIEW_ID_CLOSE_BUTTON,
           IDS_APP_ACCNAME_CLOSE))) {
@@ -152,7 +151,7 @@ void WinCaptionButtonContainer::UpdateButtons() {
   minimize_button_->SetEnabled(minimizable);
   minimize_button_->SetVisible(minimizable);
 
-  const bool is_maximized = frame_view_->frame()->IsMaximized();
+  const bool is_maximized = frame_view_->window()->IsMaximized();
   const bool maximizable = frame_view_->window()->IsMaximizable();
   restore_button_->SetVisible(is_maximized && maximizable);
   maximize_button_->SetVisible(!is_maximized && maximizable);
Repository: denoland/deno
Pull request: ci: improve verify_pr_title script

Ref https://github.com/denoland/deno/pull/28697

Changed files:
filename: tools/verify_pr_title.js
patch: @@ -11,11 +11,12 @@ if (prTitle == null) {
 console.log("PR title:", prTitle);
 
 if (
-  prTitle.startsWith("chore:") && prTitle.includes("deno_core") &&
+  prTitle.startsWith("chore:") &&
+  (prTitle.includes("deno_core") || prTitle.includes("v8")) &&
   (prTitle.includes("upgrade") || prTitle.includes("update"))
 ) {
   console.error([
-    "Please categorize this deno_core upgrade as a 'feat:', 'fix:' or a ",
+    "Please categorize this deno_core/v8 upgrade as a 'feat:', 'fix:' or a ",
     "'refactor:'. If your upgrade does not fall into either of these ",
     "categories, wait until the next deno_core release.\n\n",
     "For feats and fixes, please title your PR outlining the fixed issue ",
Repository: facebook/react
Pull request: Move ReactCurrentDispatcher back to shared internals

The jsx-runtime uses the ReactCurrentDispatcher from shared internals. Recently this was moved to ReactServerSharedInternals which broke jsx-runtime. This change moves it back to ReactSharedInternals until we can come up with a new forking mechanism.

Changed files:
filename: packages/react-server/src/ReactFlightServer.js
patch: @@ -108,6 +108,7 @@ import {
 } from 'shared/ReactSerializationErrors';
 
 import {getOrCreateServerContext} from 'shared/ReactServerContextRegistry';
+import ReactSharedInternals from 'shared/ReactSharedInternals';
 import ReactServerSharedInternals from './ReactServerSharedInternals';
 import isArray from 'shared/isArray';
 import binaryToComparableString from 'shared/binaryToComparableString';
@@ -209,9 +210,9 @@ const {
   TaintRegistryValues,
   TaintRegistryByteLengths,
   TaintRegistryPendingRequests,
-  ReactCurrentDispatcher,
   ReactCurrentCache,
 } = ReactServerSharedInternals;
+const ReactCurrentDispatcher = ReactSharedInternals.ReactCurrentDispatcher;
 
 function throwTaintViolation(message: string) {
   // eslint-disable-next-line react-internal/prod-error-codes

filename: packages/react/src/ReactServerSharedInternals.js
patch: @@ -5,7 +5,6 @@
  * LICENSE file in the root directory of this source tree.
  */
 
-import ReactCurrentDispatcher from './ReactCurrentDispatcher';
 import ReactCurrentCache from './ReactCurrentCache';
 import {
   TaintRegistryObjects,
@@ -17,7 +16,6 @@ import {
 import {enableTaint} from 'shared/ReactFeatureFlags';
 
 const ReactServerSharedInternals = {
-  ReactCurrentDispatcher,
   ReactCurrentCache,
 };
 

filename: packages/react/src/ReactSharedInternalsServer.js
patch: @@ -5,12 +5,14 @@
  * LICENSE file in the root directory of this source tree.
  */
 
+import ReactCurrentDispatcher from './ReactCurrentDispatcher';
 import ReactCurrentOwner from './ReactCurrentOwner';
 import ReactDebugCurrentFrame from './ReactDebugCurrentFrame';
 import {enableServerContext} from 'shared/ReactFeatureFlags';
 import {ContextRegistry} from './ReactServerContextRegistry';
 
 const ReactSharedInternals = {
+  ReactCurrentDispatcher,
   ReactCurrentOwner,
 };
Repository: facebook/react
Pull request: Add back temporary `experimental_` aliases for Server Actions APIs

This adds back the `experimental_`-prefixed Server Actions APIs to the experimental builds only, so that apps that use those don't immediately break when upgrading. The APIs will log a warning to encourage people to move to the unprefixed version, or to switch to the canary release channel.

We can remove these in a few weeks after we've given people a chance to upgrade.

This does not affect the canary builds at all, since they never had the prefixed versions to begin with.

Changed files:
filename: packages/react-dom/index.experimental.js
patch: @@ -30,3 +30,30 @@ export {
   preinitModule,
   version,
 } from './src/client/ReactDOM';
+
+import type {FormStatus} from 'react-dom-bindings/src/shared/ReactDOMFormActions';
+import {useFormStatus, useFormState} from './src/client/ReactDOM';
+
+export function experimental_useFormStatus(): FormStatus {
+  if (__DEV__) {
+    console.error(
+      'useFormStatus is now in canary. Remove the experimental_ prefix. ' +
+        'The prefixed alias will be removed in an upcoming release.',
+    );
+  }
+  return useFormStatus();
+}
+
+export function experimental_useFormState<S, P>(
+  action: (S, P) => Promise<S>,
+  initialState: S,
+  permalink?: string,
+): [S, (P) => void] {
+  if (__DEV__) {
+    console.error(
+      'useFormState is now in canary. Remove the experimental_ prefix. ' +
+        'The prefixed alias will be removed in an upcoming release.',
+    );
+  }
+  return useFormState(action, initialState, permalink);
+}

filename: packages/react/index.experimental.js
patch: @@ -58,3 +58,18 @@ export {
   useTransition,
   version,
 } from './src/React';
+
+import {useOptimistic} from './src/React';
+
+export function experimental_useOptimistic<S, A>(
+  passthrough: S,
+  reducer: ?(S, A) => S,
+): [S, (A) => void] {
+  if (__DEV__) {
+    console.error(
+      'useOptimistic is now in canary. Remove the experimental_ prefix. ' +
+        'The prefixed alias will be removed in an upcoming release.',
+    );
+  }
+  return useOptimistic(passthrough, reducer);
+}
Repository: denoland/deno
Pull request: fix: only strip local and debug symbols from macOS binary

Fixes #28757.

We need to retain the napi symbols in the binary. `strip` with no flags on macos strips all symbols out of the binary (including global symbols).

Only strip out the local and debug symbols from the binary, retaining the global symbols (which include the napi ones)

Changed files:
filename: .github/workflows/ci.generate.ts
patch: @@ -818,7 +818,7 @@ const ci = {
           },
           run: [
             "target/release/deno -A tools/release/create_symcache.ts target/release/deno-${{ matrix.arch }}-apple-darwin.symcache",
-            "strip target/release/deno",
+            "strip -x -S target/release/deno",
             'echo "Key is $(echo $APPLE_CODESIGN_KEY | base64 -d | wc -c) bytes"',
             "rcodesign sign target/release/deno " +
             "--code-signature-flags=runtime " +

filename: .github/workflows/ci.yml
patch: @@ -486,7 +486,7 @@ jobs:
           APPLE_CODESIGN_PASSWORD: '${{ secrets.APPLE_CODESIGN_PASSWORD }}'
         run: |-
           target/release/deno -A tools/release/create_symcache.ts target/release/deno-${{ matrix.arch }}-apple-darwin.symcache
-          strip target/release/deno
+          strip -x -S target/release/deno
           echo "Key is $(echo $APPLE_CODESIGN_KEY | base64 -d | wc -c) bytes"
           rcodesign sign target/release/deno --code-signature-flags=runtime --p12-password="$APPLE_CODESIGN_PASSWORD" --p12-file=<(echo $APPLE_CODESIGN_KEY | base64 -d) --entitlements-xml-file=cli/entitlements.plist
           cd target/release
Repository: electron/electron
Pull request: feat: view.getVisible()

Backport of #44999

See that PR for details.


Notes: Added `view.getVisible()`


Changed files:
filename: docs/api/view.md
patch: @@ -106,6 +106,12 @@ Examples of valid `color` values:
 
 * `visible` boolean - If false, the view will be hidden from display.
 
+#### `view.getVisible()`
+
+Returns `boolean` - Whether the view should be drawn. Note that this is
+different from whether the view is visible on screen—it may still be obscured
+or out of view.
+
 ### Instance Properties
 
 Objects created with `new View` have the following properties:

filename: shell/browser/api/electron_api_view.cc
patch: @@ -387,6 +387,10 @@ void View::SetVisible(bool visible) {
   view_->SetVisible(visible);
 }
 
+bool View::GetVisible() const {
+  return view_ ? view_->GetVisible() : false;
+}
+
 void View::OnViewBoundsChanged(views::View* observed_view) {
   ApplyBorderRadius();
   Emit("bounds-changed");
@@ -445,7 +449,8 @@ void View::BuildPrototype(v8::Isolate* isolate,
       .SetMethod("setBackgroundColor", &View::SetBackgroundColor)
       .SetMethod("setBorderRadius", &View::SetBorderRadius)
       .SetMethod("setLayout", &View::SetLayout)
-      .SetMethod("setVisible", &View::SetVisible);
+      .SetMethod("setVisible", &View::SetVisible)
+      .SetMethod("getVisible", &View::GetVisible);
 }
 
 }  // namespace electron::api

filename: shell/browser/api/electron_api_view.h
patch: @@ -45,6 +45,7 @@ class View : public gin_helper::EventEmitter<View>,
   void SetBackgroundColor(std::optional<WrappedSkColor> color);
   void SetBorderRadius(int radius);
   void SetVisible(bool visible);
+  bool GetVisible() const;
 
   // views::ViewObserver
   void OnViewBoundsChanged(views::View* observed_view) override;

filename: spec/api-view-spec.ts
patch: @@ -79,4 +79,17 @@ describe('View', () => {
     v.setBorderRadius(9999999);
     v.setBorderRadius(-9999999);
   });
+
+  describe('view.getVisible|setVisible', () => {
+    it('is visible by default', () => {
+      const v = new View();
+      expect(v.getVisible()).to.be.true();
+    });
+
+    it('can be set to not visible', () => {
+      const v = new View();
+      v.setVisible(false);
+      expect(v.getVisible()).to.be.false();
+    });
+  });
 });
Repository: nodejs/node
Pull request: test: force GC in test-file-write-stream4

Reduce `test/parallel/test-file-write-stream4.js` flakiness.

Refs: https://github.com/nodejs/node/pull/57927

<!--
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: test/parallel/test-file-write-stream4.js
patch: @@ -1,3 +1,4 @@
+// Flags: --expose-gc
 'use strict';
 
 // Test that 'close' emits once and not twice when `emitClose: true` is set.
@@ -17,4 +18,8 @@ const fileWriteStream = fs.createWriteStream(filepath, {
 });
 
 fileReadStream.pipe(fileWriteStream);
-fileWriteStream.on('close', common.mustCall());
+fileWriteStream.on('close', common.mustCall(() => {
+  // TODO(lpinca): Remove the forced GC when
+  // https://github.com/nodejs/node/issues/54918 is fixed.
+  globalThis.gc({ type: 'major' });
+}));
Repository: denoland/deno
Pull request: fix(lsp): filter scheme in semantic tokens registration options

Fixes https://github.com/denoland/vscode_deno/issues/1280.

It seems if you explicitly list a document filter in some capability configuration, it will override (not intersect) the document filter specified by the client.

Changed files:
filename: cli/lsp/capabilities.rs
patch: @@ -39,30 +39,33 @@ fn code_action_capabilities(
 
 pub fn semantic_tokens_registration_options(
 ) -> SemanticTokensRegistrationOptions {
+  const LANGUAGES: [&str; 4] = [
+    "javascript",
+    "javascriptreact",
+    "typescript",
+    "typescriptreact",
+  ];
+  const SCHEMES: [&str; 5] = [
+    "file",
+    "untitled",
+    "deno",
+    "vscode-notebook-cell",
+    "deno-notebook-cell",
+  ];
+  let mut document_filters =
+    Vec::with_capacity(LANGUAGES.len() * SCHEMES.len());
+  for language in &LANGUAGES {
+    for scheme in &SCHEMES {
+      document_filters.push(DocumentFilter {
+        language: Some(language.to_string()),
+        scheme: Some(scheme.to_string()),
+        pattern: None,
+      });
+    }
+  }
   SemanticTokensRegistrationOptions {
     text_document_registration_options: TextDocumentRegistrationOptions {
-      document_selector: Some(vec![
-        DocumentFilter {
-          language: Some("javascript".to_string()),
-          scheme: None,
-          pattern: None,
-        },
-        DocumentFilter {
-          language: Some("javascriptreact".to_string()),
-          scheme: None,
-          pattern: None,
-        },
-        DocumentFilter {
-          language: Some("typescript".to_string()),
-          scheme: None,
-          pattern: None,
-        },
-        DocumentFilter {
-          language: Some("typescriptreact".to_string()),
-          scheme: None,
-          pattern: None,
-        },
-      ]),
+      document_selector: Some(document_filters),
     },
     semantic_tokens_options: SemanticTokensOptions {
       legend: get_legend(),
Repository: facebook/react
Pull request: Remove unreferenced react-native-host-hooks from flow

## Summary

These modules are no longer referenced in the React codebase. We should remove them to limit the API surface area between React and React Native.

## How did you test this change?

`yarn flow native && yarn flow fabric`

Changed files:
filename: scripts/flow/react-native-host-hooks.js
patch: @@ -230,33 +230,3 @@ declare var nativeFabricUIManager: {
   unstable_getCurrentEventPriority: () => number,
   ...
 };
-
-declare module 'View' {
-  declare module.exports: typeof React$Component;
-}
-
-declare module 'RTManager' {
-  declare function createNode(
-    tag: number,
-    classType: string,
-    props: ?Object,
-  ): void;
-
-  declare function beginUpdates(): void;
-
-  declare function appendChildToContext(
-    contextTag: number,
-    childTag: number,
-  ): void;
-  declare function appendChild(parentTag: number, childTag: number): void;
-  declare function prependChild(childTag: number, beforeTag: number): void;
-  declare function deleteChild(childTag: number): void;
-  declare function updateNode(tag: number, props: ?Object): void;
-
-  declare function completeUpdates(): void;
-}
-
-// shims/ReactFeatureFlags is generated by the packaging script
-declare module '../shims/ReactFeatureFlags' {
-  declare export var debugRenderPhaseSideEffects: boolean;
-}
Repository: denoland/deno
Pull request: fix(npm): use Deno instead of Node in more cases for lifecycle scripts

Also adds some unstable flags so more things work.

Changed files:
filename: cli/task_runner.rs
patch: @@ -276,8 +276,8 @@ impl ShellCommand for NodeCommand {
     // run with deno if it's a simple invocation, fall back to node
     // if there are extra flags
     let mut args: Vec<OsString> = Vec::with_capacity(context.args.len());
-    if context.args.len() > 1
-      && ({
+    if context.args.is_empty()
+      || ({
         let first_arg = context.args[0].to_string_lossy();
         first_arg.starts_with('-') // has a flag
         || !matches!(
@@ -290,7 +290,15 @@ impl ShellCommand for NodeCommand {
         .execute(context);
     }
 
-    args.extend(["run".into(), "-A".into()]);
+    args.extend([
+      "run".into(),
+      "-A".into(),
+      "--unstable-bare-node-builtins".into(),
+      "--unstable-detect-cjs".into(),
+      "--unstable-node-globals".into(),
+      "--unstable-sloppy-imports".into(),
+      "--unstable-unsafe-proto".into(),
+    ]);
     args.extend(context.args);
 
     let mut state = context.state;
Repository: vercel/next.js
Pull request: [turbopack] Remove an unnecessary clone

It's dead, Jim!!

Closes PACK-4972

Changed files:
filename: turbopack/crates/turbo-tasks-backend/src/backend/mod.rs
patch: @@ -1553,7 +1553,6 @@ impl<B: BackingStorage> TurboTasksBackendInner<B> {
                 )
             }
             TaskType::Transient(task_type) => {
-                let task_type = task_type.clone();
                 let span = tracing::trace_span!("turbo_tasks::root_task");
                 let future = match &*task_type {
                     TransientTask::Root(f) => f(),
Repository: vercel/next.js
Pull request: [devtool] enable segment explorer when new panel present by default

Ensure the segment explorer is enabled when enabling the new panel UI is enabled

Changed files:
filename: packages/next/src/server/config-shared.ts
patch: @@ -1356,7 +1356,6 @@ export const defaultConfig = {
       static: process.env.NEXT_STATIC_CACHE_HANDLER_PATH,
     },
     cssChunking: true,
-    devtoolNewPanelUI: process.env.__NEXT_DEVTOOL_NEW_PANEL_UI === 'true',
     multiZoneDraftMode: false,
     appNavFailHandling: false,
     prerenderEarlyExit: true,
@@ -1456,7 +1455,8 @@ export const defaultConfig = {
     useCache: undefined,
     slowModuleDetection: undefined,
     globalNotFound: false,
-    devtoolSegmentExplorer: false,
+    devtoolNewPanelUI: process.env.__NEXT_DEVTOOL_NEW_PANEL_UI === 'true',
+    devtoolSegmentExplorer: process.env.__NEXT_DEVTOOL_NEW_PANEL_UI === 'true',
   },
   htmlLimitedBots: undefined,
   bundlePagesRouterDependencies: false,

filename: packages/next/src/server/config.ts
patch: @@ -493,6 +493,10 @@ function assignDefaults(
     }
   }
 
+  if (result.experimental.devtoolNewPanelUI) {
+    result.experimental.devtoolSegmentExplorer = true
+  }
+
   warnCustomizedOption(
     result,
     'experimental.esmExternals',
Repository: denoland/deno
Pull request: fix(runtime): fix duplicate unstable ids for no-legacy-abort


Changed files:
filename: runtime/js/90_deno_ns.js
patch: @@ -158,13 +158,14 @@ const unstableIds = {
   http: 5,
   kv: 6,
   net: 7,
-  nodeGlobals: 8,
-  otel: 9,
-  process: 10,
-  temporal: 11,
-  unsafeProto: 12,
-  webgpu: 13,
-  workerOptions: 14,
+  noLegacyAbort: 8,
+  nodeGlobals: 9,
+  otel: 10,
+  process: 11,
+  temporal: 12,
+  unsafeProto: 13,
+  webgpu: 14,
+  workerOptions: 15,
 };
 
 const denoNsUnstableById = { __proto__: null };

filename: runtime/lib.rs
patch: @@ -110,52 +110,52 @@ pub static UNSTABLE_GRANULAR_FLAGS: &[UnstableGranularFlag] = &[
     name: "no-legacy-abort",
     help_text: "Enable abort signal in Deno.serve without legacy behavior. This will not abort the server when the request is handled successfully.",
     show_in_help: true,
-    id: 13,
+    id: 8,
   },
   UnstableGranularFlag {
     name: "node-globals",
     help_text: "Expose Node globals everywhere",
     show_in_help: true,
-    id: 8,
+    id: 9,
   },
   UnstableGranularFlag {
     name: "otel",
     help_text: "Enable unstable OpenTelemetry features",
     show_in_help: false,
-    id: 9,
+    id: 10,
   },
   // TODO(bartlomieju): consider removing it
   UnstableGranularFlag {
     name: deno_process::UNSTABLE_FEATURE_NAME,
     help_text: "Enable unstable process APIs",
     show_in_help: false,
-    id: 10,
+    id: 11,
   },
   UnstableGranularFlag {
     name: "temporal",
     help_text: "Enable unstable Temporal API",
     show_in_help: true,
-    id: 11,
+    id: 12,
   },
   UnstableGranularFlag {
     name: "unsafe-proto",
     help_text: "Enable unsafe __proto__ support. This is a security risk.",
     show_in_help: true,
     // This number is used directly in the JS code. Search
     // for "unstableIds" to see where it's used.
-    id: 12,
+    id: 13,
   },
   UnstableGranularFlag {
     name: deno_webgpu::UNSTABLE_FEATURE_NAME,
     help_text: "Enable unstable `WebGPU` APIs",
     show_in_help: true,
-    id: 13,
+    id: 14,
   },
   UnstableGranularFlag {
     name: ops::worker_host::UNSTABLE_FEATURE_NAME,
     help_text: "Enable unstable Web Worker APIs",
     show_in_help: true,
-    id: 14,
+    id: 15,
   },
 ];