From 0bc30df703f6bd23d8ef6e8faff28bb18fe887be Mon Sep 17 00:00:00 2001 From: Vladimir Mazunin Date: Fri, 18 Jul 2025 17:03:22 +0400 Subject: [PATCH 1/7] changed version to m138 --- .github/workflows/build.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index b73ab3c..b4bf823 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -16,7 +16,7 @@ permissions: contents: write env: - version: m132-a00c390e98-1 + version: m138-cb3e25277c-1 jobs: macos: From c329cc633aa22a6f8e2e15a869e4884198adc43c Mon Sep 17 00:00:00 2001 From: Vladimir Mazunin Date: Fri, 18 Jul 2025 17:07:15 +0400 Subject: [PATCH 2/7] upd windows runner version to windows-2022 --- .github/workflows/build.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index b4bf823..3d6fef8 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -174,7 +174,7 @@ jobs: GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} windows: - runs-on: windows-2019 + runs-on: windows-2022 strategy: matrix: build_type: [Debug, Release] From 489e204fade932079d56ce55ef8377ce05df5f03 Mon Sep 17 00:00:00 2001 From: Vladimir Mazunin Date: Fri, 18 Jul 2025 17:29:57 +0400 Subject: [PATCH 3/7] upd Skia hash --- .github/workflows/build.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 3d6fef8..cde8ebd 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -16,7 +16,7 @@ permissions: contents: write env: - version: m138-cb3e25277c-1 + version: m138-32c6468cefb-1 jobs: macos: From 210d925b4555eb22aba37d8bcd80674415aab868 Mon Sep 17 00:00:00 2001 From: Vladimir Mazunin Date: Fri, 18 Jul 2025 17:35:58 +0400 Subject: [PATCH 4/7] upd Skia hash x2 --- .github/workflows/build.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index cde8ebd..c782610 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -16,7 +16,7 @@ permissions: contents: write env: - version: m138-32c6468cefb-1 + version: m138-9e6b5bff162-1 jobs: macos: From 2523462904db18f5c6bca82cac2c4597494f7905 Mon Sep 17 00:00:00 2001 From: Vladimir Mazunin Date: Fri, 18 Jul 2025 17:50:24 +0400 Subject: [PATCH 5/7] added retry to checkout dependencies --- script/checkout.py | 34 +++++++++++++++++++++++++++------- 1 file changed, 27 insertions(+), 7 deletions(-) diff --git a/script/checkout.py b/script/checkout.py index 6566313..5599a61 100755 --- a/script/checkout.py +++ b/script/checkout.py @@ -1,6 +1,6 @@ #! /usr/bin/env python3 -import common, os, re, subprocess, sys +import common, os, re, subprocess, sys, time def checkout_skia(commit): # Clone Skia @@ -21,6 +21,30 @@ def checkout_skia(commit): print("> Checking out", commit) subprocess.check_call(["git", "-c", "advice.detachedHead=false", "checkout", commit]) +def git_sync_with_retries(max_retries=3, backoff_seconds=5): + attempt = 0 + while True: + try: + print("> Running tools/git-sync-deps (attempt {}/{})".format(attempt+1, max_retries+1)) + # On Windows we need to disable HTTPS verify + if common.host() == 'windows': + env = os.environ.copy() + env['PYTHONHTTPSVERIFY'] = '0' + subprocess.check_call([sys.executable, "tools/git-sync-deps"], env=env) + else: + subprocess.check_call([sys.executable, "tools/git-sync-deps"]) + print("✔ Success") + break + except subprocess.CalledProcessError as e: + attempt += 1 + if attempt > max_retries: + print("✖ All {} retries failed. Giving up.".format(max_retries)) + raise + else: + wait = backoff_seconds * attempt + print(f"⚠️ Failed (exit {e.returncode}), retrying in {wait}s…") + time.sleep(wait) + def main(): os.chdir(os.path.join(os.path.dirname(__file__), os.pardir)) @@ -40,12 +64,8 @@ def main(): # git deps print("> Running tools/git-sync-deps") - if 'windows' == common.host(): - env = os.environ.copy() - env['PYTHONHTTPSVERIFY']='0' - subprocess.check_call(["python3", "tools/git-sync-deps"], env=env) - else: - subprocess.check_call(["python3", "tools/git-sync-deps"]) + # Trying to avoid 429 HTTP Error from Google repos + git_sync_with_retries() # fetch ninja print("> Fetching ninja") From 52df1235dceac088c996245d029ca43bae679ab9 Mon Sep 17 00:00:00 2001 From: Vladimir Mazunin Date: Fri, 18 Jul 2025 17:56:45 +0400 Subject: [PATCH 6/7] deleted unicode symbols --- script/checkout.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/script/checkout.py b/script/checkout.py index 5599a61..c10ae7b 100755 --- a/script/checkout.py +++ b/script/checkout.py @@ -33,16 +33,16 @@ def git_sync_with_retries(max_retries=3, backoff_seconds=5): subprocess.check_call([sys.executable, "tools/git-sync-deps"], env=env) else: subprocess.check_call([sys.executable, "tools/git-sync-deps"]) - print("✔ Success") + print("Success") break except subprocess.CalledProcessError as e: attempt += 1 if attempt > max_retries: - print("✖ All {} retries failed. Giving up.".format(max_retries)) + print("All {} retries failed. Giving up.".format(max_retries)) raise else: wait = backoff_seconds * attempt - print(f"⚠️ Failed (exit {e.returncode}), retrying in {wait}s…") + print(f"Failed (exit {e.returncode}), retrying in {wait}s…") time.sleep(wait) def main(): From f634487ca4d2370dfe55a59ad094e21e126c2dfb Mon Sep 17 00:00:00 2001 From: Vladimir Mazunin Date: Fri, 18 Jul 2025 20:00:13 +0400 Subject: [PATCH 7/7] updated README.md with new Skia version --- README.md | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/README.md b/README.md index a16c7d8..c69679d 100644 --- a/README.md +++ b/README.md @@ -15,18 +15,20 @@ Prebuilt binaries can be found [in releases](https://github.com/JetBrains/skia-p ## Building locally +Note: Better check build.yml for the detailed command for your machine + ```sh -python3 script/checkout.py --version m126-6fd3120c1b +python3 script/checkout.py --version m138-9e6b5bff162 python3 script/build.py -python3 script/archive.py --version m126-6fd3120c1b +python3 script/archive.py --version m138-9e6b5bff162 ``` To build a debug build: ```sh -python3 script/checkout.py --version m126-6fd3120c1b +python3 script/checkout.py --version m138-9e6b5bff162 python3 script/build.py --build-type Debug -python3 script/archive.py --version m126-6fd3120c1b --build-type Debug +python3 script/archive.py --version m138-9e6b5bff162 --build-type Debug ``` ### Windows-specific