Continue Discussion 73 replies
July 2018

bachoo786

thanks for this release.

I am trying to set up users on my Hassbian installation and cannot find the script which is in built Homeassistant. When I use the command hass --script auth --config /path/to/config on my configuration.yaml directory I get --bash: hass: command not found

Any help please?

Thanks.

1 reply
July 2018 ▶ bachoo786

balloob Founder of Home Assistant

You don’t need to use the script anymore with 0.74.

1 reply
July 2018 ▶ balloob

bachoo786

so all I need to do is to add the following in my configuration.yaml:

# Example configuration.yaml entry
homeassistant:
  auth_providers:
   - type: homeassistant
   # Uncomment next line if you want to enable legacy API password support
   # - type: legacy_api_password

# Enable the auth component
auth:

Because I have done that and I dont get a new login screen in my frontend after restarting HA.

1 reply
July 2018

firstof9 Great contributor

Mine complains about “access_token” not being setup. I can’t find this in any of the docs posted. :frowning:

1 reply
July 2018 ▶ firstof9

bachoo786

how did you set yours up?

1 reply
July 2018 ▶ bachoo786

firstof9 Great contributor

Exactly what you posted, but it never serves the UI, so I’ve reverted the auth setup in my config to get it back online.

July 2018

robertpe

Do users work with iOS application?

July 2018 ▶ bachoo786

redlotusaustin

Did you log out, after doing that?

1 reply
July 2018 ▶ redlotusaustin

bachoo786

Done that and it works fine now thank you

July 2018

automationpirate

Man… I want to get home now. Tuya is going to be awesome!

July 2018

Tribune

Is the new python build / version included in the docker image for this release already? It was mentioned here: https://twitter.com/pvizeli/status/1017906821577805825. I am specifically interested in this image: https://hub.docker.com/r/homeassistant/raspberrypi3-homeassistant/tags/

July 2018

DavidFW1960

I have a new user created when I look in Configuration>Users (in Hassio) I have the user I created that is the owner and also a homeassistant user that I didn’t create??

image

Can I delete this user? Where did it come from??

1 reply
July 2018 ▶ DavidFW1960

awarecan

That was created by legacy_api_password auth provider. You can delete it if you don’t want to use legacy_api_password anymore, and if you are regret, legacy_api_password auth provider will recreate it.

1 reply
July 2018 ▶ awarecan

DavidFW1960

no worries… just wondered where it came from. @dale3h suggested it might be that.

July 2018

Sunonline

After put in the configuration. There is popup for me to set Name, username and password. Then I cannot login to the page at all.

# Example configuration.yaml entry
homeassistant:
  auth_providers:
   - type: homeassistant
   # Uncomment next line if you want to enable legacy API password support
   # - type: legacy_api_password

# Enable the auth component
auth:
1 reply
July 2018 ▶ Sunonline

awarecan

Any error log?

1 reply
July 2018 ▶ awarecan

Sunonline

on frontend https://ip:port
error loading

July 2018

Sunonline

Do I have to logout from current (normal before setting the new authorize). then restart?

1 reply
July 2018 ▶ Sunonline

awarecan

Not necessary, but you can try. Any error in back end?

1 reply
July 2018 ▶ awarecan

Sunonline

2018-07-21 11:17:52 WARNING (MainThread) [homeassistant.components.http] Experimental auth api enabled. Please use access_token instead api_password.

1 reply
July 2018 ▶ Sunonline

awarecan

Nothing special, please open an issue in https://github.com/home-assistant/home-assistant/issues and fill in all required section in issue template.

July 2018

juan11perez

Good day. First of all thank you for this great product!
One question, once entirely migrated to this new users UI and with the API password gone; how will the components that use the API password access the system?
i.e. a saved picture for a notification an alexa custom briefing, etc.

1 reply
July 2018 ▶ juan11perez

awarecan

We will change those integrations to use new auth system before we remove api_password support. That will be a long journey.

1 reply
July 2018 ▶ awarecan

juan11perez

@awarecan thank you very much. So for the time being, we can migrate and the legacy API will continue to work until the future integration is complete?

1 reply
July 2018 ▶ juan11perez

DavidFW1960

I am using the new Auto and legacy api for ifttt and google assistant. It works seemlessly with those as well as the web GUI. I’m on HassOS.

July 2018

rosie

Apologies for a really stupid question, but how do I display the image on my frontend with the new push camera?

EDIT:
It’s simply

camera.whatever_you_called_it

also, if someone else is struggling with the motioneye command, it should be

curl -X POST -F "image=@%f" http://my.hass.server.com:8123/api/camera_push/camera.WHAT_EVER_YOU_CALLED_IT

Didn’t think that was very clear in the docs.

1 reply
July 2018 ▶ rosie

Coolie1101

ERROR during TUYA Setup

2018-07-21 19:36:19 ERROR (MainThread) [homeassistant.components.switch] Error while setting up platform tuya
Traceback (most recent call last):
  File "/srv/homeassistant/lib/python3.5/site-packages/homeassistant/helpers/entity_platform.py", line 129, in _async_setup_platform
    SLOW_SETUP_MAX_WAIT, loop=hass.loop)
  File "/usr/lib/python3.5/asyncio/tasks.py", line 400, in wait_for
    return fut.result()
  File "/usr/lib/python3.5/asyncio/futures.py", line 293, in result
    raise self._exception
  File "/usr/lib/python3.5/concurrent/futures/thread.py", line 55, in run
    result = self.fn(*self.args, **self.kwargs)
  File "/home/homeassistant/.homeassistant/custom_components/switch/tuya.py", line 48, in setup_platform
    config.get(CONF_LOCAL_KEY)
  File "/srv/homeassistant/lib/python3.5/site-packages/pytuya/__init__.py", line 249, in __init__
    super(OutletDevice, self).__init__(dev_id, address, local_key, dev_type)
  File "/srv/homeassistant/lib/python3.5/site-packages/pytuya/__init__.py", line 146, in __init__
    self.local_key = local_key.encode('latin1')
AttributeError: 'NoneType' object has no attribute 'encode'
1 reply
July 2018 ▶ Coolie1101

huangyupeng

If you want to use the tuya component in 0.74? If so, I think you should delete the tuya component in custom_component file. As I known, it will override the built-in one.

2 replies
July 2018 ▶ huangyupeng

Coolie1101

Thank you, that was it, I forgot I had that setup and disabled during the trial days.

July 2018 ▶ huangyupeng

Coolie1101

Is there any chance of getting the statistics from the switches?

image image

1 reply
July 2018 ▶ Coolie1101

huangyupeng

Sorry, it doesn’t support currently

1 reply
July 2018 ▶ huangyupeng

Coolie1101

:+1:Thanks for making this a simple implementation.

July 2018

weemaaan

With tuya components is there any way to remove the entity picture to use an icon instead?

July 2018

ArnoNel

Where do you buy Tuya products from?

1 reply
July 2018 ▶ ArnoNel

Grambo1966

Amazon is a good place in the UK don’t know for rest of the world.

July 2018

Laith_Alsunni

I’m getting this error for HDMI-CEC.

Error during setup of component hdmi_cec
Traceback (most recent call last):
  File "/usr/local/lib/python3.6/site-packages/homeassistant/setup.py", line 146, in _async_setup_component
    component.setup, hass, processed_config)  # type: ignore
  File "/usr/local/lib/python3.6/concurrent/futures/thread.py", line 56, in run
    result = self.fn(*self.args, **self.kwargs)
  File "/usr/local/lib/python3.6/site-packages/homeassistant/components/hdmi_cec.py", line 182, in setup
    adapter = CecAdapter(name=display_name[:12], activate_source=False)
  File "/usr/local/lib/python3.6/site-packages/pycec/cec.py", line 20, in __init__
    import cec
ModuleNotFoundError: No module named 'cec'

https://github.com/home-assistant/home-assistant/issues/15406

July 2018

SMARTMEDIA

I’m running Home Assistant from a Docker Container on a Synology nas.
I’ve pulled the 0.74.0 image last night and gave it a run.
Everything is working beautifully but I get some warnings in the dev-info panel, after enabling the auth: component.

My configuration.yaml is looking like this:

homeassistant:
  # Name of the location where Home Assistant is running
  name: !secret homeassistant_config_location_name
  # Location required to calculate the time the sun rises and sets
  latitude: !secret homeassistant_config_latitude
  longitude: !secret homeassistant_config_longitude
  # Impacts weather/sunrise data (altitude above sea level in meters)
  elevation: 0
  # metric for Metric, imperial for Imperial
  unit_system: metric
  # Pick yours from here: http://en.wikipedia.org/wiki/List_of_tz_database_time_zones
  time_zone: !secret homeassistant_config_time_zone

  auth_providers:
    - type: homeassistant
#   # Uncomment next line if you want to enable legacy API password support
#    - type: legacy_api_password

auth:

… and those pesky messages, are looking like this:

I own 3 x iPad Mini and 2 x iPhone, and on every one of them I went on and logged in with a previously created user & pass, then logged out and then back in without a hitch. Every time I clear the log, then issue a command (lets say, turn on a light) from an Apple device, those messages come right back (although the command executes fine).

What can I do to make those messages go away ? What am I doing wrong ?, Does someone else is having this issue ?, involving not only Apple devices, but it seems it affects cameras as well.

Thank You.

1 reply
July 2018 ▶ SMARTMEDIA

PostSven

I am getting similar results,

July 2018

bobtosh

0.74 here, configured it with new auth providers (kept the api_pass provider) but I receive similar log messages as above "Please change to use bearer token access … ". I have 2 users - me and my wife, both using the iOS app on iPhone, but when using the app, we get persistent notification for Failed Login Attempts from IP …which comes after 1 second of reloading from the HA logo screen. These notifications come if the iOS app was not used like for about 30 mins. (token expires I guess). If using the browser instead is fine and no such notifications. Maybe the iOS app needs a new version to accommodate the new auth features? Or I am missing something.

1 reply
July 2018 ▶ bobtosh

DavidFW1960

No the iOS dev is aware and has fixed this issue for the next release. Not just you.

July 2018

Joakim_Schutt

Hi,

I finally had some time for an upgrade from 0.56.2. But, after the normal procedure with “sudo pip3 install --upgrade homeassistant” I still have 0.56.2? The installation logs shows 0.74 though… What has changes? This is running on a RPI 3 with a lot of other things (MQTT, Node-Red, Unifi) so I guess that a HASS.io installation is not my best choice?

/Joakim

1 reply
July 2018 ▶ Joakim_Schutt

balloob Founder of Home Assistant

Python 56.2 was the last version to support Python 3.4. we now require Python 3.5.3 minimally

1 reply
July 2018 ▶ balloob

Joakim_Schutt

Yes, I’ve seen that. My RPI is running Stretch already. So, I assume that Python 3.5.3 is used when I start hass. I’ve tried uninstalling and reinstalling. But it does not touch my “old” installation. Only the parts in /usr/local/bin/?

July 2018

caramel

what about tuya sensors (door sensors, pir motion sensors…)?
will these work?

July 2018

Sunonline

Need help!!!
On 0.74 I cannot use. If put this I cannot access my ha frontend at all. So I remove all below.

homeassistant:
  auth_providers:
   - type: homeassistant
   # - type: legacy_api_password
auth:

After update to 0.74.1 . I cannot access my ha frontend. Whether put or don’t put.

homeassistant:
  auth_providers:
   - type: homeassistant
   # - type: legacy_api_password
July 2018

Sunonline

Ha load normally if I dont put auth_providers but I cannot access ha frontend

If I put auth_providers, Ha load normally but again I cannot access ha frontend. Log file show auth api enabled and legacy_api_password support enabled. Please use access_token instead api_password, although you can still use legacy api_password.

I cannot access ha at all. On my iphone show

This on computer

1 reply
July 2018 ▶ Sunonline

awarecan

The only change may cause this is auth component auto load since 0.74.1 no matter whether you enabled new auth or not.

So, it looks like auth component cause some error to bring down the frontend component.

Can you post your full configuration.yaml? Any third party of custom components are using?

1 reply
July 2018 ▶ awarecan

Sunonline

This happen to me since 0.74 so I didn’t use auth_providers and auth:

Upgrade 0.74.1 will automatically load auth:

My latest custom_component is alexa as media player. I have quite many custom_component mostly are broadlink.

1 reply
July 2018 ▶ Sunonline

awarecan

Please try to disable all custom component.

1 reply
July 2018 ▶ awarecan

Sunonline

I have disable custom_component. Still the same I cannot access ha frontend at all.

2018-07-24 22:22:44 WARNING (MainThread) [homeassistant.components.http] Experimental auth api enabled and legacy_api_password support enabled. Please use access_token instead api_password, although you can still use legacy api_password

1 reply
July 2018 ▶ Sunonline

awarecan

It just a warning about legacy api_password, nothing special. Again, can you post your full configuration?

1 reply
July 2018 ▶ awarecan

Sunonline

homeassistant:
  auth_providers:
   - type: homeassistant
  name: !secret homeassistant_name
  latitude: !secret home_latitude
  longitude: !secret home_longitude
  elevation: !secret home_elevation
  unit_system: metric
  time_zone: Asia/Bangkok  
  customize: !include config/customize.yaml
  customize_glob: !include config/customize_glob.yaml
  customize_domain:
    automation:
      initial_state: 'on'
  packages: !include_dir_named config/packages/
  whitelist_external_dirs:   
    - !secret whitelist_1
    - !secret whitelist_2
    - !secret whitelist_3

Whether I put with or without - type: legacy_api_password. I cannot access ha frontend. Ha is running as I see the db go bigger and status is active

homeassistant:
  auth_providers:
   - type: homeassistant
   - type: legacy_api_password
1 reply
July 2018 ▶ Sunonline

awarecan

Can you post your frontend and http config?

July 2018

Sunonline

frontend:
  javascript_version: latest   
  extra_html_url:
    - /local/custom_ui/state-card-custom-ui.html
    - /local/custom_ui/state-card-tiles.html
    - /local/custom_ui/state-card-script-custom-text.html
    - /local/custom_ui/custom-weather-card.html
    - /local/custom_ui/state-card-mini-media-player.html
    - /local/custom_ui/state-card-iframe.html

  extra_html_url_es5:
    - /local/custom_ui/state-card-custom-ui-es5.html
    - /local/custom_ui/state-card-tiles_es5.html
    - /local/custom_ui/state-card-script-custom-text-es5.html
    - /local/custom_ui/custom-weather-card.html
    - /local/custom_ui/state-card-mini-media-player_es5.html

  themes: !include_dir_merge_named themes/

http:
  base_url: !secret base_url  
  api_password: !secret api_password
#  server_port: !secret server_port
  ssl_certificate: !secret ssl_certificate
  ssl_key: !secret ssl_key
  cors_allowed_origins:
   - !secret cors_1
   - !secret cors_2
#  use_x_forwarded_for: true
#  trusted_proxies:
#    - 127.0.0.1
#    - ::1
  trusted_networks:
   - !secret trusted_1
  ip_ban_enabled: true
  login_attempts_threshold: 3

My base_url is include port inside so I # on server_port
The trusted_networks: is my local network 192.168.1.0/24

1 reply
July 2018 ▶ Sunonline

awarecan

Did you see any ip_ban warning/error in error log? I am wondering if you have been banned. Could you try to disable ip_ban_enabled and login_attempts_threshold.

There is a todo for me to honor trusted_networks config, basically if you enabled new auth, the trusted_networks will not work now. So if you have some other integration from your local network, it will trigger the failed login now, and may be caused yourself be banned.

1 reply
July 2018 ▶ awarecan

Sunonline

There is no ip_ban. Thank you for your recommend. I will disable the ip_ban_enabled and login_attempts_threshold also trust_networks and inform you.

July 2018

Sunonline

Same result. I also clear all browsing history and cached from google chrome.

in log show
2018-07-24 23:05:08 WARNING (MainThread) [homeassistant.components.http] Experimental auth api enabled. Please use access_token instead api_password.

2

1 reply
July 2018 ▶ Sunonline

awarecan

Can you ping me at #homeassistant chat channel? https://www.home-assistant.io/join-chat/
I don’t want to hijack this thread anymore.

1 reply
July 2018 ▶ awarecan

Sunonline

What is your name in discord channel?

July 2018

Sunonline

I cannot attached picture on discord. I really got problem with auth_providers: After downgrade to 0.73.2 work fine. Then I slowly upgrade to 0.74.0 with setting of auth_providers: and auth: Make the name, username and password. Then show
1

July 2018

Sunonline

Finally. I got it works. Hooray!

1 reply
July 2018 ▶ Sunonline

kirpat

How,
Please write the solution, so that in case anyone had same problem,
It can be solved

1 reply
July 2018 ▶ kirpat

Sunonline

If you are on ha 0.74.0 and want to enable auth_providers:

homeassistant:
  auth_providers:
    - type: homeassistant
    - type: legacy_api_password  #use this function to enable to login to your ha on iphone app and some component that still use api_password to login to ha
auth:

if you are on ha 0.74.1 and want to enable auth_providers:

homeassistant:
  auth_providers:
    - type: homeassistant
    - type: legacy_api_password   #use this function to enable to login to your ha on iphone app and some component that still use api_password to login to ha

in configuration.yaml under http:

http:
  base_url: !secret base_url    # mine is include server_port inside, example http://local-ip:8123 or https://name.duckdns.org:8123
  api_password: !secret api_password
#  server_port: !secret server_port  # un-comment # if you seperate server_port from base_url
  ssl_certificate: !secret ssl_certificate
  ssl_key: !secret ssl_key
#  cors_allowed_origins:  #everything under this line in http component has to be # comment
#   - !secret cors_1
#   - !secret cors_2
#  use_x_forwarded_for: true
#  trusted_proxies:
#    - 127.0.0.1
#    - ::1
#  trusted_networks:
#   - !secret trusted_1
#  ip_ban_enabled: true
#  login_attempts_threshold: 3
1 reply
July 2018 ▶ Sunonline

balloob Founder of Home Assistant

We had an issue with people that had cors_allowed_origins defined in 0.74.1 but that was resolved in .0.74.2

July 2018

tarbax

i get error ‘‘FFmpeg isn’t running!’’ after this update how can i solve this ?

config:

ffmpeg:
  ffmpeg_bin: /usr/bin/ffmpeg
camera:
   - platform: ffmpeg
     name: Camera Tuin
     input: rtsp://has:[email protected]:554/Streaming/Channels/2
     extra_arguments: -vf scale=640:360
July 2018

Beach

Anyone know how to change username for owner?

//Beach

1 reply
July 2018 ▶ Beach

awarecan

You need modify two files together to changer username, [your_config_folder]/.storage/auth and [your_config_folder]/.storage/auth_provider.homeassistant

1 reply
July 2018 ▶ awarecan

Beach

Thanks, worked perfect:-)

July 2018

barqers

Is anyone getting API exception errors with the Tuya component?

1 reply
August 2018 ▶ barqers

nikc0069

I was until I realised you need to completely close out of the app. Seems you only get one websocket at a time into Tuya.

August 2018

freekeys

Awesome to see Tuya in the mix - thanks @huangyupeng !

Are there any plans to integrate the energy monitoring feature of many Tuya plugs as a sensor? That would be amazing :grinning:

August 2018

kirpat

tuya stopped working from yesterday
i get this error even i have corrrect informattion

my config:

Tuya/Arilux/Smartlife Components

tuya:
username: !secret tuya_username
password: !secret tuya_password
country_code: !secret tuya_country_code

2018-08-18 16:05:12 ERROR (MainThread) [homeassistant.setup] Error during setup of component tuya
Traceback (most recent call last):
File “/srv/homeassistant/lib/python3.6/site-packages/homeassistant/setup.py”, line 148, in _async_setup_component
component.setup, hass, processed_config) # type: ignore
File “/usr/local/lib/python3.6/asyncio/futures.py”, line 331, in iter
yield self # This tells Task to wait for completion.
File “/usr/local/lib/python3.6/asyncio/tasks.py”, line 244, in _wakeup
future.result()
File “/usr/local/lib/python3.6/asyncio/futures.py”, line 244, in result
raise self._exception
File “/usr/local/lib/python3.6/concurrent/futures/thread.py”, line 55, in run
result = self.fn(*self.args, **self.kwargs)
File “/srv/homeassistant/lib/python3.6/site-packages/homeassistant/components/tuya.py”, line 63, in setup
tuya.init(username, password, country_code)
File “/srv/homeassistant/lib/python3.6/site-packages/tuyapy/tuyaapi.py”, line 44, in init
self.get_access_token()
File “/srv/homeassistant/lib/python3.6/site-packages/tuyapy/tuyaapi.py”, line 62, in get_access_token
raise TuyaAPIException(“get access token failed”)
tuyapy.tuyaapi.TuyaAPIException: get access token failed
2018-08-18 16:05:13 ERROR (MainThread) [homeassistant.setup] Unable to setup dependencies of light.tuya. Setup failed for dependencies: tuya

1 reply
December 2018 ▶ kirpat

iOtMy

You mean only on HA or even their SmartLife mobile app not detecting your devices? Any update on this issue?