@atproto/pds 0.4.103 → 0.4.105
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.
- package/CHANGELOG.md +35 -0
- package/dist/account-manager/{index.d.ts → account-manager.d.ts} +26 -35
- package/dist/account-manager/account-manager.d.ts.map +1 -0
- package/dist/account-manager/{index.js → account-manager.js} +52 -207
- package/dist/account-manager/account-manager.js.map +1 -0
- package/dist/account-manager/helpers/account.d.ts +3 -3
- package/dist/account-manager/helpers/device-account.d.ts +15 -15
- package/dist/account-manager/helpers/device-account.d.ts.map +1 -1
- package/dist/account-manager/helpers/device-account.js +2 -1
- package/dist/account-manager/helpers/device-account.js.map +1 -1
- package/dist/account-manager/helpers/token.d.ts +98 -98
- package/dist/account-manager/oauth-store.d.ts +58 -0
- package/dist/account-manager/oauth-store.d.ts.map +1 -0
- package/dist/account-manager/oauth-store.js +417 -0
- package/dist/account-manager/oauth-store.js.map +1 -0
- package/dist/actor-store/record/reader.d.ts +3 -3
- package/dist/actor-store/repo/reader.d.ts +2 -0
- package/dist/actor-store/repo/reader.d.ts.map +1 -1
- package/dist/actor-store/repo/reader.js +9 -0
- package/dist/actor-store/repo/reader.js.map +1 -1
- package/dist/actor-store/repo/sql-repo-reader.d.ts +1 -1
- package/dist/actor-store/repo/transactor.d.ts.map +1 -1
- package/dist/actor-store/repo/transactor.js +13 -4
- package/dist/actor-store/repo/transactor.js.map +1 -1
- package/dist/api/com/atproto/admin/deleteAccount.d.ts.map +1 -1
- package/dist/api/com/atproto/admin/deleteAccount.js +2 -3
- package/dist/api/com/atproto/admin/deleteAccount.js.map +1 -1
- package/dist/api/com/atproto/admin/sendEmail.d.ts.map +1 -1
- package/dist/api/com/atproto/admin/sendEmail.js +2 -7
- package/dist/api/com/atproto/admin/sendEmail.js.map +1 -1
- package/dist/api/com/atproto/admin/updateAccountEmail.d.ts.map +1 -1
- package/dist/api/com/atproto/admin/updateAccountEmail.js +1 -2
- package/dist/api/com/atproto/admin/updateAccountEmail.js.map +1 -1
- package/dist/api/com/atproto/admin/updateAccountHandle.d.ts.map +1 -1
- package/dist/api/com/atproto/admin/updateAccountHandle.js +2 -6
- package/dist/api/com/atproto/admin/updateAccountHandle.js.map +1 -1
- package/dist/api/com/atproto/admin/updateAccountPassword.d.ts.map +1 -1
- package/dist/api/com/atproto/admin/updateAccountPassword.js +1 -2
- package/dist/api/com/atproto/admin/updateAccountPassword.js.map +1 -1
- package/dist/api/com/atproto/identity/requestPlcOperationSignature.d.ts.map +1 -1
- package/dist/api/com/atproto/identity/requestPlcOperationSignature.js +2 -7
- package/dist/api/com/atproto/identity/requestPlcOperationSignature.js.map +1 -1
- package/dist/api/com/atproto/identity/resolveHandle.d.ts.map +1 -1
- package/dist/api/com/atproto/identity/resolveHandle.js +2 -36
- package/dist/api/com/atproto/identity/resolveHandle.js.map +1 -1
- package/dist/api/com/atproto/identity/signPlcOperation.d.ts.map +1 -1
- package/dist/api/com/atproto/identity/signPlcOperation.js +2 -7
- package/dist/api/com/atproto/identity/signPlcOperation.js.map +1 -1
- package/dist/api/com/atproto/identity/updateHandle.d.ts.map +1 -1
- package/dist/api/com/atproto/identity/updateHandle.js +3 -14
- package/dist/api/com/atproto/identity/updateHandle.js.map +1 -1
- package/dist/api/com/atproto/repo/applyWrites.d.ts.map +1 -1
- package/dist/api/com/atproto/repo/applyWrites.js +12 -7
- package/dist/api/com/atproto/repo/applyWrites.js.map +1 -1
- package/dist/api/com/atproto/repo/createRecord.d.ts.map +1 -1
- package/dist/api/com/atproto/repo/createRecord.js +12 -8
- package/dist/api/com/atproto/repo/createRecord.js.map +1 -1
- package/dist/api/com/atproto/repo/deleteRecord.d.ts.map +1 -1
- package/dist/api/com/atproto/repo/deleteRecord.js +12 -7
- package/dist/api/com/atproto/repo/deleteRecord.js.map +1 -1
- package/dist/api/com/atproto/repo/listRecords.d.ts.map +1 -1
- package/dist/api/com/atproto/repo/listRecords.js +1 -3
- package/dist/api/com/atproto/repo/listRecords.js.map +1 -1
- package/dist/api/com/atproto/repo/putRecord.d.ts.map +1 -1
- package/dist/api/com/atproto/repo/putRecord.js +11 -8
- package/dist/api/com/atproto/repo/putRecord.js.map +1 -1
- package/dist/api/com/atproto/server/activateAccount.d.ts.map +1 -1
- package/dist/api/com/atproto/server/activateAccount.js +3 -20
- package/dist/api/com/atproto/server/activateAccount.js.map +1 -1
- package/dist/api/com/atproto/server/confirmEmail.d.ts.map +1 -1
- package/dist/api/com/atproto/server/confirmEmail.js +2 -7
- package/dist/api/com/atproto/server/confirmEmail.js.map +1 -1
- package/dist/api/com/atproto/server/createAccount.d.ts.map +1 -1
- package/dist/api/com/atproto/server/createAccount.js +5 -7
- package/dist/api/com/atproto/server/createAccount.js.map +1 -1
- package/dist/api/com/atproto/server/createAppPassword.d.ts.map +1 -1
- package/dist/api/com/atproto/server/createAppPassword.js +2 -7
- package/dist/api/com/atproto/server/createAppPassword.js.map +1 -1
- package/dist/api/com/atproto/server/createSession.js +2 -2
- package/dist/api/com/atproto/server/createSession.js.map +1 -1
- package/dist/api/com/atproto/server/deactivateAccount.d.ts.map +1 -1
- package/dist/api/com/atproto/server/deactivateAccount.js +1 -2
- package/dist/api/com/atproto/server/deactivateAccount.js.map +1 -1
- package/dist/api/com/atproto/server/deleteAccount.d.ts.map +1 -1
- package/dist/api/com/atproto/server/deleteAccount.js +3 -5
- package/dist/api/com/atproto/server/deleteAccount.js.map +1 -1
- package/dist/api/com/atproto/server/deleteSession.d.ts.map +1 -1
- package/dist/api/com/atproto/server/deleteSession.js +2 -3
- package/dist/api/com/atproto/server/deleteSession.js.map +1 -1
- package/dist/api/com/atproto/server/getAccountInviteCodes.d.ts.map +1 -1
- package/dist/api/com/atproto/server/getAccountInviteCodes.js +2 -7
- package/dist/api/com/atproto/server/getAccountInviteCodes.js.map +1 -1
- package/dist/api/com/atproto/server/getSession.js +2 -2
- package/dist/api/com/atproto/server/getSession.js.map +1 -1
- package/dist/api/com/atproto/server/listAppPasswords.d.ts.map +1 -1
- package/dist/api/com/atproto/server/listAppPasswords.js +2 -7
- package/dist/api/com/atproto/server/listAppPasswords.js.map +1 -1
- package/dist/api/com/atproto/server/refreshSession.js +2 -2
- package/dist/api/com/atproto/server/refreshSession.js.map +1 -1
- package/dist/api/com/atproto/server/requestAccountDelete.d.ts.map +1 -1
- package/dist/api/com/atproto/server/requestAccountDelete.js +2 -7
- package/dist/api/com/atproto/server/requestAccountDelete.js.map +1 -1
- package/dist/api/com/atproto/server/requestEmailConfirmation.d.ts.map +1 -1
- package/dist/api/com/atproto/server/requestEmailConfirmation.js +2 -7
- package/dist/api/com/atproto/server/requestEmailConfirmation.js.map +1 -1
- package/dist/api/com/atproto/server/requestEmailUpdate.d.ts.map +1 -1
- package/dist/api/com/atproto/server/requestEmailUpdate.js +2 -7
- package/dist/api/com/atproto/server/requestEmailUpdate.js.map +1 -1
- package/dist/api/com/atproto/server/requestPasswordReset.d.ts.map +1 -1
- package/dist/api/com/atproto/server/requestPasswordReset.js +1 -2
- package/dist/api/com/atproto/server/requestPasswordReset.js.map +1 -1
- package/dist/api/com/atproto/server/resetPassword.d.ts.map +1 -1
- package/dist/api/com/atproto/server/resetPassword.js +1 -2
- package/dist/api/com/atproto/server/resetPassword.js.map +1 -1
- package/dist/api/com/atproto/server/revokeAppPassword.d.ts.map +1 -1
- package/dist/api/com/atproto/server/revokeAppPassword.js +2 -7
- package/dist/api/com/atproto/server/revokeAppPassword.js.map +1 -1
- package/dist/api/com/atproto/server/updateEmail.d.ts.map +1 -1
- package/dist/api/com/atproto/server/updateEmail.js +2 -7
- package/dist/api/com/atproto/server/updateEmail.js.map +1 -1
- package/dist/api/com/atproto/sync/getRecord.d.ts.map +1 -1
- package/dist/api/com/atproto/sync/getRecord.js +1 -4
- package/dist/api/com/atproto/sync/getRecord.js.map +1 -1
- package/dist/api/com/atproto/sync/getRepoStatus.js +1 -1
- package/dist/api/com/atproto/sync/getRepoStatus.js.map +1 -1
- package/dist/api/com/atproto/sync/listRepos.js +1 -1
- package/dist/api/com/atproto/sync/listRepos.js.map +1 -1
- package/dist/api/com/atproto/sync/subscribeRepos.d.ts.map +1 -1
- package/dist/api/com/atproto/sync/subscribeRepos.js +2 -10
- package/dist/api/com/atproto/sync/subscribeRepos.js.map +1 -1
- package/dist/api/com/atproto/temp/checkSignupQueue.js +1 -1
- package/dist/api/com/atproto/temp/checkSignupQueue.js.map +1 -1
- package/dist/api/proxy.d.ts +7 -8
- package/dist/api/proxy.d.ts.map +1 -1
- package/dist/api/proxy.js +14 -6
- package/dist/api/proxy.js.map +1 -1
- package/dist/app-view.d.ts +14 -0
- package/dist/app-view.d.ts.map +1 -0
- package/dist/app-view.js +36 -0
- package/dist/app-view.js.map +1 -0
- package/dist/auth-routes.d.ts +1 -1
- package/dist/auth-routes.d.ts.map +1 -1
- package/dist/auth-routes.js +9 -3
- package/dist/auth-routes.js.map +1 -1
- package/dist/auth-verifier.d.ts +1 -1
- package/dist/auth-verifier.d.ts.map +1 -1
- package/dist/config/config.d.ts +3 -2
- package/dist/config/config.d.ts.map +1 -1
- package/dist/config/config.js +17 -7
- package/dist/config/config.js.map +1 -1
- package/dist/config/env.d.ts +4 -0
- package/dist/config/env.d.ts.map +1 -1
- package/dist/config/env.js +5 -0
- package/dist/config/env.js.map +1 -1
- package/dist/context.d.ts +11 -4
- package/dist/context.d.ts.map +1 -1
- package/dist/context.js +33 -18
- package/dist/context.js.map +1 -1
- package/dist/handle/index.d.ts +0 -7
- package/dist/handle/index.d.ts.map +1 -1
- package/dist/handle/index.js +4 -58
- package/dist/handle/index.js.map +1 -1
- package/dist/image/image-url.d.ts +8 -0
- package/dist/image/image-url.d.ts.map +1 -0
- package/dist/image/image-url.js +26 -0
- package/dist/image/image-url.js.map +1 -0
- package/dist/index.js +1 -1
- package/dist/index.js.map +1 -1
- package/dist/lexicon/index.d.ts +6 -0
- package/dist/lexicon/index.d.ts.map +1 -1
- package/dist/lexicon/index.js +12 -0
- package/dist/lexicon/index.js.map +1 -1
- package/dist/lexicon/lexicons.d.ts +412 -158
- package/dist/lexicon/lexicons.d.ts.map +1 -1
- package/dist/lexicon/lexicons.js +222 -81
- package/dist/lexicon/lexicons.js.map +1 -1
- package/dist/lexicon/types/app/bsky/embed/video.d.ts +1 -0
- package/dist/lexicon/types/app/bsky/embed/video.d.ts.map +1 -1
- package/dist/lexicon/types/app/bsky/embed/video.js.map +1 -1
- package/dist/lexicon/types/app/bsky/labeler/defs.d.ts +7 -0
- package/dist/lexicon/types/app/bsky/labeler/defs.d.ts.map +1 -1
- package/dist/lexicon/types/app/bsky/labeler/defs.js.map +1 -1
- package/dist/lexicon/types/app/bsky/labeler/service.d.ts +7 -0
- package/dist/lexicon/types/app/bsky/labeler/service.d.ts.map +1 -1
- package/dist/lexicon/types/app/bsky/labeler/service.js.map +1 -1
- package/dist/lexicon/types/com/atproto/identity/defs.d.ts +17 -0
- package/dist/lexicon/types/com/atproto/identity/defs.d.ts.map +1 -0
- package/dist/lexicon/types/com/atproto/identity/defs.js +16 -0
- package/dist/lexicon/types/com/atproto/identity/defs.js.map +1 -0
- package/dist/lexicon/types/com/atproto/identity/refreshIdentity.d.ts +39 -0
- package/dist/lexicon/types/com/atproto/identity/refreshIdentity.d.ts.map +1 -0
- package/dist/lexicon/types/com/atproto/identity/refreshIdentity.js +7 -0
- package/dist/lexicon/types/com/atproto/identity/refreshIdentity.js.map +1 -0
- package/dist/lexicon/types/com/atproto/identity/resolveDid.d.ts +40 -0
- package/dist/lexicon/types/com/atproto/identity/resolveDid.d.ts.map +1 -0
- package/dist/lexicon/types/com/atproto/identity/resolveDid.js +7 -0
- package/dist/lexicon/types/com/atproto/identity/resolveDid.js.map +1 -0
- package/dist/lexicon/types/com/atproto/identity/resolveHandle.d.ts +1 -0
- package/dist/lexicon/types/com/atproto/identity/resolveHandle.d.ts.map +1 -1
- package/dist/lexicon/types/com/atproto/identity/resolveIdentity.d.ts +36 -0
- package/dist/lexicon/types/com/atproto/identity/resolveIdentity.d.ts.map +1 -0
- package/dist/lexicon/types/com/atproto/identity/resolveIdentity.js +7 -0
- package/dist/lexicon/types/com/atproto/identity/resolveIdentity.js.map +1 -0
- package/dist/lexicon/types/com/atproto/moderation/defs.d.ts +2 -0
- package/dist/lexicon/types/com/atproto/moderation/defs.d.ts.map +1 -1
- package/dist/lexicon/types/com/atproto/repo/listRecords.d.ts +0 -4
- package/dist/lexicon/types/com/atproto/repo/listRecords.d.ts.map +1 -1
- package/dist/lexicon/types/com/atproto/repo/listRecords.js.map +1 -1
- package/dist/lexicon/types/com/atproto/sync/getRecord.d.ts +0 -2
- package/dist/lexicon/types/com/atproto/sync/getRecord.d.ts.map +1 -1
- package/dist/lexicon/types/com/atproto/sync/subscribeRepos.d.ts +1 -30
- package/dist/lexicon/types/com/atproto/sync/subscribeRepos.d.ts.map +1 -1
- package/dist/lexicon/types/com/atproto/sync/subscribeRepos.js +0 -27
- package/dist/lexicon/types/com/atproto/sync/subscribeRepos.js.map +1 -1
- package/dist/mailer/index.d.ts +5 -5
- package/dist/mailer/index.d.ts.map +1 -1
- package/dist/mailer/index.js +6 -5
- package/dist/mailer/index.js.map +1 -1
- package/dist/read-after-write/viewer.d.ts +1 -1
- package/dist/read-after-write/viewer.d.ts.map +1 -1
- package/dist/repo/types.d.ts +6 -2
- package/dist/repo/types.d.ts.map +1 -1
- package/dist/repo/types.js.map +1 -1
- package/dist/scripts/rebuild-repo.d.ts.map +1 -1
- package/dist/scripts/rebuild-repo.js +2 -1
- package/dist/scripts/rebuild-repo.js.map +1 -1
- package/dist/sequencer/db/schema.d.ts +1 -1
- package/dist/sequencer/db/schema.d.ts.map +1 -1
- package/dist/sequencer/events.d.ts +29 -41
- package/dist/sequencer/events.d.ts.map +1 -1
- package/dist/sequencer/events.js +24 -58
- package/dist/sequencer/events.js.map +1 -1
- package/dist/sequencer/sequencer.d.ts +2 -3
- package/dist/sequencer/sequencer.d.ts.map +1 -1
- package/dist/sequencer/sequencer.js +5 -17
- package/dist/sequencer/sequencer.js.map +1 -1
- package/package.json +15 -15
- package/src/account-manager/{index.ts → account-manager.ts} +107 -307
- package/src/account-manager/helpers/device-account.ts +1 -0
- package/src/account-manager/oauth-store.ts +494 -0
- package/src/actor-store/repo/reader.ts +11 -0
- package/src/actor-store/repo/transactor.ts +15 -4
- package/src/api/com/atproto/admin/deleteAccount.ts +2 -3
- package/src/api/com/atproto/admin/sendEmail.ts +3 -5
- package/src/api/com/atproto/admin/updateAccountEmail.ts +1 -2
- package/src/api/com/atproto/admin/updateAccountHandle.ts +7 -8
- package/src/api/com/atproto/admin/updateAccountPassword.ts +1 -2
- package/src/api/com/atproto/identity/requestPlcOperationSignature.ts +3 -5
- package/src/api/com/atproto/identity/resolveHandle.ts +2 -11
- package/src/api/com/atproto/identity/signPlcOperation.ts +3 -5
- package/src/api/com/atproto/identity/updateHandle.ts +7 -13
- package/src/api/com/atproto/repo/applyWrites.ts +21 -11
- package/src/api/com/atproto/repo/createRecord.ts +19 -14
- package/src/api/com/atproto/repo/deleteRecord.ts +26 -14
- package/src/api/com/atproto/repo/listRecords.ts +1 -11
- package/src/api/com/atproto/repo/putRecord.ts +24 -16
- package/src/api/com/atproto/server/activateAccount.ts +5 -20
- package/src/api/com/atproto/server/confirmEmail.ts +3 -5
- package/src/api/com/atproto/server/createAccount.ts +10 -11
- package/src/api/com/atproto/server/createAppPassword.ts +3 -6
- package/src/api/com/atproto/server/createSession.ts +3 -3
- package/src/api/com/atproto/server/deactivateAccount.ts +1 -2
- package/src/api/com/atproto/server/deleteAccount.ts +3 -5
- package/src/api/com/atproto/server/deleteSession.ts +2 -3
- package/src/api/com/atproto/server/getAccountInviteCodes.ts +3 -5
- package/src/api/com/atproto/server/getSession.ts +3 -3
- package/src/api/com/atproto/server/listAppPasswords.ts +3 -5
- package/src/api/com/atproto/server/refreshSession.ts +3 -3
- package/src/api/com/atproto/server/requestAccountDelete.ts +3 -5
- package/src/api/com/atproto/server/requestEmailConfirmation.ts +3 -5
- package/src/api/com/atproto/server/requestEmailUpdate.ts +3 -5
- package/src/api/com/atproto/server/requestPasswordReset.ts +1 -2
- package/src/api/com/atproto/server/resetPassword.ts +1 -2
- package/src/api/com/atproto/server/revokeAppPassword.ts +3 -5
- package/src/api/com/atproto/server/updateEmail.ts +3 -5
- package/src/api/com/atproto/sync/getRecord.ts +1 -4
- package/src/api/com/atproto/sync/getRepoStatus.ts +1 -1
- package/src/api/com/atproto/sync/listRepos.ts +1 -1
- package/src/api/com/atproto/sync/subscribeRepos.ts +2 -9
- package/src/api/com/atproto/temp/checkSignupQueue.ts +2 -2
- package/src/api/proxy.ts +19 -19
- package/src/app-view.ts +24 -0
- package/src/auth-routes.ts +9 -3
- package/src/auth-verifier.ts +1 -1
- package/src/config/config.ts +25 -13
- package/src/config/env.ts +12 -0
- package/src/context.ts +60 -24
- package/src/handle/index.ts +6 -52
- package/src/image/image-url.ts +16 -0
- package/src/index.ts +1 -1
- package/src/lexicon/index.ts +36 -0
- package/src/lexicon/lexicons.ts +243 -84
- package/src/lexicon/types/app/bsky/embed/video.ts +1 -0
- package/src/lexicon/types/app/bsky/labeler/defs.ts +7 -0
- package/src/lexicon/types/app/bsky/labeler/service.ts +7 -0
- package/src/lexicon/types/com/atproto/identity/defs.ts +30 -0
- package/src/lexicon/types/com/atproto/identity/refreshIdentity.ts +52 -0
- package/src/lexicon/types/com/atproto/identity/resolveDid.ts +52 -0
- package/src/lexicon/types/com/atproto/identity/resolveHandle.ts +1 -0
- package/src/lexicon/types/com/atproto/identity/resolveIdentity.ts +48 -0
- package/src/lexicon/types/com/atproto/moderation/defs.ts +3 -0
- package/src/lexicon/types/com/atproto/repo/listRecords.ts +0 -4
- package/src/lexicon/types/com/atproto/sync/getRecord.ts +0 -2
- package/src/lexicon/types/com/atproto/sync/subscribeRepos.ts +0 -59
- package/src/mailer/index.ts +7 -5
- package/src/read-after-write/viewer.ts +1 -1
- package/src/repo/types.ts +7 -2
- package/src/scripts/rebuild-repo.ts +4 -1
- package/src/sequencer/db/schema.ts +1 -8
- package/src/sequencer/events.ts +29 -75
- package/src/sequencer/sequencer.ts +9 -23
- package/tests/account-deletion.test.ts +3 -5
- package/tests/oauth.test.ts +286 -71
- package/tests/sequencer.test.ts +18 -27
- package/tests/sync/subscribe-repos.test.ts +67 -45
- package/tsconfig.build.tsbuildinfo +1 -1
- package/dist/account-manager/index.d.ts.map +0 -1
- package/dist/account-manager/index.js.map +0 -1
- package/dist/actor-store/repo/util.d.ts +0 -5
- package/dist/actor-store/repo/util.d.ts.map +0 -1
- package/dist/actor-store/repo/util.js +0 -25
- package/dist/actor-store/repo/util.js.map +0 -1
- package/dist/oauth/provider.d.ts +0 -10
- package/dist/oauth/provider.d.ts.map +0 -1
- package/dist/oauth/provider.js +0 -38
- package/dist/oauth/provider.js.map +0 -1
- package/src/actor-store/repo/util.ts +0 -22
- package/src/oauth/provider.ts +0 -59
package/dist/mailer/index.js.map
CHANGED
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/mailer/index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;AAGA,qEAAoD;AAEpD,sCAAwC;AACxC,uDAAwC;AAExC,MAAa,YAAY;IACvB,YACkB,WAAuD,EACtD,MAAoB;QADrC;;;;mBAAgB,WAAW;WAA4C;QACvE;;;;mBAAiB,MAAM;WAAc;QAErC,WAAW,CAAC,GAAG,CAAC,SAAS,EAAE,IAAA,oCAAU,GAAE,CAAC,CAAA;IAC1C,CAAC;IAED,0DAA0D;IAC1D,MAAM,CAAC,cAAc,CAAC,OAAqB;QACzC,OAAO,EAAE,CAAA;IACX,CAAC;IAED,KAAK,CAAC,iBAAiB,CACrB,MAAyC,EACzC,QAAsB;QAEtB,
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/mailer/index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;AAGA,qEAAoD;AAEpD,sCAAwC;AACxC,uDAAwC;AAExC,6B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AAC;IAEO,KAAK,CAAC,YAAY,CACxB,YAAe,EACf,MAA4C,EAC5C,QAAsB;QAEtB,MAAM,IAAI,GAAG,SAAS,CAAC,YAAY,CAAC,CAAC;YACnC,GAAG,MAAM;YACT,MAAM,EAAE,YAAY,CAAC,cAAc,CAAC,IAAI,CAAC,MAAM,CAAC;SAC1C,CAAC,CAAA;QACT,MAAM,GAAG,GAAG,MAAM,IAAI,CAAC,WAAW,CAAC,QAAQ,CAAC;YAC1C,GAAG,QAAQ;YACX,IAAI,EAAE,QAAQ,CAAC,IAAI,IAAI,IAAI,CAAC,MAAM,CAAC,KAAK,EAAE,WAAW;YACrD,IAAI;SACL,CAAC,CAAA;QACF,IAAI,CAAC,IAAI,CAAC,MAAM,CAAC,KAAK,EAAE,OAAO,EAAE,CAAC;YAChC,qBAAY,CAAC,KAAK,CAChB,4DAA4D;gBAC1D,IAAI,CAAC,SAAS,CAAC,GAAG,EAAE,IAAI,EAAE,CAAC,CAAC,CAC/B,CAAA;QACH,CAAC;QACD,OAAO,GAAG,CAAA;IACZ,CAAC;CACF;AAzED,oCAyEC"}
|
@@ -1,4 +1,4 @@
|
|
1
|
-
import { AccountManager } from '../account-manager';
|
1
|
+
import { AccountManager } from '../account-manager/account-manager';
|
2
2
|
import { ActorStoreReader } from '../actor-store/actor-store-reader';
|
3
3
|
import { BskyAppView } from '../bsky-app-view';
|
4
4
|
import { ImageUrlBuilder } from '../image/image-url-builder';
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"viewer.d.ts","sourceRoot":"","sources":["../../src/read-after-write/viewer.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,cAAc,EAAE,MAAM,
|
1
|
+
{"version":3,"file":"viewer.d.ts","sourceRoot":"","sources":["../../src/read-after-write/viewer.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,cAAc,EAAE,MAAM,oCAAoC,CAAA;AACnE,OAAO,EAAE,gBAAgB,EAAE,MAAM,mCAAmC,CAAA;AACpE,OAAO,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EAAE,CAAC,EAAE,MAAM,EAAE,aAAa,GAAG,CAAC;IAOpC,qBAAqB,CAAC,CAAC,SAAS,mBAAmB,EACjD,IAAI,EAAE,CAAC,EACP,MAAM,EAAE,aAAa,GACpB,CAAC;CAQL"}
|
package/dist/repo/types.d.ts
CHANGED
@@ -1,6 +1,6 @@
|
|
1
1
|
import { CID } from 'multiformats/cid';
|
2
2
|
import { RepoRecord } from '@atproto/lexicon';
|
3
|
-
import {
|
3
|
+
import { BlockMap, CommitData, WriteOpAction } from '@atproto/repo';
|
4
4
|
import { AtUri } from '@atproto/syntax';
|
5
5
|
export type ValidationStatus = 'valid' | 'unknown' | undefined;
|
6
6
|
export type BlobConstraint = {
|
@@ -43,10 +43,14 @@ export type CommitOp = {
|
|
43
43
|
};
|
44
44
|
export type CommitDataWithOps = CommitData & {
|
45
45
|
ops: CommitOp[];
|
46
|
-
blobs: CidSet;
|
47
46
|
prevData: CID | null;
|
48
47
|
};
|
49
48
|
export type PreparedWrite = PreparedCreate | PreparedUpdate | PreparedDelete;
|
49
|
+
export type SyncEvtData = {
|
50
|
+
cid: CID;
|
51
|
+
rev: string;
|
52
|
+
blocks: BlockMap;
|
53
|
+
};
|
50
54
|
export declare class InvalidRecordError extends Error {
|
51
55
|
}
|
52
56
|
export declare class BadCommitSwapError extends Error {
|
package/dist/repo/types.d.ts.map
CHANGED
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../../src/repo/types.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,GAAG,EAAE,MAAM,kBAAkB,CAAA;AACtC,OAAO,EAAE,UAAU,EAAE,MAAM,kBAAkB,CAAA;AAC7C,OAAO,EAAE,
|
1
|
+
{"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../../src/repo/types.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,GAAG,EAAE,MAAM,kBAAkB,CAAA;AACtC,OAAO,EAAE,UAAU,EAAE,MAAM,kBAAkB,CAA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ACrB,MAAM,EAAE,QAAQ,GAAG,QAAQ,GAAG,QAAQ,CAAA;IACtC,IAAI,EAAE,MAAM,CAAA;IACZ,GAAG,EAAE,GAAG,GAAG,IAAI,CAAA;IACf,IAAI,CAAC,EAAE,GAAG,CAAA;CACX,CAAA;AAED,MAAM,MAAM,iBAAiB,GAAG,UAAU,GAAG;IAC3C,GAAG,EAAE,QAAQ,EAAE,CAAA;IACf,QAAQ,EAAE,GAAG,GAAG,IAAI,CAAA;CACrB,CAAA;AAED,MAAM,MAAM,aAAa,GAAG,cAAc,GAAG,cAAc,GAAG,cAAc,CAAA;AAE5E,MAAM,MAAM,WAAW,GAAG;IACxB,GAAG,EAAE,GAAG,CAAA;IACR,GAAG,EAAE,MAAM,CAAA;IACX,MAAM,EAAE,QAAQ,CAAA;CACjB,CAAA;AAED,qBAAa,kBAAmB,SAAQ,KAAK;CAAG;AAEhD,qBAAa,kBAAmB,SAAQ,KAAK;IACxB,GAAG,EAAE,GAAG;gBAAR,GAAG,EAAE,GAAG;CAG5B;AAED,qBAAa,kBAAmB,SAAQ,KAAK;IACxB,GAAG,EAAE,GAAG,GAAG,IAAI;gBAAf,GAAG,EAAE,GAAG,GAAG,IAAI;CAGnC"}
|
package/dist/repo/types.js.map
CHANGED
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"types.js","sourceRoot":"","sources":["../../src/repo/types.ts"],"names":[],"mappings":";;;
|
1
|
+
{"version":3,"file":"types.js","sourceRoot":"","sources":["../../src/repo/types.ts"],"names":[],"mappings":";;;AAgEA,MAAa,kBAAmB,SAAQ,KAAK;CAAG;AAAhD,gDAAgD;AAEhD,MAAa,kBAAmB,SAAQ,KAAK;IAC3C,YAAmB,GAAQ;QACzB,KAAK,CAAC,iBAAiB,GAAG,CAAC,QAAQ,EAAE,EAAE,CAAC,CAAA;QAD9B;;;;mBAAO,GAAG;WAAK;IAE3B,CAAC;CACF;AAJD,gDAIC;AAED,MAAa,kBAAmB,SAAQ,KAAK;IAC3C,YAAmB,GAAe;QAChC,KAAK,CAAC,iBAAiB,GAAG,EAAE,QAAQ,EAAE,IAAI,MAAM,EAAE,CAAC,CAAA;QADzC;;;;mBAAO,GAAG;WAAY;IAElC,CAAC;CACF;AAJD,gDAIC"}
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"rebuild-repo.d.ts","sourceRoot":"","sources":["../../src/scripts/rebuild-repo.ts"],"names":[],"mappings":"AASA,OAAO,EAAE,UAAU,EAAE,MAAM,YAAY,CAAA;AAEvC,eAAO,MAAM,WAAW,QAAe,UAAU,QAAQ,MAAM,EAAE,
|
1
|
+
{"version":3,"file":"rebuild-repo.d.ts","sourceRoot":"","sources":["../../src/scripts/rebuild-repo.ts"],"names":[],"mappings":"AASA,OAAO,EAAE,UAAU,EAAE,MAAM,YAAY,CAAA;AAEvC,eAAO,MAAM,WAAW,QAAe,UAAU,QAAQ,MAAM,EAAE,kBAwEhE,CAAA"}
|
@@ -68,7 +68,8 @@ const rebuildRepo = async (ctx, args) => {
|
|
68
68
|
};
|
69
69
|
});
|
70
70
|
await ctx.accountManager.updateRepoRoot(did, commit.cid, rev);
|
71
|
-
await ctx.
|
71
|
+
const syncData = await ctx.actorStore.read(did, (store) => store.repo.getSyncEventData());
|
72
|
+
await ctx.sequencer.sequenceSyncEvt(did, syncData);
|
72
73
|
};
|
73
74
|
exports.rebuildRepo = rebuildRepo;
|
74
75
|
const promptContinue = async () => {
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"rebuild-repo.js","sourceRoot":"","sources":["../../src/scripts/rebuild-repo.ts"],"names":[],"mappings":";;;;;;AAAA,sEAA6C;AAC7C,4CAAqC;AACrC,wCAMsB;AAGf,MAAM,WAAW,GAAG,KAAK,EAAE,GAAe,EAAE,IAAc,EAAE,EAAE;IACnE,MAAM,GAAG,GAAG,IAAI,CAAC,CAAC,CAAC,CAAA;IACnB,IAAI,CAAC,GAAG,IAAI,CAAC,GAAG,CAAC,UAAU,CAAC,MAAM,CAA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AC,CAAA;AACpD,CAAC,CAAA;AAxEY,QAAA,WAAW,eAwEvB;AAED,MAAM,cAAc,GAAG,KAAK,IAAsB,EAAE;IAClD,MAAM,EAAE,GAAG,kBAAQ,CAAC,eAAe,CAAC;QAClC,KAAK,EAAE,OAAO,CAAC,KAAK;QACpB,MAAM,EAAE,OAAO,CAAC,MAAM;KACvB,CAAC,CAAA;IACF,MAAM,MAAM,GAAG,MAAM,EAAE,CAAC,QAAQ,CAAC,gBAAgB,CAAC,CAAA;IAClD,OAAO,MAAM,KAAK,EAAE,CAAA;AACtB,CAAC,CAAA"}
|
@@ -1,5 +1,5 @@
|
|
1
1
|
import { Generated, GeneratedAlways, Insertable, Selectable } from 'kysely';
|
2
|
-
export type RepoSeqEventType = 'append' | '
|
2
|
+
export type RepoSeqEventType = 'append' | 'sync' | 'identity' | 'account';
|
3
3
|
export interface RepoSeq {
|
4
4
|
seq: GeneratedAlways<number>;
|
5
5
|
did: string;
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"schema.d.ts","sourceRoot":"","sources":["../../../src/sequencer/db/schema.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAE,eAAe,EAAE,UAAU,EAAE,UAAU,EAAE,MAAM,QAAQ,CAAA;AAE3E,MAAM,MAAM,gBAAgB,
|
1
|
+
{"version":3,"file":"schema.d.ts","sourceRoot":"","sources":["../../../src/sequencer/db/schema.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAE,eAAe,EAAE,UAAU,EAAE,UAAU,EAAE,MAAM,QAAQ,CAAA;AAE3E,MAAM,MAAM,gBAAgB,GAAG,QAAQ,GAAG,MAAM,GAAG,UAAU,GAAG,SAAS,CAAA;AAEzE,MAAM,WAAW,OAAO;IACtB,GAAG,EAAE,eAAe,CAAC,MAAM,CAAC,CAAA;IAC5B,GAAG,EAAE,MAAM,CAAA;IACX,SAAS,EAAE,gBAAgB,CAAA;IAC3B,KAAK,EAAE,UAAU,CAAA;IACjB,WAAW,EAAE,SAAS,CAAC,CAAC,GAAG,CAAC,CAAC,CAAA;IAC7B,WAAW,EAAE,MAAM,CAAA;CACpB;AAED,MAAM,MAAM,aAAa,GAAG,UAAU,CAAC,OAAO,CAAC,CAAA;AAC/C,MAAM,MAAM,YAAY,GAAG,UAAU,CAAC,OAAO,CAAC,CAAA;AAE9C,MAAM,MAAM,iBAAiB,GAAG;IAC9B,QAAQ,EAAE,OAAO,CAAA;CAClB,CAAA"}
|
@@ -1,27 +1,26 @@
|
|
1
1
|
import { z } from 'zod';
|
2
|
-
import { AccountStatus } from '../account-manager';
|
3
|
-
import { CommitDataWithOps } from '../repo';
|
2
|
+
import { AccountStatus } from '../account-manager/account-manager';
|
3
|
+
import { CommitDataWithOps, SyncEvtData } from '../repo';
|
4
4
|
import { RepoSeqInsert } from './db';
|
5
5
|
export declare const formatSeqCommit: (did: string, commitData: CommitDataWithOps) => Promise<RepoSeqInsert>;
|
6
|
-
export declare const
|
6
|
+
export declare const formatSeqSyncEvt: (did: string, data: SyncEvtData) => Promise<RepoSeqInsert>;
|
7
7
|
export declare const formatSeqIdentityEvt: (did: string, handle?: string) => Promise<RepoSeqInsert>;
|
8
8
|
export declare const formatSeqAccountEvt: (did: string, status: AccountStatus) => Promise<RepoSeqInsert>;
|
9
|
-
export declare const formatSeqTombstone: (did: string) => Promise<RepoSeqInsert>;
|
10
9
|
export declare const commitEvtOp: z.ZodObject<{
|
11
10
|
action: z.ZodUnion<[z.ZodLiteral<"create">, z.ZodLiteral<"update">, z.ZodLiteral<"delete">]>;
|
12
11
|
path: z.ZodString;
|
13
12
|
cid: z.ZodNullable<z.ZodEffects<z.ZodEffects<z.ZodAny, any, any>, import("multiformats/cid").CID, any>>;
|
14
13
|
prev: z.ZodOptional<z.ZodEffects<z.ZodEffects<z.ZodAny, any, any>, import("multiformats/cid").CID, any>>;
|
15
14
|
}, "strip", z.ZodTypeAny, {
|
16
|
-
cid: import("multiformats/cid").CID | null;
|
17
15
|
path: string;
|
18
|
-
|
16
|
+
cid: import("multiformats/cid").CID | null;
|
17
|
+
action: "create" | "delete" | "update";
|
19
18
|
prev?: import("multiformats/cid").CID | undefined;
|
20
19
|
}, {
|
21
20
|
path: string;
|
22
|
-
action: "create" | "
|
23
|
-
cid?: any;
|
21
|
+
action: "create" | "delete" | "update";
|
24
22
|
prev?: any;
|
23
|
+
cid?: any;
|
25
24
|
}>;
|
26
25
|
export type CommitEvtOp = z.infer<typeof commitEvtOp>;
|
27
26
|
export declare const commitEvt: z.ZodObject<{
|
@@ -38,37 +37,37 @@ export declare const commitEvt: z.ZodObject<{
|
|
38
37
|
cid: z.ZodNullable<z.ZodEffects<z.ZodEffects<z.ZodAny, any, any>, import("multiformats/cid").CID, any>>;
|
39
38
|
prev: z.ZodOptional<z.ZodEffects<z.ZodEffects<z.ZodAny, any, any>, import("multiformats/cid").CID, any>>;
|
40
39
|
}, "strip", z.ZodTypeAny, {
|
41
|
-
cid: import("multiformats/cid").CID | null;
|
42
40
|
path: string;
|
43
|
-
|
41
|
+
cid: import("multiformats/cid").CID | null;
|
42
|
+
action: "create" | "delete" | "update";
|
44
43
|
prev?: import("multiformats/cid").CID | undefined;
|
45
44
|
}, {
|
46
45
|
path: string;
|
47
|
-
action: "create" | "
|
48
|
-
cid?: any;
|
46
|
+
action: "create" | "delete" | "update";
|
49
47
|
prev?: any;
|
48
|
+
cid?: any;
|
50
49
|
}>, "many">;
|
51
50
|
blobs: z.ZodArray<z.ZodEffects<z.ZodEffects<z.ZodAny, any, any>, import("multiformats/cid").CID, any>, "many">;
|
52
51
|
prevData: z.ZodOptional<z.ZodEffects<z.ZodEffects<z.ZodAny, any, any>, import("multiformats/cid").CID, any>>;
|
53
52
|
}, "strip", z.ZodTypeAny, {
|
54
|
-
rev: string;
|
55
53
|
repo: string;
|
56
54
|
commit: import("multiformats/cid").CID;
|
55
|
+
rev: string;
|
57
56
|
blobs: import("multiformats/cid").CID[];
|
58
57
|
since: string | null;
|
59
58
|
rebase: boolean;
|
60
59
|
tooBig: boolean;
|
61
60
|
blocks: Uint8Array;
|
62
61
|
ops: {
|
63
|
-
cid: import("multiformats/cid").CID | null;
|
64
62
|
path: string;
|
65
|
-
|
63
|
+
cid: import("multiformats/cid").CID | null;
|
64
|
+
action: "create" | "delete" | "update";
|
66
65
|
prev?: import("multiformats/cid").CID | undefined;
|
67
66
|
}[];
|
68
67
|
prevData?: import("multiformats/cid").CID | undefined;
|
69
68
|
}, {
|
70
|
-
rev: string;
|
71
69
|
repo: string;
|
70
|
+
rev: string;
|
72
71
|
blobs: any[];
|
73
72
|
since: string | null;
|
74
73
|
rebase: boolean;
|
@@ -76,25 +75,28 @@ export declare const commitEvt: z.ZodObject<{
|
|
76
75
|
blocks: Uint8Array;
|
77
76
|
ops: {
|
78
77
|
path: string;
|
79
|
-
action: "create" | "
|
80
|
-
cid?: any;
|
78
|
+
action: "create" | "delete" | "update";
|
81
79
|
prev?: any;
|
80
|
+
cid?: any;
|
82
81
|
}[];
|
83
82
|
commit?: any;
|
84
83
|
prevData?: any;
|
85
84
|
}>;
|
86
85
|
export type CommitEvt = z.infer<typeof commitEvt>;
|
87
|
-
export declare const
|
86
|
+
export declare const syncEvt: z.ZodObject<{
|
88
87
|
did: z.ZodString;
|
89
|
-
|
88
|
+
blocks: z.ZodType<Uint8Array, z.ZodTypeDef, Uint8Array>;
|
89
|
+
rev: z.ZodString;
|
90
90
|
}, "strip", z.ZodTypeAny, {
|
91
91
|
did: string;
|
92
|
-
|
92
|
+
rev: string;
|
93
|
+
blocks: Uint8Array;
|
93
94
|
}, {
|
94
95
|
did: string;
|
95
|
-
|
96
|
+
rev: string;
|
97
|
+
blocks: Uint8Array;
|
96
98
|
}>;
|
97
|
-
export type
|
99
|
+
export type SyncEvt = z.infer<typeof syncEvt>;
|
98
100
|
export declare const identityEvt: z.ZodObject<{
|
99
101
|
did: z.ZodString;
|
100
102
|
handle: z.ZodOptional<z.ZodString>;
|
@@ -120,25 +122,17 @@ export declare const accountEvt: z.ZodObject<{
|
|
120
122
|
status?: AccountStatus.Takendown | AccountStatus.Suspended | AccountStatus.Deleted | AccountStatus.Deactivated | undefined;
|
121
123
|
}>;
|
122
124
|
export type AccountEvt = z.infer<typeof accountEvt>;
|
123
|
-
export declare const tombstoneEvt: z.ZodObject<{
|
124
|
-
did: z.ZodString;
|
125
|
-
}, "strip", z.ZodTypeAny, {
|
126
|
-
did: string;
|
127
|
-
}, {
|
128
|
-
did: string;
|
129
|
-
}>;
|
130
|
-
export type TombstoneEvt = z.infer<typeof tombstoneEvt>;
|
131
125
|
type TypedCommitEvt = {
|
132
126
|
type: 'commit';
|
133
127
|
seq: number;
|
134
128
|
time: string;
|
135
129
|
evt: CommitEvt;
|
136
130
|
};
|
137
|
-
type
|
138
|
-
type: '
|
131
|
+
type TypedSyncEvt = {
|
132
|
+
type: 'sync';
|
139
133
|
seq: number;
|
140
134
|
time: string;
|
141
|
-
evt:
|
135
|
+
evt: SyncEvt;
|
142
136
|
};
|
143
137
|
type TypedIdentityEvt = {
|
144
138
|
type: 'identity';
|
@@ -152,12 +146,6 @@ type TypedAccountEvt = {
|
|
152
146
|
time: string;
|
153
147
|
evt: AccountEvt;
|
154
148
|
};
|
155
|
-
type
|
156
|
-
type: 'tombstone';
|
157
|
-
seq: number;
|
158
|
-
time: string;
|
159
|
-
evt: TombstoneEvt;
|
160
|
-
};
|
161
|
-
export type SeqEvt = TypedCommitEvt | TypedHandleEvt | TypedIdentityEvt | TypedAccountEvt | TypedTombstoneEvt;
|
149
|
+
export type SeqEvt = TypedCommitEvt | TypedSyncEvt | TypedIdentityEvt | TypedAccountEvt;
|
162
150
|
export {};
|
163
151
|
//# sourceMappingURL=events.d.ts.map
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"events.d.ts","sourceRoot":"","sources":["../../src/sequencer/events.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAA;AAGvB,OAAO,EAAE,aAAa,EAAE,M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;;;;;;EAWrB,CAAA;AACF,MAAM,MAAM,UAAU,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,UAAU,CAAC,CAAA;AAEnD,KAAK,cAAc,GAAG;IACpB,IAAI,EAAE,QAAQ,CAAA;IACd,GAAG,EAAE,MAAM,CAAA;IACX,IAAI,EAAE,MAAM,CAAA;IACZ,GAAG,EAAE,SAAS,CAAA;CACf,CAAA;AACD,KAAK,YAAY,GAAG;IAClB,IAAI,EAAE,MAAM,CAAA;IACZ,GAAG,EAAE,MAAM,CAAA;IACX,IAAI,EAAE,MAAM,CAAA;IACZ,GAAG,EAAE,OAAO,CAAA;CACb,CAAA;AACD,KAAK,gBAAgB,GAAG;IACtB,IAAI,EAAE,UAAU,CAAA;IAChB,GAAG,EAAE,MAAM,CAAA;IACX,IAAI,EAAE,MAAM,CAAA;IACZ,GAAG,EAAE,WAAW,CAAA;CACjB,CAAA;AACD,KAAK,eAAe,GAAG;IACrB,IAAI,EAAE,SAAS,CAAA;IACf,GAAG,EAAE,MAAM,CAAA;IACX,IAAI,EAAE,MAAM,CAAA;IACZ,GAAG,EAAE,UAAU,CAAA;CAChB,CAAA;AACD,MAAM,MAAM,MAAM,GACd,cAAc,GACd,YAAY,GACZ,gBAAgB,GAChB,eAAe,CAAA"}
|
package/dist/sequencer/events.js
CHANGED
@@ -1,49 +1,27 @@
|
|
1
1
|
"use strict";
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
3
|
-
exports.
|
3
|
+
exports.accountEvt = exports.identityEvt = exports.syncEvt = exports.commitEvt = exports.commitEvtOp = exports.formatSeqAccountEvt = exports.formatSeqIdentityEvt = exports.formatSeqSyncEvt = exports.formatSeqCommit = void 0;
|
4
4
|
const zod_1 = require("zod");
|
5
5
|
const common_1 = require("@atproto/common");
|
6
6
|
const repo_1 = require("@atproto/repo");
|
7
|
-
const account_manager_1 = require("../account-manager");
|
7
|
+
const account_manager_1 = require("../account-manager/account-manager");
|
8
8
|
const formatSeqCommit = async (did, commitData) => {
|
9
9
|
const blocksToSend = new repo_1.BlockMap();
|
10
10
|
blocksToSend.addMap(commitData.newBlocks);
|
11
11
|
blocksToSend.addMap(commitData.relevantBlocks);
|
12
|
-
|
13
|
-
|
14
|
-
|
15
|
-
|
16
|
-
|
17
|
-
|
18
|
-
|
19
|
-
|
20
|
-
|
21
|
-
|
22
|
-
|
23
|
-
|
24
|
-
|
25
|
-
rev: commitData.rev,
|
26
|
-
since: commitData.since,
|
27
|
-
blocks: await (0, repo_1.blocksToCarFile)(commitData.cid, justRoot),
|
28
|
-
ops: [],
|
29
|
-
blobs: [],
|
30
|
-
prevData: commitData.prevData ?? undefined,
|
31
|
-
};
|
32
|
-
}
|
33
|
-
else {
|
34
|
-
evt = {
|
35
|
-
rebase: false,
|
36
|
-
tooBig: false,
|
37
|
-
repo: did,
|
38
|
-
commit: commitData.cid,
|
39
|
-
rev: commitData.rev,
|
40
|
-
since: commitData.since,
|
41
|
-
blocks: await (0, repo_1.blocksToCarFile)(commitData.cid, blocksToSend),
|
42
|
-
ops: commitData.ops,
|
43
|
-
blobs: commitData.blobs.toList(),
|
44
|
-
prevData: commitData.prevData ?? undefined,
|
45
|
-
};
|
46
|
-
}
|
12
|
+
const evt = {
|
13
|
+
repo: did,
|
14
|
+
commit: commitData.cid,
|
15
|
+
rev: commitData.rev,
|
16
|
+
since: commitData.since,
|
17
|
+
blocks: await (0, repo_1.blocksToCarFile)(commitData.cid, blocksToSend),
|
18
|
+
ops: commitData.ops,
|
19
|
+
prevData: commitData.prevData ?? undefined,
|
20
|
+
// deprecated (but still required) fields
|
21
|
+
rebase: false,
|
22
|
+
tooBig: false,
|
23
|
+
blobs: [],
|
24
|
+
};
|
47
25
|
return {
|
48
26
|
did,
|
49
27
|
eventType: 'append',
|
@@ -52,19 +30,21 @@ const formatSeqCommit = async (did, commitData) => {
|
|
52
30
|
};
|
53
31
|
};
|
54
32
|
exports.formatSeqCommit = formatSeqCommit;
|
55
|
-
const
|
33
|
+
const formatSeqSyncEvt = async (did, data) => {
|
34
|
+
const blocks = await (0, repo_1.blocksToCarFile)(data.cid, data.blocks);
|
56
35
|
const evt = {
|
57
36
|
did,
|
58
|
-
|
37
|
+
rev: data.rev,
|
38
|
+
blocks,
|
59
39
|
};
|
60
40
|
return {
|
61
41
|
did,
|
62
|
-
eventType: '
|
42
|
+
eventType: 'sync',
|
63
43
|
event: (0, common_1.cborEncode)(evt),
|
64
44
|
sequencedAt: new Date().toISOString(),
|
65
45
|
};
|
66
46
|
};
|
67
|
-
exports.
|
47
|
+
exports.formatSeqSyncEvt = formatSeqSyncEvt;
|
68
48
|
const formatSeqIdentityEvt = async (did, handle) => {
|
69
49
|
const evt = {
|
70
50
|
did,
|
@@ -96,18 +76,6 @@ const formatSeqAccountEvt = async (did, status) => {
|
|
96
76
|
};
|
97
77
|
};
|
98
78
|
exports.formatSeqAccountEvt = formatSeqAccountEvt;
|
99
|
-
const formatSeqTombstone = async (did) => {
|
100
|
-
const evt = {
|
101
|
-
did,
|
102
|
-
};
|
103
|
-
return {
|
104
|
-
did,
|
105
|
-
eventType: 'tombstone',
|
106
|
-
event: (0, common_1.cborEncode)(evt),
|
107
|
-
sequencedAt: new Date().toISOString(),
|
108
|
-
};
|
109
|
-
};
|
110
|
-
exports.formatSeqTombstone = formatSeqTombstone;
|
111
79
|
exports.commitEvtOp = zod_1.z.object({
|
112
80
|
action: zod_1.z.union([
|
113
81
|
zod_1.z.literal('create'),
|
@@ -130,9 +98,10 @@ exports.commitEvt = zod_1.z.object({
|
|
130
98
|
blobs: zod_1.z.array(common_1.schema.cid),
|
131
99
|
prevData: common_1.schema.cid.optional(),
|
132
100
|
});
|
133
|
-
exports.
|
101
|
+
exports.syncEvt = zod_1.z.object({
|
134
102
|
did: zod_1.z.string(),
|
135
|
-
|
103
|
+
blocks: common_1.schema.bytes,
|
104
|
+
rev: zod_1.z.string(),
|
136
105
|
});
|
137
106
|
exports.identityEvt = zod_1.z.object({
|
138
107
|
did: zod_1.z.string(),
|
@@ -150,7 +119,4 @@ exports.accountEvt = zod_1.z.object({
|
|
150
119
|
])
|
151
120
|
.optional(),
|
152
121
|
});
|
153
|
-
exports.tombstoneEvt = zod_1.z.object({
|
154
|
-
did: zod_1.z.string(),
|
155
|
-
});
|
156
122
|
//# sourceMappingURL=events.js.map
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"events.js","sourceRoot":"","sources":["../../src/sequencer/events.ts"],"names":[],"mappings":";;;AAAA,6BAAuB;AACvB,4CAAqE;AACrE,wCAAyD;AACzD,
|
1
|
+
{"version":3,"file":"events.js","sourceRoot":"","sources":["../../src/sequencer/events.ts"],"names":[],"mappings":";;;AAAA,6BAAuB;AACvB,4CAAqE;AACrE,wCAAyD;AACzD,wEAAkE;AAI3D,MAAM,eAAe,GAAG,KAAK,EAClC,GAAW,EACX,UAA6B,EACL,EAAE;IAC1B,MAAM,YAAY,GAAG,IAAI,eAAQ,EAAE,CAAA;IACnC,YAAY,CAAC,MAAM,CAAC,UAAU,CAAC,SAAS,CAAC,CAAA;IACzC,YAAY,CAAC,MAAM,CAAC,UAAU,CAAC,cAAc,CAAC,CAAA;IAE9C,MAAM,GAAG,GAAG;QACV,IAAI,EAAE,GAAG;QACT,MAAM,EAAE,UAAU,CAAC,GAAG;QACtB,GAAG,EAAE,UAAU,CAAC,GAAG;QACnB,KAAK,EAAE,UAAU,CAAC,KAAK;QACvB,MAAM,EAAE,MAAM,IAAA,sBAAe,EAAC,UAAU,CAAC,GAAG,EAAE,YAAY,CAAC;QAC3D,GAAG,EAAE,UAAU,CAAC,GAAG;QACnB,QAAQ,EAAE,UAAU,CAAC,QAAQ,IAAI,SAAS;QAC1C,yCAAyC;QACzC,MAAM,EAAE,KAAK;QACb,MAAM,EAAE,KAAK;QACb,KAAK,EAAE,EAAE;KACV,CAAA;IAED,OAAO;QACL,GAAG;QACH,SAAS,EAAE,QAAiB;QAC5B,KAAK,EAAE,IAAA,mBAAU,EAAC,IAAA,wBAAe,EAAC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AAC,MAAM,CAAC;IAC9B,GAAG,EAAE,OAAC,CAAC,MAAM,EAAE;IACf,MAAM,EAAE,eAAM,CAAC,KAAK;IACpB,GAAG,EAAE,OAAC,CAAC,MAAM,EAAE;CAChB,CAAC,CAAA;AAGW,QAAA,WAAW,GAAG,OAAC,CAAC,MAAM,CAAC;IAClC,GAAG,EAAE,OAAC,CAAC,MAAM,EAAE;IACf,MAAM,EAAE,OAAC,CAAC,MAAM,EAAE,CAAC,QAAQ,EAAE;CAC9B,CAAC,CAAA;AAGW,QAAA,UAAU,GAAG,OAAC,CAAC,MAAM,CAAC;IACjC,GAAG,EAAE,OAAC,CAAC,MAAM,EAAE;IACf,MAAM,EAAE,OAAC,CAAC,OAAO,EAAE;IACnB,MAAM,EAAE,OAAC;SACN,IAAI,CAAC;QACJ,+BAAa,CAAC,SAAS;QACvB,+BAAa,CAAC,SAAS;QACvB,+BAAa,CAAC,OAAO;QACrB,+BAAa,CAAC,WAAW;KAC1B,CAAC;SACD,QAAQ,EAAE;CACd,CAAC,CAAA"}
|
@@ -1,7 +1,7 @@
|
|
1
1
|
import TypedEmitter from 'typed-emitter';
|
2
2
|
import { AccountStatus } from '../account-manager/helpers/account';
|
3
3
|
import { Crawlers } from '../crawlers';
|
4
|
-
import { CommitDataWithOps } from '../repo';
|
4
|
+
import { CommitDataWithOps, SyncEvtData } from '../repo';
|
5
5
|
import { RepoSeqEntry, RepoSeqInsert, SequencerDb } from './db';
|
6
6
|
import { SeqEvt } from './events';
|
7
7
|
export * from './events';
|
@@ -29,10 +29,9 @@ export declare class Sequencer extends Sequencer_base {
|
|
29
29
|
private exponentialBackoff;
|
30
30
|
sequenceEvt(evt: RepoSeqInsert): Promise<number>;
|
31
31
|
sequenceCommit(did: string, commitData: CommitDataWithOps): Promise<number>;
|
32
|
-
|
32
|
+
sequenceSyncEvt(did: string, data: SyncEvtData): Promise<number>;
|
33
33
|
sequenceIdentityEvt(did: string, handle?: string): Promise<number>;
|
34
34
|
sequenceAccountEvt(did: string, status: AccountStatus): Promise<number>;
|
35
|
-
sequenceTombstone(did: string): Promise<number>;
|
36
35
|
deleteAllForUser(did: string, excludingSeqs?: number[]): Promise<void>;
|
37
36
|
}
|
38
37
|
type SeqRow = RepoSeqEntry;
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"sequencer.d.ts","sourceRoot":"","sources":["../../src/sequencer/sequencer.ts"],"names":[],"mappings":"AACA,OAAO,YAAY,MAAM,eAAe,CAAA;AAExC,OAAO,EAAE,aAAa,EAAE,MAAM,oCAAoC,CAAA;AAClE,OAAO,EAAE,QAAQ,EAAE,MAAM,aAAa,CAAA;AAEtC,OAAO,EAAE,iBAAiB,EAAE,MAAM,SAAS,CAAA;
|
1
|
+
{"version":3,"file":"sequencer.d.ts","sourceRoot":"","sources":["../../src/sequencer/sequencer.ts"],"names":[],"mappings":"AACA,OAAO,YAAY,MAAM,eAAe,CAAA;AAExC,OAAO,EAAE,aAAa,EAAE,MAAM,oCAAoC,CAAA;AAClE,OAAO,EAAE,QAAQ,EAAE,MAAM,aAAa,CAAA;AAEtC,OAAO,EAAE,iBAAiB,EAAE,WAAW,EAAE,MAAM,SAAS,CAAA;AACxD,OAAO,EACL,YAAY,EACZ,aAAa,EACb,WAAW,EAGZ,MAAM,MAAM,CAAA;AACb,OAAO,EAIL,MAAM,EAMP,MAAM,UAAU,CAAA;AAEjB,cAAc,UAAU,CAAA;wCAEkC,gBAAgB;AAA1E,qBAAa,SAAU,SAAQ,cAA4C;IAQhE,QAAQ,EAAE,QAAQ;IAClB,QAAQ;IARjB,EAAE,EAAE,WAAW,CAAA;IACf,SAAS,UAAQ;IACjB,WAAW,EAAE,OAAO,CAAC,IAAI,CAAC,GAAG,IAAI,CAAO;IACxC,kBAAkB,SAAI;gBAGpB,UAAU,EAAE,MAAM,EACX,QAAQ,EAAE,QAAQ,EAClB,QAAQ,SAAI,EACnB,wBAAwB,UAAQ;IAQ5B,KAAK;IAWL,OAAO;IAQP,IAAI,IAA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ends node_events_1.default {
|
|
143
143
|
continue;
|
144
144
|
}
|
145
145
|
const evt = (0, common_1.cborDecode)(row.event);
|
146
|
-
if (row.eventType === 'append'
|
146
|
+
if (row.eventType === 'append') {
|
147
147
|
seqEvts.push({
|
148
148
|
type: 'commit',
|
149
149
|
seq: row.seq,
|
@@ -151,9 +151,9 @@ class Sequencer extends node_events_1.default {
|
|
151
151
|
evt: evt,
|
152
152
|
});
|
153
153
|
}
|
154
|
-
else if (row.eventType === '
|
154
|
+
else if (row.eventType === 'sync') {
|
155
155
|
seqEvts.push({
|
156
|
-
type: '
|
156
|
+
type: 'sync',
|
157
157
|
seq: row.seq,
|
158
158
|
time: row.sequencedAt,
|
159
159
|
evt: evt,
|
@@ -175,14 +175,6 @@ class Sequencer extends node_events_1.default {
|
|
175
175
|
evt: evt,
|
176
176
|
});
|
177
177
|
}
|
178
|
-
else if (row.eventType === 'tombstone') {
|
179
|
-
seqEvts.push({
|
180
|
-
type: 'tombstone',
|
181
|
-
seq: row.seq,
|
182
|
-
time: row.sequencedAt,
|
183
|
-
evt: evt,
|
184
|
-
});
|
185
|
-
}
|
186
178
|
}
|
187
179
|
return seqEvts;
|
188
180
|
}
|
@@ -226,8 +218,8 @@ class Sequencer extends node_events_1.default {
|
|
226
218
|
const evt = await (0, events_1.formatSeqCommit)(did, commitData);
|
227
219
|
return await this.sequenceEvt(evt);
|
228
220
|
}
|
229
|
-
async
|
230
|
-
const evt = await (0, events_1.
|
221
|
+
async sequenceSyncEvt(did, data) {
|
222
|
+
const evt = await (0, events_1.formatSeqSyncEvt)(did, data);
|
231
223
|
return await this.sequenceEvt(evt);
|
232
224
|
}
|
233
225
|
async sequenceIdentityEvt(did, handle) {
|
@@ -238,10 +230,6 @@ class Sequencer extends node_events_1.default {
|
|
238
230
|
const evt = await (0, events_1.formatSeqAccountEvt)(did, status);
|
239
231
|
return await this.sequenceEvt(evt);
|
240
232
|
}
|
241
|
-
async sequenceTombstone(did) {
|
242
|
-
const evt = await (0, events_1.formatSeqTombstone)(did);
|
243
|
-
return await this.sequenceEvt(evt);
|
244
|
-
}
|
245
233
|
async deleteAllForUser(did, excludingSeqs = []) {
|
246
234
|
await this.db.executeWithRetry(this.db.db
|
247
235
|
.deleteFrom('repo_seq')
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"sequencer.js","sourceRoot":"","sources":["../../src/sequencer/sequencer.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;AAAA,8DAAsC;AAEtC,4CAA0D;AAG1D,sCAA4C;AAE5C,6BAMa;AACb,
|
1
|
+
{"version":3,"file":"sequencer.js","sourceRoot":"","sources":["../../src/sequencer/sequencer.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;AAAA,8DAAsC;AAEtC,4CAA0D;AAG1D,sCAA4C;AAE5C,6BAMa;AACb,qCAUiB;AAEjB,2CAAwB;AAExB,MAAa,SAAU,SAAS,qBAA2C;IAMzE,YACE,UAAkB,EACX,QAAkB,EAClB,WAAW,CAAC,EACnB,wBAAwB,GAAG,KAAK;QAEhC,KAAK,EAAE,CAAA;QAJP;;;;mBAAO,QAAQ;WAAU;QACzB;;;;mBAAO,QAAQ;WAAI;QARrB;;;;;WAAe;QACf;;;;mBAAY,KAAK;WAAA;QACjB;;;;mBAAoC,IAAI;WAAA;QACxC;;;;mBAAqB,CAAC;WAAA;QASpB,0EAA0E;QAC1E,IAAI,CAAC,eAAe,CAAC,GAAG,CAAC,CAAA;QACzB,IAAI,CAAC,EAAE,GAAG,IAAA,UAAK,EAAC,UAAU,EAAE,wBAAwB,CAAC,CAAA;IACvD,CAAC;IAED,KAAK,CAAC,KAAK;QACT,MAAM,IAAI,CAAC,EAAE,CAAC,SAAS,EAAE,CAAA;QACzB,MAAM,QAAQ,GAAG,IAAA,gBAAW,EAAC,IAAI,CAAC,EAAE,CAAC,CAAA;QACrC,MAAM,QAAQ,CAAC,sBAAsB,EAAE,CAAA;QACvC,MAAM,IAAI,GAAG,MAAM,IAAI,CAA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AC,EAAE,CAAC,EAAE;aACP,UAAU,CAAC,UAAU,CAAC;aACtB,KAAK,CAAC,KAAK,EAAE,GAAG,EAAE,GAAG,CAAC;aACtB,EAAE,CAAC,aAAa,CAAC,MAAM,GAAG,CAAC,EAAE,CAAC,EAAE,EAAE,EAAE,CACnC,EAAE,CAAC,KAAK,CAAC,KAAK,EAAE,QAAQ,EAAE,aAAa,CAAC,CACzC,CACJ,CAAA;IACH,CAAC;CACF;AAvND,8BAuNC;AAWD,kBAAe,SAAS,CAAA"}
|
package/package.json
CHANGED
@@ -1,6 +1,6 @@
|
|
1
1
|
{
|
2
2
|
"name": "@atproto/pds",
|
3
|
-
"version": "0.4.
|
3
|
+
"version": "0.4.105",
|
4
4
|
"license": "MIT",
|
5
5
|
"description": "Reference implementation of atproto Personal Data Server (PDS)",
|
6
6
|
"keywords": [
|
@@ -48,19 +48,19 @@
|
|
48
48
|
"uint8arrays": "3.0.0",
|
49
49
|
"undici": "^6.19.8",
|
50
50
|
"zod": "^3.23.8",
|
51
|
-
"@atproto-labs/fetch-node": "0.1.
|
52
|
-
"@atproto-labs/xrpc-utils": "0.0.
|
53
|
-
"@atproto/api": "^0.14.
|
54
|
-
"@atproto/aws": "^0.2.
|
51
|
+
"@atproto-labs/fetch-node": "0.1.8",
|
52
|
+
"@atproto-labs/xrpc-utils": "0.0.8",
|
53
|
+
"@atproto/api": "^0.14.8",
|
54
|
+
"@atproto/aws": "^0.2.17",
|
55
55
|
"@atproto/common": "^0.4.8",
|
56
56
|
"@atproto/crypto": "^0.4.4",
|
57
57
|
"@atproto/identity": "^0.4.6",
|
58
|
-
"@atproto/lexicon": "^0.4.
|
59
|
-
"@atproto/oauth-provider": "^0.
|
60
|
-
"@atproto/repo": "^0.7.
|
61
|
-
"@atproto/syntax": "^0.3.
|
62
|
-
"@atproto/xrpc": "^0.6.
|
63
|
-
"@atproto/xrpc-server": "^0.7.
|
58
|
+
"@atproto/lexicon": "^0.4.8",
|
59
|
+
"@atproto/oauth-provider": "^0.5.0",
|
60
|
+
"@atproto/repo": "^0.7.1",
|
61
|
+
"@atproto/syntax": "^0.3.4",
|
62
|
+
"@atproto/xrpc": "^0.6.10",
|
63
|
+
"@atproto/xrpc-server": "^0.7.12"
|
64
64
|
},
|
65
65
|
"devDependencies": {
|
66
66
|
"@atproto/pds-entryway": "npm:@atproto/pds@0.3.0-entryway.3",
|
@@ -78,10 +78,10 @@
|
|
78
78
|
"ts-node": "^10.8.2",
|
79
79
|
"typescript": "^5.6.3",
|
80
80
|
"ws": "^8.12.0",
|
81
|
-
"@atproto/api": "^0.14.
|
82
|
-
"@atproto/bsky": "^0.0.
|
83
|
-
"@atproto/lex-cli": "^0.6.
|
84
|
-
"@atproto/oauth-client-browser-example": "0.0.
|
81
|
+
"@atproto/api": "^0.14.8",
|
82
|
+
"@atproto/bsky": "^0.0.125",
|
83
|
+
"@atproto/lex-cli": "^0.6.2",
|
84
|
+
"@atproto/oauth-client-browser-example": "0.0.2"
|
85
85
|
},
|
86
86
|
"scripts": {
|
87
87
|
"codegen": "lex gen-server --yes ./src/lexicon ../../lexicons/com/atproto/*/* ../../lexicons/app/bsky/*/* ../../lexicons/chat/bsky/*/* ../../lexicons/tools/ozone/*/*",
|