scottlamb / moonfire-nvr

Moonfire NVR, a security camera network video recorder
Other
1.22k stars 137 forks source link

Live View Selection Starting Clockwise with Small Pane Hangs on Last Large Pane #157

Closed jlpoolen closed 3 years ago

jlpoolen commented 3 years ago

Describe the bug In Live View, specifying the feeds in five-plus-one view starting with top right small and going clockwise ends up with large pane not working. After successfully specifying the 5 small panes, When I pull the menu down for the large pane and select the camera (as yet unspecified), the first pane changes to the one I selected for the large pane and the pull down menu freezes. Then the entire interface locks up, although the videos continue to change. The only way to get out of the quandry is to perform a refresh of the page and then select Live VIew and go through the sequence. If I specify the large pane first, then rotatie around clockwise specifying the the small feeds, everything works.

To Reproduce Steps to reproduce the behavior:

  1. Go to main url, i.e: pi:8080
  2. Click on Live View
  3. Select "Solo" button and change to main-plus-five
  4. Select top right small pane and select feed, work clockwise through the other four small panes, then try to select the feed for the large pane

Expected behavior Should be able to select any pane and change the camera feed in any sequence.

Screenshots 2021-08-31_06-34

Server (please complete the following information):

Camera (please complete the following information): Various Reolinks:

GarageWest
RLC-420
build 17112700
IPC_3816M
v2.0.0.0
v2.0.0.889_17112700
IPC_3816M110000000000000
v1.0.227

GarageEast
RLC-420
build 17112700
IPC_3816M
v2.0.0.0
v2.0.0.889_17112700
IPC_3816M110000000000000
v1.0.227

Peck Alley West
RLC-420-5MP
build 19013001
IPC_51516M5M
v2.0.0.0
v2.0.0.354_19013001
IPC_51516M5M110000000100000
v1.0.239

Peck Alley East
RLC-420-5MP
build 19013001
IPC_51516M5M
v2.0.0.0
v2.0.0.354_19013001
IPC_51516M5M110000000100000
v1.0.239

    Camera Name PeckPear
    Model   RLC-410-5MP
    UID 95270002JS5EWXMZ
    Build No.build 20121100
    Hardware No.    IPC_515B16M5M
    Config Version  v3.0.0.0
    Firmware Version    v3.0.0.136_20121100
    Details IPC_515B16M5MS10E1W01100000001

    Camera Name Maple1
    Model   RLC-410-5MP
    UID 95270002JS5IEVPW
    Build No.   build 20121100
    Hardware No.    IPC_515B16M5M
    Config Version  v3.0.0.0
    Firmware Version    v3.0.0.136_20121100
    Details IPC_515B16M5MS10E1W01100000001

Desktop (please complete the following information):

jlpoolen commented 3 years ago

I should clarify, when I am selecting the large pane, the choice I make is then reflected in the right top small pane and nothing shows up in the large pane.

jlpoolen commented 3 years ago

Further, once the pull down menu for the large window displays and does not collapse, I can go through the choices and click them which causes the top right small to change to that selection (and if the selection was appearing in another small window, that corresponding window goes dark to "none", though I cannot select any other window's pull down menu). I tried this 55 minutes later just to see if anything blocking might have timed out or whatever and the screen remains in a state where the main pull down can control the top right pane only.

jlpoolen commented 3 years ago

I used Chrome (Version 92.0.4515.159 (Official Build) (64-bit)) and refreshed getting the main window, selected Live View and went through the drill and arrived at the same result: hung page with no main pane showing anything. The other small panes continue to update fine. I tried clicking anything and am frozen out, the main pane sub menu sticking seems to prevent me from selecting anything else.

scottlamb commented 3 years ago

I'd never tried doing it in that order before. I see the same thing in Firefox and Chrome. No idea why yet.

jlpoolen commented 3 years ago

Here's a Firefox JavaScript console log which doesn't seem to reveal anything: moonfire-nvr_Aug_31_FireFox_JavaScriptConsole_0740.log

jlpoolen commented 3 years ago

The Firefox log captures the event of refresh, select LiveView up to the point of freezing and then when I saw the smaller panes dutifully refreshing I marked that as the end point of the log to capture.

jlpoolen commented 3 years ago

Work-around for this issue is to always specify the large pane first.

jlpoolen commented 3 years ago

I pulled the latest (and ended up rebuilding):

jlpoole@pi:/usr/local/src/moonfire-nvr/server $ git --describe dirty
unknown option: --describe
usage: git [--version] [--help] [-C <path>] [-c <name>=<value>]
           [--exec-path[=<path>]] [--html-path] [--man-path] [--info-path]
           [-p | --paginate | -P | --no-pager] [--no-replace-objects] [--bare]
           [--git-dir=<path>] [--work-tree=<path>] [--namespace=<name>]
           <command> [<args>]
jlpoole@pi:/usr/local/src/moonfire-nvr/server $ git describe --dirty
v0.6.5-22-gd2c7b62
jlpoole@pi:/usr/local/src/moonfire-nvr/server $ git pull
remote: Enumerating objects: 15, done.
remote: Counting objects: 100% (15/15), done.
remote: Compressing objects: 100% (2/2), done.
remote: Total 9 (delta 7), reused 9 (delta 7), pack-reused 0
Unpacking objects: 100% (9/9), done.
From https://github.com/scottlamb/moonfire-nvr
   d2c7b62..981a91c  master     -> origin/master
Updating d2c7b62..981a91c
Fast-forward
 CHANGELOG.md               |  3 +++
 ui/src/Live/LiveCamera.tsx | 12 +++++++++---
 2 files changed, 12 insertions(+), 3 deletions(-)
jlpoole@pi:/usr/local/src/moonfire-nvr/server $ cargo build --release
    Finished release [optimized + debuginfo] target(s) in 1.28s
jlpoole@pi:/usr/local/src/moonfire-nvr/server $ nvr run --rtsp-transport=udp 2>/tmp/moonfire-nvr.log
jlpoole@pi:/usr/local/src/moonfire-nvr/server $ git describe --dirty
v0.6.5-24-g981a91c
jlpoole@pi:/usr/local/src/moonfire-nvr/server $which nvr
/home/jlpoole/bin/nvr
jlpoole@pi:/usr/local/src/moonfire-nvr/server $ ls -la /home/jlpoole/bin/nvr
lrwxrwxrwx 1 jlpoole jlpoole 12 Aug 19 17:25 /home/jlpoole/bin/nvr -> moonfire-nvr
jlpoole@pi:/usr/local/src/moonfire-nvr/server $ ls -la /home/jlpoole/bin/moonfire-nvr
lrwxrwxrwx 1 jlpoole jlpoole 62 Aug 19 17:10 /home/jlpoole/bin/moonfire-nvr -> /usr/local/src/moonfire-nvr/server/target/release/moonfire-nvr
jlpoole@pi:/usr/local/src/moonfire-nvr/server $

I then started nvr and tried the selection of panes as described above starting with the smallest top right and ended up with the same problem at the large pane pull down menu: hung interface.

scottlamb commented 3 years ago

For this change you have to rebuild/install the JavaScript UI, not the Rust server.

jlpoolen commented 3 years ago

Confirmed the fix works. Thank you.