NeonGeckoCom / skill-user_settings

Control Skill to handle profile settings
Other
1 stars 3 forks source link

[BUG] Change units to imperial not affecting responses #64

Closed builderjer closed 1 year ago

builderjer commented 1 year ago

Description

Does not change units.

Steps to Reproduce

When asking 'change my units to imperial' it responds 'your units are already set to imperial', but it still speaks in metric. When I ask 'change my units to metric' it responds 'changed your units to metric' Ask again to change to imperial and it responds 'your units are already set to imperial'

Relevant Code

No response

Other Notes

No response

NeonDaniel commented 1 year ago

What skill is reporting in imperial units?

builderjer commented 1 year ago

Weather for sure. Not sure what other skill to test it with

NeonDaniel commented 1 year ago

I'll take a look into this with the weather skill in particular. CaffeineWiz and Wolfram Alpha should also respect unit settings. I test with things like: "how much caffeine is in coke" (responds mg/oz imperial and mg/L metric) "how far away is the moon" (miles vs kilometers)

builderjer commented 1 year ago

Ok, so this is what I see happening. Once again, letting you know I am using OVOS 0.0.7 and not NEON

The only config file that has "units" is the default from ovos-core and it is set to "metric", so assuming that, all of my units, weather, volume, distance, should also be metric.

The weather skill responds with Celsius, wolf responds in KM, but caffeinewiz gives me imperial. (ounces). Could be hardcoded, havent checked

I ask to "change my units to imperial" and it replies "units are already set to imperial" "change my units to metric"..."updating units to metric"

caffeinewiz still in imperial, must be the skill

"change my units to imperial"..."units are already set to imperial"

I am seeing this error in the logs 14:16:33.732 - skills - neon_utils.skills.neon_skill:update_profile:169 - ERROR - No profile found for user: None. Maybe something to do with it?

builderjer commented 1 year ago

I just tested this with the latest Neon image, and it seems to work perfectly. It must be with OVOS interrogation

NeonDaniel commented 1 year ago

Probably related to the way I patch settings references in NeonSkill methods. I'll take a look and see if I can determine why CaffeineWiz is different at least. Eventually, the user settings in Message objects will become a standard used in OVOS too, so that should take care of the other cases.