File tree Expand file tree Collapse file tree 3 files changed +8
-8
lines changed Expand file tree Collapse file tree 3 files changed +8
-8
lines changed Original file line number Diff line number Diff line change @@ -166,12 +166,12 @@ def __get_hardware_value(self):
166
166
data = func_timeout (self ._UPDATE_TIME_OUT , self ._get_hardware_value )
167
167
168
168
except FunctionTimedOut :
169
- raise terrariumRelayUpdateException (f"{ error_message } : Timed out after { self ._UPDATE_TIME_OUT } seconds. " )
169
+ raise terrariumRelayUpdateException (f"{ error_message } : Timed out after { self ._UPDATE_TIME_OUT } seconds" )
170
170
except Exception as ex :
171
- raise terrariumRelayUpdateException (f"{ error_message } : { ex } . " )
171
+ raise terrariumRelayUpdateException (f"{ error_message } : { ex } " )
172
172
173
173
if data is None :
174
- raise terrariumRelayUpdateException (f"{ error_message } : no data. " )
174
+ raise terrariumRelayUpdateException (f"{ error_message } : no data" )
175
175
176
176
return data
177
177
Original file line number Diff line number Diff line change @@ -296,14 +296,14 @@ def get_data(self):
296
296
data = func_timeout (self ._UPDATE_TIME_OUT , self ._get_data )
297
297
298
298
except FunctionTimedOut :
299
- raise terrariumSensorUpdateException (f"{ error_message } : Timed out after { self ._UPDATE_TIME_OUT } seconds. " )
299
+ raise terrariumSensorUpdateException (f"{ error_message } : Timed out after { self ._UPDATE_TIME_OUT } seconds" )
300
300
except Exception as ex :
301
- raise terrariumSensorUpdateException (f"{ error_message } : { ex } . " )
301
+ raise terrariumSensorUpdateException (f"{ error_message } : { ex } " )
302
302
finally :
303
303
self .__power_management (False )
304
304
305
305
if data is None :
306
- raise terrariumSensorUpdateException (f"{ error_message } : no data. " )
306
+ raise terrariumSensorUpdateException (f"{ error_message } : no data" )
307
307
308
308
return data
309
309
Original file line number Diff line number Diff line change @@ -92,7 +92,7 @@ def __repr__(self):
92
92
Returns:
93
93
string: Area with area type
94
94
"""
95
- return f'{ terrariumArea .__TYPES [self .type ]["name" ]} named { self .name } '
95
+ return f'{ terrariumArea .__TYPES [self .type ]["name" ]} named \' { self .name } \' '
96
96
97
97
@property
98
98
def _powered (self ):
@@ -877,7 +877,7 @@ def update(self, read_only=False):
877
877
self .state ["last_update" ] = int (datetime .datetime .now ().timestamp ())
878
878
879
879
logger .info (
880
- f"Updated area { self } in { self .mode } mode at enclosure { self .enclosure .name } in { time .time ()- start :.2f} seconds."
880
+ f"Updated area { self } in ' { self .mode } ' mode at enclosure { self .enclosure .name } in { time .time ()- start :.2f} seconds."
881
881
)
882
882
return self .state
883
883
You can’t perform that action at this time.
0 commit comments