mirror of
https://github.com/jokob-sk/NetAlertX.git
synced 2025-12-07 09:36:05 -08:00
📚 docs + guess_icon logging
This commit is contained in:
@@ -76,3 +76,16 @@ In the above output notice the section logging how many events are produced by t
|
||||
These values, if formatted correctly, will also show up in the UI:
|
||||
|
||||

|
||||
|
||||
|
||||
### Sharing application state
|
||||
|
||||
Sometimes specific log sections are needed to debug issues. The Devices and CurrentScan table data is sometimes needed to figure out what's wrong.
|
||||
|
||||
1. Please set `LOG_LEVEL` to `trace` (Disable it once you have the info as this produces big log files).
|
||||
2. Wait for the issue to occur.
|
||||
3. Search for `================ DEVICES table content ================` in your logs.
|
||||
4. Search for `================ CurrentScan table content ================` in your logs.
|
||||
5. Open a new issue and post (redacted) output into the issue description (or send to the netalertx@gmail.com email if sensitive data present).
|
||||
6. Please set `LOG_LEVEL` to `debug` or lower.
|
||||
|
||||
|
||||
@@ -49,6 +49,17 @@ services:
|
||||
# Other service configurations...
|
||||
```
|
||||
|
||||
## 5. Sharing application state
|
||||
|
||||
Sometimes specific log sections are needed to debug issues. The Devices and CurrentScan table data is sometimes needed to figure out what's wrong.
|
||||
|
||||
1. Please set `LOG_LEVEL` to `trace` (Disable it once you have the info as this produces big log files).
|
||||
2. Wait for the issue to occur.
|
||||
3. Search for `================ DEVICES table content ================` in your logs.
|
||||
4. Search for `================ CurrentScan table content ================` in your logs.
|
||||
5. Open a new issue and post (redacted) output into the issue description (or send to the netalertx@gmail.com email if sensitive data present).
|
||||
6. Please set `LOG_LEVEL` to `debug` or lower.
|
||||
|
||||
## 📃Common issues
|
||||
|
||||
### Permissions
|
||||
|
||||
@@ -678,6 +678,9 @@ icons = {
|
||||
#-------------------------------------------------------------------------------
|
||||
# Guess device icon
|
||||
def guess_icon(vendor, mac, ip, name, default):
|
||||
|
||||
mylog('debug', [f"[guess_icon] Guessing icon for (vendor|mac|ip|name): ('{vendor}'|'{mac}'|{ip}|{name})"])
|
||||
|
||||
result = default
|
||||
mac = mac.upper()
|
||||
vendor = vendor.lower() if vendor else "unknown"
|
||||
@@ -706,7 +709,7 @@ def guess_icon(vendor, mac, ip, name, default):
|
||||
result = icons.get("microchip")
|
||||
|
||||
# Guess icon based on MAC address patterns
|
||||
elif mac == "INTERNET": # Apple
|
||||
elif mac == "INTERNET":
|
||||
result = icons.get("globe")
|
||||
elif mac.startswith("00:1A:79"): # Apple
|
||||
result = icons.get("apple")
|
||||
|
||||
Reference in New Issue
Block a user