### Is there an existing issue for this?

- [X] I have searched the existing issues

### Current Behavior

When cloudwatch alarm should trigger alarm action sending message to sns topic the following error messages occurs:

`2023-08-18T08:01:21.489 ERROR --- [   asgi_gw_1] l.aws.handlers.logging     : exception during call chain: could not convert string to float: 'None'
2023-08-18T08:01:21.918 ERROR --- [   asgi_gw_5] l.aws.handlers.logging     : exception during call chain: could not convert string to float: 'None'
2023-08-18T08:01:23.526 ERROR --- [   asgi_gw_0] l.aws.handlers.logging     : exception during call chain: could not convert string to float: 'None'
2023-08-18T08:01:26.861 ERROR --- [   asgi_gw_3] l.aws.handlers.logging     : exception during call chain: could not convert string to float: 'None'
2023-08-18T08:01:32.779 ERROR --- [   asgi_gw_2] l.aws.handlers.logging     : exception during call chain: could not convert string to float: 'None'
2023-08-18T08:01:32.782 ERROR --- [ch-scheduler] l.s.c.alarm_scheduler      : Error executing scheduled alarm
Traceback (most recent call last):
  File "/opt/code/localstack/localstack/utils/scheduler.py", line 64, in run
    self.task(*self.args, **self.kwargs)
  File "/opt/code/localstack/localstack/services/cloudwatch/alarm_scheduler.py", line 294, in calculate_alarm_state
    metric_values = collect_metric_data(alarm_details, client)
  File "/opt/code/localstack/localstack/services/cloudwatch/alarm_scheduler.py", line 243, in collect_metric_data
    metric_data = client.get_metric_data(
  File "/opt/code/localstack/.venv/lib/python3.10/site-packages/botocore/client.py", line 534, in _api_call
    return self._make_api_call(operation_name, kwargs)
  File "/opt/code/localstack/.venv/lib/python3.10/site-packages/botocore/client.py", line 976, in _make_api_call
    raise error_class(parsed_response, operation_name)
botocore.exceptions.ClientError: An error occurred (InternalError) when calling the GetMetricData operation (reached max retries: 4): exception while calling cloudwatch.GetMetricData: could not convert string to float: 'None'
`

### Expected Behavior

Alarm should send message to sns topic

### How are you starting LocalStack?

With a `docker run` command

### Steps To Reproduce

### Sequence of actions:
1 - run docker image
2 - run terraform aplly
3 - send message to the queue from localstack container terminal

#### How are you starting localstack (e.g., `bin/localstack` command, arguments, or `docker-compose.yml`)

`docker run --rm -eSERVICES=sqs,cloudwatch,sns -p4566:4566 localstack/localstack:2.2.0`

#### Client commands (e.g., AWS SDK code snippet, or sequence of "awslocal" commands)

    awslocal sqs send-message \
        --queue-url http://localhost:4566/000000000000/queue-to-watch \
        --message-body '{"test" : "test_message"}'

### Terraform script 

```terraform
terraform {

  required_providers {
    aws = {
      source  = "hashicorp/aws"
      version = "~> 4.62.0"
    }
  }

  required_version = ">= 1.4.4"
}

provider "aws" {
  region = "us-east-1"

  skip_requesting_account_id = true
  skip_credentials_validation = true
  skip_metadata_api_check     = true
  s3_use_path_style         = true
  access_key                  = "mock_access_key"
  secret_key                  = "mock_secret_key"

  endpoints {
    sqs       = "http://localhost:4566"
    sns       = "http://localhost:4566"
    cloudwatch       = "http://localhost:4566"
  }
}

resource "aws_sns_topic" "error_notifications" {
  name = "error-notifications-topic"
}

resource "aws_sqs_queue" "queue_to_watch" {
  name                 = "queue-to-watch"
}

resource "aws_cloudwatch_metric_alarm" "queue_to_watch_new_message_alarm" {
  alarm_name          = "queue_to_watch_new_message"
  comparison_operator = "GreaterThanThreshold"
  threshold           = 0
  evaluation_periods  = 1
  metric_name         = "NumberOfMessagesSent"
  namespace           = "AWS/SQS"
  dimensions = {
    QueueName = aws_sqs_queue.queue_to_watch.name
  }
  period              = 1 * 60 // 1 minutes
  statistic           = "SampleCount"

  alarm_description   = "New event in queue-to-watch queue"
  alarm_actions       = [aws_sns_topic.error_notifications.arn]
}
```

### Environment

```markdown
- OS: macOS 13.4.1 (22F770820d)
- LocalStack: 2.1.0 and 2.2.0
```


### Anything else?

[cloudwatch_alarm_error.log](https://github.com/localstack/localstack/files/12377169/cloudwatch_alarm_error.log)

self.tags = TaggingService()
        self.alarm_scheduler = None
    def on_after_init(self):
        ROUTER.add(PATH_GET_RAW_METRICS, self.get_raw_metrics)
        self.start_alarm_scheduler()
    def on_before_state_reset(self):
        self.shutdown_alarm_scheduler()
    def on_after_state_reset(self):
        self.start_alarm_scheduler()
    def on_before_state_load(self):
        self.shutdown_alarm_scheduler()
    def on_after_state_load(self):
        self.start_alarm_scheduler()
        def restart_alarms(*args):
            poll_condition(lambda: SERVICE_PLUGINS.is_running("cloudwatch"))
            self.alarm_scheduler.restart_existing_alarms()
        start_worker_thread(restart_alarms)
    def on_before_stop(self):
        self.shutdown_alarm_scheduler()
    def start_alarm_scheduler(self):
        if not self.alarm_scheduler:
            LOG.debug("starting cloudwatch scheduler")
            self.alarm_scheduler = AlarmScheduler()
    def shutdown_alarm_scheduler(self):
        LOG.debug("stopping cloudwatch scheduler")
        self.alarm_scheduler.shutdown_scheduler()
        self.alarm_scheduler = None
    def delete_alarms(self, context: RequestContext, alarm_names: AlarmNames) -> None: