FIRST-Tech-Challenge / fmltc

FIRST Machine Learning Toolchain
Other
38 stars 14 forks source link

Put limits into constants.py #195

Closed lizlooney closed 2 years ago

lizlooney commented 2 years ago

This puts the limits in just one place. Before they were just hardcoded and many were hardcoded in multiple places (python and javascript code.)

Most of this code is from Uday.

github-actions[bot] commented 2 years ago

Terraform plan Succeeded for Workspace: default

Show Output ```diff An execution plan has been generated and is shown below. Resource actions are indicated with the following symbols: ! update in-place -/+ destroy and then create replacement Terraform will perform the following actions: # module.dev.google_app_engine_standard_app_version.fmltc-app-v1 will be updated in-place ! resource "google_app_engine_standard_app_version" "fmltc-app-v1" { id = "apps/ftc-ml-firstinspires-dev/services/default/versions/v1" name = "apps/ftc-ml-firstinspires-dev/services/default/versions/v1" # (9 unchanged attributes hidden) ! deployment { ! zip { ! source_url = "https://storage.googleapis.com/ftc-ml-firstinspires-dev-gae-source/6c7d8b5b7d8d682222783d33858c776a.zip" -> "https://storage.googleapis.com/ftc-ml-firstinspires-dev-gae-source/ce5c2f609b9a7fc735e8a8f0797ace09.zip" # (1 unchanged attribute hidden) } } - handlers { - auth_fail_action = "AUTH_FAIL_ACTION_REDIRECT" -> null - login = "LOGIN_OPTIONAL" -> null - security_level = "SECURE_OPTIONAL" -> null - url_regex = ".*" -> null - script { - script_path = "auto" -> null } } # (8 unchanged blocks hidden) } # module.dev.google_cloudfunctions_function.perform-action will be updated in-place ! resource "google_cloudfunctions_function" "perform-action" { id = "projects/ftc-ml-firstinspires-dev/locations/us-central1/functions/perform_action" name = "perform_action" ! source_archive_object = "24ad83cd83ddb756bd83a070ac191aaf.zip" -> "0e9f31142fbf9969a27904b9074784b1.zip" # (13 unchanged attributes hidden) # (2 unchanged blocks hidden) } # module.dev.google_storage_bucket_object.app-server-archive must be replaced -/+ resource "google_storage_bucket_object" "app-server-archive" { ! content_type = "application/zip" -> (known after apply) ! crc32c = "o+++QQ==" -> (known after apply) ! detect_md5hash = "bH2LW32NaCIieD0zhYx3ag==" -> "different hash" # forces replacement - event_based_hold = false -> null ! id = "ftc-ml-firstinspires-dev-gae-source-6c7d8b5b7d8d682222783d33858c776a.zip" -> (known after apply) + kms_key_name = (known after apply) ! md5hash = "bH2LW32NaCIieD0zhYx3ag==" -> (known after apply) ! media_link = "https://storage.googleapis.com/download/storage/v1/b/ftc-ml-firstinspires-dev-gae-source/o/6c7d8b5b7d8d682222783d33858c776a.zip?generation=1636481455353570&alt=media" -> (known after apply) - metadata = {} -> null ! name = "6c7d8b5b7d8d682222783d33858c776a.zip" -> "ce5c2f609b9a7fc735e8a8f0797ace09.zip" # forces replacement ! output_name = "6c7d8b5b7d8d682222783d33858c776a.zip" -> (known after apply) ! self_link = "https://www.googleapis.com/storage/v1/b/ftc-ml-firstinspires-dev-gae-source/o/6c7d8b5b7d8d682222783d33858c776a.zip" -> (known after apply) ! storage_class = "STANDARD" -> (known after apply) - temporary_hold = false -> null # (2 unchanged attributes hidden) } # module.dev.google_storage_bucket_object.closure_js must be replaced -/+ resource "google_storage_bucket_object" "closure_js" { ! crc32c = "nBzWTA==" -> (known after apply) ! detect_md5hash = "cooMT8u9ghWVqg73WfIhYw==" -> "different hash" # forces replacement - event_based_hold = false -> null ! id = "ftc-ml-firstinspires-dev-compiled/js/fmltc.js" -> (known after apply) + kms_key_name = (known after apply) ! md5hash = "cooMT8u9ghWVqg73WfIhYw==" -> (known after apply) ! media_link = "https://storage.googleapis.com/download/storage/v1/b/ftc-ml-firstinspires-dev/o/compiled%2Fjs%2Ffmltc.js?generation=1636415818343267&alt=media" -> (known after apply) - metadata = {} -> null name = "compiled/js/fmltc.js" ! output_name = "compiled/js/fmltc.js" -> (known after apply) ! self_link = "https://www.googleapis.com/storage/v1/b/ftc-ml-firstinspires-dev/o/compiled%2Fjs%2Ffmltc.js" -> (known after apply) ! storage_class = "STANDARD" -> (known after apply) - temporary_hold = false -> null # (3 unchanged attributes hidden) } # module.dev.google_storage_bucket_object.cloud-function-archive must be replaced -/+ resource "google_storage_bucket_object" "cloud-function-archive" { ! content_type = "application/zip" -> (known after apply) ! crc32c = "j8yL2Q==" -> (known after apply) ! detect_md5hash = "JK2DzYPdt1a9g6BwrBkarw==" -> "different hash" # forces replacement - event_based_hold = false -> null ! id = "ftc-ml-firstinspires-dev-gcf-source-24ad83cd83ddb756bd83a070ac191aaf.zip" -> (known after apply) + kms_key_name = (known after apply) ! md5hash = "JK2DzYPdt1a9g6BwrBkarw==" -> (known after apply) ! media_link = "https://storage.googleapis.com/download/storage/v1/b/ftc-ml-firstinspires-dev-gcf-source/o/24ad83cd83ddb756bd83a070ac191aaf.zip?generation=1636481455492732&alt=media" -> (known after apply) - metadata = {} -> null ! name = "24ad83cd83ddb756bd83a070ac191aaf.zip" -> "0e9f31142fbf9969a27904b9074784b1.zip" # forces replacement ! output_name = "24ad83cd83ddb756bd83a070ac191aaf.zip" -> (known after apply) ! self_link = "https://www.googleapis.com/storage/v1/b/ftc-ml-firstinspires-dev-gcf-source/o/24ad83cd83ddb756bd83a070ac191aaf.zip" -> (known after apply) ! storage_class = "STANDARD" -> (known after apply) - temporary_hold = false -> null # (2 unchanged attributes hidden) } Plan: 3 to add, 2 to change, 3 to destroy. ```