-
Notifications
You must be signed in to change notification settings - Fork 0
Troubleshooting
Common issues and solutions across the PotentPowershell scripts.
Symptom:
.\script.ps1 : File cannot be loaded because running scripts is disabled on this system.
Cause: The PowerShell execution policy is blocking the script.
Fix:
# Check current policy
Get-ExecutionPolicy -List
# Allow local scripts for current user (recommended)
Set-ExecutionPolicy RemoteSigned -Scope CurrentUser
# Or for a one-time run without changing the policy
powershell.exe -ExecutionPolicy Bypass -File ".\script.ps1"Cause: The script requires elevated privileges.
Fix:
- Right-click the PowerShell shortcut → "Run as administrator".
- Then run the script normally.
Or launch via the command line:
Start-Process powershell -Verb RunAsSome scripts auto-elevate (they call Start-Process ... -Verb RunAs and exit). Others check and exit with a message. The script header comment (.NOTES block) specifies which behavior applies.
Symptom: The inline Chocolatey install via Invoke-Expression (... DownloadString('https://chocolatey.org/install.ps1')) fails with a TLS or download error.
Fix:
# Force TLS 1.2
[Net.ServicePointManager]::SecurityProtocol = [Net.SecurityProtocolType]::Tls12
Set-ExecutionPolicy Bypass -Scope Process -Force
Invoke-Expression ((New-Object System.Net.WebClient).DownloadString('https://chocolatey.org/install.ps1'))Or install Chocolatey manually following the official instructions.
Symptom: "No errors found in the Application or System logs within the past N days."
Causes and fixes:
- Genuinely no errors — run
Get-EventLog -LogName System -EntryType Error -Newest 5to verify. - Running without admin — some log entries require elevation. Re-run as admin.
-
-DaysBacktoo narrow — try a larger value:.\Get-ErrorReport.ps1 -DaysBack 30.
Cause: chkdsk /r cannot run on a live (in-use) volume. This is expected behavior for the C: drive.
What happens: chkdsk schedules itself to run at the next boot and prompts to confirm. Type Y and reboot when ready.
Cause: Sandboxie Plus is not installed at any of the searched paths.
Fix:
- Install Sandboxie Plus via the official releases or via Scoop (
scoop install sandboxie-plus-np). - If installed to a custom path, edit
$PossibleSandboxiePathsin the script to add your path.
This is a known bug in the script. The per-game loop searches for appmanifests in the wrong location.
Workaround: Use steam://validate/<appid> for individual games. See Scripts-Gaming for details.
Cause: Several cmdlets in this script (Enable-IAMMFA, Test-IAMMFA, Initialize-AWSSSO) do not exist in standard AWS.Tools module releases.
Fix: This script is a guided checklist, not a fully runnable automation. Use it as a reference and perform the flagged steps manually via the AWS Console or the correct AWS.Tools cmdlets for your installed version. Run Get-Command *MFA*, Get-Command *SSO* to find what is available in your environment.
Cause: python may not be on the PATH, or may point to a different version than expected after removal steps.
Fix:
# Check what 'python' resolves to
(Get-Command python).Source
# Run pip upgrade for a specific interpreter
& "C:\Python312\python.exe" -m pip install --upgrade pipCause: Discord rejected the payload — usually an empty -Title or -Description, or a malformed -Author hashtable.
Fix: Ensure all mandatory parameters are non-empty. For -Author, provide both name and icon_url keys:
$author = @{ name = "My Bot"; icon_url = "https://example.com/icon.png" }The icon_url must be a valid HTTPS image URL. If you don't need an author icon, omit the -Author parameter entirely.