From de91521e3794267ef118e45ec40d8a5d646ea2a4 Mon Sep 17 00:00:00 2001 From: cvvergara Date: Sat, 12 Oct 2024 10:25:22 -0600 Subject: [PATCH 01/12] (C++) adding missing include to be fully compatible with C++13 (cherry picked from commit c5cb8f9cc9da57e2dd23d901ee75e9743af6e562) --- include/cpp_common/rule.hpp | 1 + 1 file changed, 1 insertion(+) diff --git a/include/cpp_common/rule.hpp b/include/cpp_common/rule.hpp index 29d414291d..97e45aad5b 100644 --- a/include/cpp_common/rule.hpp +++ b/include/cpp_common/rule.hpp @@ -28,6 +28,7 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. #include #include +#include typedef struct Restriction_t Restriction_t; From d474cbd4cbee7b5ce762c0a56588aacc3da9d20f Mon Sep 17 00:00:00 2001 From: cvvergara Date: Sat, 12 Oct 2024 10:50:32 -0600 Subject: [PATCH 02/12] (doc) documenting changes (cherry picked from commit 4dc28137efa98f11df6cde34646bfa3486e45140) --- NEWS.md | 2 ++ doc/src/release_notes.rst | 2 ++ 2 files changed, 4 insertions(+) diff --git a/NEWS.md b/NEWS.md index feb7c7789b..4e7ec2b817 100644 --- a/NEWS.md +++ b/NEWS.md @@ -83,6 +83,8 @@ milestone for 3.6.3 * postgres 11.0.0 * postgis 3.0.0 +* g++ 13+ is supported + **Code fixes** * Fix warnings from cpplint. diff --git a/doc/src/release_notes.rst b/doc/src/release_notes.rst index ff53e86be6..3fac319973 100644 --- a/doc/src/release_notes.rst +++ b/doc/src/release_notes.rst @@ -116,6 +116,8 @@ milestone for 3.6.3 * postgres 11.0.0 * postgis 3.0.0 +* g++ 13+ is supported + .. rubric:: Code fixes * Fix warnings from cpplint. From e5fb8499ecbe7fd7230d344d51ecd4c0d0aa7c9f Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Fri, 27 Oct 2023 15:59:12 +0000 Subject: [PATCH 03/12] Bump actions/checkout from 3 to 4 Bumps [actions/checkout](https://github.com/actions/checkout) from 3 to 4. - [Release notes](https://github.com/actions/checkout/releases) - [Changelog](https://github.com/actions/checkout/blob/main/CHANGELOG.md) - [Commits](https://github.com/actions/checkout/compare/v3...v4) --- updated-dependencies: - dependency-name: actions/checkout dependency-type: direct:production update-type: version-update:semver-major ... Signed-off-by: dependabot[bot] (cherry picked from commit c89addc82c8e78581a31f2ec1a7c1947733b429b) --- .github/workflows/centos.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/centos.yml b/.github/workflows/centos.yml index 497209954b..d7adcf5ad6 100644 --- a/.github/workflows/centos.yml +++ b/.github/workflows/centos.yml @@ -32,7 +32,7 @@ jobs: - centos-7 gcc-4.8.5 steps: - - uses: actions/checkout@v3 + - uses: actions/checkout@v4 - name: get postgres version run: | From 332464054b489c5182ae2ebbdd301bc499a9fa32 Mon Sep 17 00:00:00 2001 From: cvvergara Date: Thu, 10 Oct 2024 09:50:38 -0600 Subject: [PATCH 04/12] (license test) fix docqueries license test --- tools/scripts/test_license.sh | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/tools/scripts/test_license.sh b/tools/scripts/test_license.sh index d0b8e9b13b..0bb937e1a6 100755 --- a/tools/scripts/test_license.sh +++ b/tools/scripts/test_license.sh @@ -25,13 +25,12 @@ mylicensecheck() { } DIR=$(git rev-parse --show-toplevel) - pushd "${DIR}" > /dev/null || exit -missing=$(! { mylicensecheck src & mylicensecheck sql & mylicensecheck include & mylicensecheck pgtap;} | grep "No copyright\|UNKNOWN") +{ mylicensecheck src & mylicensecheck sql & mylicensecheck include & mylicensecheck pgtap;} | grep "No copyright\|UNKNOWN" missing1=$(mylicensecheck doc | grep "No copyright") missing2=$(grep --files-without-match 'Creative Commons' doc/*/*.rst) missing3=$(mylicensecheck docqueries | grep "No copyright") -missing4=$(grep --files-without-match 'Creative Commons' "$(git ls-files docqueries | grep '.sql')") +missing4=$(grep --files-without-match 'Creative Commons' docqueries/*/*.sql) popd > /dev/null || exit #mylicensecheck doc From 48eba2aae0a87545668762d6bc51006712966e49 Mon Sep 17 00:00:00 2001 From: cvvergara Date: Sun, 13 Oct 2024 10:50:37 -0600 Subject: [PATCH 05/12] (license test) on docqueries Adjust to .pg extension --- tools/scripts/test_license.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tools/scripts/test_license.sh b/tools/scripts/test_license.sh index 0bb937e1a6..c4c0e7553f 100755 --- a/tools/scripts/test_license.sh +++ b/tools/scripts/test_license.sh @@ -30,7 +30,7 @@ pushd "${DIR}" > /dev/null || exit missing1=$(mylicensecheck doc | grep "No copyright") missing2=$(grep --files-without-match 'Creative Commons' doc/*/*.rst) missing3=$(mylicensecheck docqueries | grep "No copyright") -missing4=$(grep --files-without-match 'Creative Commons' docqueries/*/*.sql) +missing4=$(grep --files-without-match 'Creative Commons' docqueries/*/*.pg) popd > /dev/null || exit #mylicensecheck doc From 0a6d80acf192925d0b4294fbe37adb042d647b4c Mon Sep 17 00:00:00 2001 From: cvvergara Date: Wed, 9 Oct 2024 09:34:38 -0600 Subject: [PATCH 06/12] (clan-tidy) fix script not finding postgres.h --- .github/scripts/tidy-vs-commit.sh | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/scripts/tidy-vs-commit.sh b/.github/scripts/tidy-vs-commit.sh index 2b0db9f07b..ae8328a74a 100755 --- a/.github/scripts/tidy-vs-commit.sh +++ b/.github/scripts/tidy-vs-commit.sh @@ -6,7 +6,7 @@ readonly BUILD_DIR=build MODIFIED_FILES=$(git diff-tree --no-commit-id --diff-filter=d --name-only -r "$BASE" HEAD | grep '\.c') MODIFIED_HEADERS=$(git diff-tree --no-commit-id --diff-filter=d --name-only -r "$BASE" HEAD | grep '\.h') -POSTGRES_SERVER=$(grep -o -m1 '\-isystem .*' "${BUILD_DIR}/compile_commands.json" | head -1 | awk '{print $1" "$2}') +POSTGRES_SERVER=$(grep -o -m1 '\-isystem .*' "${BUILD_DIR}/compile_commands.json" | head -1 | awk '{print $2}') echo "POSTGRES_SERVER ${POSTGRES_SERVER}" @@ -34,6 +34,6 @@ if [ ${#MODIFIED_HEADERS[@]} != 0 ] ; then do echo "${f}" clang-tidy "${CHECKS}" -header-filter=.* "${f}" \ - -- -I./include "${POSTGRES_SERVER}" + -- -I./include -isystem "${POSTGRES_SERVER}" done fi From 73a3f277b79296c1635d374a6e546b1f800c5d46 Mon Sep 17 00:00:00 2001 From: Ashish Kumar Date: Wed, 16 Oct 2024 16:40:06 +0200 Subject: [PATCH 07/12] Update release actions --- .github/workflows/release.yml | 56 ++++++++++++----------------------- 1 file changed, 19 insertions(+), 37 deletions(-) diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index f4c79c9b65..0048a62fd3 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -1,10 +1,7 @@ name: Release on: - push: - tags: - - 'v*.*.*' - + workflow_dispatch: permissions: contents: read @@ -25,6 +22,11 @@ jobs: with: fetch-depth: 0 + - name: Initialize mandatory git config + run: | + git config user.name "github-actions[bot]" + git config user.email "41898282+github-actions[bot]@users.noreply.github.com" + - name: Get postgres version run: | sudo service postgresql start @@ -34,17 +36,14 @@ jobs: echo "PGPORT=5432" >> $GITHUB_ENV echo "PGIS=3" >> $GITHUB_ENV echo "PGROUTING_VERSION=${PGROUTING_VERSION}" >> $GITHUB_ENV + echo "TAG_NAME=v${PGROUTING_VERSION}" >> $GITHUB_ENV - - name: Verify Tag Name + - name: Create and Push Tag run: | - TAG_NAME=${GITHUB_REF#refs/*/} - echo "TAG_NAME=${TAG_NAME}" >> $GITHUB_ENV - echo ${TAG_NAME} - echo ${PGROUTING_VERSION} - if [ "${TAG_NAME}" != "v${PGROUTING_VERSION}" ]; then - echo "Tag name should be v${PGROUTING_VERSION}" - exit 1 - fi + git tag -a "${TAG_NAME}" -m "Release version ${TAG_NAME}" + git push origin "${TAG_NAME}" + env: + GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} - name: Extract branch name and commit hash run: | @@ -62,7 +61,7 @@ jobs: $(lsb_release -cs)-pgdg main" > /etc/apt/sources.list.d/pgdg.list' - name: Install python - uses: actions/setup-python@v4 + uses: actions/setup-python@v5 with: python-version: '3.x' @@ -87,7 +86,8 @@ jobs: export PATH=/usr/lib/postgresql/${PGVER}/bin:$PATH mkdir build cd build - cmake -DPOSTGRESQL_VERSION=${PGVER} -DDOC_USE_BOOTSTRAP=ON -DWITH_DOC=ON -DBUILD_DOXY=ON -DCMAKE_BUILD_TYPE=Release -DES=ON .. + cmake -DPOSTGRESQL_VERSION=${PGVER} -DDOC_USE_BOOTSTRAP=ON -DWITH_DOC=ON -DBUILD_DOXY=ON -DCMAKE_BUILD_TYPE=Release \ + -DES=ON -DZH_HANS=ON .. - name: Build run: | @@ -97,11 +97,6 @@ jobs: sudo make install make doxy - - name: Initialize mandatory git config - run: | - git config user.name "github-actions[bot]" - git config user.email "41898282+github-actions[bot]@users.noreply.github.com" - - name: Update Users Documentation run: | git checkout origin/gh-pages @@ -140,26 +135,15 @@ jobs: run: | cd build/doc - cp -r html doc-v${PGROUTING_VERSION}-en-es - tar -zcvf doc-v${PGROUTING_VERSION}-en-es.tar.gz doc-v${PGROUTING_VERSION}-en-es - - cp -r html doc-v${PGROUTING_VERSION}-en - rm -rf doc-v${PGROUTING_VERSION}-en/es - tar -zcvf doc-v${PGROUTING_VERSION}-en.tar.gz doc-v${PGROUTING_VERSION}-en - - cp -r html doc-v${PGROUTING_VERSION}-es - rm -rf doc-v${PGROUTING_VERSION}-es/en - perl -pi -e 's/en\/index.html/es\/index.html/g' doc-v${PGROUTING_VERSION}-es/index.html - tar -zcvf doc-v${PGROUTING_VERSION}-es.tar.gz doc-v${PGROUTING_VERSION}-es + cp -r html doc-v${PGROUTING_VERSION} + tar -zcvf doc-v${PGROUTING_VERSION}.tar.gz doc-v${PGROUTING_VERSION} cd ../.. grep -Pzo "(?s)pgRouting ${PGROUTING_VERSION//./\\.} Release Notes.*?(?=pgRouting .\..\.. Release Notes)" NEWS.md | tr '\0' '\n' > release_body.txt echo "**Attachments**" >> release_body.txt echo "File | Contents" >> release_body.txt echo "| --- | --- |" >> release_body.txt - echo "| \`doc-v${PGROUTING_VERSION}-en-es.tar.gz\` | English and Spanish documentation. Redirection to English" >> release_body.txt - echo "| \`doc-v${PGROUTING_VERSION}-en.tar.gz\`|English documentation. Redirection to English" >> release_body.txt - echo "| \`doc-v${PGROUTING_VERSION}-es.tar.gz\`|Spanish documentation. Redirection to Spanish" >> release_body.txt + echo "| \`doc-v${PGROUTING_VERSION}tar.gz\` | English and Spanish documentation. Redirection to English" >> release_body.txt echo "| \`pgrouting-${PGROUTING_VERSION}.tar.gz\` | tar.gz of the release" >> release_body.txt echo "| \`pgrouting-${PGROUTING_VERSION}.zip\`| zip of the release" >> release_body.txt cat release_body.txt @@ -172,9 +156,7 @@ jobs: draft: true prerelease: false files: | - build/doc/doc-v${{ env.PGROUTING_VERSION }}-en-es.tar.gz - build/doc/doc-v${{ env.PGROUTING_VERSION }}-en.tar.gz - build/doc/doc-v${{ env.PGROUTING_VERSION }}-es.tar.gz + build/doc/doc-v${{ env.PGROUTING_VERSION }}.tar.gz ${{ github.event.repository.name }}-${{ env.PGROUTING_VERSION }}.zip ${{ github.event.repository.name }}-${{ env.PGROUTING_VERSION }}.tar.gz From a9b338327e4b03eec2543f19ef5b1802ec5877f9 Mon Sep 17 00:00:00 2001 From: cvvergara Date: Sat, 12 Oct 2024 22:48:00 -0600 Subject: [PATCH 08/12] (CI) boost graph v0.86 has fixes in functions we use (cherry picked from commit 54bc91015dc041daab163a56272c64728b5faa73) --- .github/workflows/boost_version.yml | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/.github/workflows/boost_version.yml b/.github/workflows/boost_version.yml index c7a82760ba..b5c697698f 100644 --- a/.github/workflows/boost_version.yml +++ b/.github/workflows/boost_version.yml @@ -19,6 +19,7 @@ name: Boost supported versions # - boost::geometry has not changed anything we use # # boost::graph +# - 1.86 does not support C++11 (Aug 2024) # - 1.84 is failing its own tests (Jul 2022) # - 1.83 transitive closure & stoer wagner changed on 83 (Jul 2022) # - 1.80 changed on 1.80 (Aug 2022) @@ -69,7 +70,7 @@ jobs: strategy: fail-fast: false matrix: - boost_minor: [56, 68, 75, 76, 77, 78, 79, 80, 83, 84] + boost_minor: [56, 68, 75, 76, 77, 78, 79, 80, 83, 84, 86] steps: - uses: actions/checkout@v4 From ef3a5b6852467be2a915057bf6f0f7463b6006d7 Mon Sep 17 00:00:00 2001 From: cvvergara Date: Wed, 16 Oct 2024 12:33:08 -0600 Subject: [PATCH 09/12] (CI) Using python-v5 --- .github/workflows/doc-check.yml | 4 +--- .github/workflows/macos.yml | 2 +- .github/workflows/update-locale.yml | 2 +- .github/workflows/update.yml | 2 +- .github/workflows/website.yml | 2 +- 5 files changed, 5 insertions(+), 7 deletions(-) diff --git a/.github/workflows/doc-check.yml b/.github/workflows/doc-check.yml index 1c22de909c..7bf3f60a79 100644 --- a/.github/workflows/doc-check.yml +++ b/.github/workflows/doc-check.yml @@ -65,8 +65,6 @@ jobs: # allways processing english, no matter what the change was if [[ "${{ matrix.language }}" == "en" ]]; then echo "PROCESS=true" >> $GITHUB_ENV; exit 0; fi - # if [[ "${{ matrix.language }}" == "zh_Hans" && "${{ github.repository_owner }}" != "pgRouting" ]]; then echo "PROCESS=false" >> $GITHUB_ENV; exit 0; fi - # when this file changes all languages are tested if git diff --name-only HEAD^ HEAD | grep -q '.github/workflows/doc-check.yml' ; then echo "PROCESS=true" >> $GITHUB_ENV; exit 0; fi @@ -95,7 +93,7 @@ jobs: - name: Install python if: env.PROCESS == 'true' - uses: actions/setup-python@v4 + uses: actions/setup-python@v5 with: python-version: '3.x' diff --git a/.github/workflows/macos.yml b/.github/workflows/macos.yml index 95921e88fb..acff96fbaa 100644 --- a/.github/workflows/macos.yml +++ b/.github/workflows/macos.yml @@ -46,7 +46,7 @@ jobs: strategy: fail-fast: false matrix: - os: [macos-latest] + os: [macos-latest, macos-14] steps: - name: Checkout repository diff --git a/.github/workflows/update-locale.yml b/.github/workflows/update-locale.yml index efea648f01..9e93208483 100644 --- a/.github/workflows/update-locale.yml +++ b/.github/workflows/update-locale.yml @@ -55,7 +55,7 @@ jobs: $(lsb_release -cs)-pgdg main" > /etc/apt/sources.list.d/pgdg.list' - name: Install python - uses: actions/setup-python@v4 + uses: actions/setup-python@v5 with: python-version: '3.x' diff --git a/.github/workflows/update.yml b/.github/workflows/update.yml index 828b6937d2..aff82b1e59 100644 --- a/.github/workflows/update.yml +++ b/.github/workflows/update.yml @@ -55,7 +55,7 @@ jobs: $(lsb_release -cs)-pgdg main" > /etc/apt/sources.list.d/pgdg.list' - name: Install python - uses: actions/setup-python@v4 + uses: actions/setup-python@v5 with: python-version: '3.x' diff --git a/.github/workflows/website.yml b/.github/workflows/website.yml index e92f43c232..abcab337e1 100644 --- a/.github/workflows/website.yml +++ b/.github/workflows/website.yml @@ -57,7 +57,7 @@ jobs: $(lsb_release -cs)-pgdg main" > /etc/apt/sources.list.d/pgdg.list' - name: Install python - uses: actions/setup-python@v4 + uses: actions/setup-python@v5 with: python-version: '3.x' From ebcb173ca2ece2507b7859ca4be1267ba9965089 Mon Sep 17 00:00:00 2001 From: cvvergara Date: Sat, 12 Oct 2024 10:50:32 -0600 Subject: [PATCH 10/12] (CI/macos) Remove warning --- .github/workflows/macos.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/macos.yml b/.github/workflows/macos.yml index acff96fbaa..3e1fceedec 100644 --- a/.github/workflows/macos.yml +++ b/.github/workflows/macos.yml @@ -54,7 +54,7 @@ jobs: - name: install deps run: | - brew install postgresql postgis boost + brew install postgresql@14 postgis boost - name: Configure run: | From 5010dca6722e3bbcd34b1b891ad2075de8765a6e Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 14 Oct 2024 08:31:44 +0000 Subject: [PATCH 11/12] Bump softprops/action-gh-release from 1 to 2 Bumps [softprops/action-gh-release](https://github.com/softprops/action-gh-release) from 1 to 2. - [Release notes](https://github.com/softprops/action-gh-release/releases) - [Changelog](https://github.com/softprops/action-gh-release/blob/master/CHANGELOG.md) - [Commits](https://github.com/softprops/action-gh-release/compare/v1...v2) --- updated-dependencies: - dependency-name: softprops/action-gh-release dependency-type: direct:production update-type: version-update:semver-major ... Signed-off-by: dependabot[bot] (cherry picked from commit ac71b4efce47f26e4e942f4dcabca80e2404bc00) --- .github/workflows/release.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index 0048a62fd3..59ce4f79f0 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -149,7 +149,7 @@ jobs: cat release_body.txt - name: Create Draft Release - uses: softprops/action-gh-release@v1 + uses: softprops/action-gh-release@v2 with: body_path: release_body.txt name: ${{ env.TAG_NAME }} From 733203248831bd3be36f933b83c11a2326b48a54 Mon Sep 17 00:00:00 2001 From: cvvergara Date: Wed, 16 Oct 2024 13:31:33 -0600 Subject: [PATCH 12/12] (CI) dependabot to work also on develop --- .github/dependabot.yml | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/.github/dependabot.yml b/.github/dependabot.yml index 203f3c889b..afe66d47eb 100644 --- a/.github/dependabot.yml +++ b/.github/dependabot.yml @@ -4,3 +4,11 @@ updates: directory: "/" schedule: interval: "weekly" + target-branch: main + +#develop branch starts here +- package-ecosystem: "github-actions" + directory: "/" + schedule: + interval: "weekly" + target-branch: develop