diff --git a/aws_embedded_metrics/constants.py b/aws_embedded_metrics/constants.py
index ea53e7b..4fcdc5f 100644
--- a/aws_embedded_metrics/constants.py
+++ b/aws_embedded_metrics/constants.py
@@ -12,4 +12,4 @@
 # limitations under the License.
 
 DEFAULT_NAMESPACE = "aws-embedded-metrics"
-MAX_DIMENSIONS = 10
+MAX_DIMENSIONS = 9

MAX_DIMENSIONS should be 9, not 10
Per [the upstream docs](https://docs.aws.amazon.com/AmazonCloudWatch/latest/monitoring/CloudWatch_Embedded_Metric_Format_Specification.html#CloudWatch_Embedded_Metric_Format_Specification_structure_dimensionset):

> A DimensionSet MUST NOT contain more than 9 dimension keys.

Currently, you're setting `MAX_DIMENSIONS` to 10:

https://github.com/awslabs/aws-embedded-metrics-python/blob/658b2ebe829853a0ad53675d4b9d8917f7de18b7/aws_embedded_metrics/constants.py#L15

… and then using that to truncate the dimension set to 10 entries when serializing, e.g.:

https://github.com/awslabs/aws-embedded-metrics-python/blob/658b2ebe829853a0ad53675d4b9d8917f7de18b7/aws_embedded_metrics/serializers/log_serializer.py#L23-L30

I'm not sure that “silently truncating the dimension set” to an acceptable size is the best solution, but in any case the `MAX_DIMENSIONS` should be reduced to 9.
diff --git a/tests/serializer/test_log_serializer.py b/tests/serializer/test_log_serializer.py
index bd58d35..2a7eedd 100644
--- a/tests/serializer/test_log_serializer.py
+++ b/tests/serializer/test_log_serializer.py
@@ -28,11 +28,11 @@ def test_serialize_dimensions():
     assert_json_equality(result_json, expected)
 
 
-def test_cannot_serialize_more_than_10_dimensions():
+def test_cannot_serialize_more_than_9_dimensions():
     # arrange
     dimensions = {}
     dimension_pointers = []
-    allowed_dimensions = 10
+    allowed_dimensions = 9
     dimensions_to_add = 15
 
     for i in range(0, dimensions_to_add):

pip install -e .
parse_log_pytest
requirements.txt
pytest pytest-asyncio pytest-mock Faker aresponses boto3 pytest-timeout
apt-get update apt-get install -y gcc
3.7
requirements/base.txt
pytest --no-header -rA --tb=line --color=no -p no:cacheprovider -W ignore::DeprecationWarning
aiohttp==3.8.6
aiosignal==1.3.1
aresponses==3.0.0
async-timeout==4.0.3
asynctest==0.13.0
attrs==24.2.0
-e git+https://github.com/awslabs/aws-embedded-metrics-python.git@4388e0df2153a749defeece304521dac93c6d218#egg=aws_embedded_metrics
boto3==1.33.13
botocore==1.33.13
certifi @ file:///croot/certifi_1671487769961/work/certifi
charset-normalizer==3.4.1
exceptiongroup==1.2.2
Faker==18.13.0
frozenlist==1.3.3
idna==3.10
importlib-metadata==6.7.0
iniconfig==2.0.0
jmespath==1.0.1
multidict==6.0.5
packaging==24.0
pluggy==1.2.0
pytest==7.4.4
pytest-asyncio==0.21.2
pytest-mock==3.11.1
pytest-timeout==2.3.1
python-dateutil==2.9.0.post0
s3transfer==0.8.2
six==1.17.0
tomli==2.0.1
typing_extensions==4.7.1
urllib3==1.26.20
yarl==1.9.4
zipp==3.15.0

name: aws-embedded-metrics-python
channels:
  - defaults
  - https://repo.anaconda.com/pkgs/main
  - https://repo.anaconda.com/pkgs/r
  - conda-forge
dependencies:
  - _libgcc_mutex=0.1=main
  - _openmp_mutex=5.1=1_gnu
  - ca-certificates=2025.2.25=h06a4308_0
  - certifi=2022.12.7=py37h06a4308_0
  - ld_impl_linux-64=2.40=h12ee557_0
  - libffi=3.4.4=h6a678d5_1
  - libgcc-ng=11.2.0=h1234567_1
  - libgomp=11.2.0=h1234567_1
  - libstdcxx-ng=11.2.0=h1234567_1
  - ncurses=6.4=h6a678d5_0
  - openssl=1.1.1w=h7f8727e_0
  - pip=22.3.1=py37h06a4308_0
  - python=3.7.16=h7a1cb2a_0
  - readline=8.2=h5eee18b_0
  - setuptools=65.6.3=py37h06a4308_0
  - sqlite=3.45.3=h5eee18b_0
  - tk=8.6.14=h39e8969_0
  - wheel=0.38.4=py37h06a4308_0
  - xz=5.6.4=h5eee18b_1
  - zlib=1.2.13=h5eee18b_1
  - pip:
      - aiohttp==3.8.6
      - aiosignal==1.3.1
      - aresponses==3.0.0
      - async-timeout==4.0.3
      - asynctest==0.13.0
      - attrs==24.2.0
      - boto3==1.33.13
      - botocore==1.33.13
      - charset-normalizer==3.4.1
      - exceptiongroup==1.2.2
      - faker==18.13.0
      - frozenlist==1.3.3
      - idna==3.10
      - importlib-metadata==6.7.0
      - iniconfig==2.0.0
      - jmespath==1.0.1
      - multidict==6.0.5
      - packaging==24.0
      - pluggy==1.2.0
      - pytest==7.4.4
      - pytest-asyncio==0.21.2
      - pytest-mock==3.11.1
      - pytest-timeout==2.3.1
      - python-dateutil==2.9.0.post0
      - s3transfer==0.8.2
      - six==1.17.0
      - tomli==2.0.1
      - typing-extensions==4.7.1
      - urllib3==1.26.20
      - yarl==1.9.4
      - zipp==3.15.0
prefix: /opt/conda/envs/aws-embedded-metrics-python

tests/serializer/test_log_serializer.py::test_cannot_serialize_more_than_9_dimensions
tests/serializer/test_log_serializer.py::test_serialize_dimensions tests/serializer/test_log_serializer.py::test_serialize_properties tests/serializer/test_log_serializer.py::test_serialize_metrics
aws_embedded_metrics/constants.py
aws_embedded_metrics/constants.py