Android App (1.7)

I’m having this issue too.

Also none of my notifications are coming through on Android until I leave my geofence. iOS are coming through fine. Anyone else having an issue with notifications?

I just wanted to chime in here and state that everything has been working perfectly for me with the new app.

I love how quick it loads everything now and the widget is quite useful! Hopefully it keeps improving like this!

1 Like

What “widget” is everyone talking about?

there’s a hello home action widget, have a look in your android widgets…

I have seen it. Never figured out what it was for, so I have ignored it.

Just want to follow up on a few of the reported issues and to let you know that we have bugs filed, and will address them.

  • Needing to add an extra params when getting parameters from an href input element in Android. This should be the same as iOS and we will correct this.
  • tile backgroundColors should support decimal values, not just integers.
  • Using a \n character in a tile label should work like it did previously.

Tagging @kris so he can keep abreast of these issues :smile:

3 Likes

@Jim, When a smart app has dynamic pages and inputs with defaults, they are not instantiated. This is pretty serious…

@Jim, This always fails when saving a SmartApp in the IDE

def title = "${location?.name}

java.lang.NullPointerException: Cannot get property ‘name’ on null object.

@625alex is this an issue observed with the Android update? Can you post a code snippet? (the only thing I found in this thread about dynamic preferences was @Mike_Maxwell’s reported issue about params from an href input not working correctly)

https://github.com/625alex/ActiON-Dashboard/blob/master/app-v5/ActiON5SmartApp.groovy#L217

Any of the 4 inputs in this block are null unless you step into that dynamic page. I believe this used to instantiate defaults prior to update last week.

I can’t reproduce this in my simple case - this works for me:

def installed() {log.debug "location?.name"}

Is there some other context that this is failing in?

you even removed the post from the blog lol look like the bugs are real, i havent had any luckily

Just wanted to say things have been pretty smooth for me. I have several custom device types and smart apps both made by others and myself and haven’t had any new issues. Presence still seems pretty broken, working fine for a couple days then refusing to work at all while other apps/integrations still work fine. I’ve reverted back to Life360 integration for presence instead of the built in native stuff. I had hoped 1.7.x had addressed some of it but it looks like they had/have bigger fish to fry.

Not singling any issue out in particular and heck, maybe none of them even fall into this category, but as a developer in my day job, I want to point out that just because something “works” doesn’t mean it was done the correct way previously. Just something to think about. When writing good code, a developer shouldn’t write to working, they should write to correct/efficient/consistent/etc. I’ve seen hacky code made all too often then ends up being broken in an update and the hacky developer blames the update instead of themselves :stuck_out_tongue:

Jim, refer to this minimalist sample:
https://github.com/625alex/SmartThings/blob/master/apps/bugger.groovy

location?.name fails when saving a smart app. Lines 27-29.

All of inputs on lines 36-39 are not initialized with the default value unless I step into that dynamic page.

Thanks for the code example, that should help reproduce it.

I think this is a good opportunity for @kris to jump in and try and reproduce and help :slight_smile:

Jim, the bug about app label defaulting to “Tap to set” is not on this list…

@Jim, https://github.com/625alex/SmartThings/blob/master/apps/bugger2.groovy demonstrates another bug:

groovy.lang.MissingMethodException: No signature of method: java.lang.String.refresh() is applicable for argument types: () values: [] Possible solutions: reverse(), reverse(), every(), every(groovy.lang.Closure), length(), grep() @ line 74

This only happens when the input for weather tile is inside a dynamic page.

Note that the system.out for weather is not what it should be. Should display device name, not ID.

initialized with settings: [weather:[7ee73fe9-5fdc-4523-894d-d0488de66cb0]]

There was no issue running this code last week.

edit: basically weather device is cast to String when input sits in a dynamic page. Was the weather tile updated recently?

Hey @625alex, If you remove the “.name” property you should be returned the name by default.

label title: "Title", required: false, defaultValue: "${location != null ? location : 'none'}"

I’m not seeing this issue on Android. Please let me know if you’re still seeing it.