docs(mkdocs): add ahk exe troubleshooting section

This commit is contained in:
LGUG2Z
2024-05-10 14:50:41 -07:00
parent 1accbf65ca
commit c47cf4718b
+69 -51
View File
@@ -1,5 +1,23 @@
# Troubleshooting # Troubleshooting
## AutoHotKey executable not found
If you try to start komorebi with AHK using `komorebic start --ahk`, and you have
not installed AHK using `scoop`, you'll probably receive an error:
```text
Error: could not find autohotkey, please make sure it is installed before using the --ahk flag
```
Depending on how AHK is installed the executable on your system may have a
different name. In order to account for this, you may set the `KOMOREBI_AHK_EXE`
environment variable in your
[PowerShell profile](https://learn.microsoft.com/en-us/powershell/module/microsoft.powershell.core/about/about_profiles?view=powershell-7.4)
to match the name of the executable as it is found on your system.
After setting `KOMOREBI_AHK_EXE` make sure to either reload your PowerShell
profile or open a new terminal tab.
## Komorebi is unresponsive when the display wakes from sleep ## Komorebi is unresponsive when the display wakes from sleep
This can happen in rare cases when your monitor state is not preserved after it This can happen in rare cases when your monitor state is not preserved after it
@@ -36,71 +54,71 @@ running `komorebic stop` and `komorebic start`.
1. **`komorebic state`** 1. **`komorebic state`**
```json ```json
{ {
"monitors": { "monitors": {
"elements": [ "elements": [
{ {
"id": 65537, "id": 65537,
"name": "DISPLAY1", "name": "DISPLAY1",
"device": "SAM71AA", "device": "SAM71AA",
"device_id": "SAM71AA-5&a1a3e88&0&UID24834", "device_id": "SAM71AA-5&a1a3e88&0&UID24834",
"size": { "size": {
"left": 0, "left": 0,
"top": 0, "top": 0,
"right": 5120, "right": 5120,
"bottom": 1440 "bottom": 1440
} }
} }
] ]
} }
} }
``` ```
This appears to be fine -- _komorebi_ is aware of the device and associated This appears to be fine -- _komorebi_ is aware of the device and associated
window handles. window handles.
2. **Let your display go to sleep.** 2. **Let your display go to sleep.**
Simply turning the monitor off is not enough to reproduce the problem; you must Simply turning the monitor off is not enough to reproduce the problem; you must
let Windows turn off the display itself. let Windows turn off the display itself.
To avoid waiting an eternity: To avoid waiting an eternity:
- _Control Panel_ -> _Hardware and Sound_ -> _Power Options_ -> _Edit Plan - _Control Panel_ -> _Hardware and Sound_ -> _Power Options_ -> _Edit Plan
Settings_ Settings_
_Turn off the display: 1 minute_ _Turn off the display: 1 minute_
Allow a minute for the display to reset, then once it actually shuts off Allow a minute for the display to reset, then once it actually shuts off
allow for any additional time as prompted by your monitor for the cycle to allow for any additional time as prompted by your monitor for the cycle to
complete. complete.
3. **Wake your display again** by pressing any key. 3. **Wake your display again** by pressing any key.
_komorebi_ should now be unresponsive. _komorebi_ should now be unresponsive.
4. **`komorebic state`** 4. **`komorebic state`**
Don't stop _komorebi_ just yet. Don't stop _komorebi_ just yet.
Since it's unresponsive, you can open another shell instead to execute the above command. Since it's unresponsive, you can open another shell instead to execute the above command.
```json ```json
{ {
"monitors": { "monitors": {
"elements": [ "elements": [
{ {
"id": 65537, "id": 65537,
"name": "DISPLAY1", "name": "DISPLAY1",
"device": null, "device": null,
"device_id": null, "device_id": null
} }
] ]
} }
} }
``` ```
We can see the _komorebi_ state is no longer associated with the previous We can see the _komorebi_ state is no longer associated with the previous
device: `null`, suggesting an issue when the display resumes from a suspended device: `null`, suggesting an issue when the display resumes from a suspended
state. state.