From 0bcf2311e2b09739cb12aa441617f752a049059c Mon Sep 17 00:00:00 2001 From: Simon Gerber Date: Tue, 3 Mar 2020 17:34:52 +0100 Subject: [PATCH 1/2] Explicitly disable check mode for subprocess.run in kapitan_compile This allows us to still explicitly check the return code of the call to kapitan in the compile() method. With check mode enabled, subprocess.run raises an exception instead of just returning the return code of the subprocess. --- commodore/compile.py | 2 +- commodore/helpers.py | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/commodore/compile.py b/commodore/compile.py index 6a7b1b88..6bf7a98c 100644 --- a/commodore/compile.py +++ b/commodore/compile.py @@ -154,7 +154,7 @@ def compile(config, cluster_id): p = kapitan_compile() if p.returncode != 0: - raise click.ClickException(f"Catalog compilation failed") + raise click.ClickException(f"Kapitan catalog compilation failed.") postprocess_components(kapitan_inventory, target_name, config.get_components()) diff --git a/commodore/helpers.py b/commodore/helpers.py index 04f988d3..67a831c0 100644 --- a/commodore/helpers.py +++ b/commodore/helpers.py @@ -93,7 +93,7 @@ def kapitan_compile(): click.secho('Compiling catalog...', bold=True) return subprocess.run( # nosec shlex.split('kapitan compile --fetch -J . dependencies --refs-path ./catalog/refs'), - check=True) + check=False) def rm_tree_contents(basedir): From 0d4f0a93b840a539a66ad3146f849d97dcd506d8 Mon Sep 17 00:00:00 2001 From: Simon Gerber Date: Tue, 3 Mar 2020 17:36:52 +0100 Subject: [PATCH 2/2] Bulk update python dependencies --- Pipfile.lock | 73 ++++++++++++++++++++++++++++------------------------ 1 file changed, 40 insertions(+), 33 deletions(-) diff --git a/Pipfile.lock b/Pipfile.lock index f334e5cc..fec90850 100644 --- a/Pipfile.lock +++ b/Pipfile.lock @@ -44,17 +44,17 @@ }, "boto3": { "hashes": [ - "sha256:3f02c5ec585fe0c7c843026f0f3db3a7bb98a830072b0eb151456ed07ba8e46d", - "sha256:435fc7220e76894228f9ceebc19ab226de78f515652f8643e3e22581a7e08ed7" + "sha256:08886cd451c2ab89912372262208f2c041f4f88b333291e364723d46e97be5b5", + "sha256:f191e02140e9691e91fac8cb87d74ad111015a1c98c3b99a24bba9982dc5ae7e" ], - "version": "==1.11.17" + "version": "==1.12.12" }, "botocore": { "hashes": [ - "sha256:02fe4673ab0c62393dc81c85fe0c65ae84f66cf55b0e0dbda785cf3e68b25762", - "sha256:75c759fcd89c4b2c717b40c2bd43915716bf15cfb7fb5bfccdc9bd9f697ac75f" + "sha256:c4efa61c90604913ac093fe4fe9f47e404ad980bc658a9f5fc1c9046e9fe094d", + "sha256:f12dd27c759992460b8ce70bfeed600437829b0293e6a08211237f11757678e5" ], - "version": "==1.14.17" + "version": "==1.15.12" }, "cachetools": { "hashes": [ @@ -154,10 +154,10 @@ }, "docker": { "hashes": [ - "sha256:6e06c5e70ba4fad73e35f00c55a895a448398f3ada7faae072e2bb01348bafc1", - "sha256:8f93775b8bdae3a2df6bc9a5312cce564cade58d6555f2c2570165a1270cd8a7" + "sha256:1c2ddb7a047b2599d1faec00889561316c674f7099427b9c51e8cb804114b553", + "sha256:ddae66620ab5f4bce769f64bcd7934f880c8abe6aa50986298db56735d0f722e" ], - "version": "==4.1.0" + "version": "==4.2.0" }, "docutils": { "hashes": [ @@ -173,20 +173,27 @@ ], "version": "==0.18.2" }, + "gitdb": { + "hashes": [ + "sha256:284a6a4554f954d6e737cddcff946404393e030b76a282c6640df8efd6b3da5e", + "sha256:598e0096bb3175a0aab3a0b5aedaa18a9a25c6707e0eca0695ba1a0baf1b2150" + ], + "version": "==4.0.2" + }, "gitdb2": { "hashes": [ - "sha256:1b6df1433567a51a4a9c1a5a0de977aa351a405cc56d7d35f3388bad1f630350", - "sha256:96bbb507d765a7f51eb802554a9cfe194a174582f772e0d89f4e87288c288b7b" + "sha256:0986cb4003de743f2b3aba4c828edd1ab58ce98e1c4a8acf72ef02760d4beb4e", + "sha256:a1c974e5fab8c2c90192c1367c81cbc54baec04244bda1816e9c8ab377d1cba3" ], - "version": "==2.0.6" + "version": "==4.0.2" }, "gitpython": { "hashes": [ - "sha256:9c2398ffc3dcb3c40b27324b316f08a4f93ad646d5a6328cafbb871aa79f5e42", - "sha256:c155c6a2653593ccb300462f6ef533583a913e17857cfef8fc617c246b6dc245" + "sha256:620b3c729bbc143b498cfea77e302999deedc55faec5b1067086c9ef90e101bc", + "sha256:a43a5d88a5bbc3cf32bb5223e4b4e68fd716db5e9996cad6e561bbfee6e5f4af" ], "index": "pypi", - "version": "==3.0.5" + "version": "==3.0.8" }, "google-api-python-client": { "hashes": [ @@ -246,16 +253,16 @@ }, "jmespath": { "hashes": [ - "sha256:3720a4b1bd659dd2eecad0666459b9788813e032b83e7ba58578e48254e0a0e6", - "sha256:bde2aef6f44302dfb30320115b17d030798de8c4110e28d5cf6cf91a7a31074c" + "sha256:695cb76fa78a10663425d5b73ddc5714eb711157e52704d69be03b1a02ba4fec", + "sha256:cca55c8d153173e21baa59983015ad0daf603f9cb799904ff057bfb8ff8dc2d9" ], - "version": "==0.9.4" + "version": "==0.9.5" }, "jsonnet": { "hashes": [ - "sha256:7b27c12e0c91d1f7a885287f039a217ed851c45b9b07dd34e35f25e206e2cd15" + "sha256:e8fcf1049df374c0e81ed13288bdc6d826fd381e7fc2671b0946f4964b06f915" ], - "version": "==0.14.0" + "version": "==0.15.0" }, "jsonschema": { "hashes": [ @@ -266,11 +273,11 @@ }, "kapitan": { "hashes": [ - "sha256:7935436137eabaaafac654243ff9146f4163691d3cc05095341efa1e03316718", - "sha256:999babfe341bb21d3024db92df06e6b8049b3a3613909462c7dfe7f8f9f25299" + "sha256:150bed3e714aaab6d0ce20f7b53c83f77ac50c0b9afc8c3dc3a22f73d7e19ca2", + "sha256:c819ee3418843902c9c470d3e815829808dddc4c70e6e3e65c9a829166897b49" ], "index": "pypi", - "version": "==0.26.1" + "version": "==0.27.0" }, "markupsafe": { "hashes": [ @@ -423,12 +430,12 @@ ], "version": "==1.14.0" }, - "smmap2": { + "smmap": { "hashes": [ - "sha256:0555a7bf4df71d1ef4218e4807bbf9b201f910174e6e08af2e138d4e517b4dde", - "sha256:29a9ffa0497e7f2be94ca0ed1ca1aa3cd4cf25a1f6b4f5f87f74b46ed91d609a" + "sha256:171484fe62793e3626c8b05dd752eb2ca01854b0c55a1efc0dc4210fccb65446", + "sha256:5fead614cf2de17ee0707a8c6a5f2aa5a2fc6c698c70993ba42f515485ffda78" ], - "version": "==2.0.5" + "version": "==3.0.1" }, "uritemplate": { "hashes": [ @@ -554,18 +561,18 @@ }, "tox": { "hashes": [ - "sha256:5c45d08f1dcc9bc97cdea3e5a69c8f4ad042cc37cbe6cf53e126f4a9005b7d3b", - "sha256:73e2ade68cd71a2765ee739ecc27c8c92e9b9c09acbad0f2c5307b20214e0d13" + "sha256:0cbe98369081fa16bd6f1163d3d0b2a62afa29d402ccfad2bd09fb2668be0956", + "sha256:676f1e3e7de245ad870f956436b84ea226210587d1f72c8dfb8cd5ac7b6f0e70" ], "index": "pypi", - "version": "==3.14.4" + "version": "==3.14.5" }, "virtualenv": { "hashes": [ - "sha256:08f3623597ce73b85d6854fb26608a6f39ee9d055c81178dc6583803797f8994", - "sha256:de2cbdd5926c48d7b84e0300dea9e8f276f61d186e8e49223d71d91250fbaebd" + "sha256:30ea90b21dabd11da5f509710ad3be2ae47d40ccbc717dfdd2efe4367c10f598", + "sha256:4a36a96d785428278edd389d9c36d763c5755844beb7509279194647b1ef47f1" ], - "version": "==20.0.4" + "version": "==20.0.7" } } }