helloadhavan/github_issues huggingface dataset:
Repository: ollama/ollama
Pull request: fix dkms on debian

debian installs dkms into `/usr/sbin`

Changed files:
filename: scripts/install.sh
patch: @@ -204,7 +204,7 @@ if ! lsmod | grep -q nvidia; then
         debian|ubuntu) $SUDO apt-get -y install linux-headers-$KERNEL_RELEASE ;;
     esac
 
-    NVIDIA_CUDA_VERSION=$(dkms status | awk -F: '/added/ { print $1 }')
+    NVIDIA_CUDA_VERSION=$($SUDO dkms status | awk -F: '/added/ { print $1 }')
     if [ -n "$NVIDIA_CUDA_VERSION" ]; then
         $SUDO dkms install $NVIDIA_CUDA_VERSION
     fi
Repository: ggml-org/llama.cpp
Pull request: ggml: fix CUDA grid launch condition for large block_nums.y in binbcast

This PR fixes a potential CUDA grid launch issue in `binbcast.cu`.
Previously, only the `z` dimension (`block_nums.z`) was checked against the CUDA grid limit (65535).
However, the `y` dimension can also exceed this limit for large tensors, leading to an invalid grid configuration and potential launch failure.

The fix adds a check for `block_nums.y > 65535` to prevent grid dimension overflow.


Changed files:
filename: ggml/src/ggml-cuda/binbcast.cu
patch: @@ -272,7 +272,7 @@ static void launch_bin_bcast_pack(const ggml_tensor * src0, const ggml_tensor *
         const uint3 ne12 = init_fastdiv_values((uint32_t) cne1[2]);
         const uint3 ne13 = init_fastdiv_values((uint32_t) cne1[3]);
 
-        if (block_nums.z > 65535) {
+        if (block_nums.z > 65535 || block_nums.y > 65535) {
             int         block_num  = (ne0 * ne1 * ne2 * ne3 + block_size - 1) / block_size;
             const uint3 prod_012    = init_fastdiv_values((uint32_t) (ne0 * ne1 * ne2));
             const uint3 prod_01     = init_fastdiv_values((uint32_t) (ne0 * ne1));

filename: tests/test-backend-ops.cpp
patch: @@ -6407,6 +6407,7 @@ static std::vector<std::unique_ptr<test_case>> make_test_cases_eval() {
         add_test_bin_bcast(type, {1, 1, 640, 1}, {32, 32, 1, 1});
         add_test_bin_bcast(type, {5120, 1, 1, 1}, {1, 256, 1, 1});
         add_test_bin_bcast(type, {640, 1, 1, 1}, {1, 1, 1, 1});
+        add_test_bin_bcast(type, {64, 262144, 1, 1}, {1, 1, 1, 1});
         //add_test_bin_bcast(type, {3, 3, 2560, 1280}, {1, 1, 1, 1});
         //add_test_bin_bcast(type, {3, 3, 2560, 1280}, {2, 1, 1, 1});
     }
Repository: ollama/ollama
Pull request: fix dkms install


Changed files:
filename: scripts/install.sh
patch: @@ -138,7 +138,6 @@ install_cuda_driver_yum() {
     esac
 
     status 'Installing CUDA driver...'
-    $SUDO $PACKAGE_MANAGER -y update
 
     if [ "$1" = 'centos' ] || [ "$1$2" = 'rhel7' ]; then
         $SUDO $PACKAGE_MANAGER -y install nvidia-driver-latest-dkms
@@ -192,7 +191,7 @@ if ! check_gpu nvidia-smi || [ -z "$(nvidia-smi | grep -o "CUDA Version: [0-9]*\
     case $OS_NAME in
         centos|rhel) install_cuda_driver_yum 'rhel' $OS_VERSION ;;
         rocky) install_cuda_driver_yum 'rhel' $(echo $OS_VERSION | cut -c1) ;;
-        fedora) install_cuda_driver_dnf $OS_NAME $OS_VERSION ;;
+        fedora) install_cuda_driver_yum $OS_NAME $OS_VERSION ;;
         debian) install_cuda_driver_apt $OS_NAME $OS_VERSION ;;
         ubuntu) install_cuda_driver_apt $OS_NAME $(echo $OS_VERSION | sed 's/\.//') ;;
     esac
@@ -205,6 +204,10 @@ if ! lsmod | grep -q nvidia; then
         debian|ubuntu) $SUDO apt-get -y install linux-headers-$KERNEL_RELEASE ;;
     esac
 
-    $SUDO dkms status | awk -F: '/added/ { print $1 }' | xargs -n1 $SUDO dkms install
+    NVIDIA_CUDA_VERSION=$(dkms status | awk -F: '/added/ { print $1 }')
+    if [ -n "$NVIDIA_CUDA_VERSION" ]; then
+        $SUDO dkms install $NVIDIA_CUDA_VERSION
+    fi
+
     $SUDO modprobe nvidia
 fi
Repository: denoland/deno
Pull request: fix(cache): cache and uninstall are package manager subcommands


Changed files:
filename: cli/factory.rs
patch: @@ -1264,6 +1264,8 @@ fn new_workspace_factory_options(
     is_package_manager_subcommand: matches!(
       flags.subcommand,
       DenoSubcommand::Install(_)
+        | DenoSubcommand::Uninstall(_)
+        | DenoSubcommand::Cache(_)
         | DenoSubcommand::Add(_)
         | DenoSubcommand::Remove(_)
         | DenoSubcommand::Init(_)
Repository: vercel/next.js
Pull request: fix: remove a few old references to 'next lint'


Changed files:
filename: docs/01-app/01-getting-started/01-installation.mdx
patch: @@ -66,7 +66,7 @@ Then, add the following scripts to your `package.json` file:
     "dev": "next dev",
     "build": "next build",
     "start": "next start",
-    "lint": "next lint"
+    "lint": "eslint"
   }
 }
 ```
@@ -76,7 +76,7 @@ These scripts refer to the different stages of developing an application:
 - `next dev`: Starts the development server.
 - `next build`: Builds the application for production.
 - `next start`: Starts the production server.
-- `next lint`: Runs ESLint.
+- `eslint`: Runs ESLint.
 
 <AppOnly>
 

filename: docs/01-app/02-guides/testing/cypress.mdx
patch: @@ -42,7 +42,7 @@ Add the Cypress `open` command to the `package.json` scripts field:
     "dev": "next dev",
     "build": "next build",
     "start": "next start",
-    "lint": "next lint",
+    "lint": "eslint",
     "cypress:open": "cypress open"
   }
 }
Repository: ollama/ollama
Pull request: update install.sh

minor changes to warnings/errors

Changed files:
filename: scripts/install.sh
patch: @@ -35,15 +35,19 @@ SUDO=
 if [ "$(id -u)" -ne 0 ]; then
     # Running as root, no need for sudo
     if ! command -v sudo >/dev/null; then
-        error "Ollama install.sh requires elevated privileges. Please re-run as root."
+        error "This script requires superuser permissions. Please re-run as root."
     fi
 
     SUDO="sudo"
 fi
 
 MISSING_TOOLS=$(required_tools curl awk grep sed tee xargs)
 if [ -n "$MISSING_TOOLS" ]; then
-    error "The following tools are required but missing: $MISSING_TOOLS"
+    status "ERROR: The following tools are required but missing:"
+    for MISSING_TOOL in $MISSING_TOOLS; do
+        echo "  - $MISSING_TOOL"
+    done
+    exit 1
 fi
 
 status "Downloading ollama..."
@@ -81,12 +85,15 @@ Environment="HOME=/usr/share/ollama"
 [Install]
 WantedBy=default.target
 EOF
-    if [ "$(systemctl is-system-running || echo 'not running')" = 'running' ]; then 
-        status "Enabling and starting ollama service..."
-        $SUDO systemctl daemon-reload
-        $SUDO systemctl enable ollama
-        $SUDO systemctl restart ollama
-    fi
+    SYSTEMCTL_RUNNING="$(systemctl is-system-running)"
+    case $SYSTEMCTL_RUNNING in
+        running|degraded)
+            status "Enabling and starting ollama service..."
+            $SUDO systemctl daemon-reload
+            $SUDO systemctl enable ollama
+            $SUDO systemctl restart ollama
+            ;;
+    esac
 }
 
 if command -v systemctl >/dev/null; then
@@ -118,7 +125,7 @@ install_cuda_driver_yum() {
             $SUDO $PACKAGE_MANAGER-config-manager --add-repo https://developer.download.nvidia.com/compute/cuda/repos/$1$2/$(uname -m)/cuda-$1$2.repo
             ;;
         dnf)
-            $SUDO dnf config-manager --add-repo https://developer.download.nvidia.com/compute/cuda/repos/$1$2/$(uname -m)/cuda-$1$2.repo
+            $SUDO $PACKAGE_MANAGER config-manager --add-repo https://developer.download.nvidia.com/compute/cuda/repos/$1$2/$(uname -m)/cuda-$1$2.repo
             ;;
     esac
 
@@ -156,7 +163,9 @@ install_cuda_driver_apt() {
     status 'Installing CUDA driver...'
     $SUDO dpkg -i $TEMP_DIR/cuda-keyring.deb
     $SUDO apt-get update
-    $SUDO DEBIAN_FRONTEND=noninteractive apt-get -y install cuda-drivers -q
+
+    [ -n "$SUDO" ] && SUDO_E="$SUDO -E" || SUDO_E=
+    DEBIAN_FRONTEND=noninteractive $SUDO_E apt-get -y install cuda-drivers -q
 }
 
 if [ ! -f "/etc/os-release" ]; then
@@ -184,7 +193,8 @@ if ! check_gpu nvidia-smi || [ -z "$(nvidia-smi | grep -o "CUDA Version: [0-9]*\
         centos|rhel) install_cuda_driver_yum 'rhel' $OS_VERSION ;;
         rocky) install_cuda_driver_yum 'rhel' $(echo $OS_VERSION | cut -c1) ;;
         fedora) install_cuda_driver_dnf $OS_NAME $OS_VERSION ;;
-        debian|ubuntu) install_cuda_driver_apt $OS_NAME $OS_VERSION ;;
+        debian) install_cuda_driver_apt $OS_NAME $OS_VERSION ;;
+        ubuntu) install_cuda_driver_apt $OS_NAME $(echo $OS_VERSION | sed 's/\.//') ;;
     esac
 fi
Repository: electron/electron
Pull request: perf: avoid redundant map lookup in `HidChooserContext::DeviceChanged()`

Backport of #46451

See that PR for details.


Notes: none.

Changed files:
filename: shell/browser/hid/hid_chooser_context.cc
patch: @@ -274,10 +274,11 @@ void HidChooserContext::DeviceRemoved(device::mojom::HidDeviceInfoPtr device) {
 
 void HidChooserContext::DeviceChanged(device::mojom::HidDeviceInfoPtr device) {
   DCHECK(device);
-  DCHECK(devices_.contains(device->guid));
 
   // Update the device list.
-  devices_[device->guid] = device->Clone();
+  auto& mapped = devices_[device->guid];
+  DCHECK(!mapped.is_null());
+  mapped = device->Clone();
 
   // Notify all observers.
   for (auto& observer : device_observer_list_)
Repository: ollama/ollama
Pull request: fix linux installer warning logs

Fixes warnings on `lshw` command when not running as root user. Adds missing `warning` logger.

Changed files:
filename: scripts/install.sh
patch: @@ -6,6 +6,7 @@ set -eu
 
 status() { echo ">>> $*" >&2; }
 error() { echo "ERROR $*"; exit 1; }
+warning() { echo "WARNING: $*"; }
 
 TEMP_DIR=$(mktemp -d)
 cleanup() { rm -rf $TEMP_DIR; }
@@ -95,7 +96,7 @@ fi
 check_gpu() {
     case $1 in
         lspci) command -v lspci >/dev/null && lspci -d '10de:' | grep -q 'NVIDIA' || return 1 ;;
-        lshw) command -v lshw >/dev/null && lshw -c display -numeric | grep -q 'vendor: .* \[10DE\]' || return 1 ;;
+        lshw) command -v lshw >/dev/null && $SUDO lshw -c display -numeric | grep -q 'vendor: .* \[10DE\]' || return 1 ;;
         nvidia-smi) command -v nvidia-smi >/dev/null || return 1 ;;
     esac
 }
Repository: nodejs/node
Pull request: build,win: fix dll build

Fixes a linker error when building Node.js DLL with ClangCL by moving `BuiltinLoader::GetBuiltinIds()` implementation from `.h` to `.cc` file.

This PR tries different approach from https://github.com/nodejs/node/pull/58235 based on @joyeecheung's [comment](https://github.com/nodejs/node/pull/58235#issuecomment-2866756274)

Fixes: https://github.com/nodejs/node/issues/58208

Changed files:
filename: src/node_builtins.cc
patch: @@ -64,6 +64,11 @@ BuiltinLoader::BuiltinLoader()
 #endif  // HAVE_AMARO
 }
 
+std::ranges::keys_view<std::ranges::ref_view<const BuiltinSourceMap>>
+BuiltinLoader::GetBuiltinIds() const {
+  return std::views::keys(*source_.read());
+}
+
 bool BuiltinLoader::Exists(const char* id) {
   auto source = source_.read();
   return source->find(id) != source->end();

filename: src/node_builtins.h
patch: @@ -127,9 +127,9 @@ class NODE_EXTERN_PRIVATE BuiltinLoader {
 
   void CopySourceAndCodeCacheReferenceFrom(const BuiltinLoader* other);
 
-  [[nodiscard]] auto GetBuiltinIds() const {
-    return std::views::keys(*source_.read());
-  }
+  [[nodiscard]] std::ranges::keys_view<
+      std::ranges::ref_view<const BuiltinSourceMap>>
+  GetBuiltinIds() const;
 
   void SetEagerCompile() { should_eager_compile_ = true; }
Repository: electron/electron
Pull request: perf: avoid redundant map lookup in `HidChooserContext::DeviceChanged()`

Backport of #46451

See that PR for details.


Notes: none.

Changed files:
filename: shell/browser/hid/hid_chooser_context.cc
patch: @@ -277,10 +277,11 @@ void HidChooserContext::DeviceRemoved(device::mojom::HidDeviceInfoPtr device) {
 
 void HidChooserContext::DeviceChanged(device::mojom::HidDeviceInfoPtr device) {
   DCHECK(device);
-  DCHECK(devices_.contains(device->guid));
 
   // Update the device list.
-  devices_[device->guid] = device->Clone();
+  auto& mapped = devices_[device->guid];
+  DCHECK(!mapped.is_null());
+  mapped = device->Clone();
 
   // Notify all observers.
   for (auto& observer : device_observer_list_)
Repository: huggingface/transformers
Pull request: Update notification service amd_daily_ci_workflows definition

Add mi355 wf to amd_daily_ci_workflows

Changed files:
filename: utils/notification_service.py
patch: @@ -1397,8 +1397,8 @@ def pop_default(l: list[Any], i: int, default: Any) -> Any:
 
     nvidia_daily_ci_workflow = "huggingface/transformers/.github/workflows/self-scheduled-caller.yml"
     amd_daily_ci_workflows = (
-        "huggingface/transformers/.github/workflows/self-scheduled-amd-mi300-caller.yml",
         "huggingface/transformers/.github/workflows/self-scheduled-amd-mi325-caller.yml",
+        "huggingface/transformers/.github/workflows/self-scheduled-amd-mi355-caller.yml",
     )
     is_nvidia_daily_ci_workflow = os.environ.get("GITHUB_WORKFLOW_REF").startswith(nvidia_daily_ci_workflow)
     is_amd_daily_ci_workflow = os.environ.get("GITHUB_WORKFLOW_REF").startswith(amd_daily_ci_workflows)
Repository: ggml-org/llama.cpp
Pull request: webui: support q URL parameter

Fixes #16722
I’ve checked that it works with Firefox’s AI tools

I’m not sure if I have to rebuild the webui bundle in this PR or let a maintainer do it before merging.

Changed files:
filename: tools/server/webui/src/routes/+page.svelte
patch: @@ -2,13 +2,21 @@
 	import { ChatScreen } from '$lib/components/app';
 	import { chatStore, isInitialized } from '$lib/stores/chat.svelte';
 	import { onMount } from 'svelte';
+	import { page } from '$app/state';
+
+	let qParam = $derived(page.url.searchParams.get('q'));
 
 	onMount(async () => {
 		if (!isInitialized) {
 			await chatStore.initialize();
 		}
 
 		chatStore.clearActiveConversation();
+
+		if (qParam !== null) {
+			await chatStore.createConversation();
+			await chatStore.sendMessage(qParam);
+		}
 	});
 </script>
Repository: denoland/deno
Pull request: fix(ext/node): ignore Node.js' `--experimental-*` flags when spawning child process

<!--
Before submitting a PR, please read https://docs.deno.com/runtime/manual/references/contributing

1. Give the PR a descriptive title.

  Examples of good title:
    - fix(std/http): Fix race condition in server
    - docs(console): Update docstrings
    - feat(doc): Handle nested reexports

  Examples of bad title:
    - fix #7123
    - update docs
    - fix bugs

2. Ensure there is a related issue and it is referenced in the PR text.
3. Ensure there are tests that cover the changes.
4. Ensure `cargo test` passes.
5. Ensure `./tools/format.js` passes without changing files.
6. Ensure `./tools/lint.js` passes.
7. Open as a draft PR if your work is still in progress. The CI won't run
   all steps, but you can add '[ci]' to a commit message to force it to.
8. If you would like to run the benchmarks on the CI, add the 'ci-bench' label.
-->

Closes https://github.com/denoland/deno/issues/26349


Changed files:
filename: ext/node/polyfills/child_process.ts
patch: @@ -54,6 +54,7 @@ const {
   ObjectAssign,
   PromiseWithResolvers,
   StringPrototypeSlice,
+  StringPrototypeStartsWith,
 } = primordials;
 
 const MAX_BUFFER = 1024 * 1024;
@@ -135,6 +136,13 @@ export function fork(
         execArgv.splice(index, rm);
       } else if (flag.startsWith("--no-warnings")) {
         execArgv[index] = "--quiet";
+      } else if (
+        StringPrototypeStartsWith(execArgv[index], "--experimental-")
+      ) {
+        // `--experimental-*` args are ignored, because most experimental Node features
+        // are implemented in Deno, but it doens't exactly match Deno's `--unstable-*` flags.
+        execArgv.splice(index, 1);
+        index++;
       } else {
         index++;
       }

filename: ext/node/polyfills/internal/child_process.ts
patch: @@ -1275,6 +1275,9 @@ function toDenoArgs(args: string[]): [string[], string[], boolean] {
         // ignore --permission flag
       } else if (arg === "--pending-deprecation") {
         nodeOptions.push(arg);
+      } else if (StringPrototypeStartsWith(arg, "--experimental-")) {
+        // `--experimental-*` args are ignored, because most experimental Node features
+        // are implemented in Deno, but it doens't exactly match Deno's `--unstable-*` flags.
       } else {
         // Not a known flag that expects a value. Just copy it to the output.
         denoArgs.push(arg);

filename: tests/unit_node/child_process_test.ts
patch: @@ -1172,3 +1172,19 @@ Deno.test({
     );
   },
 });
+
+Deno.test(async function experimentalFlag() {
+  const code = ``;
+  const file = await Deno.makeTempFile();
+  await Deno.writeTextFile(file, code);
+  const timeout = withTimeout<void>();
+  const child = CP.fork(file, [], {
+    execArgv: ["--experimental-vm-modules"],
+    stdio: ["inherit", "inherit", "inherit", "ipc"],
+  });
+  child.on("close", () => {
+    timeout.resolve();
+  });
+
+  await timeout.promise;
+});
Repository: ollama/ollama
Pull request: Added a new community project


Changed files:
filename: README.md
patch: @@ -214,6 +214,7 @@ curl -X POST http://localhost:11434/api/generate -d '{
 | [Discord AI Bot](https://github.com/mekb-turtle/discord-ai-bot)            | Interact with Ollama as a chatbot on Discord.                                                                                                                |
 | [Raycast Ollama](https://github.com/MassimilianoPasquini97/raycast_ollama) | Raycast extension to use Ollama for local llama inference on Raycast.                                                                                        |
 | [Simple HTML UI](https://github.com/rtcfirefly/ollama-ui)                  | Also, there is a Chrome extension.                                                                                                                           |
+| [Ollama-GUI](https://github.com/ollama-interface/Ollama-Gui?tab=readme-ov-file)                  | 🖥️ Mac Chat Interface ⚡️                                                                                                                           |
 | [Emacs client](https://github.com/zweifisch/ollama)                        |                                                                                                                                                              |
 
 [1]: https://python.langchain.com/docs/integrations/llms/ollama
Repository: facebook/react
Pull request: Land useModernStrictMode in www

this has landed

Changed files:
filename: packages/shared/forks/ReactFeatureFlags.www-dynamic.js
patch: @@ -28,7 +28,6 @@ export const alwaysThrottleRetries = __VARIANT__;
 export const enableDO_NOT_USE_disableStrictPassiveEffect = __VARIANT__;
 export const enableUseDeferredValueInitialArg = __VARIANT__;
 export const enableRenderableContext = __VARIANT__;
-export const useModernStrictMode = __VARIANT__;
 export const enableRefAsProp = __VARIANT__;
 export const enableRetryLaneExpiration = __VARIANT__;
 export const favorSafetyOverHydrationPerf = __VARIANT__;

filename: packages/shared/forks/ReactFeatureFlags.www.js
patch: @@ -36,7 +36,6 @@ export const {
   transitionLaneExpirationMs,
   enableInfiniteRenderLoopDetection,
   enableRenderableContext,
-  useModernStrictMode,
   enableRefAsProp,
   favorSafetyOverHydrationPerf,
 } = dynamicFeatureFlags;
@@ -109,6 +108,7 @@ export const enableServerComponentKeys = true;
 export const enableServerComponentLogs = true;
 
 export const enableReactTestRendererWarning = false;
+export const useModernStrictMode = true;
 
 // TODO: Roll out with GK. Don't keep as dynamic flag for too long, though,
 // because JSX is an extremely hot path.
Repository: ggml-org/llama.cpp
Pull request: server: add memory breakdown print

While looking at server logs for debugging I've noticed that it does not print a memory breakdown upon shutdown. This PR simply adds the corresponding call. The breakdown is printed after cleanup because otherwise the table would become misaligned from the `^C` in console.

Changed files:
filename: tools/server/server.cpp
patch: @@ -5714,6 +5714,7 @@ int main(int argc, char ** argv) {
 
     clean_up();
     t.join();
+    llama_memory_breakdown_print(ctx_server.ctx);
 
     return 0;
 }
Repository: ollama/ollama
Pull request: fix end-of-line issue with the new prompt

The readline library had this fix which overwrote the end of the `S` in "Send a message..." which prevented the cursor from moving up the screen whenever you backspaced through the end of the line. We removed it to fix the placeholder text issue, but then the bug crept back in.

Changed files:
filename: cmd/cmd.go
patch: @@ -33,15 +33,22 @@ import (
 )
 
 type Painter struct {
-	HideHint bool
+	IsMultiLine bool
 }
 
 func (p Painter) Paint(line []rune, _ int) []rune {
 	termType := os.Getenv("TERM")
-	if termType == "xterm-256color" && len(line) == 0 && !p.HideHint {
-		prompt := "Send a message (/? for help)"
+	if termType == "xterm-256color" && len(line) == 0 {
+		var prompt string
+		if p.IsMultiLine {
+			prompt = "Use \"\"\" to end multi-line input"
+		} else {
+			prompt = "Send a message (/? for help)"
+		}
 		return []rune(fmt.Sprintf("\033[38;5;245m%s\033[%dD\033[0m", prompt, len(prompt)))
 	}
+	// add a space and a backspace to prevent the cursor from walking up the screen
+	line = append(line, []rune(" \b")...)
 	return line
 }
 
@@ -579,7 +586,7 @@ func generateInteractive(cmd *cobra.Command, model string) error {
 		case isMultiLine:
 			if strings.HasSuffix(line, `"""`) {
 				isMultiLine = false
-				painter.HideHint = false
+				painter.IsMultiLine = isMultiLine
 				multiLineBuffer += strings.TrimSuffix(line, `"""`)
 				line = multiLineBuffer
 				multiLineBuffer = ""
@@ -590,9 +597,9 @@ func generateInteractive(cmd *cobra.Command, model string) error {
 			}
 		case strings.HasPrefix(line, `"""`):
 			isMultiLine = true
+			painter.IsMultiLine = isMultiLine
 			multiLineBuffer = strings.TrimPrefix(line, `"""`) + " "
 			scanner.SetPrompt("... ")
-			painter.HideHint = true
 			continue
 		case strings.HasPrefix(line, "/list"):
 			args := strings.Fields(line)