def describe_autoscale(self): results = as_client.describe_auto_scaling_instances( InstanceIds=[self.instance.instance_id]) return results['AutoScalingInstances'][0]
def describe_autoscale(self) -> Optional[Dict]: results = as_client.describe_auto_scaling_instances( InstanceIds=[self.instance.instance_id])['AutoScalingInstances'] if not results: return None return results[0]