@biffo/cli 0.272.2 → 0.272.4
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.
|
@@ -1,21 +1,30 @@
|
|
|
1
1
|
terraform {
|
|
2
2
|
required_providers {
|
|
3
|
-
aws
|
|
4
|
-
archive = { source = "hashicorp/archive", version = "~> 2.0" }
|
|
3
|
+
aws = { source = "hashicorp/aws", version = "~> 5.0" }
|
|
5
4
|
}
|
|
6
5
|
}
|
|
7
6
|
|
|
8
|
-
# Minimal placeholder zip —
|
|
9
|
-
#
|
|
10
|
-
#
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
7
|
+
# Minimal placeholder zip — a COMMITTED file, deliberately not generated.
|
|
8
|
+
#
|
|
9
|
+
# It exists only so the Lambda resource can be created on first apply; the
|
|
10
|
+
# CI/CD pipeline overwrites the function code on every deploy and this resource
|
|
11
|
+
# ignores changes to it thereafter.
|
|
12
|
+
#
|
|
13
|
+
# It used to be produced by a `data "archive_file"` writing to
|
|
14
|
+
# ${path.module}/placeholder.zip. That is evaluated at PLAN time, and
|
|
15
|
+
# deploy-infra.yml runs plan and apply as separate jobs on separate self-hosted
|
|
16
|
+
# runners, transporting only `tfplan`. So the file existed on the plan runner
|
|
17
|
+
# and not on the apply runner, and creating a Lambda failed with
|
|
18
|
+
# "reading ZIP file ...: no such file or directory" — see #1457.
|
|
19
|
+
#
|
|
20
|
+
# It survived a long time because it bites ONLY a function being created: an
|
|
21
|
+
# existing one is unchanged, so `filename` is never re-read. Every routine
|
|
22
|
+
# deploy was green. It was also intermittent, because two jobs landing on the
|
|
23
|
+
# same runner share that runner's checkout — which makes a re-run look like a
|
|
24
|
+
# fix and teaches exactly the wrong lesson.
|
|
25
|
+
#
|
|
26
|
+
# Committing the bytes removes the plan/apply coupling rather than transporting
|
|
27
|
+
# it. The contents are irrelevant, so generating them bought nothing.
|
|
19
28
|
|
|
20
29
|
locals {
|
|
21
30
|
name_prefix = "${var.project_name}-${var.environment}"
|
|
@@ -113,8 +122,8 @@ resource "aws_lambda_function" "main" {
|
|
|
113
122
|
memory_size = var.memory_size
|
|
114
123
|
timeout = var.timeout
|
|
115
124
|
|
|
116
|
-
filename =
|
|
117
|
-
source_code_hash =
|
|
125
|
+
filename = "${path.module}/placeholder.zip"
|
|
126
|
+
source_code_hash = filebase64sha256("${path.module}/placeholder.zip")
|
|
118
127
|
|
|
119
128
|
dead_letter_config {
|
|
120
129
|
target_arn = aws_sqs_queue.dlq.arn
|
package/package.json
CHANGED
package/scripts/verify.sh
CHANGED
|
@@ -746,10 +746,20 @@ pg_test_run() {
|
|
|
746
746
|
timeout "$PG_TEST_BUDGET_SECONDS" uv run --directory "$1" \
|
|
747
747
|
pytest -q -m 'not serial' -n auto --dist loadfile $2 >"$_out" 2>&1
|
|
748
748
|
_pg_rc=$?
|
|
749
|
+
# pytest exits 5 when `-m 'not serial'` matches nothing -- correct when
|
|
750
|
+
# every currently-collected pg module happens to be serial-only (a repo's
|
|
751
|
+
# first test_*_pg.py file can legitimately start out that way; this repo
|
|
752
|
+
# hit it the moment its only pg module went 3-for-3 serial,
|
|
753
|
+
# biffo-template#1453). Symmetric with the identical exit-5 tolerance on
|
|
754
|
+
# the serial pass below: "nothing to run in THIS pass" is not "the lane
|
|
755
|
+
# failed", and treating it as a hard failure here would stop the serial
|
|
756
|
+
# pass -- which DOES have tests to run -- from ever executing.
|
|
757
|
+
[ "$_pg_rc" -eq 5 ] && _pg_rc=0
|
|
749
758
|
|
|
750
|
-
# Only if the parallel pass actually passed
|
|
751
|
-
#
|
|
752
|
-
#
|
|
759
|
+
# Only if the parallel pass actually passed (or had nothing to run, per
|
|
760
|
+
# the exit-5 tolerance above). A failure there is the answer already, and
|
|
761
|
+
# running the serial pass on top would append a second summary line that
|
|
762
|
+
# the "did it exercise anything" grep below would happily match.
|
|
753
763
|
if [ "$_pg_rc" -eq 0 ]; then
|
|
754
764
|
_pg_left=$((PG_TEST_BUDGET_SECONDS - ($(date +%s) - _pg_started)))
|
|
755
765
|
[ "$_pg_left" -lt 10 ] && _pg_left=10
|