diff --git a/.github/workflows/master.yml b/.github/workflows/master.yml index 98fc43ed1..026ba4bfe 100644 --- a/.github/workflows/master.yml +++ b/.github/workflows/master.yml @@ -49,7 +49,8 @@ jobs: registry-url: https://registry.npmjs.org always-auth: true - name: Install pipenv - uses: dschep/install-pipenv-action@v1 + run: | + python -m pip install --upgrade pipenv pip requests wheel urllib3 chardet - name: Install Twine run: python -m pip install pip twine - name: Checkout Repo @@ -165,7 +166,8 @@ jobs: with: node-version: ${{ matrix.node-version }} - name: Install pipenv - uses: dschep/install-pipenv-action@v1 + run: | + python -m pip install --upgrade pipenv pip requests wheel urllib3 chardet - name: Setup git run: | git config --global user.email "you@example.com" @@ -233,7 +235,8 @@ jobs: with: node-version: ${{ matrix.node-version }} - name: Install pipenv - uses: dschep/install-pipenv-action@v1 + run: | + python -m pip install --upgrade pipenv pip requests wheel urllib3 chardet - name: Setup git run: | git config --global user.email "you@example.com" @@ -266,6 +269,9 @@ jobs: - name: Install run: | make install_all + # Install Pulumi Python SDK globally (on CI only) to workaround a + # problem a sub-process in a test failing to find it. + python -m pip install -e sdk/python/env/src env: PULUMI_NODE_MODULES: ${{ runner.temp }}/opt/pulumi/node_modules PULUMI_LOCAL_NUGET: ${{ runner.temp }}/opt/pulumi/nuget diff --git a/.github/workflows/prerelease.yml b/.github/workflows/prerelease.yml index 5c340fbfe..f2615b03f 100644 --- a/.github/workflows/prerelease.yml +++ b/.github/workflows/prerelease.yml @@ -49,7 +49,8 @@ jobs: registry-url: https://registry.npmjs.org always-auth: true - name: Install pipenv - uses: dschep/install-pipenv-action@v1 + run: | + python -m pip install --upgrade pipenv pip requests wheel urllib3 chardet - name: Install Twine run: python -m pip install pip twine - name: Checkout Repo @@ -148,7 +149,8 @@ jobs: with: node-version: ${{ matrix.node-version }} - name: Install pipenv - uses: dschep/install-pipenv-action@v1 + run: | + python -m pip install --upgrade pipenv pip requests wheel urllib3 chardet - name: Setup git run: | git config --global user.email "you@example.com" @@ -210,7 +212,8 @@ jobs: with: node-version: ${{ matrix.node-version }} - name: Install pipenv - uses: dschep/install-pipenv-action@v1 + run: | + python -m pip install --upgrade pipenv pip requests wheel urllib3 chardet - name: Install pulumictl uses: jaxxstorm/action-install-gh-release@v1.2.0 with: @@ -243,6 +246,9 @@ jobs: - name: Install run: | make install_all + # Install Pulumi Python SDK globally (on CI only) to workaround a + # problem a sub-process in a test failing to find it. + python -m pip install -e sdk/python/env/src env: PULUMI_NODE_MODULES: ${{ runner.temp }}/opt/pulumi/node_modules PULUMI_LOCAL_NUGET: ${{ runner.temp }}/opt/pulumi/nuget diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index 790f1bd11..2f248fdb3 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -141,7 +141,8 @@ jobs: registry-url: https://registry.npmjs.org always-auth: true - name: Install pipenv - uses: dschep/install-pipenv-action@v1 + run: | + python -m pip install --upgrade pipenv pip requests wheel urllib3 chardet - name: Install Twine run: python -m pip install pip twine - name: Checkout Repo @@ -241,7 +242,8 @@ jobs: with: node-version: ${{ matrix.node-version }} - name: Install pipenv - uses: dschep/install-pipenv-action@v1 + run: | + python -m pip install --upgrade pipenv pip requests wheel urllib3 chardet - name: Setup git run: | git config --global user.email "you@example.com" @@ -309,7 +311,8 @@ jobs: with: node-version: ${{ matrix.node-version }} - name: Install pipenv - uses: dschep/install-pipenv-action@v1 + run: | + python -m pip install --upgrade pipenv pip requests wheel urllib3 chardet - name: Setup git run: | git config --global user.email "you@example.com" @@ -349,6 +352,9 @@ jobs: - name: Install run: | make install_all + # Install Pulumi Python SDK globally (on CI only) to workaround a + # problem a sub-process in a test failing to find it. + python -m pip install -e sdk/python/env/src env: PULUMI_NODE_MODULES: ${{ runner.temp }}/opt/pulumi/node_modules PULUMI_LOCAL_NUGET: ${{ runner.temp }}/opt/pulumi/nuget diff --git a/.github/workflows/run-build-and-acceptance-tests.yml b/.github/workflows/run-build-and-acceptance-tests.yml index 7ef448b78..d9208bdb6 100644 --- a/.github/workflows/run-build-and-acceptance-tests.yml +++ b/.github/workflows/run-build-and-acceptance-tests.yml @@ -88,7 +88,8 @@ jobs: with: node-version: ${{ matrix.node-version }} - name: Install pipenv - uses: dschep/install-pipenv-action@v1 + run: | + python -m pip install --upgrade pipenv pip requests wheel urllib3 chardet - name: Setup git run: | git config --global user.email "you@example.com" @@ -175,7 +176,8 @@ jobs: with: node-version: ${{ matrix.node-version }} - name: Install pipenv - uses: dschep/install-pipenv-action@v1 + run: | + python -m pip install --upgrade pipenv pip requests wheel urllib3 chardet - name: Setup git run: | git config --global user.email "you@example.com" @@ -219,6 +221,9 @@ jobs: - name: Install run: | make install_all + # Install Pulumi Python SDK globally (on CI only) to workaround a + # problem a sub-process in a test failing to find it. + python -m pip install -e sdk/python/env/src env: PULUMI_NODE_MODULES: ${{ runner.temp }}/opt/pulumi/node_modules PULUMI_LOCAL_NUGET: ${{ runner.temp }}/opt/pulumi/nuget diff --git a/pkg/codegen/internal/test/sdk_driver.go b/pkg/codegen/internal/test/sdk_driver.go index 0800be0bf..2f204322d 100644 --- a/pkg/codegen/internal/test/sdk_driver.go +++ b/pkg/codegen/internal/test/sdk_driver.go @@ -151,7 +151,9 @@ var sdkTests = []sdkTest{ { Directory: "hyphen-url", Description: "A resource url with a hyphen in its path", - Skip: codegen.NewStringSet("python/test", "nodejs/test"), + // TODO[pulumi/pulumi#8370]: Re-enable compiling for Go. + SkipCompileCheck: codegen.NewStringSet(golang), + Skip: codegen.NewStringSet("python/test", "nodejs/test"), }, { Directory: "output-funcs", diff --git a/sdk/python/Makefile b/sdk/python/Makefile index 3a378c470..1dcb38110 100644 --- a/sdk/python/Makefile +++ b/sdk/python/Makefile @@ -48,7 +48,7 @@ install:: install_package install_plugin test_fast:: $(TEST_ALL_DEPS) $(GO_TEST) ${PROJECT_PKGS} - pipenv run pip install ./env/src + pipenv install -e ./env/src # TODO the ignored test seems to fail in pytest but not unittest. Need to trackdown why $(RUN_TESTSUITE) python/lib/test pipenv run pytest lib/test --ignore lib/test/automation --ignore lib/test/langhost/resource_thens/test_resource_thens.py $(RUN_TESTSUITE) python/lib/test/langhost/resource_thens pipenv run python -m unittest lib/test/langhost/resource_thens/test_resource_thens.py