Skip to content

Commit 35af003

Browse files
authored
Fix CI tests failing on MacOS ARM64 (#268)
Fixes #265 Github Actions started to run on MacOS ARM64. Neither "coverage" nor any other legacy dependency or library shipping platform-specific binaries support arm64 on python 3.3 As a result running CI tests on MacOS requires either explicitly requesting x64 platform or must not use platform-specific python 3.3 dependendencies/libraries. This commit therefore excludes coverage dependency on arm64 platforms for python 3.3 Changes: * Increase timeout for satisfying libraries * Fix error log of missing libraries * Exclude coverage from python 3.3 on arm64 platforms
1 parent 1469d6f commit 35af003

File tree

2 files changed

+23
-4
lines changed

2 files changed

+23
-4
lines changed

actions/setup/install_package_control_helper.py

Lines changed: 11 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,9 @@
55

66

77
def plugin_loaded():
8-
package_path = os.path.join(sublime.packages_path(), "0_install_package_control_helper")
8+
package_path = os.path.join(
9+
sublime.packages_path(), "0_install_package_control_helper"
10+
)
911

1012
logfile = os.path.join(package_path, "log")
1113

@@ -61,13 +63,19 @@ def check_libraries():
6163
if missing_libraries:
6264
nonlocal num_retries
6365

64-
if num_retries < 3:
66+
if num_retries < 10:
6567
num_retries += 1
6668
sublime.set_timeout(check_libraries, 2000)
6769
return
6870

6971
log.write("missing libraries:" + "\n")
70-
log.write(" ".join(sorted(missing_libraries)) + "\n")
72+
log.write(
73+
"\n".join(
74+
"- {lib.name} for Python {lib.python_version}".format(lib)
75+
for lib in sorted(missing_libraries)
76+
)
77+
+ "\n"
78+
)
7179
touch("failed")
7280
else:
7381
touch("success")

plugin.py

Lines changed: 12 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -62,7 +62,18 @@ class UnitTesting33Command(ut38.UnitTestingCommand):
6262

6363
try:
6464
with open(os.path.join(UT33, "dependencies.json"), "x") as f:
65-
f.write(json.dumps({"*": {">3000": ["coverage"]}}))
65+
f.write(
66+
json.dumps(
67+
{
68+
"linux-x32": {">3000": ["coverage"]},
69+
"linux-x64": {">3000": ["coverage"]},
70+
"osx-x32": {">3000": ["coverage"]},
71+
"osx-x32": {">3000": ["coverage"]},
72+
"windows-x32": {">3000": ["coverage"]},
73+
"windows-x64": {">3000": ["coverage"]},
74+
}
75+
)
76+
)
6677
except FileExistsError:
6778
pass
6879

0 commit comments

Comments
 (0)