code: def test_py3_error(load_config, scope):
      VERSIONS = load_config[scope]["versions"]
      for version in VERSIONS:
          with pytest.raises(ValueError) as e:
              image_uris.retrieve(
                  "autogluon",
                  region="us-west-2",
                  version=version,
                  py_version="py3",
                  image_scope="training",
                  instance_type="ml.c4.xlarge",
              )
  
      assert "Unsupported Python version: py3." in str(e.value)
  
imports: from __future__ import absolute_import
  import pytest
  from sagemaker import image_uris
  from tests.unit.sagemaker.image_uris import expected_uris
label_desc: Use image node_id 2 for calling a global function with example usage: test_py3_error(load_config, scope) without return types