alibuild 2.0.3__tar.gz → 2.0.5__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- {alibuild-2.0.3 → alibuild-2.0.5}/PKG-INFO +1 -1
- {alibuild-2.0.3 → alibuild-2.0.5}/alibuild.egg-info/PKG-INFO +1 -1
- {alibuild-2.0.3 → alibuild-2.0.5}/alibuild_helpers/_version.py +3 -3
- {alibuild-2.0.3 → alibuild-2.0.5}/alibuild_helpers/sync_reapi.py +10 -2
- {alibuild-2.0.3 → alibuild-2.0.5}/tests/test_sync_reapi.py +44 -0
- {alibuild-2.0.3 → alibuild-2.0.5}/.claude/skills/s3-conditional-writes/SKILL.md +0 -0
- {alibuild-2.0.3 → alibuild-2.0.5}/.claude/skills/support-architecture/SKILL.md +0 -0
- {alibuild-2.0.3 → alibuild-2.0.5}/.flake8 +0 -0
- {alibuild-2.0.3 → alibuild-2.0.5}/.github/dependabot.yml +0 -0
- {alibuild-2.0.3 → alibuild-2.0.5}/.github/workflows/documentation.yml +0 -0
- {alibuild-2.0.3 → alibuild-2.0.5}/.github/workflows/homebrew.yml +0 -0
- {alibuild-2.0.3 → alibuild-2.0.5}/.github/workflows/pr-check.yml +0 -0
- {alibuild-2.0.3 → alibuild-2.0.5}/.github/workflows/release.yml +0 -0
- {alibuild-2.0.3 → alibuild-2.0.5}/.gitignore +0 -0
- {alibuild-2.0.3 → alibuild-2.0.5}/.pylintrc +0 -0
- {alibuild-2.0.3 → alibuild-2.0.5}/ANALYTICS.md +0 -0
- {alibuild-2.0.3 → alibuild-2.0.5}/DESIGN.md +0 -0
- {alibuild-2.0.3 → alibuild-2.0.5}/LICENSE.md +0 -0
- {alibuild-2.0.3 → alibuild-2.0.5}/PACKAGING.md +0 -0
- {alibuild-2.0.3 → alibuild-2.0.5}/README.rst +0 -0
- {alibuild-2.0.3 → alibuild-2.0.5}/REMOTE_STORE_CAS_AC.md +0 -0
- {alibuild-2.0.3 → alibuild-2.0.5}/alfaBuild +0 -0
- {alibuild-2.0.3 → alibuild-2.0.5}/aliBuild +0 -0
- {alibuild-2.0.3 → alibuild-2.0.5}/aliDeps +0 -0
- {alibuild-2.0.3 → alibuild-2.0.5}/aliDoctor +0 -0
- {alibuild-2.0.3 → alibuild-2.0.5}/alibuild.egg-info/SOURCES.txt +0 -0
- {alibuild-2.0.3 → alibuild-2.0.5}/alibuild.egg-info/dependency_links.txt +0 -0
- {alibuild-2.0.3 → alibuild-2.0.5}/alibuild.egg-info/requires.txt +0 -0
- {alibuild-2.0.3 → alibuild-2.0.5}/alibuild.egg-info/top_level.txt +0 -0
- {alibuild-2.0.3 → alibuild-2.0.5}/alibuild_helpers/__init__.py +0 -0
- {alibuild-2.0.3 → alibuild-2.0.5}/alibuild_helpers/analytics.py +0 -0
- {alibuild-2.0.3 → alibuild-2.0.5}/alibuild_helpers/args.py +0 -0
- {alibuild-2.0.3 → alibuild-2.0.5}/alibuild_helpers/build.py +0 -0
- {alibuild-2.0.3 → alibuild-2.0.5}/alibuild_helpers/build_template.sh +0 -0
- {alibuild-2.0.3 → alibuild-2.0.5}/alibuild_helpers/clean.py +0 -0
- {alibuild-2.0.3 → alibuild-2.0.5}/alibuild_helpers/cmd.py +0 -0
- {alibuild-2.0.3 → alibuild-2.0.5}/alibuild_helpers/completion.py +0 -0
- {alibuild-2.0.3 → alibuild-2.0.5}/alibuild_helpers/completions/__init__.py +0 -0
- {alibuild-2.0.3 → alibuild-2.0.5}/alibuild_helpers/completions/bash.sh +0 -0
- {alibuild-2.0.3 → alibuild-2.0.5}/alibuild_helpers/completions/zsh.sh +0 -0
- {alibuild-2.0.3 → alibuild-2.0.5}/alibuild_helpers/deps.py +0 -0
- {alibuild-2.0.3 → alibuild-2.0.5}/alibuild_helpers/doctor.py +0 -0
- {alibuild-2.0.3 → alibuild-2.0.5}/alibuild_helpers/git.py +0 -0
- {alibuild-2.0.3 → alibuild-2.0.5}/alibuild_helpers/init.py +0 -0
- {alibuild-2.0.3 → alibuild-2.0.5}/alibuild_helpers/install.py +0 -0
- {alibuild-2.0.3 → alibuild-2.0.5}/alibuild_helpers/keyring.json +0 -0
- {alibuild-2.0.3 → alibuild-2.0.5}/alibuild_helpers/log.py +0 -0
- {alibuild-2.0.3 → alibuild-2.0.5}/alibuild_helpers/migrate.py +0 -0
- {alibuild-2.0.3 → alibuild-2.0.5}/alibuild_helpers/reconstruct.py +0 -0
- {alibuild-2.0.3 → alibuild-2.0.5}/alibuild_helpers/sandbox.py +0 -0
- {alibuild-2.0.3 → alibuild-2.0.5}/alibuild_helpers/scm.py +0 -0
- {alibuild-2.0.3 → alibuild-2.0.5}/alibuild_helpers/signing.py +0 -0
- {alibuild-2.0.3 → alibuild-2.0.5}/alibuild_helpers/sl.py +0 -0
- {alibuild-2.0.3 → alibuild-2.0.5}/alibuild_helpers/source.py +0 -0
- {alibuild-2.0.3 → alibuild-2.0.5}/alibuild_helpers/sync.py +0 -0
- {alibuild-2.0.3 → alibuild-2.0.5}/alibuild_helpers/templating_plugin.py +0 -0
- {alibuild-2.0.3 → alibuild-2.0.5}/alibuild_helpers/utilities.py +0 -0
- {alibuild-2.0.3 → alibuild-2.0.5}/alibuild_helpers/workarea.py +0 -0
- {alibuild-2.0.3 → alibuild-2.0.5}/alienv +0 -0
- {alibuild-2.0.3 → alibuild-2.0.5}/codecov.yml +0 -0
- {alibuild-2.0.3 → alibuild-2.0.5}/debian/changelog +0 -0
- {alibuild-2.0.3 → alibuild-2.0.5}/debian/compat +0 -0
- {alibuild-2.0.3 → alibuild-2.0.5}/debian/control +0 -0
- {alibuild-2.0.3 → alibuild-2.0.5}/debian/copyright +0 -0
- {alibuild-2.0.3 → alibuild-2.0.5}/debian/files +0 -0
- {alibuild-2.0.3 → alibuild-2.0.5}/debian/rules +0 -0
- {alibuild-2.0.3 → alibuild-2.0.5}/docs/SUPPORT +0 -0
- {alibuild-2.0.3 → alibuild-2.0.5}/docs/docs/alice_logo.png +0 -0
- {alibuild-2.0.3 → alibuild-2.0.5}/docs/docs/deps.png +0 -0
- {alibuild-2.0.3 → alibuild-2.0.5}/docs/docs/index.md +0 -0
- {alibuild-2.0.3 → alibuild-2.0.5}/docs/docs/quick.md +0 -0
- {alibuild-2.0.3 → alibuild-2.0.5}/docs/docs/reference.md +0 -0
- {alibuild-2.0.3 → alibuild-2.0.5}/docs/docs/stylesheets/extra.css +0 -0
- {alibuild-2.0.3 → alibuild-2.0.5}/docs/docs/troubleshooting.md +0 -0
- {alibuild-2.0.3 → alibuild-2.0.5}/docs/docs/user.md +0 -0
- {alibuild-2.0.3 → alibuild-2.0.5}/docs/mkdocs.yml +0 -0
- {alibuild-2.0.3 → alibuild-2.0.5}/extras/nix/alibuild_nix.jnj +0 -0
- {alibuild-2.0.3 → alibuild-2.0.5}/extras/nix/alidist-aliphysics.nix +0 -0
- {alibuild-2.0.3 → alibuild-2.0.5}/extras/nix/alidist-helpers.nix +0 -0
- {alibuild-2.0.3 → alibuild-2.0.5}/extras/nix/alidist.nix +0 -0
- {alibuild-2.0.3 → alibuild-2.0.5}/extras/nix/flake.lock +0 -0
- {alibuild-2.0.3 → alibuild-2.0.5}/extras/nix/flake.nix +0 -0
- {alibuild-2.0.3 → alibuild-2.0.5}/extras/nix/hyperloop.nix +0 -0
- {alibuild-2.0.3 → alibuild-2.0.5}/extras/nix/hyperloopTest.nix +0 -0
- {alibuild-2.0.3 → alibuild-2.0.5}/extras/nix/nix-interactive.bash +0 -0
- {alibuild-2.0.3 → alibuild-2.0.5}/extras/nix/update-envs.sh +0 -0
- {alibuild-2.0.3 → alibuild-2.0.5}/pb +0 -0
- {alibuild-2.0.3 → alibuild-2.0.5}/pyproject.toml +0 -0
- {alibuild-2.0.3 → alibuild-2.0.5}/requirements.txt +0 -0
- {alibuild-2.0.3 → alibuild-2.0.5}/setup.cfg +0 -0
- {alibuild-2.0.3 → alibuild-2.0.5}/setup.py +0 -0
- {alibuild-2.0.3 → alibuild-2.0.5}/templates/alibuild_nix.jnj +0 -0
- {alibuild-2.0.3 → alibuild-2.0.5}/templates/alibuild_to_please.jnj +0 -0
- {alibuild-2.0.3 → alibuild-2.0.5}/tests/test_analytics.py +0 -0
- {alibuild-2.0.3 → alibuild-2.0.5}/tests/test_args.py +0 -0
- {alibuild-2.0.3 → alibuild-2.0.5}/tests/test_build.py +0 -0
- {alibuild-2.0.3 → alibuild-2.0.5}/tests/test_clean.py +0 -0
- {alibuild-2.0.3 → alibuild-2.0.5}/tests/test_cmd.py +0 -0
- {alibuild-2.0.3 → alibuild-2.0.5}/tests/test_completion.py +0 -0
- {alibuild-2.0.3 → alibuild-2.0.5}/tests/test_deps.py +0 -0
- {alibuild-2.0.3 → alibuild-2.0.5}/tests/test_doctor.py +0 -0
- {alibuild-2.0.3 → alibuild-2.0.5}/tests/test_git.py +0 -0
- {alibuild-2.0.3 → alibuild-2.0.5}/tests/test_hashing.py +0 -0
- {alibuild-2.0.3 → alibuild-2.0.5}/tests/test_init.py +0 -0
- {alibuild-2.0.3 → alibuild-2.0.5}/tests/test_install.py +0 -0
- {alibuild-2.0.3 → alibuild-2.0.5}/tests/test_log.py +0 -0
- {alibuild-2.0.3 → alibuild-2.0.5}/tests/test_migrate.py +0 -0
- {alibuild-2.0.3 → alibuild-2.0.5}/tests/test_packagelist.py +0 -0
- {alibuild-2.0.3 → alibuild-2.0.5}/tests/test_parseRecipe.py +0 -0
- {alibuild-2.0.3 → alibuild-2.0.5}/tests/test_reconstruct.py +0 -0
- {alibuild-2.0.3 → alibuild-2.0.5}/tests/test_sandbox.py +0 -0
- {alibuild-2.0.3 → alibuild-2.0.5}/tests/test_signing.py +0 -0
- {alibuild-2.0.3 → alibuild-2.0.5}/tests/test_source.py +0 -0
- {alibuild-2.0.3 → alibuild-2.0.5}/tests/test_sync.py +0 -0
- {alibuild-2.0.3 → alibuild-2.0.5}/tests/test_utilities.py +0 -0
- {alibuild-2.0.3 → alibuild-2.0.5}/tests/test_workarea.py +0 -0
- {alibuild-2.0.3 → alibuild-2.0.5}/tests/testdist/broken1.sh +0 -0
- {alibuild-2.0.3 → alibuild-2.0.5}/tests/testdist/broken2.sh +0 -0
- {alibuild-2.0.3 → alibuild-2.0.5}/tests/testdist/broken3.sh +0 -0
- {alibuild-2.0.3 → alibuild-2.0.5}/tests/testdist/broken4.sh +0 -0
- {alibuild-2.0.3 → alibuild-2.0.5}/tests/testdist/broken5.sh +0 -0
- {alibuild-2.0.3 → alibuild-2.0.5}/tests/testdist/broken6.sh +0 -0
- {alibuild-2.0.3 → alibuild-2.0.5}/tests/testdist/broken7.sh +0 -0
- {alibuild-2.0.3 → alibuild-2.0.5}/tests/testdist/clobber-initdotsh.sh +0 -0
- {alibuild-2.0.3 → alibuild-2.0.5}/tests/testdist/defaults-o2.sh +0 -0
- {alibuild-2.0.3 → alibuild-2.0.5}/tests/testdist/delete-etc.sh +0 -0
- {alibuild-2.0.3 → alibuild-2.0.5}/tests/testdist/tracking-env.sh +0 -0
- {alibuild-2.0.3 → alibuild-2.0.5}/tox.ini +0 -0
|
@@ -28,7 +28,7 @@ version_tuple: VERSION_TUPLE
|
|
|
28
28
|
commit_id: COMMIT_ID
|
|
29
29
|
__commit_id__: COMMIT_ID
|
|
30
30
|
|
|
31
|
-
__version__ = version = '2.0.
|
|
32
|
-
__version_tuple__ = version_tuple = (2, 0,
|
|
31
|
+
__version__ = version = '2.0.5'
|
|
32
|
+
__version_tuple__ = version_tuple = (2, 0, 5)
|
|
33
33
|
|
|
34
|
-
__commit_id__ = commit_id = '
|
|
34
|
+
__commit_id__ = commit_id = 'gb11291743'
|
|
@@ -363,7 +363,13 @@ class REAPIRemoteSync(Boto3RemoteSync):
|
|
|
363
363
|
The check has to happen before the base implementation writes anything: it
|
|
364
364
|
claims the per-package link and uploads the legacy symlinks *before* calling
|
|
365
365
|
_upload_tarball, so aborting from in there leaves a claimed link with no
|
|
366
|
-
artifact behind it for a later build to clean up.
|
|
366
|
+
artifact behind it for a later build to clean up.
|
|
367
|
+
|
|
368
|
+
A read-only store publishes nothing, so there is nothing to check either:
|
|
369
|
+
return before the ledger lookup, which needs the AC *write* bucket and would
|
|
370
|
+
otherwise fail on an empty bucket name (the base class returns early too)."""
|
|
371
|
+
if not self.writeStore:
|
|
372
|
+
return
|
|
367
373
|
ac_entry = spec.get("ac_entry")
|
|
368
374
|
if ac_entry:
|
|
369
375
|
self.assert_deps_in_ledger(ac_entry["action"])
|
|
@@ -604,7 +610,9 @@ class REAPIRemoteSync(Boto3RemoteSync):
|
|
|
604
610
|
"""Return the retention tag value of an object, or None if untagged/absent."""
|
|
605
611
|
from botocore.exceptions import ClientError
|
|
606
612
|
try:
|
|
607
|
-
|
|
613
|
+
# An untagged object (e.g. uploaded before retention tags existed)
|
|
614
|
+
# comes back from Ceph RGW without a TagSet at all, not an empty one.
|
|
615
|
+
tags = self.s3.get_object_tagging(Bucket=bucket, Key=key).get("TagSet", [])
|
|
608
616
|
except ClientError:
|
|
609
617
|
return None
|
|
610
618
|
return next((t["Value"] for t in tags if t["Key"] == self.RETENTION_TAG_KEY), None)
|
|
@@ -220,6 +220,31 @@ class REAPIRemoteSyncTestCase(unittest.TestCase):
|
|
|
220
220
|
self.assertEqual(client.upload_file.call_args.kwargs["Key"], cas_path)
|
|
221
221
|
self.assertEqual(bucket_of[store_key], "artifacts")
|
|
222
222
|
|
|
223
|
+
@patch("alibuild_helpers.sync_reapi.file_digest",
|
|
224
|
+
new=MagicMock(return_value=REAPI_CONTENT_HASH))
|
|
225
|
+
@patch("os.path.getsize", new=MagicMock(return_value=4096))
|
|
226
|
+
@patch("os.listdir",
|
|
227
|
+
new=lambda path: [tarball_name(REAPI_SPEC)] if path.endswith("-1") else [])
|
|
228
|
+
@patch("os.readlink", new=MagicMock(return_value="../../store/de/dead/x.tar.gz"))
|
|
229
|
+
@patch("os.path.islink", new=MagicMock(return_value=True))
|
|
230
|
+
def test_upload_read_only_store_is_a_noop_with_deps(self) -> None:
|
|
231
|
+
# A read-only store (e.g. the isolated rebuild of `aliBuild reconstruct`)
|
|
232
|
+
# must not run the ledger check: it has no AC write bucket, and looking a
|
|
233
|
+
# dependency up in "" raised ParamValidationError for every package with
|
|
234
|
+
# dependencies.
|
|
235
|
+
client = self.make_client()
|
|
236
|
+
reapi = sync_reapi.REAPIRemoteSync(
|
|
237
|
+
remoteStore="reapi://localhost/bucket", writeStore="",
|
|
238
|
+
architecture=ARCHITECTURE, workdir="/sw")
|
|
239
|
+
reapi.s3 = client
|
|
240
|
+
spec = json.loads(json.dumps(REAPI_SPEC))
|
|
241
|
+
spec["ac_entry"]["action"]["deps"] = [
|
|
242
|
+
{"actionHash": "0" * 40, "package": "dep"}]
|
|
243
|
+
reapi.upload_symlinks_and_tarball(spec)
|
|
244
|
+
client.head_object.assert_not_called()
|
|
245
|
+
client.put_object.assert_not_called()
|
|
246
|
+
client.upload_file.assert_not_called()
|
|
247
|
+
|
|
223
248
|
@patch("alibuild_helpers.sync_reapi.file_digest",
|
|
224
249
|
new=MagicMock(return_value=REAPI_CONTENT_HASH))
|
|
225
250
|
@patch("os.path.getsize", new=MagicMock(return_value=4096))
|
|
@@ -671,6 +696,25 @@ class REAPIRemoteSyncTestCase(unittest.TestCase):
|
|
|
671
696
|
reapi.download_artifact(REAPI_CONTENT_HASH, "/tmp/x")
|
|
672
697
|
client.copy_object.assert_not_called() # fresh (10d < 60d), no refresh
|
|
673
698
|
|
|
699
|
+
@patch("os.path.exists", new=MagicMock(return_value=False))
|
|
700
|
+
def test_download_old_untagged_blob(self) -> None:
|
|
701
|
+
# A blob from before retention tags: Ceph RGW answers GetObjectTagging
|
|
702
|
+
# with no TagSet at all. That must read as "untagged" (no refresh),
|
|
703
|
+
# not crash the build with KeyError.
|
|
704
|
+
from datetime import datetime, timezone, timedelta
|
|
705
|
+
client = self.make_client()
|
|
706
|
+
client.get_object_tagging = MagicMock(return_value={"ResponseMetadata": {}})
|
|
707
|
+
client.head_object = MagicMock(
|
|
708
|
+
return_value={"LastModified": datetime.now(timezone.utc) - timedelta(days=400)})
|
|
709
|
+
client.copy_object = MagicMock()
|
|
710
|
+
reapi = sync_reapi.REAPIRemoteSync("reapi://localhost/bucket", "reapi://localhost/bucket",
|
|
711
|
+
architecture=ARCHITECTURE, workdir="/sw",
|
|
712
|
+
storage="ephemeral")
|
|
713
|
+
reapi.s3 = client
|
|
714
|
+
self.assertIsNone(reapi._retention_of("bucket", "key"))
|
|
715
|
+
reapi.download_artifact(REAPI_CONTENT_HASH, "/tmp/x")
|
|
716
|
+
client.copy_object.assert_not_called()
|
|
717
|
+
|
|
674
718
|
@patch("glob.glob", new=MagicMock(return_value=[]))
|
|
675
719
|
@patch("os.makedirs", new=MagicMock())
|
|
676
720
|
def test_fetch_via_action_cache(self) -> None:
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|