nextmv 1.0.0.dev2__tar.gz → 1.0.0.dev3__tar.gz

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (224) hide show
  1. {nextmv-1.0.0.dev2 → nextmv-1.0.0.dev3}/PKG-INFO +1 -1
  2. nextmv-1.0.0.dev3/nextmv/__about__.py +1 -0
  3. {nextmv-1.0.0.dev2 → nextmv-1.0.0.dev3}/nextmv/cli/cloud/__init__.py +2 -0
  4. {nextmv-1.0.0.dev2 → nextmv-1.0.0.dev3}/nextmv/cli/cloud/shadow/__init__.py +1 -1
  5. {nextmv-1.0.0.dev2 → nextmv-1.0.0.dev3}/nextmv/cli/cloud/shadow/create.py +2 -2
  6. {nextmv-1.0.0.dev2 → nextmv-1.0.0.dev3}/nextmv/cli/cloud/shadow/stop.py +5 -5
  7. {nextmv-1.0.0.dev2 → nextmv-1.0.0.dev3}/nextmv/cli/cloud/shadow/update.py +1 -0
  8. nextmv-1.0.0.dev3/nextmv/cli/cloud/switchback/__init__.py +33 -0
  9. nextmv-1.0.0.dev3/nextmv/cli/cloud/switchback/create.py +147 -0
  10. nextmv-1.0.0.dev3/nextmv/cli/cloud/switchback/delete.py +68 -0
  11. nextmv-1.0.0.dev3/nextmv/cli/cloud/switchback/get.py +62 -0
  12. nextmv-1.0.0.dev3/nextmv/cli/cloud/switchback/list.py +63 -0
  13. nextmv-1.0.0.dev3/nextmv/cli/cloud/switchback/metadata.py +68 -0
  14. nextmv-1.0.0.dev3/nextmv/cli/cloud/switchback/start.py +43 -0
  15. nextmv-1.0.0.dev3/nextmv/cli/cloud/switchback/stop.py +43 -0
  16. nextmv-1.0.0.dev3/nextmv/cli/cloud/switchback/update.py +96 -0
  17. {nextmv-1.0.0.dev2 → nextmv-1.0.0.dev3}/nextmv/cli/options.py +14 -0
  18. {nextmv-1.0.0.dev2 → nextmv-1.0.0.dev3}/nextmv/cloud/__init__.py +5 -0
  19. {nextmv-1.0.0.dev2 → nextmv-1.0.0.dev3}/nextmv/cloud/application/__init__.py +2 -0
  20. nextmv-1.0.0.dev3/nextmv/cloud/application/_switchback.py +315 -0
  21. nextmv-1.0.0.dev3/nextmv/cloud/switchback.py +189 -0
  22. nextmv-1.0.0.dev2/nextmv/__about__.py +0 -1
  23. {nextmv-1.0.0.dev2 → nextmv-1.0.0.dev3}/.gitignore +0 -0
  24. {nextmv-1.0.0.dev2 → nextmv-1.0.0.dev3}/LICENSE +0 -0
  25. {nextmv-1.0.0.dev2 → nextmv-1.0.0.dev3}/README.md +0 -0
  26. {nextmv-1.0.0.dev2 → nextmv-1.0.0.dev3}/nextmv/__entrypoint__.py +0 -0
  27. {nextmv-1.0.0.dev2 → nextmv-1.0.0.dev3}/nextmv/__init__.py +0 -0
  28. {nextmv-1.0.0.dev2 → nextmv-1.0.0.dev3}/nextmv/_serialization.py +0 -0
  29. {nextmv-1.0.0.dev2 → nextmv-1.0.0.dev3}/nextmv/base_model.py +0 -0
  30. {nextmv-1.0.0.dev2 → nextmv-1.0.0.dev3}/nextmv/cli/CONTRIBUTING.md +0 -0
  31. {nextmv-1.0.0.dev2 → nextmv-1.0.0.dev3}/nextmv/cli/__init__.py +0 -0
  32. {nextmv-1.0.0.dev2 → nextmv-1.0.0.dev3}/nextmv/cli/cloud/acceptance/__init__.py +0 -0
  33. {nextmv-1.0.0.dev2 → nextmv-1.0.0.dev3}/nextmv/cli/cloud/acceptance/create.py +0 -0
  34. {nextmv-1.0.0.dev2 → nextmv-1.0.0.dev3}/nextmv/cli/cloud/acceptance/delete.py +0 -0
  35. {nextmv-1.0.0.dev2 → nextmv-1.0.0.dev3}/nextmv/cli/cloud/acceptance/get.py +0 -0
  36. {nextmv-1.0.0.dev2 → nextmv-1.0.0.dev3}/nextmv/cli/cloud/acceptance/list.py +0 -0
  37. {nextmv-1.0.0.dev2 → nextmv-1.0.0.dev3}/nextmv/cli/cloud/acceptance/update.py +0 -0
  38. {nextmv-1.0.0.dev2 → nextmv-1.0.0.dev3}/nextmv/cli/cloud/account/__init__.py +0 -0
  39. {nextmv-1.0.0.dev2 → nextmv-1.0.0.dev3}/nextmv/cli/cloud/account/create.py +0 -0
  40. {nextmv-1.0.0.dev2 → nextmv-1.0.0.dev3}/nextmv/cli/cloud/account/delete.py +0 -0
  41. {nextmv-1.0.0.dev2 → nextmv-1.0.0.dev3}/nextmv/cli/cloud/account/get.py +0 -0
  42. {nextmv-1.0.0.dev2 → nextmv-1.0.0.dev3}/nextmv/cli/cloud/account/update.py +0 -0
  43. {nextmv-1.0.0.dev2 → nextmv-1.0.0.dev3}/nextmv/cli/cloud/app/__init__.py +0 -0
  44. {nextmv-1.0.0.dev2 → nextmv-1.0.0.dev3}/nextmv/cli/cloud/app/create.py +0 -0
  45. {nextmv-1.0.0.dev2 → nextmv-1.0.0.dev3}/nextmv/cli/cloud/app/delete.py +0 -0
  46. {nextmv-1.0.0.dev2 → nextmv-1.0.0.dev3}/nextmv/cli/cloud/app/exists.py +0 -0
  47. {nextmv-1.0.0.dev2 → nextmv-1.0.0.dev3}/nextmv/cli/cloud/app/get.py +0 -0
  48. {nextmv-1.0.0.dev2 → nextmv-1.0.0.dev3}/nextmv/cli/cloud/app/list.py +0 -0
  49. {nextmv-1.0.0.dev2 → nextmv-1.0.0.dev3}/nextmv/cli/cloud/app/push.py +0 -0
  50. {nextmv-1.0.0.dev2 → nextmv-1.0.0.dev3}/nextmv/cli/cloud/app/update.py +0 -0
  51. {nextmv-1.0.0.dev2 → nextmv-1.0.0.dev3}/nextmv/cli/cloud/batch/__init__.py +0 -0
  52. {nextmv-1.0.0.dev2 → nextmv-1.0.0.dev3}/nextmv/cli/cloud/batch/create.py +0 -0
  53. {nextmv-1.0.0.dev2 → nextmv-1.0.0.dev3}/nextmv/cli/cloud/batch/delete.py +0 -0
  54. {nextmv-1.0.0.dev2 → nextmv-1.0.0.dev3}/nextmv/cli/cloud/batch/get.py +0 -0
  55. {nextmv-1.0.0.dev2 → nextmv-1.0.0.dev3}/nextmv/cli/cloud/batch/list.py +0 -0
  56. {nextmv-1.0.0.dev2 → nextmv-1.0.0.dev3}/nextmv/cli/cloud/batch/metadata.py +0 -0
  57. {nextmv-1.0.0.dev2 → nextmv-1.0.0.dev3}/nextmv/cli/cloud/batch/update.py +0 -0
  58. {nextmv-1.0.0.dev2 → nextmv-1.0.0.dev3}/nextmv/cli/cloud/data/__init__.py +0 -0
  59. {nextmv-1.0.0.dev2 → nextmv-1.0.0.dev3}/nextmv/cli/cloud/data/upload.py +0 -0
  60. {nextmv-1.0.0.dev2 → nextmv-1.0.0.dev3}/nextmv/cli/cloud/ensemble/__init__.py +0 -0
  61. {nextmv-1.0.0.dev2 → nextmv-1.0.0.dev3}/nextmv/cli/cloud/ensemble/create.py +0 -0
  62. {nextmv-1.0.0.dev2 → nextmv-1.0.0.dev3}/nextmv/cli/cloud/ensemble/delete.py +0 -0
  63. {nextmv-1.0.0.dev2 → nextmv-1.0.0.dev3}/nextmv/cli/cloud/ensemble/get.py +0 -0
  64. {nextmv-1.0.0.dev2 → nextmv-1.0.0.dev3}/nextmv/cli/cloud/ensemble/update.py +0 -0
  65. {nextmv-1.0.0.dev2 → nextmv-1.0.0.dev3}/nextmv/cli/cloud/input_set/__init__.py +0 -0
  66. {nextmv-1.0.0.dev2 → nextmv-1.0.0.dev3}/nextmv/cli/cloud/input_set/create.py +0 -0
  67. {nextmv-1.0.0.dev2 → nextmv-1.0.0.dev3}/nextmv/cli/cloud/input_set/get.py +0 -0
  68. {nextmv-1.0.0.dev2 → nextmv-1.0.0.dev3}/nextmv/cli/cloud/input_set/list.py +0 -0
  69. {nextmv-1.0.0.dev2 → nextmv-1.0.0.dev3}/nextmv/cli/cloud/input_set/update.py +0 -0
  70. {nextmv-1.0.0.dev2 → nextmv-1.0.0.dev3}/nextmv/cli/cloud/instance/__init__.py +0 -0
  71. {nextmv-1.0.0.dev2 → nextmv-1.0.0.dev3}/nextmv/cli/cloud/instance/create.py +0 -0
  72. {nextmv-1.0.0.dev2 → nextmv-1.0.0.dev3}/nextmv/cli/cloud/instance/delete.py +0 -0
  73. {nextmv-1.0.0.dev2 → nextmv-1.0.0.dev3}/nextmv/cli/cloud/instance/exists.py +0 -0
  74. {nextmv-1.0.0.dev2 → nextmv-1.0.0.dev3}/nextmv/cli/cloud/instance/get.py +0 -0
  75. {nextmv-1.0.0.dev2 → nextmv-1.0.0.dev3}/nextmv/cli/cloud/instance/list.py +0 -0
  76. {nextmv-1.0.0.dev2 → nextmv-1.0.0.dev3}/nextmv/cli/cloud/instance/update.py +0 -0
  77. {nextmv-1.0.0.dev2 → nextmv-1.0.0.dev3}/nextmv/cli/cloud/managed_input/__init__.py +0 -0
  78. {nextmv-1.0.0.dev2 → nextmv-1.0.0.dev3}/nextmv/cli/cloud/managed_input/create.py +0 -0
  79. {nextmv-1.0.0.dev2 → nextmv-1.0.0.dev3}/nextmv/cli/cloud/managed_input/delete.py +0 -0
  80. {nextmv-1.0.0.dev2 → nextmv-1.0.0.dev3}/nextmv/cli/cloud/managed_input/get.py +0 -0
  81. {nextmv-1.0.0.dev2 → nextmv-1.0.0.dev3}/nextmv/cli/cloud/managed_input/list.py +0 -0
  82. {nextmv-1.0.0.dev2 → nextmv-1.0.0.dev3}/nextmv/cli/cloud/managed_input/update.py +0 -0
  83. {nextmv-1.0.0.dev2 → nextmv-1.0.0.dev3}/nextmv/cli/cloud/run/__init__.py +0 -0
  84. {nextmv-1.0.0.dev2 → nextmv-1.0.0.dev3}/nextmv/cli/cloud/run/cancel.py +0 -0
  85. {nextmv-1.0.0.dev2 → nextmv-1.0.0.dev3}/nextmv/cli/cloud/run/create.py +0 -0
  86. {nextmv-1.0.0.dev2 → nextmv-1.0.0.dev3}/nextmv/cli/cloud/run/get.py +0 -0
  87. {nextmv-1.0.0.dev2 → nextmv-1.0.0.dev3}/nextmv/cli/cloud/run/input.py +0 -0
  88. {nextmv-1.0.0.dev2 → nextmv-1.0.0.dev3}/nextmv/cli/cloud/run/list.py +0 -0
  89. {nextmv-1.0.0.dev2 → nextmv-1.0.0.dev3}/nextmv/cli/cloud/run/logs.py +0 -0
  90. {nextmv-1.0.0.dev2 → nextmv-1.0.0.dev3}/nextmv/cli/cloud/run/metadata.py +0 -0
  91. {nextmv-1.0.0.dev2 → nextmv-1.0.0.dev3}/nextmv/cli/cloud/run/track.py +0 -0
  92. {nextmv-1.0.0.dev2 → nextmv-1.0.0.dev3}/nextmv/cli/cloud/scenario/__init__.py +0 -0
  93. {nextmv-1.0.0.dev2 → nextmv-1.0.0.dev3}/nextmv/cli/cloud/scenario/create.py +0 -0
  94. {nextmv-1.0.0.dev2 → nextmv-1.0.0.dev3}/nextmv/cli/cloud/scenario/delete.py +0 -0
  95. {nextmv-1.0.0.dev2 → nextmv-1.0.0.dev3}/nextmv/cli/cloud/scenario/get.py +0 -0
  96. {nextmv-1.0.0.dev2 → nextmv-1.0.0.dev3}/nextmv/cli/cloud/scenario/list.py +0 -0
  97. {nextmv-1.0.0.dev2 → nextmv-1.0.0.dev3}/nextmv/cli/cloud/scenario/metadata.py +0 -0
  98. {nextmv-1.0.0.dev2 → nextmv-1.0.0.dev3}/nextmv/cli/cloud/scenario/update.py +0 -0
  99. {nextmv-1.0.0.dev2 → nextmv-1.0.0.dev3}/nextmv/cli/cloud/secrets/__init__.py +0 -0
  100. {nextmv-1.0.0.dev2 → nextmv-1.0.0.dev3}/nextmv/cli/cloud/secrets/create.py +0 -0
  101. {nextmv-1.0.0.dev2 → nextmv-1.0.0.dev3}/nextmv/cli/cloud/secrets/delete.py +0 -0
  102. {nextmv-1.0.0.dev2 → nextmv-1.0.0.dev3}/nextmv/cli/cloud/secrets/get.py +0 -0
  103. {nextmv-1.0.0.dev2 → nextmv-1.0.0.dev3}/nextmv/cli/cloud/secrets/list.py +0 -0
  104. {nextmv-1.0.0.dev2 → nextmv-1.0.0.dev3}/nextmv/cli/cloud/secrets/update.py +0 -0
  105. {nextmv-1.0.0.dev2 → nextmv-1.0.0.dev3}/nextmv/cli/cloud/shadow/delete.py +0 -0
  106. {nextmv-1.0.0.dev2 → nextmv-1.0.0.dev3}/nextmv/cli/cloud/shadow/get.py +0 -0
  107. {nextmv-1.0.0.dev2 → nextmv-1.0.0.dev3}/nextmv/cli/cloud/shadow/list.py +0 -0
  108. {nextmv-1.0.0.dev2 → nextmv-1.0.0.dev3}/nextmv/cli/cloud/shadow/metadata.py +0 -0
  109. {nextmv-1.0.0.dev2 → nextmv-1.0.0.dev3}/nextmv/cli/cloud/shadow/start.py +0 -0
  110. {nextmv-1.0.0.dev2 → nextmv-1.0.0.dev3}/nextmv/cli/cloud/upload/__init__.py +0 -0
  111. {nextmv-1.0.0.dev2 → nextmv-1.0.0.dev3}/nextmv/cli/cloud/upload/create.py +0 -0
  112. {nextmv-1.0.0.dev2 → nextmv-1.0.0.dev3}/nextmv/cli/cloud/version/__init__.py +0 -0
  113. {nextmv-1.0.0.dev2 → nextmv-1.0.0.dev3}/nextmv/cli/cloud/version/create.py +0 -0
  114. {nextmv-1.0.0.dev2 → nextmv-1.0.0.dev3}/nextmv/cli/cloud/version/delete.py +0 -0
  115. {nextmv-1.0.0.dev2 → nextmv-1.0.0.dev3}/nextmv/cli/cloud/version/exists.py +0 -0
  116. {nextmv-1.0.0.dev2 → nextmv-1.0.0.dev3}/nextmv/cli/cloud/version/get.py +0 -0
  117. {nextmv-1.0.0.dev2 → nextmv-1.0.0.dev3}/nextmv/cli/cloud/version/list.py +0 -0
  118. {nextmv-1.0.0.dev2 → nextmv-1.0.0.dev3}/nextmv/cli/cloud/version/update.py +0 -0
  119. {nextmv-1.0.0.dev2 → nextmv-1.0.0.dev3}/nextmv/cli/community/__init__.py +0 -0
  120. {nextmv-1.0.0.dev2 → nextmv-1.0.0.dev3}/nextmv/cli/community/clone.py +0 -0
  121. {nextmv-1.0.0.dev2 → nextmv-1.0.0.dev3}/nextmv/cli/community/list.py +0 -0
  122. {nextmv-1.0.0.dev2 → nextmv-1.0.0.dev3}/nextmv/cli/configuration/__init__.py +0 -0
  123. {nextmv-1.0.0.dev2 → nextmv-1.0.0.dev3}/nextmv/cli/configuration/config.py +0 -0
  124. {nextmv-1.0.0.dev2 → nextmv-1.0.0.dev3}/nextmv/cli/configuration/create.py +0 -0
  125. {nextmv-1.0.0.dev2 → nextmv-1.0.0.dev3}/nextmv/cli/configuration/delete.py +0 -0
  126. {nextmv-1.0.0.dev2 → nextmv-1.0.0.dev3}/nextmv/cli/configuration/list.py +0 -0
  127. {nextmv-1.0.0.dev2 → nextmv-1.0.0.dev3}/nextmv/cli/main.py +0 -0
  128. {nextmv-1.0.0.dev2 → nextmv-1.0.0.dev3}/nextmv/cli/message.py +0 -0
  129. {nextmv-1.0.0.dev2 → nextmv-1.0.0.dev3}/nextmv/cli/version.py +0 -0
  130. {nextmv-1.0.0.dev2 → nextmv-1.0.0.dev3}/nextmv/cloud/acceptance_test.py +0 -0
  131. {nextmv-1.0.0.dev2 → nextmv-1.0.0.dev3}/nextmv/cloud/account.py +0 -0
  132. {nextmv-1.0.0.dev2 → nextmv-1.0.0.dev3}/nextmv/cloud/application/_acceptance.py +0 -0
  133. {nextmv-1.0.0.dev2 → nextmv-1.0.0.dev3}/nextmv/cloud/application/_batch_scenario.py +0 -0
  134. {nextmv-1.0.0.dev2 → nextmv-1.0.0.dev3}/nextmv/cloud/application/_ensemble.py +0 -0
  135. {nextmv-1.0.0.dev2 → nextmv-1.0.0.dev3}/nextmv/cloud/application/_input_set.py +0 -0
  136. {nextmv-1.0.0.dev2 → nextmv-1.0.0.dev3}/nextmv/cloud/application/_instance.py +0 -0
  137. {nextmv-1.0.0.dev2 → nextmv-1.0.0.dev3}/nextmv/cloud/application/_managed_input.py +0 -0
  138. {nextmv-1.0.0.dev2 → nextmv-1.0.0.dev3}/nextmv/cloud/application/_run.py +0 -0
  139. {nextmv-1.0.0.dev2 → nextmv-1.0.0.dev3}/nextmv/cloud/application/_secrets.py +0 -0
  140. {nextmv-1.0.0.dev2 → nextmv-1.0.0.dev3}/nextmv/cloud/application/_shadow.py +0 -0
  141. {nextmv-1.0.0.dev2 → nextmv-1.0.0.dev3}/nextmv/cloud/application/_utils.py +0 -0
  142. {nextmv-1.0.0.dev2 → nextmv-1.0.0.dev3}/nextmv/cloud/application/_version.py +0 -0
  143. {nextmv-1.0.0.dev2 → nextmv-1.0.0.dev3}/nextmv/cloud/assets.py +0 -0
  144. {nextmv-1.0.0.dev2 → nextmv-1.0.0.dev3}/nextmv/cloud/batch_experiment.py +0 -0
  145. {nextmv-1.0.0.dev2 → nextmv-1.0.0.dev3}/nextmv/cloud/client.py +0 -0
  146. {nextmv-1.0.0.dev2 → nextmv-1.0.0.dev3}/nextmv/cloud/ensemble.py +0 -0
  147. {nextmv-1.0.0.dev2 → nextmv-1.0.0.dev3}/nextmv/cloud/input_set.py +0 -0
  148. {nextmv-1.0.0.dev2 → nextmv-1.0.0.dev3}/nextmv/cloud/instance.py +0 -0
  149. {nextmv-1.0.0.dev2 → nextmv-1.0.0.dev3}/nextmv/cloud/integration.py +0 -0
  150. {nextmv-1.0.0.dev2 → nextmv-1.0.0.dev3}/nextmv/cloud/package.py +0 -0
  151. {nextmv-1.0.0.dev2 → nextmv-1.0.0.dev3}/nextmv/cloud/scenario.py +0 -0
  152. {nextmv-1.0.0.dev2 → nextmv-1.0.0.dev3}/nextmv/cloud/secrets.py +0 -0
  153. {nextmv-1.0.0.dev2 → nextmv-1.0.0.dev3}/nextmv/cloud/shadow.py +0 -0
  154. {nextmv-1.0.0.dev2 → nextmv-1.0.0.dev3}/nextmv/cloud/url.py +0 -0
  155. {nextmv-1.0.0.dev2 → nextmv-1.0.0.dev3}/nextmv/cloud/version.py +0 -0
  156. {nextmv-1.0.0.dev2 → nextmv-1.0.0.dev3}/nextmv/default_app/.gitignore +0 -0
  157. {nextmv-1.0.0.dev2 → nextmv-1.0.0.dev3}/nextmv/default_app/README.md +0 -0
  158. {nextmv-1.0.0.dev2 → nextmv-1.0.0.dev3}/nextmv/default_app/app.yaml +0 -0
  159. {nextmv-1.0.0.dev2 → nextmv-1.0.0.dev3}/nextmv/default_app/input.json +0 -0
  160. {nextmv-1.0.0.dev2 → nextmv-1.0.0.dev3}/nextmv/default_app/main.py +0 -0
  161. {nextmv-1.0.0.dev2 → nextmv-1.0.0.dev3}/nextmv/default_app/requirements.txt +0 -0
  162. {nextmv-1.0.0.dev2 → nextmv-1.0.0.dev3}/nextmv/default_app/src/__init__.py +0 -0
  163. {nextmv-1.0.0.dev2 → nextmv-1.0.0.dev3}/nextmv/default_app/src/visuals.py +0 -0
  164. {nextmv-1.0.0.dev2 → nextmv-1.0.0.dev3}/nextmv/deprecated.py +0 -0
  165. {nextmv-1.0.0.dev2 → nextmv-1.0.0.dev3}/nextmv/input.py +0 -0
  166. {nextmv-1.0.0.dev2 → nextmv-1.0.0.dev3}/nextmv/local/__init__.py +0 -0
  167. {nextmv-1.0.0.dev2 → nextmv-1.0.0.dev3}/nextmv/local/application.py +0 -0
  168. {nextmv-1.0.0.dev2 → nextmv-1.0.0.dev3}/nextmv/local/executor.py +0 -0
  169. {nextmv-1.0.0.dev2 → nextmv-1.0.0.dev3}/nextmv/local/geojson_handler.py +0 -0
  170. {nextmv-1.0.0.dev2 → nextmv-1.0.0.dev3}/nextmv/local/local.py +0 -0
  171. {nextmv-1.0.0.dev2 → nextmv-1.0.0.dev3}/nextmv/local/plotly_handler.py +0 -0
  172. {nextmv-1.0.0.dev2 → nextmv-1.0.0.dev3}/nextmv/local/runner.py +0 -0
  173. {nextmv-1.0.0.dev2 → nextmv-1.0.0.dev3}/nextmv/logger.py +0 -0
  174. {nextmv-1.0.0.dev2 → nextmv-1.0.0.dev3}/nextmv/manifest.py +0 -0
  175. {nextmv-1.0.0.dev2 → nextmv-1.0.0.dev3}/nextmv/model.py +0 -0
  176. {nextmv-1.0.0.dev2 → nextmv-1.0.0.dev3}/nextmv/options.py +0 -0
  177. {nextmv-1.0.0.dev2 → nextmv-1.0.0.dev3}/nextmv/output.py +0 -0
  178. {nextmv-1.0.0.dev2 → nextmv-1.0.0.dev3}/nextmv/polling.py +0 -0
  179. {nextmv-1.0.0.dev2 → nextmv-1.0.0.dev3}/nextmv/run.py +0 -0
  180. {nextmv-1.0.0.dev2 → nextmv-1.0.0.dev3}/nextmv/safe.py +0 -0
  181. {nextmv-1.0.0.dev2 → nextmv-1.0.0.dev3}/nextmv/status.py +0 -0
  182. {nextmv-1.0.0.dev2 → nextmv-1.0.0.dev3}/pyproject.toml +0 -0
  183. {nextmv-1.0.0.dev2 → nextmv-1.0.0.dev3}/tests/__init__.py +0 -0
  184. {nextmv-1.0.0.dev2 → nextmv-1.0.0.dev3}/tests/cli/__init__.py +0 -0
  185. {nextmv-1.0.0.dev2 → nextmv-1.0.0.dev3}/tests/cli/test_community.py +0 -0
  186. {nextmv-1.0.0.dev2 → nextmv-1.0.0.dev3}/tests/cli/test_configuration.py +0 -0
  187. {nextmv-1.0.0.dev2 → nextmv-1.0.0.dev3}/tests/cli/test_main.py +0 -0
  188. {nextmv-1.0.0.dev2 → nextmv-1.0.0.dev3}/tests/cli/test_version.py +0 -0
  189. {nextmv-1.0.0.dev2 → nextmv-1.0.0.dev3}/tests/cloud/__init__.py +0 -0
  190. {nextmv-1.0.0.dev2 → nextmv-1.0.0.dev3}/tests/cloud/app.yaml +0 -0
  191. {nextmv-1.0.0.dev2 → nextmv-1.0.0.dev3}/tests/cloud/test_client.py +0 -0
  192. {nextmv-1.0.0.dev2 → nextmv-1.0.0.dev3}/tests/cloud/test_instance.py +0 -0
  193. {nextmv-1.0.0.dev2 → nextmv-1.0.0.dev3}/tests/cloud/test_package.py +0 -0
  194. {nextmv-1.0.0.dev2 → nextmv-1.0.0.dev3}/tests/cloud/test_scenario.py +0 -0
  195. {nextmv-1.0.0.dev2 → nextmv-1.0.0.dev3}/tests/local/__init__.py +0 -0
  196. {nextmv-1.0.0.dev2 → nextmv-1.0.0.dev3}/tests/local/test_application.py +0 -0
  197. {nextmv-1.0.0.dev2 → nextmv-1.0.0.dev3}/tests/local/test_executor.py +0 -0
  198. {nextmv-1.0.0.dev2 → nextmv-1.0.0.dev3}/tests/local/test_runner.py +0 -0
  199. {nextmv-1.0.0.dev2 → nextmv-1.0.0.dev3}/tests/scripts/__init__.py +0 -0
  200. {nextmv-1.0.0.dev2 → nextmv-1.0.0.dev3}/tests/scripts/options1.py +0 -0
  201. {nextmv-1.0.0.dev2 → nextmv-1.0.0.dev3}/tests/scripts/options2.py +0 -0
  202. {nextmv-1.0.0.dev2 → nextmv-1.0.0.dev3}/tests/scripts/options3.py +0 -0
  203. {nextmv-1.0.0.dev2 → nextmv-1.0.0.dev3}/tests/scripts/options4.py +0 -0
  204. {nextmv-1.0.0.dev2 → nextmv-1.0.0.dev3}/tests/scripts/options5.py +0 -0
  205. {nextmv-1.0.0.dev2 → nextmv-1.0.0.dev3}/tests/scripts/options6.py +0 -0
  206. {nextmv-1.0.0.dev2 → nextmv-1.0.0.dev3}/tests/scripts/options7.py +0 -0
  207. {nextmv-1.0.0.dev2 → nextmv-1.0.0.dev3}/tests/scripts/options_deprecated.py +0 -0
  208. {nextmv-1.0.0.dev2 → nextmv-1.0.0.dev3}/tests/test_base_model.py +0 -0
  209. {nextmv-1.0.0.dev2 → nextmv-1.0.0.dev3}/tests/test_entrypoint/__init__.py +0 -0
  210. {nextmv-1.0.0.dev2 → nextmv-1.0.0.dev3}/tests/test_entrypoint/test_entrypoint.py +0 -0
  211. {nextmv-1.0.0.dev2 → nextmv-1.0.0.dev3}/tests/test_input.py +0 -0
  212. {nextmv-1.0.0.dev2 → nextmv-1.0.0.dev3}/tests/test_inputs/test_data.csv +0 -0
  213. {nextmv-1.0.0.dev2 → nextmv-1.0.0.dev3}/tests/test_inputs/test_data.json +0 -0
  214. {nextmv-1.0.0.dev2 → nextmv-1.0.0.dev3}/tests/test_inputs/test_data.txt +0 -0
  215. {nextmv-1.0.0.dev2 → nextmv-1.0.0.dev3}/tests/test_logger.py +0 -0
  216. {nextmv-1.0.0.dev2 → nextmv-1.0.0.dev3}/tests/test_manifest.py +0 -0
  217. {nextmv-1.0.0.dev2 → nextmv-1.0.0.dev3}/tests/test_model.py +0 -0
  218. {nextmv-1.0.0.dev2 → nextmv-1.0.0.dev3}/tests/test_options.py +0 -0
  219. {nextmv-1.0.0.dev2 → nextmv-1.0.0.dev3}/tests/test_output.py +0 -0
  220. {nextmv-1.0.0.dev2 → nextmv-1.0.0.dev3}/tests/test_polling.py +0 -0
  221. {nextmv-1.0.0.dev2 → nextmv-1.0.0.dev3}/tests/test_run.py +0 -0
  222. {nextmv-1.0.0.dev2 → nextmv-1.0.0.dev3}/tests/test_safe.py +0 -0
  223. {nextmv-1.0.0.dev2 → nextmv-1.0.0.dev3}/tests/test_serialization.py +0 -0
  224. {nextmv-1.0.0.dev2 → nextmv-1.0.0.dev3}/tests/test_version.py +0 -0
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: nextmv
3
- Version: 1.0.0.dev2
3
+ Version: 1.0.0.dev3
4
4
  Summary: The all-purpose Python SDK for Nextmv
5
5
  Project-URL: Homepage, https://www.nextmv.io
6
6
  Project-URL: Documentation, https://nextmv-py.docs.nextmv.io/en/latest/nextmv/
@@ -0,0 +1 @@
1
+ __version__ = "v1.0.0.dev3"
@@ -17,6 +17,7 @@ from nextmv.cli.cloud.run import app as run_app
17
17
  from nextmv.cli.cloud.scenario import app as scenario_app
18
18
  from nextmv.cli.cloud.secrets import app as secrets_app
19
19
  from nextmv.cli.cloud.shadow import app as shadow_app
20
+ from nextmv.cli.cloud.switchback import app as switchback_app
20
21
  from nextmv.cli.cloud.upload import app as upload_app
21
22
  from nextmv.cli.cloud.version import app as version_app
22
23
 
@@ -35,6 +36,7 @@ app.add_typer(run_app, name="run")
35
36
  app.add_typer(scenario_app, name="scenario")
36
37
  app.add_typer(secrets_app, name="secrets")
37
38
  app.add_typer(shadow_app, name="shadow")
39
+ app.add_typer(switchback_app, name="switchback")
38
40
  app.add_typer(upload_app, name="upload")
39
41
  app.add_typer(version_app, name="version")
40
42
 
@@ -1,5 +1,5 @@
1
1
  """
2
- This module defines the cloud batch command tree for the Nextmv CLI.
2
+ This module defines the cloud shadow command tree for the Nextmv CLI.
3
3
  """
4
4
 
5
5
  import typer
@@ -115,7 +115,7 @@ def create(
115
115
  control over when the shadow test should terminate, after said number of
116
116
  runs. Alternatively, you may specify the [code]--termination-time[/code]
117
117
  option or use the [code]nextmv cloud shadow stop[/code] command to stop the
118
- test
118
+ test.
119
119
 
120
120
  [bold][underline]Examples[/underline][/bold]
121
121
 
@@ -168,7 +168,7 @@ def create(
168
168
  except json.JSONDecodeError as e:
169
169
  error(f"Invalid comparisons format: [magenta]{comparisons}[/magenta]. Error: {e}")
170
170
 
171
- in_progress(msg="Creating shadow test...")
171
+ in_progress(msg="Creating shadow test in draft mode...")
172
172
  shadow_test = cloud_app.new_shadow_test(
173
173
  comparisons=comparisons_dict,
174
174
  termination_events=TerminationEvents(
@@ -29,15 +29,15 @@ def stop(
29
29
 
30
30
  [bold][underline]Examples[/underline][/bold]
31
31
 
32
- - Start the shadow test with the ID [magenta]hop-analysis[/magenta] from application
32
+ - Stop the shadow test with the ID [magenta]hop-analysis[/magenta] from application
33
33
  [magenta]hare-app[/magenta].
34
- $ [green]nextmv cloud shadow start --app-id hare-app --shadow-test-id hop-analysis[/green]
34
+ $ [green]nextmv cloud shadow stop --app-id hare-app --shadow-test-id hop-analysis[/green]
35
35
  """
36
36
 
37
- in_progress(msg="Starting shadow test...")
37
+ in_progress(msg="Stopping shadow test...")
38
38
  cloud_app = build_app(app_id=app_id, profile=profile)
39
- cloud_app.start_shadow_test(shadow_test_id=shadow_test_id)
39
+ cloud_app.stop_shadow_test(shadow_test_id=shadow_test_id)
40
40
  success(
41
- f"Shadow test [magenta]{shadow_test_id}[/magenta] started successfully "
41
+ f"Shadow test [magenta]{shadow_test_id}[/magenta] stopped successfully "
42
42
  f"in application [magenta]{app_id}[/magenta]."
43
43
  )
@@ -90,6 +90,7 @@ def update(
90
90
  json.dump(shadow_test_dict, f, indent=2)
91
91
 
92
92
  success(msg=f"Updated shadow test information saved to [magenta]{output}[/magenta].")
93
+
93
94
  return
94
95
 
95
96
  print_json(shadow_test_dict)
@@ -0,0 +1,33 @@
1
+ """
2
+ This module defines the cloud switchback command tree for the Nextmv CLI.
3
+ """
4
+
5
+ import typer
6
+
7
+ from nextmv.cli.cloud.switchback.create import app as create_app
8
+ from nextmv.cli.cloud.switchback.delete import app as delete_app
9
+ from nextmv.cli.cloud.switchback.get import app as get_app
10
+ from nextmv.cli.cloud.switchback.list import app as list_app
11
+ from nextmv.cli.cloud.switchback.metadata import app as metadata_app
12
+ from nextmv.cli.cloud.switchback.start import app as start_app
13
+ from nextmv.cli.cloud.switchback.stop import app as stop_app
14
+ from nextmv.cli.cloud.switchback.update import app as update_app
15
+
16
+ # Set up subcommand application.
17
+ app = typer.Typer()
18
+ app.add_typer(create_app)
19
+ app.add_typer(delete_app)
20
+ app.add_typer(get_app)
21
+ app.add_typer(list_app)
22
+ app.add_typer(metadata_app)
23
+ app.add_typer(start_app)
24
+ app.add_typer(stop_app)
25
+ app.add_typer(update_app)
26
+
27
+
28
+ @app.callback()
29
+ def callback() -> None:
30
+ """
31
+ Create and manage Nextmv Cloud switchback tests.
32
+ """
33
+ pass
@@ -0,0 +1,147 @@
1
+ """
2
+ This module defines the cloud switchback create command for the Nextmv CLI.
3
+ """
4
+
5
+ from datetime import datetime
6
+ from typing import Annotated
7
+
8
+ import typer
9
+
10
+ from nextmv.cli.configuration.config import build_app
11
+ from nextmv.cli.message import in_progress, print_json
12
+ from nextmv.cli.options import AppIDOption, ProfileOption
13
+ from nextmv.cloud.switchback import TestComparisonSingle
14
+
15
+ # Set up subcommand application.
16
+ app = typer.Typer()
17
+
18
+
19
+ @app.command()
20
+ def create(
21
+ app_id: AppIDOption,
22
+ baseline_instance_id: Annotated[
23
+ str,
24
+ typer.Option(
25
+ "--baseline-instance-id",
26
+ "-b",
27
+ help="ID of the baseline instance for the switchback test.",
28
+ metavar="BASELINE_INSTANCE_ID",
29
+ ),
30
+ ],
31
+ candidate_instance_id: Annotated[
32
+ str,
33
+ typer.Option(
34
+ "--candidate-instance-id",
35
+ "-c",
36
+ help="ID of the candidate instance for the switchback test.",
37
+ metavar="CANDIDATE_INSTANCE_ID",
38
+ ),
39
+ ],
40
+ unit_duration_minutes: Annotated[
41
+ float,
42
+ typer.Option(
43
+ "--unit-duration-minutes",
44
+ "-u",
45
+ help="Duration of each interval in minutes.",
46
+ metavar="UNIT_DURATION_MINUTES",
47
+ ),
48
+ ],
49
+ units: Annotated[
50
+ int,
51
+ typer.Option(
52
+ "--units",
53
+ "-t",
54
+ help="Total number of intervals in the switchback test.",
55
+ metavar="UNITS",
56
+ ),
57
+ ],
58
+ description: Annotated[
59
+ str | None,
60
+ typer.Option(
61
+ "--description",
62
+ "-d",
63
+ help="Description of the switchback test.",
64
+ metavar="DESCRIPTION",
65
+ ),
66
+ ] = None,
67
+ name: Annotated[
68
+ str | None,
69
+ typer.Option(
70
+ "--name",
71
+ "-n",
72
+ help="Name of the switchback test. If not provided, the ID will be used as the name.",
73
+ metavar="NAME",
74
+ ),
75
+ ] = None,
76
+ switchback_test_id: Annotated[
77
+ str | None,
78
+ typer.Option(
79
+ "--switchback-test-id",
80
+ "-s",
81
+ help="ID for the switchback test. Will be generated if not provided.",
82
+ envvar="NEXTMV_SWITCHBACK_TEST_ID",
83
+ metavar="SWITCHBACK_TEST_ID",
84
+ ),
85
+ ] = None,
86
+ start: Annotated[
87
+ datetime | None,
88
+ typer.Option(
89
+ "--start",
90
+ "-r",
91
+ formats=["%Y-%m-%dT%H:%M:%S%z"],
92
+ help="Scheduled time for switchback test start in [magenta]RFC 3339[/magenta] format. "
93
+ "Example: [magenta]'2024-01-01T00:00:00Z'[/magenta]",
94
+ metavar="START",
95
+ ),
96
+ ] = None,
97
+ profile: ProfileOption = None,
98
+ ) -> None:
99
+ """
100
+ Create a new Nextmv Cloud switchback test in draft mode.
101
+
102
+ The test will alternate between the [code]--baseline-instance-id[/code] and
103
+ [code]--candidate-instance-id[/code] over specified time intervals.
104
+
105
+ You may specify the [code]--start[/code] option to make the switchback
106
+ test start at a specific time. Alternatively, you may use the
107
+ [code]nextmv cloud switchback start[/code] command to start the test.
108
+
109
+ Use the [code]nextmv cloud switchback stop[/code] command to stop the test.
110
+
111
+ [bold][underline]Examples[/underline][/bold]
112
+
113
+ - Create a switchback test alternating between two bunny instances:
114
+ $ [green]nextmv cloud switchback create --app-id hare-app --switchback-test-id bunny-switch-hop \\
115
+ --name "Bunny Switch Hop" --baseline-instance-id fluffy-bunny-baseline \\
116
+ --candidate-instance-id speedy-cottontail --unit-duration-minutes 15 --units 10[/green]
117
+
118
+ - Create a switchback test with a scheduled start time:
119
+ $ [green]nextmv cloud switchback create --app-id hare-app --switchback-test-id sunrise-switch \\
120
+ --name "Sunrise Switch Test" --baseline-instance-id wise-old-rabbit \\
121
+ --candidate-instance-id burrow-master --unit-duration-minutes 30 --units 8 \\
122
+ --start '2026-01-23T10:00:00Z'[/green]
123
+
124
+ - Create a switchback test with a description:
125
+ $ [green]nextmv cloud switchback create --app-id hare-app --switchback-test-id carrot-switch \\
126
+ --name "Carrot Switch" --baseline-instance-id fluffy-bunny-baseline \\
127
+ --candidate-instance-id hopping-candidate-ears --unit-duration-minutes 20 --units 12 \\
128
+ --description "Which bunny hops best for carrots?"[/green]
129
+ """
130
+
131
+ cloud_app = build_app(app_id=app_id, profile=profile)
132
+
133
+ in_progress(msg="Creating switchback test in draft mode...")
134
+ switchback_test = cloud_app.new_switchback_test(
135
+ comparison=TestComparisonSingle(
136
+ baseline_instance_id=baseline_instance_id,
137
+ candidate_instance_id=candidate_instance_id,
138
+ ),
139
+ unit_duration_minutes=unit_duration_minutes,
140
+ units=units,
141
+ switchback_test_id=switchback_test_id,
142
+ name=name,
143
+ description=description,
144
+ start=start,
145
+ )
146
+
147
+ print_json(switchback_test.to_dict())
@@ -0,0 +1,68 @@
1
+ """
2
+ This module defines the cloud switchback delete command for the Nextmv CLI.
3
+ """
4
+
5
+ from typing import Annotated
6
+
7
+ import typer
8
+ from rich.prompt import Confirm
9
+
10
+ from nextmv.cli.configuration.config import build_app
11
+ from nextmv.cli.message import info, success
12
+ from nextmv.cli.options import AppIDOption, ProfileOption, SwitchbackTestIDOption
13
+
14
+ # Set up subcommand application.
15
+ app = typer.Typer()
16
+
17
+
18
+ @app.command()
19
+ def delete(
20
+ app_id: AppIDOption,
21
+ switchback_test_id: SwitchbackTestIDOption,
22
+ yes: Annotated[
23
+ bool,
24
+ typer.Option(
25
+ "--yes",
26
+ "-y",
27
+ help="Agree to deletion confirmation prompt. Useful for non-interactive sessions.",
28
+ ),
29
+ ] = False,
30
+ profile: ProfileOption = None,
31
+ ) -> None:
32
+ """
33
+ Deletes a Nextmv Cloud switchback test.
34
+
35
+ This action is permanent and cannot be undone. The switchback test and all
36
+ associated data, including runs, will be deleted. Use the [code]--yes[/code]
37
+ flag to skip the confirmation prompt.
38
+
39
+ [bold][underline]Examples[/underline][/bold]
40
+
41
+ - Delete the switchback test with the ID [magenta]hop-analysis[/magenta] from application
42
+ [magenta]hare-app[/magenta].
43
+ $ [green]nextmv cloud switchback delete --app-id hare-app --switchback-test-id hop-analysis[/green]
44
+
45
+ - Delete the switchback test without confirmation prompt.
46
+ $ [green]nextmv cloud switchback delete --app-id hare-app --switchback-test-id carrot-routes --yes[/green]
47
+ """
48
+
49
+ if not yes:
50
+ confirm = Confirm.ask(
51
+ f"Are you sure you want to delete switchback test [magenta]{switchback_test_id}[/magenta] "
52
+ f"from application [magenta]{app_id}[/magenta]? This action cannot be undone.",
53
+ default=False,
54
+ )
55
+
56
+ if not confirm:
57
+ info(
58
+ msg=f"Switchback test [magenta]{switchback_test_id}[/magenta] will not be deleted.",
59
+ emoji=":bulb:",
60
+ )
61
+ return
62
+
63
+ cloud_app = build_app(app_id=app_id, profile=profile)
64
+ cloud_app.delete_switchback_test(switchback_test_id=switchback_test_id)
65
+ success(
66
+ f"Switchback test [magenta]{switchback_test_id}[/magenta] deleted successfully "
67
+ f"from application [magenta]{app_id}[/magenta]."
68
+ )
@@ -0,0 +1,62 @@
1
+ """
2
+ This module defines the cloud switchback get command for the Nextmv CLI.
3
+ """
4
+
5
+ import json
6
+ from typing import Annotated
7
+
8
+ import typer
9
+
10
+ from nextmv.cli.configuration.config import build_app
11
+ from nextmv.cli.message import in_progress, print_json, success
12
+ from nextmv.cli.options import AppIDOption, ProfileOption, SwitchbackTestIDOption
13
+
14
+ # Set up subcommand application.
15
+ app = typer.Typer()
16
+
17
+
18
+ @app.command()
19
+ def get(
20
+ app_id: AppIDOption,
21
+ switchback_test_id: SwitchbackTestIDOption,
22
+ output: Annotated[
23
+ str | None,
24
+ typer.Option(
25
+ "--output",
26
+ "-o",
27
+ help="Saves the results to this location.",
28
+ metavar="OUTPUT_PATH",
29
+ ),
30
+ ] = None,
31
+ profile: ProfileOption = None,
32
+ ) -> None:
33
+ """
34
+ Get a Nextmv Cloud switchback test, including its runs.
35
+
36
+ [bold][underline]Examples[/underline][/bold]
37
+
38
+ - Get the switchback test with ID [magenta]carrot-optimization[/magenta] from application
39
+ [magenta]hare-app[/magenta].
40
+ $ [green]nextmv cloud switchback get --app-id hare-app --switchback-test-id carrot-optimization[/green]
41
+
42
+ - Get the switchback test using a specific profile.
43
+ $ [green]nextmv cloud switchback get --app-id hare-app --switchback-test-id lettuce-routes \\
44
+ --profile prod[/green]
45
+ """
46
+
47
+ cloud_app = build_app(app_id=app_id, profile=profile)
48
+ in_progress(msg="Getting switchback test...")
49
+ switchback_test = cloud_app.switchback_test(switchback_test_id=switchback_test_id)
50
+
51
+ switchback_test_dict = switchback_test.to_dict()
52
+
53
+ # Handle output
54
+ if output is not None and output != "":
55
+ with open(output, "w") as f:
56
+ json.dump(switchback_test_dict, f, indent=2)
57
+
58
+ success(msg=f"Switchback test output saved to [magenta]{output}[/magenta].")
59
+
60
+ return
61
+
62
+ print_json(switchback_test_dict)
@@ -0,0 +1,63 @@
1
+ """
2
+ This module defines the cloud switchback list command for the Nextmv CLI.
3
+ """
4
+
5
+ import json
6
+ from typing import Annotated
7
+
8
+ import typer
9
+
10
+ from nextmv.cli.configuration.config import build_app
11
+ from nextmv.cli.message import in_progress, print_json, success
12
+ from nextmv.cli.options import AppIDOption, ProfileOption
13
+
14
+ # Set up subcommand application.
15
+ app = typer.Typer()
16
+
17
+
18
+ @app.command()
19
+ def list(
20
+ app_id: AppIDOption,
21
+ output: Annotated[
22
+ str | None,
23
+ typer.Option(
24
+ "--output",
25
+ "-o",
26
+ help="Saves the list of switchback tests to this location.",
27
+ metavar="OUTPUT_PATH",
28
+ ),
29
+ ] = None,
30
+ profile: ProfileOption = None,
31
+ ) -> None:
32
+ """
33
+ List all Nextmv Cloud switchback tests for an application.
34
+
35
+ This command retrieves all switchback tests associated with the specified
36
+ application.
37
+
38
+ [bold][underline]Examples[/underline][/bold]
39
+
40
+ - List all switchback tests for application [magenta]hare-app[/magenta].
41
+ $ [green]nextmv cloud switchback list --app-id hare-app[/green]
42
+
43
+ - List all switchback tests and save to a file.
44
+ $ [green]nextmv cloud switchback list --app-id hare-app --output tests.json[/green]
45
+
46
+ - List all switchback tests using a specific profile.
47
+ $ [green]nextmv cloud switchback list --app-id hare-app --profile prod[/green]
48
+ """
49
+
50
+ cloud_app = build_app(app_id=app_id, profile=profile)
51
+ in_progress(msg="Listing switchback tests...")
52
+ switchback_tests = cloud_app.list_switchback_tests()
53
+ switchback_tests_dict = [test.to_dict() for test in switchback_tests]
54
+
55
+ if output is not None and output != "":
56
+ with open(output, "w") as f:
57
+ json.dump(switchback_tests_dict, f, indent=2)
58
+
59
+ success(msg=f"Switchback tests list saved to [magenta]{output}[/magenta].")
60
+
61
+ return
62
+
63
+ print_json(switchback_tests_dict)
@@ -0,0 +1,68 @@
1
+ """
2
+ This module defines the cloud switchback metadata command for the Nextmv CLI.
3
+ """
4
+
5
+ import json
6
+ from typing import Annotated
7
+
8
+ import typer
9
+
10
+ from nextmv.cli.configuration.config import build_app
11
+ from nextmv.cli.message import in_progress, print_json, success
12
+ from nextmv.cli.options import AppIDOption, ProfileOption, SwitchbackTestIDOption
13
+
14
+ # Set up subcommand application.
15
+ app = typer.Typer()
16
+
17
+
18
+ @app.command()
19
+ def metadata(
20
+ app_id: AppIDOption,
21
+ switchback_test_id: SwitchbackTestIDOption,
22
+ output: Annotated[
23
+ str | None,
24
+ typer.Option(
25
+ "--output",
26
+ "-o",
27
+ help="Saves the switchback test metadata to this location.",
28
+ metavar="OUTPUT_PATH",
29
+ ),
30
+ ] = None,
31
+ profile: ProfileOption = None,
32
+ ) -> None:
33
+ """
34
+ Get metadata for a Nextmv Cloud switchback test.
35
+
36
+ This command retrieves metadata for a specific switchback test, including
37
+ status, creation date, and other high-level information without the full
38
+ run details.
39
+
40
+ [bold][underline]Examples[/underline][/bold]
41
+
42
+ - Get metadata for switchback test [magenta]bunny-warren-optimization[/magenta] from application
43
+ [magenta]hare-app[/magenta].
44
+ $ [green]nextmv cloud switchback metadata --app-id hare-app \\
45
+ --switchback-test-id bunny-warren-optimization[/green]
46
+
47
+ - Get metadata and save to a file.
48
+ $ [green]nextmv cloud switchback metadata --app-id hare-app --switchback-test-id lettuce-delivery \\
49
+ --output metadata.json[/green]
50
+
51
+ - Get metadata using a specific profile.
52
+ $ [green]nextmv cloud switchback metadata --app-id hare-app --switchback-test-id hop-schedule \\
53
+ --profile prod[/green]
54
+ """
55
+
56
+ cloud_app = build_app(app_id=app_id, profile=profile)
57
+ in_progress(msg="Getting switchback test metadata...")
58
+ switchback_metadata = cloud_app.switchback_test_metadata(switchback_test_id=switchback_test_id)
59
+ switchback_metadata_dict = switchback_metadata.to_dict()
60
+
61
+ if output is not None and output != "":
62
+ with open(output, "w") as f:
63
+ json.dump(switchback_metadata_dict, f, indent=2)
64
+
65
+ success(msg=f"Switchback test metadata saved to [magenta]{output}[/magenta].")
66
+ return
67
+
68
+ print_json(switchback_metadata_dict)
@@ -0,0 +1,43 @@
1
+ """
2
+ This module defines the cloud switchback start command for the Nextmv CLI.
3
+ """
4
+
5
+ import typer
6
+
7
+ from nextmv.cli.configuration.config import build_app
8
+ from nextmv.cli.message import in_progress, success
9
+ from nextmv.cli.options import AppIDOption, ProfileOption, SwitchbackTestIDOption
10
+
11
+ # Set up subcommand application.
12
+ app = typer.Typer()
13
+
14
+
15
+ @app.command()
16
+ def start(
17
+ app_id: AppIDOption,
18
+ switchback_test_id: SwitchbackTestIDOption,
19
+ profile: ProfileOption = None,
20
+ ) -> None:
21
+ """
22
+ Starts a Nextmv Cloud switchback test.
23
+
24
+ Before starting a switchback test, it must be created in draft state. You
25
+ may use the [code]nextmv cloud switchback create[/code] command to create a
26
+ new switchback test. Alternatively, define a [code]--start[/code] when
27
+ using the [code]nextmv cloud switchback create[/code] command to have the
28
+ switchback test start automatically at a specific time.
29
+
30
+ [bold][underline]Examples[/underline][/bold]
31
+
32
+ - Start the switchback test with the ID [magenta]hop-analysis[/magenta] from application
33
+ [magenta]hare-app[/magenta].
34
+ $ [green]nextmv cloud switchback start --app-id hare-app --switchback-test-id hop-analysis[/green]
35
+ """
36
+
37
+ in_progress(msg="Starting switchback test...")
38
+ cloud_app = build_app(app_id=app_id, profile=profile)
39
+ cloud_app.start_switchback_test(switchback_test_id=switchback_test_id)
40
+ success(
41
+ f"Switchback test [magenta]{switchback_test_id}[/magenta] started successfully "
42
+ f"in application [magenta]{app_id}[/magenta]."
43
+ )
@@ -0,0 +1,43 @@
1
+ """
2
+ This module defines the cloud switchback stop command for the Nextmv CLI.
3
+ """
4
+
5
+ import typer
6
+
7
+ from nextmv.cli.configuration.config import build_app
8
+ from nextmv.cli.message import in_progress, success
9
+ from nextmv.cli.options import AppIDOption, ProfileOption, SwitchbackTestIDOption
10
+
11
+ # Set up subcommand application.
12
+ app = typer.Typer()
13
+
14
+
15
+ @app.command()
16
+ def stop(
17
+ app_id: AppIDOption,
18
+ switchback_test_id: SwitchbackTestIDOption,
19
+ profile: ProfileOption = None,
20
+ ) -> None:
21
+ """
22
+ Stops a Nextmv Cloud switchback test.
23
+
24
+ Before stopping a switchback test, it must be in a started state. You may
25
+ use the [code]nextmv cloud switchback start[/code] command to start a
26
+ switchback test. Alternatively, define a [code]--start[/code] when using
27
+ the [code]nextmv cloud switchback create[/code] command to have the
28
+ switchback test start automatically at a specific time.
29
+
30
+ [bold][underline]Examples[/underline][/bold]
31
+
32
+ - Stop the switchback test with the ID [magenta]hop-analysis[/magenta] from application
33
+ [magenta]hare-app[/magenta].
34
+ $ [green]nextmv cloud switchback stop --app-id hare-app --switchback-test-id hop-analysis[/green]
35
+ """
36
+
37
+ in_progress(msg="Stopping switchback test...")
38
+ cloud_app = build_app(app_id=app_id, profile=profile)
39
+ cloud_app.stop_switchback_test(switchback_test_id=switchback_test_id)
40
+ success(
41
+ f"Switchback test [magenta]{switchback_test_id}[/magenta] stopped successfully "
42
+ f"in application [magenta]{app_id}[/magenta]."
43
+ )