From fd3e7640b19ebfb631be26d11a8842833d922a09 Mon Sep 17 00:00:00 2001 From: David Glick Date: Wed, 19 Feb 2020 15:20:57 -0500 Subject: [PATCH 01/18] Try a github action for publishing to TestPyPI --- .github/workflows/publish-to-test-pypi.yml | 27 ++++++++++++++++++++++ 1 file changed, 27 insertions(+) create mode 100644 .github/workflows/publish-to-test-pypi.yml diff --git a/.github/workflows/publish-to-test-pypi.yml b/.github/workflows/publish-to-test-pypi.yml new file mode 100644 index 0000000000..4568dcff09 --- /dev/null +++ b/.github/workflows/publish-to-test-pypi.yml @@ -0,0 +1,27 @@ +name: Publish Python distributions to TestPyPI + +on: + push: + branches: + - feature/release-action + +jobs: + build-n-publish: + name: Build and publish Python distributions to TestPyPI + runs-on: ubuntu-18.04 + steps: + - uses: actions/checkout@master + - name: Set up Python 3.7 + uses: actions/setup-python@v1 + with: + python-version: 3.7 + - name: Build source tarball and binary wheel + run: python setup.py sdist bdist_wheel + - name: Install twine + run: python -m pip install twine + - name: Upload to TestPyPI + run: twine upload dist/* + env: + TWINE_REPOSITORY_URL: https://test.pypi.org/legacy/ + TWINE_USERNAME: __token__ + TWINE_PASSWORD: ${{ secrets.TEST_PYPI_TOKEN }} From 1a1d1cee6f1488fd1f607d1138435a1a050e51d2 Mon Sep 17 00:00:00 2001 From: David Glick Date: Wed, 19 Feb 2020 15:22:41 -0500 Subject: [PATCH 02/18] need wheel --- .github/workflows/publish-to-test-pypi.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/publish-to-test-pypi.yml b/.github/workflows/publish-to-test-pypi.yml index 4568dcff09..f997bb392b 100644 --- a/.github/workflows/publish-to-test-pypi.yml +++ b/.github/workflows/publish-to-test-pypi.yml @@ -15,10 +15,10 @@ jobs: uses: actions/setup-python@v1 with: python-version: 3.7 + - name: Install build tools + run: python -m pip install twine wheel - name: Build source tarball and binary wheel run: python setup.py sdist bdist_wheel - - name: Install twine - run: python -m pip install twine - name: Upload to TestPyPI run: twine upload dist/* env: From 5b3adbea345bd149945b6bfce9a4fa6200f700be Mon Sep 17 00:00:00 2001 From: David Glick Date: Wed, 19 Feb 2020 16:36:19 -0500 Subject: [PATCH 03/18] Attempt to update homebrew-sfdo as well --- .github/workflows/publish-to-test-pypi.yml | 27 ----------- .github/workflows/release.yml | 56 ++++++++++++++++++++++ 2 files changed, 56 insertions(+), 27 deletions(-) delete mode 100644 .github/workflows/publish-to-test-pypi.yml create mode 100644 .github/workflows/release.yml diff --git a/.github/workflows/publish-to-test-pypi.yml b/.github/workflows/publish-to-test-pypi.yml deleted file mode 100644 index f997bb392b..0000000000 --- a/.github/workflows/publish-to-test-pypi.yml +++ /dev/null @@ -1,27 +0,0 @@ -name: Publish Python distributions to TestPyPI - -on: - push: - branches: - - feature/release-action - -jobs: - build-n-publish: - name: Build and publish Python distributions to TestPyPI - runs-on: ubuntu-18.04 - steps: - - uses: actions/checkout@master - - name: Set up Python 3.7 - uses: actions/setup-python@v1 - with: - python-version: 3.7 - - name: Install build tools - run: python -m pip install twine wheel - - name: Build source tarball and binary wheel - run: python setup.py sdist bdist_wheel - - name: Upload to TestPyPI - run: twine upload dist/* - env: - TWINE_REPOSITORY_URL: https://test.pypi.org/legacy/ - TWINE_USERNAME: __token__ - TWINE_PASSWORD: ${{ secrets.TEST_PYPI_TOKEN }} diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml new file mode 100644 index 0000000000..4abe6035f9 --- /dev/null +++ b/.github/workflows/release.yml @@ -0,0 +1,56 @@ +name: Release cumulusci + +on: + push: + branches: + - feature/release-action + +jobs: + publish-to-pypi: + name: Publish new release to PyPI + runs-on: ubuntu-18.04 + steps: + - uses: actions/checkout@master + - name: Set up Python 3.7 + uses: actions/setup-python@v1 + with: + python-version: 3.7 + - name: Install build tools + run: python -m pip install twine wheel + - name: Build source tarball and binary wheel + run: python setup.py sdist bdist_wheel + - name: Upload to TestPyPI + run: twine upload dist/* + env: + TWINE_REPOSITORY_URL: https://test.pypi.org/legacy/ + TWINE_USERNAME: __token__ + TWINE_PASSWORD: ${{ secrets.TEST_PYPI_TOKEN }} + publish-to-homebrew: + name: Publish new release for Homebrew + needs: publish-to-pypi + runs-on: macos-10.15 + steps: + - uses: actions/checkout@master + - name: Set up Python 3.7 + uses: actions/setup-python@v1 + with: + python-version: 3.7 + - name: Build formula + run: utility/build-homebrew.sh cumulusci.rb + - name: Test formula + run: | + brew audit cumulusci.rb + brew install cumulusci.rb + brew test cumulusci.rb + - name: Update homebrew-sfdo repository + run: | + git clone https://HOMEBREW_GITHUB_USER:HOMEBREW_GITHUB_TOKEN@github.com/SFDO-Tooling/homebrew-sfdo.git + cd homebrew-sfdo + git checkout -b auto-update + cp ../cumulusci.rb ./ + git add cumulusci.rb + git commit -m "Update formula" + git push origin master + +# to do: +# - add release notes in github From a62ca85fe758af797c30a8f6d7688cb022b3d3e0 Mon Sep 17 00:00:00 2001 From: David Glick Date: Wed, 19 Feb 2020 16:40:14 -0500 Subject: [PATCH 04/18] new version --- cumulusci/__init__.py | 2 +- setup.cfg | 2 +- setup.py | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/cumulusci/__init__.py b/cumulusci/__init__.py index 139e230b85..b044f5f0fc 100644 --- a/cumulusci/__init__.py +++ b/cumulusci/__init__.py @@ -3,7 +3,7 @@ __import__("pkg_resources").declare_namespace("cumulusci") -__version__ = "3.6.1.dev0" +__version__ = "3.6.1.dev1" __location__ = os.path.dirname(os.path.realpath(__file__)) diff --git a/setup.cfg b/setup.cfg index 9b8864d355..d9e6e6e2c7 100644 --- a/setup.cfg +++ b/setup.cfg @@ -1,5 +1,5 @@ [bumpversion] -current_version = 3.6.1.dev0 +current_version = 3.6.1.dev1 commit = True tag = False diff --git a/setup.py b/setup.py index a380d9e49b..e12bdeca7a 100644 --- a/setup.py +++ b/setup.py @@ -34,7 +34,7 @@ def find_packages(path=["."], prefix=""): setup( name="cumulusci", - version="3.6.1.dev0", + version="3.6.1.dev1", description="Build and release tools for Salesforce developers", long_description=readme + u"\n\n" + history, long_description_content_type="text/x-rst", From b3223078b7147dd97f6e87d602c1219764c2c594 Mon Sep 17 00:00:00 2001 From: David Glick Date: Wed, 19 Feb 2020 16:44:34 -0500 Subject: [PATCH 05/18] don't break in build-homebrew.sh if no active virtualenv --- cumulusci/__init__.py | 2 +- setup.cfg | 2 +- setup.py | 2 +- utility/build-homebrew.sh | 2 +- 4 files changed, 4 insertions(+), 4 deletions(-) diff --git a/cumulusci/__init__.py b/cumulusci/__init__.py index b044f5f0fc..11eaf91132 100644 --- a/cumulusci/__init__.py +++ b/cumulusci/__init__.py @@ -3,7 +3,7 @@ __import__("pkg_resources").declare_namespace("cumulusci") -__version__ = "3.6.1.dev1" +__version__ = "3.6.1.dev2" __location__ = os.path.dirname(os.path.realpath(__file__)) diff --git a/setup.cfg b/setup.cfg index d9e6e6e2c7..b4d9b444f9 100644 --- a/setup.cfg +++ b/setup.cfg @@ -1,5 +1,5 @@ [bumpversion] -current_version = 3.6.1.dev1 +current_version = 3.6.1.dev2 commit = True tag = False diff --git a/setup.py b/setup.py index e12bdeca7a..43bd12f578 100644 --- a/setup.py +++ b/setup.py @@ -34,7 +34,7 @@ def find_packages(path=["."], prefix=""): setup( name="cumulusci", - version="3.6.1.dev1", + version="3.6.1.dev2", description="Build and release tools for Salesforce developers", long_description=readme + u"\n\n" + history, long_description_content_type="text/x-rst", diff --git a/utility/build-homebrew.sh b/utility/build-homebrew.sh index b125ea0bbe..d761899809 100755 --- a/utility/build-homebrew.sh +++ b/utility/build-homebrew.sh @@ -17,7 +17,7 @@ PACKAGE_VERSION="$(cat setup.cfg | grep current_version | head -n 1 | cut -f 3 - echo " " echo "=> Creating a temporary virtualenv and installing CumulusCI..." echo " " -source deactivate +source deactivate || true python3.7 -m venv "$ENV_DIR" || exit 1 source "$ENV_DIR/bin/activate" || exit 1 pip install -U pip From 9f8512d741ddd790b65a59a1fca6292134912325 Mon Sep 17 00:00:00 2001 From: David Glick Date: Wed, 19 Feb 2020 16:47:08 -0500 Subject: [PATCH 06/18] try another way --- cumulusci/__init__.py | 2 +- setup.cfg | 2 +- setup.py | 2 +- utility/build-homebrew.sh | 1 - 4 files changed, 3 insertions(+), 4 deletions(-) diff --git a/cumulusci/__init__.py b/cumulusci/__init__.py index 11eaf91132..03ff43e1ab 100644 --- a/cumulusci/__init__.py +++ b/cumulusci/__init__.py @@ -3,7 +3,7 @@ __import__("pkg_resources").declare_namespace("cumulusci") -__version__ = "3.6.1.dev2" +__version__ = "3.6.1.dev3" __location__ = os.path.dirname(os.path.realpath(__file__)) diff --git a/setup.cfg b/setup.cfg index b4d9b444f9..4594910689 100644 --- a/setup.cfg +++ b/setup.cfg @@ -1,5 +1,5 @@ [bumpversion] -current_version = 3.6.1.dev2 +current_version = 3.6.1.dev3 commit = True tag = False diff --git a/setup.py b/setup.py index 43bd12f578..16ba2c3ec7 100644 --- a/setup.py +++ b/setup.py @@ -34,7 +34,7 @@ def find_packages(path=["."], prefix=""): setup( name="cumulusci", - version="3.6.1.dev2", + version="3.6.1.dev3", description="Build and release tools for Salesforce developers", long_description=readme + u"\n\n" + history, long_description_content_type="text/x-rst", diff --git a/utility/build-homebrew.sh b/utility/build-homebrew.sh index d761899809..7b3a4b5d01 100755 --- a/utility/build-homebrew.sh +++ b/utility/build-homebrew.sh @@ -17,7 +17,6 @@ PACKAGE_VERSION="$(cat setup.cfg | grep current_version | head -n 1 | cut -f 3 - echo " " echo "=> Creating a temporary virtualenv and installing CumulusCI..." echo " " -source deactivate || true python3.7 -m venv "$ENV_DIR" || exit 1 source "$ENV_DIR/bin/activate" || exit 1 pip install -U pip From f545ea2e1c59c87bd1302dbe7272a5cbaa131b33 Mon Sep 17 00:00:00 2001 From: David Glick Date: Wed, 19 Feb 2020 16:50:08 -0500 Subject: [PATCH 07/18] need to include test pypi as an index for now --- cumulusci/__init__.py | 2 +- setup.cfg | 2 +- setup.py | 2 +- utility/build-homebrew.sh | 2 +- 4 files changed, 4 insertions(+), 4 deletions(-) diff --git a/cumulusci/__init__.py b/cumulusci/__init__.py index 03ff43e1ab..2de852f926 100644 --- a/cumulusci/__init__.py +++ b/cumulusci/__init__.py @@ -3,7 +3,7 @@ __import__("pkg_resources").declare_namespace("cumulusci") -__version__ = "3.6.1.dev3" +__version__ = "3.6.1.dev4" __location__ = os.path.dirname(os.path.realpath(__file__)) diff --git a/setup.cfg b/setup.cfg index 4594910689..bf20094356 100644 --- a/setup.cfg +++ b/setup.cfg @@ -1,5 +1,5 @@ [bumpversion] -current_version = 3.6.1.dev3 +current_version = 3.6.1.dev4 commit = True tag = False diff --git a/setup.py b/setup.py index 16ba2c3ec7..e277800954 100644 --- a/setup.py +++ b/setup.py @@ -34,7 +34,7 @@ def find_packages(path=["."], prefix=""): setup( name="cumulusci", - version="3.6.1.dev3", + version="3.6.1.dev4", description="Build and release tools for Salesforce developers", long_description=readme + u"\n\n" + history, long_description_content_type="text/x-rst", diff --git a/utility/build-homebrew.sh b/utility/build-homebrew.sh index 7b3a4b5d01..3afabb9264 100755 --- a/utility/build-homebrew.sh +++ b/utility/build-homebrew.sh @@ -20,7 +20,7 @@ echo " " python3.7 -m venv "$ENV_DIR" || exit 1 source "$ENV_DIR/bin/activate" || exit 1 pip install -U pip -pip install --no-cache cumulusci==$PACKAGE_VERSION homebrew-pypi-poet || exit 1 +pip install --no-cache --extra-index-url https://test.pypi.org/simple/ cumulusci==$PACKAGE_VERSION homebrew-pypi-poet || exit 1 echo " " echo "=> Collecting dependencies and generating resource stanzas..." From 70c672a8b6dbe91b9dfc1f0e0b93f7aee47639a6 Mon Sep 17 00:00:00 2001 From: David Glick Date: Wed, 19 Feb 2020 19:04:33 -0500 Subject: [PATCH 08/18] fix homebrew formula to pass audit --- utility/build-homebrew.sh | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/utility/build-homebrew.sh b/utility/build-homebrew.sh index 3afabb9264..b46cf1ed3d 100755 --- a/utility/build-homebrew.sh +++ b/utility/build-homebrew.sh @@ -25,7 +25,7 @@ pip install --no-cache --extra-index-url https://test.pypi.org/simple/ cumulusci echo " " echo "=> Collecting dependencies and generating resource stanzas..." echo " " -poet cumulusci > "$RES_FILE" +poet cumulusci | awk '/resource "cumulusci"/{c=5} !(c&&c--)' > "$RES_FILE" if [ $? -ne 0 ]; then exit 1 fi @@ -52,6 +52,8 @@ $(cat "$RES_FILE") site_packages = libexec/"lib/python#{xy}/site-packages" ENV.prepend_create_path "PYTHONPATH", site_packages + system "python3", *Language::Python.setup_install_args(libexec) + deps = resources.map(&:name).to_set deps.each do |r| resource(r).stage do From 8c6e293ba1213e4f03068b8d55e53823a4a4133a Mon Sep 17 00:00:00 2001 From: David Glick Date: Wed, 19 Feb 2020 19:04:58 -0500 Subject: [PATCH 09/18] version bump --- cumulusci/__init__.py | 2 +- setup.cfg | 2 +- setup.py | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/cumulusci/__init__.py b/cumulusci/__init__.py index 2de852f926..88fef1d0c7 100644 --- a/cumulusci/__init__.py +++ b/cumulusci/__init__.py @@ -3,7 +3,7 @@ __import__("pkg_resources").declare_namespace("cumulusci") -__version__ = "3.6.1.dev4" +__version__ = "3.6.1.dev5" __location__ = os.path.dirname(os.path.realpath(__file__)) diff --git a/setup.cfg b/setup.cfg index bf20094356..b93b9f52a0 100644 --- a/setup.cfg +++ b/setup.cfg @@ -1,5 +1,5 @@ [bumpversion] -current_version = 3.6.1.dev4 +current_version = 3.6.1.dev5 commit = True tag = False diff --git a/setup.py b/setup.py index e277800954..2aab72ea1d 100644 --- a/setup.py +++ b/setup.py @@ -34,7 +34,7 @@ def find_packages(path=["."], prefix=""): setup( name="cumulusci", - version="3.6.1.dev4", + version="3.6.1.dev5", description="Build and release tools for Salesforce developers", long_description=readme + u"\n\n" + history, long_description_content_type="text/x-rst", From 7d7c17133b381e79689fd99501cd4bd3fcdd53a8 Mon Sep 17 00:00:00 2001 From: David Glick Date: Wed, 19 Feb 2020 22:06:03 -0500 Subject: [PATCH 10/18] wait a bit --- .github/workflows/release.yml | 4 +++- cumulusci/__init__.py | 2 +- setup.cfg | 2 +- setup.py | 2 +- 4 files changed, 6 insertions(+), 4 deletions(-) diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index 4abe6035f9..38519a6cf4 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -36,7 +36,9 @@ jobs: with: python-version: 3.7 - name: Build formula - run: utility/build-homebrew.sh cumulusci.rb + run: | + sleep 10 + utility/build-homebrew.sh cumulusci.rb - name: Test formula run: | brew audit cumulusci.rb diff --git a/cumulusci/__init__.py b/cumulusci/__init__.py index 88fef1d0c7..d3804ab350 100644 --- a/cumulusci/__init__.py +++ b/cumulusci/__init__.py @@ -3,7 +3,7 @@ __import__("pkg_resources").declare_namespace("cumulusci") -__version__ = "3.6.1.dev5" +__version__ = "3.6.1.dev6" __location__ = os.path.dirname(os.path.realpath(__file__)) diff --git a/setup.cfg b/setup.cfg index b93b9f52a0..ce369a2f0c 100644 --- a/setup.cfg +++ b/setup.cfg @@ -1,5 +1,5 @@ [bumpversion] -current_version = 3.6.1.dev5 +current_version = 3.6.1.dev6 commit = True tag = False diff --git a/setup.py b/setup.py index 2aab72ea1d..a223e2bd66 100644 --- a/setup.py +++ b/setup.py @@ -34,7 +34,7 @@ def find_packages(path=["."], prefix=""): setup( name="cumulusci", - version="3.6.1.dev5", + version="3.6.1.dev6", description="Build and release tools for Salesforce developers", long_description=readme + u"\n\n" + history, long_description_content_type="text/x-rst", From 7bdfc1453bc729aa5e4929a7f7e1e3513da6a170 Mon Sep 17 00:00:00 2001 From: David Glick Date: Thu, 20 Feb 2020 00:18:37 -0500 Subject: [PATCH 11/18] fix another pypi ref --- cumulusci/__init__.py | 2 +- setup.cfg | 2 +- setup.py | 2 +- utility/build-homebrew.sh | 3 ++- 4 files changed, 5 insertions(+), 4 deletions(-) diff --git a/cumulusci/__init__.py b/cumulusci/__init__.py index d3804ab350..7b728db272 100644 --- a/cumulusci/__init__.py +++ b/cumulusci/__init__.py @@ -3,7 +3,7 @@ __import__("pkg_resources").declare_namespace("cumulusci") -__version__ = "3.6.1.dev6" +__version__ = "3.6.1.dev7" __location__ = os.path.dirname(os.path.realpath(__file__)) diff --git a/setup.cfg b/setup.cfg index ce369a2f0c..3e537de379 100644 --- a/setup.cfg +++ b/setup.cfg @@ -1,5 +1,5 @@ [bumpversion] -current_version = 3.6.1.dev6 +current_version = 3.6.1.dev7 commit = True tag = False diff --git a/setup.py b/setup.py index a223e2bd66..783e82b2c8 100644 --- a/setup.py +++ b/setup.py @@ -34,7 +34,7 @@ def find_packages(path=["."], prefix=""): setup( name="cumulusci", - version="3.6.1.dev6", + version="3.6.1.dev7", description="Build and release tools for Salesforce developers", long_description=readme + u"\n\n" + history, long_description_content_type="text/x-rst", diff --git a/utility/build-homebrew.sh b/utility/build-homebrew.sh index b46cf1ed3d..8431cef438 100755 --- a/utility/build-homebrew.sh +++ b/utility/build-homebrew.sh @@ -9,7 +9,8 @@ PYPI_JSON="$(mktemp)" || exit 1 echo " " echo "=> Collecting package info from PyPI..." echo " " -curl -L "https://pypi.io/pypi/cumulusci/json" > "$PYPI_JSON" || exit 1 +#curl -L "https://pypi.io/pypi/cumulusci/json" > "$PYPI_JSON" || exit 1 +curl -L "https://test.pypi.org/pypi/cumulusci/json" > "$PYPI_JSON" || exit 1 PACKAGE_URL="$(cat "$PYPI_JSON" | jq '.urls[1].url')" || exit 1 PACKAGE_SHA="$(cat "$PYPI_JSON" | jq '.urls[1].digests.sha256')" || exit 1 PACKAGE_VERSION="$(cat setup.cfg | grep current_version | head -n 1 | cut -f 3 -d' ')" || exit 1 From 3c6b7b672339f4098d35c24af696782f9ca12deb Mon Sep 17 00:00:00 2001 From: David Glick Date: Thu, 20 Feb 2020 00:22:31 -0500 Subject: [PATCH 12/18] try again --- .github/workflows/release.yml | 2 +- cumulusci/__init__.py | 2 +- setup.cfg | 2 +- setup.py | 2 +- 4 files changed, 4 insertions(+), 4 deletions(-) diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index 38519a6cf4..f859a55696 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -37,7 +37,7 @@ jobs: python-version: 3.7 - name: Build formula run: | - sleep 10 + sleep 30 utility/build-homebrew.sh cumulusci.rb - name: Test formula run: | diff --git a/cumulusci/__init__.py b/cumulusci/__init__.py index 7b728db272..415395ecd3 100644 --- a/cumulusci/__init__.py +++ b/cumulusci/__init__.py @@ -3,7 +3,7 @@ __import__("pkg_resources").declare_namespace("cumulusci") -__version__ = "3.6.1.dev7" +__version__ = "3.6.1.dev8" __location__ = os.path.dirname(os.path.realpath(__file__)) diff --git a/setup.cfg b/setup.cfg index 3e537de379..39317124ab 100644 --- a/setup.cfg +++ b/setup.cfg @@ -1,5 +1,5 @@ [bumpversion] -current_version = 3.6.1.dev7 +current_version = 3.6.1.dev8 commit = True tag = False diff --git a/setup.py b/setup.py index 783e82b2c8..1e004b74fc 100644 --- a/setup.py +++ b/setup.py @@ -34,7 +34,7 @@ def find_packages(path=["."], prefix=""): setup( name="cumulusci", - version="3.6.1.dev7", + version="3.6.1.dev8", description="Build and release tools for Salesforce developers", long_description=readme + u"\n\n" + history, long_description_content_type="text/x-rst", From 7fec5fcb0a308324782a04c287b97193c6ca6ff0 Mon Sep 17 00:00:00 2001 From: David Glick Date: Thu, 20 Feb 2020 00:29:40 -0500 Subject: [PATCH 13/18] no-cache-dir --- cumulusci/__init__.py | 2 +- setup.cfg | 2 +- setup.py | 2 +- utility/build-homebrew.sh | 2 +- 4 files changed, 4 insertions(+), 4 deletions(-) diff --git a/cumulusci/__init__.py b/cumulusci/__init__.py index 415395ecd3..be8a2b7784 100644 --- a/cumulusci/__init__.py +++ b/cumulusci/__init__.py @@ -3,7 +3,7 @@ __import__("pkg_resources").declare_namespace("cumulusci") -__version__ = "3.6.1.dev8" +__version__ = "3.6.1.dev9" __location__ = os.path.dirname(os.path.realpath(__file__)) diff --git a/setup.cfg b/setup.cfg index 39317124ab..9dc4e1d490 100644 --- a/setup.cfg +++ b/setup.cfg @@ -1,5 +1,5 @@ [bumpversion] -current_version = 3.6.1.dev8 +current_version = 3.6.1.dev9 commit = True tag = False diff --git a/setup.py b/setup.py index 1e004b74fc..73ff734fc8 100644 --- a/setup.py +++ b/setup.py @@ -34,7 +34,7 @@ def find_packages(path=["."], prefix=""): setup( name="cumulusci", - version="3.6.1.dev8", + version="3.6.1.dev9", description="Build and release tools for Salesforce developers", long_description=readme + u"\n\n" + history, long_description_content_type="text/x-rst", diff --git a/utility/build-homebrew.sh b/utility/build-homebrew.sh index 8431cef438..cec4bcd381 100755 --- a/utility/build-homebrew.sh +++ b/utility/build-homebrew.sh @@ -21,7 +21,7 @@ echo " " python3.7 -m venv "$ENV_DIR" || exit 1 source "$ENV_DIR/bin/activate" || exit 1 pip install -U pip -pip install --no-cache --extra-index-url https://test.pypi.org/simple/ cumulusci==$PACKAGE_VERSION homebrew-pypi-poet || exit 1 +pip install --no-cache-dir --extra-index-url https://test.pypi.org/simple/ cumulusci==$PACKAGE_VERSION homebrew-pypi-poet || exit 1 echo " " echo "=> Collecting dependencies and generating resource stanzas..." From 77a12d1b71a1af15df2cc3395cc9c65179bc2d23 Mon Sep 17 00:00:00 2001 From: David Glick Date: Mon, 16 Mar 2020 12:53:54 -0400 Subject: [PATCH 14/18] Publish to production PyPI; create tag --- .github/workflows/release.yml | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index fa8d617090..55bf587581 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -21,12 +21,15 @@ jobs: run: python -m pip install twine wheel - name: Build source tarball and binary wheel run: python setup.py sdist bdist_wheel - - name: Upload to TestPyPI + - name: Upload to PyPI run: twine upload dist/* env: - TWINE_REPOSITORY_URL: https://test.pypi.org/legacy/ TWINE_USERNAME: __token__ - TWINE_PASSWORD: ${{ secrets.TEST_PYPI_TOKEN }} + TWINE_PASSWORD: ${{ secrets.PYPI_TOKEN }} + - name: Create tag + run: | + git tag -a -m "version $(python setup.py --version)" v$(python setup.py --version) + git push --follow-tags # to do: # - add release notes in github From 8547c9aed87e71632e2fd96068454d23e3fbe144 Mon Sep 17 00:00:00 2001 From: David Glick Date: Mon, 16 Mar 2020 15:19:01 -0400 Subject: [PATCH 15/18] Restore homebrew script to use production PyPI --- utility/build-homebrew.sh | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/utility/build-homebrew.sh b/utility/build-homebrew.sh index cec4bcd381..7fb4fe0972 100755 --- a/utility/build-homebrew.sh +++ b/utility/build-homebrew.sh @@ -9,8 +9,7 @@ PYPI_JSON="$(mktemp)" || exit 1 echo " " echo "=> Collecting package info from PyPI..." echo " " -#curl -L "https://pypi.io/pypi/cumulusci/json" > "$PYPI_JSON" || exit 1 -curl -L "https://test.pypi.org/pypi/cumulusci/json" > "$PYPI_JSON" || exit 1 +curl -L "https://pypi.io/pypi/cumulusci/json" > "$PYPI_JSON" || exit 1 PACKAGE_URL="$(cat "$PYPI_JSON" | jq '.urls[1].url')" || exit 1 PACKAGE_SHA="$(cat "$PYPI_JSON" | jq '.urls[1].digests.sha256')" || exit 1 PACKAGE_VERSION="$(cat setup.cfg | grep current_version | head -n 1 | cut -f 3 -d' ')" || exit 1 @@ -18,10 +17,11 @@ PACKAGE_VERSION="$(cat setup.cfg | grep current_version | head -n 1 | cut -f 3 - echo " " echo "=> Creating a temporary virtualenv and installing CumulusCI..." echo " " +source deactivate python3.7 -m venv "$ENV_DIR" || exit 1 source "$ENV_DIR/bin/activate" || exit 1 pip install -U pip -pip install --no-cache-dir --extra-index-url https://test.pypi.org/simple/ cumulusci==$PACKAGE_VERSION homebrew-pypi-poet || exit 1 +pip install --no-cache-dir cumulusci==$PACKAGE_VERSION homebrew-pypi-poet || exit 1 echo " " echo "=> Collecting dependencies and generating resource stanzas..." From 4cd7803ded1ff3d4fd03e1a0e7d2b57d83bb8af5 Mon Sep 17 00:00:00 2001 From: David Glick Date: Mon, 16 Mar 2020 15:39:15 -0400 Subject: [PATCH 16/18] prepare 3.9.0 --- HISTORY.rst | 38 ++++++++++++++++++++ cumulusci/tasks/salesforce/update_profile.py | 6 ++-- cumulusci/version.txt | 2 +- docs/install.rst | 2 +- docs/tasks.rst | 2 +- 5 files changed, 44 insertions(+), 6 deletions(-) diff --git a/HISTORY.rst b/HISTORY.rst index a394c4958a..4b73738291 100644 --- a/HISTORY.rst +++ b/HISTORY.rst @@ -2,6 +2,44 @@ History ======= +3.9.0 (2020-03-16) +------------------ + +Critical changes: + +* The ``UpdateAdminProfile``/``UpdateProfile`` task has been revised to use the new Metadata ETL framework + as ``ProfileGrantAllAccess``. This is a breaking change for custom tasks which subclassed + ``UpdateAdminProfile``. The new task supports updating arbitrary Profiles in addition to + System Administrator. + +* Refactored how CumulusCI uses the Bulk API to load, extract, and delete data sets. + These changes should have no functional impact, but projects that subclass + CumulusCI's bulk data tasks should carefully review the changes. + +Changes: + +* New projects created using ``cci project init`` will now get set up with scratch org settings to: + + * Use the Enhanced Profile Editor + * Allow logging in as another user + * _not_ force relogin after Login-As + +* If ``cumulusci.yml`` contains non-breaking spaces in indentation, + they will be automatically converted to normal spaces. + +* Bulk data tasks: + + * Added improved validation that mapping files are in the expected format. + + * When using the ``ignore_row_errors`` option, warnings will be suppressed after the 10th row with errors. + +Issues closed: + +* The ``github_release`` task now validates the ``commit`` option to make sure it is in the right format. + +* If there is an error from ``sfdx`` while using the ``retrieve_changes`` task, it will now be logged. + + 3.8.0 (2020-02-28) ------------------ diff --git a/cumulusci/tasks/salesforce/update_profile.py b/cumulusci/tasks/salesforce/update_profile.py index a9160bc0a7..5553e8e36d 100644 --- a/cumulusci/tasks/salesforce/update_profile.py +++ b/cumulusci/tasks/salesforce/update_profile.py @@ -47,7 +47,7 @@ class ProfileGrantAllAccess(MetadataSingleEntityTransformTask): }, "include_packaged_objects": { "description": "Automatically include objects from all installed managed packages. " - "Defaults to True in projects that require CumulusCI 3.8.1 and greater that don't use a custom package.xml, otherwise False." + "Defaults to True in projects that require CumulusCI 3.9.0 and greater that don't use a custom package.xml, otherwise False." }, "api_names": {"description": "List of API names of Profiles to affect"}, } @@ -80,13 +80,13 @@ def _init_options(self, kwargs): # We enable new functionality to extend the package.xml to packaged objects # by default only if we meet specific requirements: the project has to require - # CumulusCI >= 3.8.1 (i.e., creation date or opt-in after release), and it must + # CumulusCI >= 3.9.0 (i.e., creation date or opt-in after release), and it must # not be using a custom `package.xml` min_cci_version = self.project_config.minimum_cumulusci_version if min_cci_version and "package_xml" not in self.options: parsed_version = pkg_resources.parse_version(min_cci_version) default_packages_arg = parsed_version >= pkg_resources.parse_version( - "3.8.1" + "3.9.0" ) else: default_packages_arg = False diff --git a/cumulusci/version.txt b/cumulusci/version.txt index 0be1fc7d24..b72ad011fa 100644 --- a/cumulusci/version.txt +++ b/cumulusci/version.txt @@ -1 +1 @@ -3.8.0 \ No newline at end of file +3.9.0 \ No newline at end of file diff --git a/docs/install.rst b/docs/install.rst index 2d1902c1aa..19bad64507 100644 --- a/docs/install.rst +++ b/docs/install.rst @@ -102,7 +102,7 @@ is installed correctly by running ``cci version``: .. code:: console $ cci version - CumulusCI version: 3.8.0 (/path/to/bin/cci) + CumulusCI version: 3.9.0 (/path/to/bin/cci) Python version: 3.7.4 (/path/to/bin/python) You have the latest version of CumulusCI. diff --git a/docs/tasks.rst b/docs/tasks.rst index 8263b25b27..5bf6b9d0ba 100644 --- a/docs/tasks.rst +++ b/docs/tasks.rst @@ -3063,7 +3063,7 @@ Options ``-o include_packaged_objects INCLUDEPACKAGEDOBJECTS`` *Optional* - Automatically include objects from all installed managed packages. Defaults to True in projects that require CumulusCI 3.8.1 and greater that don't use a custom package.xml, otherwise False. + Automatically include objects from all installed managed packages. Defaults to True in projects that require CumulusCI 3.9.0 and greater that don't use a custom package.xml, otherwise False. ``-o api_names APINAMES`` *Optional* From da340fed570da4e040631822e10db62b1d9a1267 Mon Sep 17 00:00:00 2001 From: David Glick Date: Mon, 16 Mar 2020 16:25:25 -0400 Subject: [PATCH 17/18] update where build-homebrew.sh gets the version --- utility/build-homebrew.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/utility/build-homebrew.sh b/utility/build-homebrew.sh index 7fb4fe0972..5dc2877d20 100755 --- a/utility/build-homebrew.sh +++ b/utility/build-homebrew.sh @@ -12,7 +12,7 @@ echo " " curl -L "https://pypi.io/pypi/cumulusci/json" > "$PYPI_JSON" || exit 1 PACKAGE_URL="$(cat "$PYPI_JSON" | jq '.urls[1].url')" || exit 1 PACKAGE_SHA="$(cat "$PYPI_JSON" | jq '.urls[1].digests.sha256')" || exit 1 -PACKAGE_VERSION="$(cat setup.cfg | grep current_version | head -n 1 | cut -f 3 -d' ')" || exit 1 +PACKAGE_VERSION="$(cat cumulusci/version.txt)" echo " " echo "=> Creating a temporary virtualenv and installing CumulusCI..." From 0feff34eff1b97e13e5d2ea087c3ff8abee4680f Mon Sep 17 00:00:00 2001 From: David Glick Date: Mon, 16 Mar 2020 16:42:45 -0400 Subject: [PATCH 18/18] revise release notes --- HISTORY.rst | 12 ++++++++---- 1 file changed, 8 insertions(+), 4 deletions(-) diff --git a/HISTORY.rst b/HISTORY.rst index 4b73738291..be69827b4d 100644 --- a/HISTORY.rst +++ b/HISTORY.rst @@ -7,10 +7,14 @@ History Critical changes: -* The ``UpdateAdminProfile``/``UpdateProfile`` task has been revised to use the new Metadata ETL framework - as ``ProfileGrantAllAccess``. This is a breaking change for custom tasks which subclassed - ``UpdateAdminProfile``. The new task supports updating arbitrary Profiles in addition to - System Administrator. +* The ``update_admin_profile`` task can now add field-level permissions for all packaged objects. + This behavior is the default for projects with ``minimum_cumulusci_version`` >= 3.9.0 that are + not using the ``package_xml`` option. Other projects can opt into it using the + ``include_packaged_objects`` option. + + The Python class used for this task has been renamed to ``ProfileGrantAllAccess`` and refactored + to use the Metadata ETL framework. This is a breaking change for custom tasks that subclassed + ``UpdateAdminProfile`` or ``UpdateProfile``. * Refactored how CumulusCI uses the Bulk API to load, extract, and delete data sets. These changes should have no functional impact, but projects that subclass