winpax/sfsu

Bug Report: Scoop Path Recognition Issue, sfsu crashed on all sub command

Closed this issue · 2 comments

Description

It appears that sfsu does not recognize the correct path of Scoop. While the Scoop CLI operates correctly, both hok and sfsu fail to function properly.

Steps to Reproduce

  1. Reset Windows 10 PC.

  2. Reinstall Scoop using the following commands:

    $env:SCOOP='D:\scoop\Scoop'
    $env:SCOOP_GLOBAL='D:\scoop\GlobalScoopApps'
    [Environment]::SetEnvironmentVariable('SCOOP_GLOBAL', $env:SCOOP_GLOBAL, 'Machine')
    irm get.scoop.sh | iex

Crash Log

"name" = "sfsu"
"operating_system" = "Windows 10.0.19045 (Windows 10 IoT Enterprise) [64-bit]"
"crate_version" = """
1.14.0
sprinkles 0.16.0 (git rev: be8ed0c7f3b680758e3909fdeed499cb722f0068)
branch:
tag:v1.14.0
commit_hash:179e02b0
build_time:2024-06-12 08:20:20 +00:00
build_env:rustc 1.80.0-nightly (867900499 2024-05-23),nightly-2024-05-24-x86_64-pc-windows-msvc
libgit2:1.7.2"""
"explanation" = '''
Panic occurred in file 'C:\Users\runneradmin/.cargo\git\checkouts\sprinkles-1ae7f229d9e11ff9\be8ed0c\src\contexts\user.rs' at line 36
'''
"cause" = "Scoop path does not exist"
"method" = "Panic"
"backtrace" = """

   0: 0x7ff6c84f0958 - <unresolved>
   1: 0x7ff6c84ecdc1 - <unresolved>
   2: 0x7ff6c82a44b6 - <unresolved>
   3: 0x7ff6c84f39d7 - <unresolved>
   4: 0x7ff6c8cc66bc - git_midx_writer_new
   5: 0x7ffc15747344 - BaseThreadInitThunk
   6: 0x7ffc175fcc91 - RtlUserThreadStart
"""

Additional Information

  • The issue occurs after resetting the Windows 10 PC and reinstalling Scoop using the provided commands.
  • The hok and sfsu tools do not recognize the Scoop path, leading to a panic as shown in the crash log.
  • error still occur even after I restart my pc

Can you upload the contents of your scoop config.json file (without private info such as API keys), and in a fresh shell (close and reopen completely) run the following and upload the output:

echo $env:SCOOP
echo $env:SCOOP_GLOBAL

Thanks

Thank you for the guidance! I discovered that the $env:SCOOP and $env:SCOOP_GLOBAL environment variables were not set in my system.

After manually adding them as user environment variables in my Windows settings, the issue is now resolved.