Repository navigation
Conversation
…-931-934-key-analytics-and-governance
The three write paths of upsertPriceSnapshot() were only asserted indirectly inside the debug-log suite, and only against update/history calls, so a stray write on the unchanged-price path could pass unnoticed. Assert on the whole transaction instead, and pin down the first-snapshot seed values. Timestamps are relative to now because price24hAgo rotation is wall-clock dependent. 🤖 Generated with Codebuff Co-Authored-By: Codebuff <noreply@codebuff.com>
The merge of main into this branch concatenated two copies of the manifest: the old devDependencies block was left unterminated and main's full manifest was appended after it, so package.json was not valid JSON. pnpm/action-setup always parses package.json in the workspace, so CI died before installing. Restore the file to main's manifest, which already matches the lockfile's ws@8.21.0 and @types/ws entries. 🤖 Generated with Codebuff Co-Authored-By: Codebuff <noreply@codebuff.com>
…m/flare-999/accesslayer-server into freebuff/5fcf9f2ef09a1450a9b0a3fc
api.js is a 28 KB hex-string-array payload (the shape the repo's own malware scan flags) that PR accesslayerorg#973 wired into dev/start/build. Those script references are gone on main, so nothing loads it, but eslint still parsed it and failed the lint step. The unchanged-price guard these tests asserted was removed upstream in ef59c18: TWAP reads creator_price_history, so a repeated price must still append a point. The tests now pin that invariant instead. 🤖 Generated with Codebuff Co-Authored-By: Codebuff <noreply@codebuff.com>
Member
🚨 Automated Security AlertThis PR has been automatically closed by the PR monitor because it contains code patterns associated with the PolinRider malware campaign. Detected indicators may include:
Please do not reopen this PR or run the code locally. If you believe this is a false positive, contact a maintainer directly. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
PR description:
Summary
This change ensures creator price snapshots are only written when they represent a real change.
When the latest price matches the previous snapshot, the system should skip the database write. When the price changes, it should write the new snapshot. The first ever snapshot for a creator should always be persisted regardless of comparison.
Scope
Changes
Acceptance Criteria
Testing
closes Add unit tests for the price snapshot writer skipping a write when the price is unchanged from the previous snapshot #763