diff --git a/TestModels/Aggregate/Makefile b/TestModels/Aggregate/Makefile index cd915ae64..48a8fb216 100644 --- a/TestModels/Aggregate/Makefile +++ b/TestModels/Aggregate/Makefile @@ -6,6 +6,8 @@ CORES=2 include ../SharedMakefile.mk NAMESPACE=simple.aggregate +# TODO: Move to smithy-build.json once language-specific config is supported +PYTHON_MODULE_NAME=simple_aggregate # This project has no dependencies # DEPENDENT-MODELS:= diff --git a/TestModels/Aggregate/runtimes/python/pyproject.toml b/TestModels/Aggregate/runtimes/python/pyproject.toml index 4ce526024..aeff17558 100644 --- a/TestModels/Aggregate/runtimes/python/pyproject.toml +++ b/TestModels/Aggregate/runtimes/python/pyproject.toml @@ -24,7 +24,3 @@ simple-aggregate-test-internaldafny = { path = "test/internaldafny", develop = f [build-system] requires = ["poetry-core"] build-backend = "poetry.core.masonry.api" - -[aws.polymorph.config] -# The string below defines where Polymorph will move code. -polymorph_package_name = "simple_aggregate" \ No newline at end of file diff --git a/TestModels/Constraints/Makefile b/TestModels/Constraints/Makefile index 14cd02de9..fe6e07734 100644 --- a/TestModels/Constraints/Makefile +++ b/TestModels/Constraints/Makefile @@ -6,6 +6,8 @@ CORES=2 include ../SharedMakefile.mk NAMESPACE=simple.constraints +# TODO: Move to smithy-build.json once language-specific config is supported +PYTHON_MODULE_NAME=simple_constraints # This project has no dependencies # DEPENDENT-MODELS:= diff --git a/TestModels/Constraints/runtimes/python/pyproject.toml b/TestModels/Constraints/runtimes/python/pyproject.toml index 6476965b8..78edd473e 100644 --- a/TestModels/Constraints/runtimes/python/pyproject.toml +++ b/TestModels/Constraints/runtimes/python/pyproject.toml @@ -24,7 +24,3 @@ simple-constraints-test-internaldafny = { path = "test/internaldafny", develop = [build-system] requires = ["poetry-core"] build-backend = "poetry.core.masonry.api" - -[aws.polymorph.config] -# The string below defines where Polymorph will move code. -polymorph_package_name = "simple_constraints" \ No newline at end of file diff --git a/TestModels/Constructor/Makefile b/TestModels/Constructor/Makefile index d45d3c705..36d7a8305 100644 --- a/TestModels/Constructor/Makefile +++ b/TestModels/Constructor/Makefile @@ -6,6 +6,8 @@ CORES=2 include ../SharedMakefile.mk NAMESPACE=simple.constructor +# TODO: Move to smithy-build.json once language-specific config is supported +PYTHON_MODULE_NAME=simple_constructor # This project has no dependencies # DEPENDENT-MODELS:= diff --git a/TestModels/Constructor/runtimes/python/pyproject.toml b/TestModels/Constructor/runtimes/python/pyproject.toml index b7c2e0812..f6ba6b529 100644 --- a/TestModels/Constructor/runtimes/python/pyproject.toml +++ b/TestModels/Constructor/runtimes/python/pyproject.toml @@ -24,7 +24,3 @@ simple-constructor-test-internaldafny = { path = "test/internaldafny", develop = [build-system] requires = ["poetry-core"] build-backend = "poetry.core.masonry.api" - -[aws.polymorph.config] -# The string below defines where Polymorph will move code. -polymorph_package_name = "simple_constructor" \ No newline at end of file diff --git a/TestModels/Dependencies/Makefile b/TestModels/Dependencies/Makefile index 0403381cc..402a4c1aa 100644 --- a/TestModels/Dependencies/Makefile +++ b/TestModels/Dependencies/Makefile @@ -6,6 +6,8 @@ CORES=2 include ../SharedMakefile.mk NAMESPACE=simple.dependencies +# TODO: Move to smithy-build.json once language-specific config is supported +PYTHON_MODULE_NAME=simple_dependencies # This project takes dependencies on: # - SimpleResource diff --git a/TestModels/Dependencies/runtimes/python/pyproject.toml b/TestModels/Dependencies/runtimes/python/pyproject.toml index 16185b15e..0a2cbd221 100644 --- a/TestModels/Dependencies/runtimes/python/pyproject.toml +++ b/TestModels/Dependencies/runtimes/python/pyproject.toml @@ -28,7 +28,3 @@ simple-dependencies-test-internaldafny = { path = "test/internaldafny", develop [build-system] requires = ["poetry-core"] build-backend = "poetry.core.masonry.api" - -[aws.polymorph.config] -# The string below defines where Polymorph will move code. -polymorph_package_name = "simple_dependencies" \ No newline at end of file diff --git a/TestModels/Errors/Makefile b/TestModels/Errors/Makefile index a5116a2ed..d9b92ce71 100644 --- a/TestModels/Errors/Makefile +++ b/TestModels/Errors/Makefile @@ -6,6 +6,8 @@ CORES=2 include ../SharedMakefile.mk NAMESPACE=simple.errors +# TODO: Move to smithy-build.json once language-specific config is supported +PYTHON_MODULE_NAME=simple_errors # This project has no dependencies # DEPENDENT-MODELS:= diff --git a/TestModels/Errors/runtimes/python/pyproject.toml b/TestModels/Errors/runtimes/python/pyproject.toml index 45ca60b85..25c18704d 100644 --- a/TestModels/Errors/runtimes/python/pyproject.toml +++ b/TestModels/Errors/runtimes/python/pyproject.toml @@ -24,7 +24,3 @@ simple-errors-test-internaldafny = { path = "test/internaldafny", develop = fals [build-system] requires = ["poetry-core"] build-backend = "poetry.core.masonry.api" - -[aws.polymorph.config] -# The string below defines where Polymorph will move code. -polymorph_package_name = "simple_errors" \ No newline at end of file diff --git a/TestModels/Extendable/Makefile b/TestModels/Extendable/Makefile index 37eb3309a..bf8c9988f 100644 --- a/TestModels/Extendable/Makefile +++ b/TestModels/Extendable/Makefile @@ -6,6 +6,8 @@ CORES=2 include ../SharedMakefile.mk NAMESPACE=simple.extendable.resources +# TODO: Move to smithy-build.json once language-specific config is supported +PYTHON_MODULE_NAME=simple_extendable_resources # This project has no dependencies # DEPENDENT-MODELS:= diff --git a/TestModels/Extendable/runtimes/python/pyproject.toml b/TestModels/Extendable/runtimes/python/pyproject.toml index bf5676bdb..8eafc44b9 100644 --- a/TestModels/Extendable/runtimes/python/pyproject.toml +++ b/TestModels/Extendable/runtimes/python/pyproject.toml @@ -24,7 +24,3 @@ simple-extendable-resources-test-internaldafny = { path = "test/internaldafny", [build-system] requires = ["poetry-core"] build-backend = "poetry.core.masonry.api" - -[aws.polymorph.config] -# The string below defines where Polymorph will move code. -polymorph_package_name = "simple_extendable_resources" \ No newline at end of file diff --git a/TestModels/Extern/Makefile b/TestModels/Extern/Makefile index 5eb231418..ded1dd1cd 100644 --- a/TestModels/Extern/Makefile +++ b/TestModels/Extern/Makefile @@ -6,6 +6,8 @@ CORES=2 include ../SharedMakefile.mk NAMESPACE=simple.dafnyExtern +# TODO: Move to smithy-build.json once language-specific config is supported +PYTHON_MODULE_NAME=simple_dafnyextern # This project has no dependencies # DEPENDENT-MODELS:= diff --git a/TestModels/Extern/runtimes/python/pyproject.toml b/TestModels/Extern/runtimes/python/pyproject.toml index 39d0476d5..4066c6485 100644 --- a/TestModels/Extern/runtimes/python/pyproject.toml +++ b/TestModels/Extern/runtimes/python/pyproject.toml @@ -24,7 +24,3 @@ simple-extern-test-internaldafny = { path = "test/internaldafny", develop = fals [build-system] requires = ["poetry-core"] build-backend = "poetry.core.masonry.api" - -[aws.polymorph.config] -# The string below defines where Polymorph will move code. -polymorph_package_name = "simple_dafnyextern" \ No newline at end of file diff --git a/TestModels/LocalService/Makefile b/TestModels/LocalService/Makefile index 79574bc6b..badb14a51 100644 --- a/TestModels/LocalService/Makefile +++ b/TestModels/LocalService/Makefile @@ -6,6 +6,8 @@ CORES=2 include ../SharedMakefile.mk NAMESPACE=simple.localService +# TODO: Move to smithy-build.json once language-specific config is supported +PYTHON_MODULE_NAME=simple_localservice # This project has no dependencies # DEPENDENT-MODELS:= diff --git a/TestModels/LocalService/runtimes/python/pyproject.toml b/TestModels/LocalService/runtimes/python/pyproject.toml index 0b51a93d1..8e888f66f 100644 --- a/TestModels/LocalService/runtimes/python/pyproject.toml +++ b/TestModels/LocalService/runtimes/python/pyproject.toml @@ -24,7 +24,3 @@ simple-localservice-test-internaldafny = { path = "test/internaldafny", develop [build-system] requires = ["poetry-core"] build-backend = "poetry.core.masonry.api" - -[aws.polymorph.config] -# The string below defines where Polymorph will move code. -polymorph_package_name = "simple_localservice" \ No newline at end of file diff --git a/TestModels/Refinement/Makefile b/TestModels/Refinement/Makefile index 6c97fe105..b4f2a7236 100644 --- a/TestModels/Refinement/Makefile +++ b/TestModels/Refinement/Makefile @@ -6,6 +6,8 @@ CORES=2 include ../SharedMakefile.mk NAMESPACE=simple.refinement +# TODO: Move to smithy-build.json once language-specific config is supported +PYTHON_MODULE_NAME=simple_refinement # This project has no dependencies # DEPENDENT-MODELS:= diff --git a/TestModels/Refinement/runtimes/python/pyproject.toml b/TestModels/Refinement/runtimes/python/pyproject.toml index 91fcc550a..74ded209a 100644 --- a/TestModels/Refinement/runtimes/python/pyproject.toml +++ b/TestModels/Refinement/runtimes/python/pyproject.toml @@ -24,7 +24,3 @@ simple-refinement-test-internaldafny = { path = "test/internaldafny", develop = [build-system] requires = ["poetry-core"] build-backend = "poetry.core.masonry.api" - -[aws.polymorph.config] -# The string below defines where Polymorph will move code. -polymorph_package_name = "simple_refinement" \ No newline at end of file diff --git a/TestModels/Resource/Makefile b/TestModels/Resource/Makefile index 54f4b648f..ff562b474 100644 --- a/TestModels/Resource/Makefile +++ b/TestModels/Resource/Makefile @@ -6,6 +6,8 @@ CORES=2 include ../SharedMakefile.mk NAMESPACE=simple.resources +# TODO: Move to smithy-build.json once language-specific config is supported +PYTHON_MODULE_NAME=simple_resources # This project has no dependencies # DEPENDENT-MODELS:= diff --git a/TestModels/Resource/runtimes/python/pyproject.toml b/TestModels/Resource/runtimes/python/pyproject.toml index 456ae1f8e..81e6b8f36 100644 --- a/TestModels/Resource/runtimes/python/pyproject.toml +++ b/TestModels/Resource/runtimes/python/pyproject.toml @@ -24,7 +24,3 @@ simple-resources-test-internaldafny = { path = "test/internaldafny", develop = f [build-system] requires = ["poetry-core"] build-backend = "poetry.core.masonry.api" - -[aws.polymorph.config] -# The string below defines where Polymorph will move code. -polymorph_package_name = "simple_resources" \ No newline at end of file diff --git a/TestModels/SharedMakefile.mk b/TestModels/SharedMakefile.mk index 31724060f..b7349c7d3 100644 --- a/TestModels/SharedMakefile.mk +++ b/TestModels/SharedMakefile.mk @@ -54,9 +54,9 @@ CODEGEN_CLI_ROOT := $(PROJECT_ROOT)/../codegen/smithy-dafny-codegen-cli GRADLEW := $(PROJECT_ROOT)/../codegen/gradlew # Returns the name of the Python module as stored in the project's build configuration file (pyproject.toml). -define GetPythonModuleName -$(shell grep -m 1 polymorph_package_name runtimes/python/pyproject.toml | tr -s ' ' | tr -d '"' | tr -d "'" | cut -d' ' -f3) -endef +#define GetPythonModuleName +#$(shell grep -m 1 polymorph_package_name runtimes/python/pyproject.toml | tr -s ' ' | tr -d '"' | tr -d "'" | cut -d' ' -f3) +#endef ########################## Dafny targets @@ -189,7 +189,6 @@ _polymorph: --dependent-model $(PROJECT_ROOT)/dafny-dependencies/Model \ $(patsubst %, --dependent-model $(PROJECT_ROOT)/%/Model, $(LIBRARIES)) \ --namespace $(NAMESPACE) \ - $(SMITHY_BUILD) \ $(AWS_SDK_CMD)"; # If the target language of _polymorph_wrapped includes Python, @@ -208,7 +207,6 @@ _polymorph_wrapped: $(patsubst %, --dependent-model $(PROJECT_ROOT)/%/Model, $(LIBRARIES)) \ --namespace $(NAMESPACE) \ $(OUTPUT_LOCAL_SERVICE) \ - $(SMITHY_BUILD) \ $(AWS_SDK_CMD)"; _polymorph_dependencies: @@ -257,14 +255,13 @@ polymorph_java: _polymorph_dependencies # For python, _polymorph_wrapped includes _polymorph (i.e. local service generation AND wrapped test) # To generate only the local service, use the `_polymorph` target # There is not a good way to generate only the wrapped test without the local service... -polymorph_python: SMITHY_BUILD=--smithy-build $(LIBRARY_ROOT)/smithy-build.json polymorph_python: OUTPUT_PYTHON_WRAPPED=--output-python $(LIBRARY_ROOT)/runtimes/python/smithygenerated polymorph_python: OUTPUT_LOCAL_SERVICE=--local-service-test polymorph_python: _polymorph_wrapped polymorph_python: - rm -rf runtimes/python/src/$(call GetPythonModuleName)/smithygenerated - mkdir runtimes/python/src/$(call GetPythonModuleName)/smithygenerated - mv runtimes/python/smithygenerated/$(call GetPythonModuleName)/* runtimes/python/src/$(call GetPythonModuleName)/smithygenerated + rm -rf runtimes/python/src/$(PYTHON_MODULE_NAME)/smithygenerated + mkdir runtimes/python/src/$(PYTHON_MODULE_NAME)/smithygenerated + mv runtimes/python/smithygenerated/$(PYTHON_MODULE_NAME)/* runtimes/python/src/$(PYTHON_MODULE_NAME)/smithygenerated rm -rf runtimes/python/smithygenerated polymorph_python: POLYMORPH_LANGUAGE_TARGET=python polymorph_python: _polymorph_dependencies @@ -406,9 +403,9 @@ _python_revert_underscore_dependency_extern_names: # Move Dafny-generated code into its expected location in the Python module _mv_internaldafny_python: # Remove any previously generated Dafny code in src/, then copy in newly-generated code - rm -rf runtimes/python/src/$(call GetPythonModuleName)/internaldafny/generated/ - mkdir runtimes/python/src/$(call GetPythonModuleName)/internaldafny/generated/ - mv runtimes/python/dafny_src-py/*.py runtimes/python/src/$(call GetPythonModuleName)/internaldafny/generated + rm -rf runtimes/python/src/$(PYTHON_MODULE_NAME)/internaldafny/generated/ + mkdir runtimes/python/src/$(PYTHON_MODULE_NAME)/internaldafny/generated/ + mv runtimes/python/dafny_src-py/*.py runtimes/python/src/$(PYTHON_MODULE_NAME)/internaldafny/generated rm -rf runtimes/python/dafny_src-py # Remove any previously generated Dafny code in test/, then copy in newly-generated code rm -rf runtimes/python/test/internaldafny/generated @@ -439,7 +436,7 @@ _remove_src_module_python: # The test/ file contains code to execute tests. The src/ file is largely empty. # If the src/ file is installed most recently, tests will fail to run. # By removing the src/ file, we ensure the test/ file is always the installed file. - rm runtimes/python/src/$(call GetPythonModuleName)/internaldafny/generated/module_.py + rm runtimes/python/src/$(PYTHON_MODULE_NAME)/internaldafny/generated/module_.py transpile_dependencies_python: LANG=python transpile_dependencies_python: transpile_dependencies diff --git a/TestModels/SimpleTypes/SimpleBlob/Makefile b/TestModels/SimpleTypes/SimpleBlob/Makefile index 1c43413b7..94bcd27e6 100644 --- a/TestModels/SimpleTypes/SimpleBlob/Makefile +++ b/TestModels/SimpleTypes/SimpleBlob/Makefile @@ -6,6 +6,8 @@ CORES=2 include ../../SharedMakefile.mk NAMESPACE=simple.types.blob +# TODO: Move to smithy-build.json once language-specific config is supported +PYTHON_MODULE_NAME=simple_blob # This project has no dependencies # DEPENDENT-MODELS:= diff --git a/TestModels/SimpleTypes/SimpleBlob/runtimes/python/pyproject.toml b/TestModels/SimpleTypes/SimpleBlob/runtimes/python/pyproject.toml index a19ea4555..5ba4a7dd6 100644 --- a/TestModels/SimpleTypes/SimpleBlob/runtimes/python/pyproject.toml +++ b/TestModels/SimpleTypes/SimpleBlob/runtimes/python/pyproject.toml @@ -24,7 +24,3 @@ simple-blob-test-internaldafny = { path = "test/internaldafny", develop = false} [build-system] requires = ["poetry-core"] build-backend = "poetry.core.masonry.api" - -[aws.polymorph.config] -# The string below defines where Polymorph will move code. -polymorph_package_name = "simple_types_blob" \ No newline at end of file diff --git a/TestModels/SimpleTypes/SimpleBoolean/Makefile b/TestModels/SimpleTypes/SimpleBoolean/Makefile index 2125437c8..3016dc95d 100644 --- a/TestModels/SimpleTypes/SimpleBoolean/Makefile +++ b/TestModels/SimpleTypes/SimpleBoolean/Makefile @@ -6,6 +6,8 @@ CORES=2 include ../../SharedMakefile.mk NAMESPACE=simple.types.boolean +# TODO: Move to smithy-build.json once language-specific config is supported +PYTHON_MODULE_NAME=simple_boolean # This project has no dependencies # DEPENDENT-MODELS:= diff --git a/TestModels/SimpleTypes/SimpleBoolean/runtimes/python/pyproject.toml b/TestModels/SimpleTypes/SimpleBoolean/runtimes/python/pyproject.toml index 037ce45ec..add7f5ff2 100644 --- a/TestModels/SimpleTypes/SimpleBoolean/runtimes/python/pyproject.toml +++ b/TestModels/SimpleTypes/SimpleBoolean/runtimes/python/pyproject.toml @@ -24,7 +24,3 @@ simple-boolean-test-internaldafny = { path = "test/internaldafny", develop = fal [build-system] requires = ["poetry-core"] build-backend = "poetry.core.masonry.api" - -[aws.polymorph.config] -# The string below defines where Polymorph will move code. -polymorph_package_name = "simple_types_boolean" \ No newline at end of file diff --git a/TestModels/SimpleTypes/SimpleDouble/Makefile b/TestModels/SimpleTypes/SimpleDouble/Makefile index 9951b80c8..5e561b931 100644 --- a/TestModels/SimpleTypes/SimpleDouble/Makefile +++ b/TestModels/SimpleTypes/SimpleDouble/Makefile @@ -6,6 +6,8 @@ CORES=2 include ../../SharedMakefile.mk NAMESPACE=simple.types.smithyDouble +# TODO: Move to smithy-build.json once language-specific config is supported +PYTHON_MODULE_NAME=simple_types_smithydouble # This project has no dependencies # DEPENDENT-MODELS:= diff --git a/TestModels/SimpleTypes/SimpleDouble/runtimes/python/pyproject.toml b/TestModels/SimpleTypes/SimpleDouble/runtimes/python/pyproject.toml index e93681116..0d5f9439d 100644 --- a/TestModels/SimpleTypes/SimpleDouble/runtimes/python/pyproject.toml +++ b/TestModels/SimpleTypes/SimpleDouble/runtimes/python/pyproject.toml @@ -25,6 +25,3 @@ simple-double-test-internaldafny = { path = "test/internaldafny", develop = fals requires = ["poetry-core"] build-backend = "poetry.core.masonry.api" -[aws.polymorph.config] -# The string below defines where Polymorph will move code. -polymorph_package_name = "simple_types_smithydouble" diff --git a/TestModels/SimpleTypes/SimpleEnum/Makefile b/TestModels/SimpleTypes/SimpleEnum/Makefile index 180dc8811..55767b031 100644 --- a/TestModels/SimpleTypes/SimpleEnum/Makefile +++ b/TestModels/SimpleTypes/SimpleEnum/Makefile @@ -6,6 +6,8 @@ CORES=2 include ../../SharedMakefile.mk NAMESPACE=simple.types.smithyEnum +# TODO: Move to smithy-build.json once language-specific config is supported +PYTHON_MODULE_NAME=simple_types_smithyenum # This project has no dependencies # DEPENDENT-MODELS:= diff --git a/TestModels/SimpleTypes/SimpleEnum/runtimes/python/pyproject.toml b/TestModels/SimpleTypes/SimpleEnum/runtimes/python/pyproject.toml index 596fa26af..051233c2d 100644 --- a/TestModels/SimpleTypes/SimpleEnum/runtimes/python/pyproject.toml +++ b/TestModels/SimpleTypes/SimpleEnum/runtimes/python/pyproject.toml @@ -24,7 +24,3 @@ simple-enum-test-internaldafny = { path = "test/internaldafny", develop = false} [build-system] requires = ["poetry-core"] build-backend = "poetry.core.masonry.api" - -[aws.polymorph.config] -# The string below defines where Polymorph will move code. -polymorph_package_name = "simple_types_smithyenum" \ No newline at end of file diff --git a/TestModels/SimpleTypes/SimpleInteger/Makefile b/TestModels/SimpleTypes/SimpleInteger/Makefile index 8ce7f0866..083d0789a 100644 --- a/TestModels/SimpleTypes/SimpleInteger/Makefile +++ b/TestModels/SimpleTypes/SimpleInteger/Makefile @@ -6,6 +6,8 @@ CORES=2 include ../../SharedMakefile.mk NAMESPACE=simple.types.integer +# TODO: Move to smithy-build.json once language-specific config is supported +PYTHON_MODULE_NAME=simple_types_integer # This project has no dependencies # DEPENDENT-MODELS:= diff --git a/TestModels/SimpleTypes/SimpleInteger/runtimes/python/pyproject.toml b/TestModels/SimpleTypes/SimpleInteger/runtimes/python/pyproject.toml index 4e89c3283..973f48aad 100644 --- a/TestModels/SimpleTypes/SimpleInteger/runtimes/python/pyproject.toml +++ b/TestModels/SimpleTypes/SimpleInteger/runtimes/python/pyproject.toml @@ -24,7 +24,3 @@ simple-integer-test-internaldafny = { path = "test/internaldafny", develop = fal [build-system] requires = ["poetry-core"] build-backend = "poetry.core.masonry.api" - -[aws.polymorph.config] -# The string below defines where Polymorph will move code. -polymorph_package_name = "simple_types_integer" \ No newline at end of file diff --git a/TestModels/SimpleTypes/SimpleLong/Makefile b/TestModels/SimpleTypes/SimpleLong/Makefile index 1a345b126..730b4da80 100644 --- a/TestModels/SimpleTypes/SimpleLong/Makefile +++ b/TestModels/SimpleTypes/SimpleLong/Makefile @@ -6,6 +6,8 @@ CORES=2 include ../../SharedMakefile.mk NAMESPACE=simple.types.smithyLong +# TODO: Move to smithy-build.json once language-specific config is supported +PYTHON_MODULE_NAME=simple_types_smithylong # This project has no dependencies # DEPENDENT-MODELS:= diff --git a/TestModels/SimpleTypes/SimpleLong/runtimes/python/pyproject.toml b/TestModels/SimpleTypes/SimpleLong/runtimes/python/pyproject.toml index 50fca5501..fe4ae595b 100644 --- a/TestModels/SimpleTypes/SimpleLong/runtimes/python/pyproject.toml +++ b/TestModels/SimpleTypes/SimpleLong/runtimes/python/pyproject.toml @@ -24,7 +24,3 @@ simple-long-test-internaldafny = { path = "test/internaldafny", develop = false} [build-system] requires = ["poetry-core"] build-backend = "poetry.core.masonry.api" - -[aws.polymorph.config] -# The string below defines where Polymorph will move code. -polymorph_package_name = "simple_types_smithylong" \ No newline at end of file diff --git a/TestModels/SimpleTypes/SimpleString/Makefile b/TestModels/SimpleTypes/SimpleString/Makefile index cf02822a1..a3427b4a0 100644 --- a/TestModels/SimpleTypes/SimpleString/Makefile +++ b/TestModels/SimpleTypes/SimpleString/Makefile @@ -6,6 +6,8 @@ CORES=2 include ../../SharedMakefile.mk NAMESPACE=simple.types.smithyString +# TODO: Move to smithy-build.json once language-specific config is supported +PYTHON_MODULE_NAME=simple_types_smithystring # This project has no dependencies # DEPENDENT-MODELS:= diff --git a/TestModels/SimpleTypes/SimpleString/runtimes/python/pyproject.toml b/TestModels/SimpleTypes/SimpleString/runtimes/python/pyproject.toml index 4f250d511..271999742 100644 --- a/TestModels/SimpleTypes/SimpleString/runtimes/python/pyproject.toml +++ b/TestModels/SimpleTypes/SimpleString/runtimes/python/pyproject.toml @@ -24,7 +24,3 @@ simple-string-test-internaldafny = { path = "test/internaldafny", develop = fals [build-system] requires = ["poetry-core"] build-backend = "poetry.core.masonry.api" - -[aws.polymorph.config] -# The string below defines where Polymorph will move code. -polymorph_package_name = "simple_types_smithystring" \ No newline at end of file diff --git a/TestModels/Union/Makefile b/TestModels/Union/Makefile index f394a6fc8..4830f2951 100644 --- a/TestModels/Union/Makefile +++ b/TestModels/Union/Makefile @@ -6,6 +6,8 @@ CORES=2 include ../SharedMakefile.mk NAMESPACE=simple.union +# TODO: Move to smithy-build.json once language-specific config is supported +PYTHON_MODULE_NAME=simple_union # This project has no dependencies # DEPENDENT-MODELS:= diff --git a/TestModels/Union/runtimes/python/pyproject.toml b/TestModels/Union/runtimes/python/pyproject.toml index 448b7e7b7..5ae60b577 100644 --- a/TestModels/Union/runtimes/python/pyproject.toml +++ b/TestModels/Union/runtimes/python/pyproject.toml @@ -24,7 +24,3 @@ simple-union-test-internaldafny = { path = "test/internaldafny", develop = false [build-system] requires = ["poetry-core"] build-backend = "poetry.core.masonry.api" - -[aws.polymorph.config] -# The string below defines where Polymorph will move code. -polymorph_package_name = "simple_union" \ No newline at end of file diff --git a/TestModels/dafny-dependencies/StandardLibrary/Makefile b/TestModels/dafny-dependencies/StandardLibrary/Makefile index 15798ed58..04bf20b60 100644 --- a/TestModels/dafny-dependencies/StandardLibrary/Makefile +++ b/TestModels/dafny-dependencies/StandardLibrary/Makefile @@ -6,6 +6,7 @@ CORES=2 include ../../SharedMakefile.mk MAX_RESOURCE_COUNT=500000000 +PYTHON_MODULE_NAME=standard_library LIBRARIES := # define standard colors diff --git a/TestModels/dafny-dependencies/StandardLibrary/runtimes/python/pyproject.toml b/TestModels/dafny-dependencies/StandardLibrary/runtimes/python/pyproject.toml index 071dd4fd2..1fd4a6400 100644 --- a/TestModels/dafny-dependencies/StandardLibrary/runtimes/python/pyproject.toml +++ b/TestModels/dafny-dependencies/StandardLibrary/runtimes/python/pyproject.toml @@ -22,7 +22,3 @@ standard-library-test-internaldafny = { path = "test/internaldafny", develop = f [build-system] requires = ["poetry-core"] build-backend = "poetry.core.masonry.api" - -[aws.polymorph.config] -# The string below defines where Polymorph will move code. -polymorph_package_name = "standard_library" \ No newline at end of file diff --git a/codegen/smithy-dafny-codegen/src/main/java/software/amazon/polymorph/CodegenEngine.java b/codegen/smithy-dafny-codegen/src/main/java/software/amazon/polymorph/CodegenEngine.java index 3bf3e5e8b..c538f31c1 100644 --- a/codegen/smithy-dafny-codegen/src/main/java/software/amazon/polymorph/CodegenEngine.java +++ b/codegen/smithy-dafny-codegen/src/main/java/software/amazon/polymorph/CodegenEngine.java @@ -22,6 +22,8 @@ import software.amazon.polymorph.smithyjava.generator.awssdk.v2.JavaAwsSdkV2; import software.amazon.polymorph.smithyjava.generator.library.JavaLibrary; import software.amazon.polymorph.smithyjava.generator.library.TestJavaLibrary; +import software.amazon.polymorph.smithypython.Constants.GenerationType; +import software.amazon.polymorph.smithypython.extensions.DafnyPythonClientCodegenPlugin; import software.amazon.polymorph.utils.IOUtils; import software.amazon.polymorph.utils.ModelUtils; import software.amazon.smithy.aws.traits.ServiceTrait;