I’ve got two custom components that import mqtt in this way: “loader.get_component(‘mqtt’)” where loader is “homeassistant.loader”.
It worked fine for a few releases, but now with 0.69 and 0.69.1 I get can error while starting HASS: TypeError: get_component() missing 1 required positional argument: ‘comp_or_platform’
Any idea what’s wrong? I obviously miss an argument, but is there any more information about it? Is that all, or is the whole usage of mqtt different for example? Some API docs would be great…
You’re not alone and I’m getting exactly what’s happening to you. I’m digging for a solution but if anybody else more knowledgeable can chime in with a solution that would be nice.
@Gerben321 you helped me out figuring out that you need to use mqtt like this: mqtt = hass.components.mqtt and from this I think I might have figured this out:
@ccuono Wow that would make a lot of sense. I was getting some other errors which this might also explain! I’ll give it a shot tonight. Let me know if it works for you! Cheers.