Closed joestump closed 4 months ago
It's the most broken on Firefox:
Hi there,
Can you please try to refresh the cache by clicking this button:
@jokob-sk that fixed it. 👍🏼 How do I avoid in the future?
I will keep imroving the app - the current cache expiration and re-caching mechanism isn't too reliable so I will have a look how to improve it. Thanks for the patience. If anyone wants to help, have a look at the common.js file first initialization sequence, below this section:
// -----------------------------------------------------------------------------
// initialize
// -----------------------------------------------------------------------------
In the mean time I already implemented some changes so if you'd like feel free to test the netalertx-dev
image to check, if the issues are still occurring.
@jokob-sk no worries at all; I think I speak for many when I say I'm stoked with all you've done with NetAlertX. 😄
Sadly, the netalertx-dev
didn't work out for me. The settings page failed to load. Nothing amiss in the logs:
16:43:43 [API] Updating table_settings.json file in /front/api
16:43:43 [Config] Imported new config
16:43:43 [API] Updating table_appevents.json file in /front/api
16:43:43 [API] Updating table_devices.json file in /front/api
16:43:43 [API] Updating table_events_pending_alert.json file in /front/api
16:43:43 [API] Updating table_plugins_events.json file in /front/api
16:43:43 [API] Updating table_plugins_history.json file in /front/api
16:43:43 [API] Updating table_plugins_objects.json file in /front/api
16:43:43 [API] Updating table_plugins_language_strings.json file in /front/api
16:43:43 [API] Updating table_notifications.json file in /front/api
Firefox:
Chrome:
Firefox console:
Hey, thanks for the kind words!
Trying something out (adding a version in the query string of requested js files to expire the cache) - you can test the netalertx-dev
image again if interested. Ideally in a new / incognito session and then existing session.
It works/loads fine in a cognito window, but not in the normal windows. Clicking the refresh icon doesn't seem to clear/help either. Here's a video:
https://github.com/jokob-sk/NetAlertX/assets/37667/201ec79f-a1d1-4488-991b-777901b8e067
Here's what I did:
docker compose
to pull/start new container.I'm free this weekend if you'd like to schedule a screen sharing session to debug in real-time. It's a weird one for sure! For now I can use the regular container and reload whenever settings doesn't refresh.
Delete the container + image via Portainer.
Re-run
docker compose
to pull/start new container.Go to Chrome and start an incognito session. All is well.
And I think that's the best we can do at this point. I think the old session has the js files cached and strings cached/not cached and they have to expire for the new assets to load and be initialized properly.
Empty strings indicate that the strings were not cached correctly, and I hope I'm slowly making this more solid for a first-time load (again, anyone reading - please help out, I'm a bit tired looking at this part of the code 😩)
@jokob-sk as we often say, there are two big problems in programming: naming, cache invalidation, and off-by-one errors. 😁 There's a very simple/easy workaround for now: click the refresh button in the application's UI.
I just noticed in your change 584fdb7734d2954c506b77a9ae77287b8dc85e33 the following detail:
You will have to run the container on the
host
network.
This explains why my NetAlertX ARP scanner isn't finding anything. 😅 I wonder if this is related to this bug? I'm going to go back to latest
and move to network_mode: host
. Will report back.
This explains why my NetAlertX ARP scanner isn't finding anything. 😅 I wonder if this is related to this bug?
I don't think so but worth a shot. Definitely having the container on the host network will however correct other things. I still think the -dev image is now in a better state regarding the caching issues. 🤞
Okay, I verified it's network_mode: host
, but the ARP scans aren't finding my devices. I strongly suspect this is due to a poorly configured VLAN setup on my end. I'm fiddling with the subnets docs to see if I can get somewhere.
Can't help on that front as I don't use vlans on my end. However there's a discussion going on over here: https://github.com/jokob-sk/NetAlertX/discussions/654
released/workaround provided -> closing for now
Is there an existing issue for this?
Current Behavior
Not entirely sure what's going on here, but settings only show up for me when I use Safari on iOS. On Firefox, Safari, and Chrome on the desktop all of the setting sections show up blank save the "Read more in the docs" links. The following two screenshots are the same settings page - one taken from Chrome on MacOS and one taken from Safari on iOS.
Working settings on iOS:
Blank settings on desktop:
Expected Behavior
Settings are confgurable from desktop and mobile browsers.
Steps To Reproduce
jokobsk/netalertx:latest
I even did an
rm -fr
on the bind mount, deleted the container, and started from scratch.app.conf
docker-compose.yml
What branch are you running?
Production
app.log
Debug enabled