diff --git a/.ots/.attestation-cache b/.ots/.attestation-cache index 36f6542..aa496dc 100644 --- a/.ots/.attestation-cache +++ b/.ots/.attestation-cache @@ -7,3 +7,11 @@ db6f29e01a33d8ed8f127ff169d9f91d55e8a229:pending:1772897641 c0685dabfb48360a3abc103b75357f94e9f054b2:pending:1772897657 810d26b7af9c5d306e77fec290d360c7ac876b2e:pending:1772897661 3b54e0cb8c611d3f3525ad2386368f60200891f1:pending:1772897667 +392ee723c3cf626d0e5281aa94771d7133bb345e:pending:1772897676 +db6f29e01a33d8ed8f127ff169d9f91d55e8a229:pending:1772897680 +4a6f5ed0c12315b0bc8a0fa5815ada1bd20e5963:pending:1772897683 +46aded7b9582bbed673843e2cf8a3f8fa742ad91:pending:1772897687 +c0685dabfb48360a3abc103b75357f94e9f054b2:pending:1772897691 +810d26b7af9c5d306e77fec290d360c7ac876b2e:pending:1772897694 +3b54e0cb8c611d3f3525ad2386368f60200891f1:pending:1772897698 +ed2cd259e918344c5a21ecf884b3178b4256ea74:pending:1772897704 diff --git a/.ots/commit-chain.txt b/.ots/commit-chain.txt index 4e07156..5c48dc5 100644 --- a/.ots/commit-chain.txt +++ b/.ots/commit-chain.txt @@ -20,3 +20,11 @@ c0685dabfb48360a3abc103b75357f94e9f054b2:46aded7b9582bbed673843e2cf8a3f8fa742ad9 4a6f5ed0c12315b0bc8a0fa5815ada1bd20e5963:db6f29e01a33d8ed8f127ff169d9f91d55e8a229 db6f29e01a33d8ed8f127ff169d9f91d55e8a229:392ee723c3cf626d0e5281aa94771d7133bb345e 392ee723c3cf626d0e5281aa94771d7133bb345e:392ee723c3cf626d0e5281aa94771d7133bb345e^1 +ed2cd259e918344c5a21ecf884b3178b4256ea74:3b54e0cb8c611d3f3525ad2386368f60200891f1 +3b54e0cb8c611d3f3525ad2386368f60200891f1:810d26b7af9c5d306e77fec290d360c7ac876b2e +810d26b7af9c5d306e77fec290d360c7ac876b2e:c0685dabfb48360a3abc103b75357f94e9f054b2 +c0685dabfb48360a3abc103b75357f94e9f054b2:46aded7b9582bbed673843e2cf8a3f8fa742ad91 +46aded7b9582bbed673843e2cf8a3f8fa742ad91:4a6f5ed0c12315b0bc8a0fa5815ada1bd20e5963 +4a6f5ed0c12315b0bc8a0fa5815ada1bd20e5963:db6f29e01a33d8ed8f127ff169d9f91d55e8a229 +db6f29e01a33d8ed8f127ff169d9f91d55e8a229:392ee723c3cf626d0e5281aa94771d7133bb345e +392ee723c3cf626d0e5281aa94771d7133bb345e:392ee723c3cf626d0e5281aa94771d7133bb345e^1 diff --git a/.ots/ed2cd259e918344c5a21ecf884b3178b4256ea74.ots b/.ots/ed2cd259e918344c5a21ecf884b3178b4256ea74.ots new file mode 100644 index 0000000..ac3398e Binary files /dev/null and b/.ots/ed2cd259e918344c5a21ecf884b3178b4256ea74.ots differ diff --git a/.ots/prev-commit.txt b/.ots/prev-commit.txt index 5d50931..abca7dd 100644 --- a/.ots/prev-commit.txt +++ b/.ots/prev-commit.txt @@ -1 +1 @@ -3b54e0cb8c611d3f3525ad2386368f60200891f1 +ed2cd259e918344c5a21ecf884b3178b4256ea74 diff --git a/.ots/proof.ots b/.ots/proof.ots index ab33f8e..4da399d 100644 Binary files a/.ots/proof.ots and b/.ots/proof.ots differ diff --git a/backfill-proofs.sh b/backfill-proofs.sh index a859ec4..38fc3c0 100755 --- a/backfill-proofs.sh +++ b/backfill-proofs.sh @@ -108,7 +108,18 @@ for COMMIT in $COMMITS; do # Cache as pending cache_status "$COMMIT" "pending" - # Try to upgrade existing proof (only contacts calendars if pending) + # Skip upgrade if cache is fresh (< 10 min old) + CACHE_LINE=$(grep "^$COMMIT:" "$STATUS_CACHE" | tail -1) + CACHE_TIME=$(echo "$CACHE_LINE" | cut -d: -f3) + NOW=$(date +%s) + CACHE_AGE=$((NOW - CACHE_TIME)) + + if [ "$CACHE_AGE" -lt 600 ]; then + echo " - Pending (cached <10min, skipping calendar call)" + continue + fi + + # Try to upgrade existing proof (contacts calendars) echo " Upgrading pending proof..." if ots upgrade "$PROOF_FILE" 2>/dev/null; then echo " ✓ Upgraded to attested" @@ -116,6 +127,8 @@ for COMMIT in $COMMITS; do UPDATED=$((UPDATED + 1)) else echo " - Still pending (no upgrade available yet)" + # Update cache timestamp + cache_status "$COMMIT" "pending" fi else # Generate new proof for this commit diff --git a/test8.txt b/test8.txt new file mode 100644 index 0000000..c251836 --- /dev/null +++ b/test8.txt @@ -0,0 +1 @@ +# Fourth commit