diff --git a/.github/workflows/redshift.yml b/.github/workflows/redshift.yml index 35efbd419..9dfa0c7ca 100644 --- a/.github/workflows/redshift.yml +++ b/.github/workflows/redshift.yml @@ -26,7 +26,7 @@ jobs: test: runs-on: ubuntu-20.04 container: python:2.7.18-buster - timeout-minutes: 30 + timeout-minutes: 3 env: RS_PREFIX: ci_${{ github.sha }}_${{ github.run_id }}_${{ github.run_attempt }}_ RS_HOST: ${{ secrets.RS_HOST_CI }} diff --git a/clouds/redshift/common/run_script.py b/clouds/redshift/common/run_script.py index 167b42730..15db51a72 100644 --- a/clouds/redshift/common/run_script.py +++ b/clouds/redshift/common/run_script.py @@ -33,6 +33,7 @@ def run_queries(queries): with conn.cursor() as cursor: for i in trange(len(queries) if not filter else 1, ncols=97): query = apply_replacements(queries[i]) + print(query) if (not filter) or (filter in query): pattern = os.environ['RS_SCHEMA'] + '.(.*?)[(|\n]' result = re.search(pattern, str(query)) diff --git a/clouds/redshift/libraries/python/Makefile b/clouds/redshift/libraries/python/Makefile index 9b7cd958e..eac0570f0 100644 --- a/clouds/redshift/libraries/python/Makefile +++ b/clouds/redshift/libraries/python/Makefile @@ -39,7 +39,7 @@ build: rm -rf $(BUILD_DIR) mkdir $(BUILD_DIR) $(MAKE) build-library - $(MAKE) build-dependencies +# $(MAKE) build-dependencies $(MAKE) build-libraries-sql build-library: @@ -69,8 +69,9 @@ endif done deploy: check build - echo "Deploying libraries..." + echo "copy libraries..." $(MAKE) copy-libraries + echo "Deploying libraries..." $(MAKE) deploy-libraries $(MAKE) remove-libraries @@ -87,9 +88,9 @@ endif deploy-libraries: venv3 ifeq ("$(library)","carto") - FILTER=$(RS_LIBRARY) $(VENV3_BIN)/python $(COMMON_DIR)/run_script.py $(BUILD_DIR)/libraries.sql || exit 1 + FILTER=$(RS_LIBRARY) $(VENV3_BIN)/python $(COMMON_DIR)/run_script.py $(BUILD_DIR)/libraries.sql else - $(VENV3_BIN)/python $(COMMON_DIR)/run_script.py $(BUILD_DIR)/libraries.sql || exit 1 + $(VENV3_BIN)/python $(COMMON_DIR)/run_script.py $(BUILD_DIR)/libraries.sql endif remove-libraries: diff --git a/clouds/redshift/modules/sql/quadbin/QUADBIN_BBOX.sql b/clouds/redshift/modules/sql/quadbin/QUADBIN_BBOX.sql index 3cbef9751..eccd20a34 100644 --- a/clouds/redshift/modules/sql/quadbin/QUADBIN_BBOX.sql +++ b/clouds/redshift/modules/sql/quadbin/QUADBIN_BBOX.sql @@ -13,6 +13,7 @@ AS $$ if quadbin is None: return None + return json.dumps(cell_to_bounding_box(quadbin)) $$ LANGUAGE plpythonu;