hassio-addons / addon-grocy

Grocy - Home Assistant Community Add-ons
https://addons.community
MIT License
319 stars 60 forks source link

Allow disabling barcode camera scanner (requires HTTPS) #411

Closed igorsantos07 closed 8 months ago

igorsantos07 commented 11 months ago

Problem/Motivation

The barcode scanner only works on HTTPS, which is not mandatory on HA and, I guess, not exactly common either.

This causes the scanner to not behave well; there are no warnings displayed, and even a console error that gets ignored by the application and the developer itself (https://github.com/grocy/grocy/issues/2383).

Expected behavior

The developer refuses to make a proper UI when the scanner won't work, but pointed out to a config which I cannot set in HA to disable that option.

Proposed changes

I suggest to include an equivalent to FEATURE_FLAG_DISABLE_BROWSER_BARCODE_CAMERA_SCANNING in the add-on configs, and maybe have that automatically enabled if the instance isn't running in HTTPS?

I tried adding disable_browser_barcode_camera_scanning: true to both the features and tweaks sections on the Configuration screen, but they didn't made any difference. I wonder if it would be feasible to auto-support any Grocy setting prefixed with FEATURE_FLAG_, instead of having manual counterparts? There are a lot of other options in the original config file.

igorsantos07 commented 10 months ago

stale-proof comment

frenck commented 9 months ago

I suggest to include an equivalent to FEATURE_FLAG_DISABLE_BROWSER_BARCODE_CAMERA_SCANNING

Sounds good!

and maybe have that automatically enabled if the instance isn't running in HTTPS?

We can't know. It might be using some kind of SSL termination (like a reverse proxy).

../Frenck

github-actions[bot] commented 8 months ago

There hasn't been any activity on this issue recently, so we clean up some of the older and inactive issues. Please make sure to update to the latest version and check if that solves the issue. Let us know if that works for you by leaving a comment 👍 This issue has now been marked as stale and will be closed if no further activity occurs. Thanks!