Core: Wunderlist Addon no variables supported

Created on 12 Jul 2019  路  9Comments  路  Source: home-assistant/core

Home Assistant release with the issue:

0.95.4

Last working Home Assistant release (if known):
none

Operating environment (Hass.io/Docker/Windows/etc.):

Hass.io

Component/platform:

https://www.home-assistant.io/components/wunderlist/

Description of problem:

The component Wunderlist does not support variables.

I set up wunderlist in the configuration.yaml.

I created this script with a variable:

einkaufsliste:
  alias: auf die Einkaufsliste
  sequence:
  - service: wunderlist.create_task
    data:
      list_name: 'Einkaufsliste'
      name: "{{states.input_text.einkaufsliste}}"
      starred: false

I have this input_text in the configuration.yaml:

input_text:
  einkaufsliste:
    name: Eintrag f眉r die Einkaufsliste
    initial: Test
    mode: text

It doesn't matter if I use "data" or "date_template". If I use "data", it writes "{{states.input_text.einkaufsliste}}" into my wunderlist. If I use "data_template", it doesn't do anything.

Please add support for variables for wunderlist scripts.

wunderlist

All 9 comments

You would have to use a data_template for this:

einkaufsliste:
  alias: auf die Einkaufsliste
  sequence:
  - service: wunderlist.create_task
    data_template:
      list_name: 'Einkaufsliste'
      name: "{{ states('input_text.einkaufsliste') }}"
      starred: false

Could you try this exact one?

I've tried your script, but unluckily it doesn't work as described before. Nothing appears in the wunderlist. If I replace "data_template" througt "data" then in my wunderlist appears "{{ states(input_text.einkaufsliste) }}".

It seams like your addon doesn't support "data_template". Can you please add support for variables in the wunderlist addon?

@Mar1u503 sorry m8, I don't know. This is not an integration I've developed, nor do I see a reason why it should not have worked.

@frenck Hmm.. Who developed this integration? Maybe I can ask him what I've done wrong or what the bug in the integration is. Can you please give me his mail address or any contact information? Is the developer maybe @balloob or @cgtobi ? https://github.com/home-assistant/home-assistant/tree/dev/homeassistant/components/wunderlist

It's working now!! 馃槂

In the UI I clicked on scripts and started the script from there. Then I got an error:
image
Fehler beim Aufrufen des Service script/einkaufsliste. 400 {'error': {'type': 'missing_parameter', 'translation_key': 'api_error_missing_params', 'message': 'Missing parameter.', 'starred': ['required']}}

I removed the last line "starred: false" and then it worked as it should!

I tried the script with "starred: false", "starred: 'false'", "starred: true" and "starred: 'true'", but nothing worked. I think there is a bug with the starred attribute. This error only appears if I use "data_template" and disappears if I use "data".

Luckily i don't need the star and if I remove this line it doesn't use a star. Here's the working script:

einkaufsliste:
  alias: auf die Einkaufsliste
  sequence:
  - service: wunderlist.create_task
    data_template:
      list_name: 'Einkaufsliste'
      name: "{{ states('input_text.einkaufsliste') }}"

@developer can you please fix this bug if it is one?

@frenck thanks for your help. Can you please send this to the developer of this integration or send me some contact information of the developer so this "bug" with the star can be fixed?

Please do not tag random people in your responses. Thank is not appreciated.

This integration has currently no code owner, so it has to be picked up by somebody that can find the time for it. You've reported it, now you have to wait for somebody to pick it up, look into it and maybe contribute a fix.

I double checked but as far as I can tell the component works fine.

Calling wunderlist.create_task with

{
"list_name": "Shoppinglist",
"name": "Milk"
}

works as expected.

Did you try that by hand in the services menu (developer tools)?

@cgtobi are you the developer of this component? I've tried it in the service menu with this code:

{
"list_name": "Einkaufsliste",
"name": "test"
}

it worked as expected (works in the script too)

I think you didn't understand the problem. I try to explain it again:

this works (without starred and with data_template):

einkaufsliste:
  alias: auf die Einkaufsliste
  sequence:
  - service: wunderlist.create_task
    data_template:
      list_name: 'Einkaufsliste'
      name: "{{ states('input_text.einkaufsliste') }}"

this doesn't work (with starred and with data_template):

einkaufsliste:
  alias: auf die Einkaufsliste
  sequence:
  - service: wunderlist.create_task
    data_template:
      list_name: 'Einkaufsliste'
      name: "{{ states('input_text.einkaufsliste') }}"
      starred: true

error: image

this works (with starred and with data):

einkaufsliste:
  alias: auf die Einkaufsliste
  sequence:
  - service: wunderlist.create_task
    data:
      list_name: 'Einkaufsliste'
      name: "test"
      starred: true

As you can see it works if you use the starred attribute and data or if you use data_template without the starred attribute (then it automatically uses the default value for starred: false). But it doensn't work if you use data_template and the starred attribute. Do you understand it now? You only have to read this comment if you want to know what the bug is.

~Looks like it is a bug with the data_template.~ We're looking into it.

It was a bug in the wunderlist component.

Was this page helpful?
0 / 5 - 0 ratings

Related issues

aguilaair picture aguilaair  路  162Comments

gieljnssns picture gieljnssns  路  277Comments

Bergasha picture Bergasha  路  176Comments

soldag picture soldag  路  143Comments

sagilo picture sagilo  路  130Comments