robmarkcole / HASS-plate-recognizer

Read number plates with https://platerecognizer.com/
128 stars 25 forks source link

get_orientations error: 'orientation' #36

Closed greberg closed 3 years ago

greberg commented 3 years ago

Getting following error get_orientations error: 'orientation'. Getting this everytime a platrecognizer is triggered

Source: custom_components/platerecognizer/image_processing.py:94

Running release 1.1.0 of Plate and HA 2021.5.2

greberg commented 3 years ago

It seems like it is due to mmc=false. Orientation is only possible to get if you have set mmc = true. API says // Make Model, Orientation and Color are only available if you set mmc=true. The custom_component is firing def get_orientations(results : List[Dict]) -> List[str]: every time it run a platerecognizer. Should probably be a if-statement here

robmarkcole commented 3 years ago

Can someone create a PR?

supajason commented 3 years ago

PR created @robmarkcole

Marco2205 commented 1 year ago

Dear @robmarkcole congratulations for the project, can you confirm that orientation can only be used with the paid subscription? it's really a shame!