Skip to content
This repository was archived by the owner on Jul 4, 2025. It is now read-only.
This repository was archived by the owner on Jul 4, 2025. It is now read-only.

bug: cortex update stdouts "Update cortex sucessfully" even when update failed #1257

@freelerobot

Description

@freelerobot

Cortex version

v65->v67

Describe the Bug

  1. User runs cortex update
  2. For some reason update fails (cut wifi halfway), we still log "Update cortex successfully"
  3. Expected: stdout that the update failed, missing permissions, etc.
❯ cortex-nightly -v
v0.5.0-65

A new release of cortex is available: v0.5.0-65 -> v0.5.0-67
To upgrade, run: cortex-nightly update
❯ cortex-nightly update
Server is running. Stopping server before updating!
HTTP error: Failed to read connection
Validating download items, please wait..
Start downloading: cortex-nightly.tar.gz
  % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
                                 Dload  Upload   Total   Spent    Left  Speed
100 11.6M  100 11.6M    0     0  41.8M      0 --:--:-- --:--:-- --:--:-- 42.0M
Update cortex sucessfully
❯ cortex-nightly
libc++abi: terminating due to uncaught exception of type std::__1::__fs::filesystem::filesystem_error: filesystem error: in create_directories: Permission denied ["/Users/nicolezhu/cortexcpp-nightly/models"]
[1]    10434 abort      cortex-nightly

How I fixed it:

  1. I just ran sudo cortex update
  2. And everything worked fine
❯ sudo cortex-nightly update
Password:
Validating download items, please wait..
Start downloading: cortex-nightly.tar.gz
  % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
                                 Dload  Upload   Total   Spent    Left  Speed
100 11.6M  100 11.6M    0     0  40.2M      0 --:--:-- --:--:-- --:--:-- 40.3M
Update cortex sucessfully
❯ cortex-nightly
Cortex.cpp CLI
cortex-nightly [OPTIONS] [SUBCOMMAND]

Options:
  -h,--help                   Print this help message and exit
  --verbose                   Verbose logging

Steps to Reproduce

No response

Screenshots / Logs

No response

What is your OS?

  • MacOS
  • Windows
  • Linux

What engine are you running?

  • cortex.llamacpp (default)
  • cortex.tensorrt-llm (Nvidia GPUs)
  • cortex.onnx (NPUs, DirectML)

Metadata

Metadata

Labels

Type

No type

Projects

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions