From 78471cca5c5545c173651e62fc6f347db0cee7eb Mon Sep 17 00:00:00 2001 From: Sina Iman Date: Mon, 9 Sep 2024 15:19:59 +0200 Subject: [PATCH 01/81] sentry update --- desci-server/.gitignore | 3 + desci-server/package.json | 10 +- desci-server/src/server.ts | 4 +- desci-server/tsconfig.json | 14 +- desci-server/yarn.lock | 506 ++++++++++++++++++++++++++++++++++--- 5 files changed, 488 insertions(+), 49 deletions(-) diff --git a/desci-server/.gitignore b/desci-server/.gitignore index e9b57f85c..358616150 100755 --- a/desci-server/.gitignore +++ b/desci-server/.gitignore @@ -16,3 +16,6 @@ server.log repo-tmp queries.sql + +# Sentry Config File +.sentryclirc diff --git a/desci-server/package.json b/desci-server/package.json index 7db90e069..9735e4a81 100755 --- a/desci-server/package.json +++ b/desci-server/package.json @@ -25,7 +25,7 @@ "script:seed-social-data": "debug=* node --no-warnings --enable-source-maps --loader ts-node/esm ./src/scripts/seed-social-data.ts", "script:DESTRUCTIVE-clear-social-data": "debug=* node --no-warnings --enable-source-maps --loader ts-node/esm ./src/scripts/DESTRUCTIVE-clear-social-data.ts", "script:seed-community-member": "debug=* node --no-warnings --enable-source-maps --loader ts-node/esm ./src/scripts/seed-community-members.ts", - "build": "rimraf dist && tsc && yarn copy-files", + "build": "rimraf dist && tsc && yarn copy-files && yarn sentry:sourcemaps", "copy-files": "copyfiles -u 1 src/**/*.cjs dist/", "generate": "npx prisma generate", "migrate:local": "DATABASE_URL=postgresql://walter:white@localhost:5433/boilerplate npx prisma migrate dev", @@ -50,7 +50,8 @@ "docker:prod": "../dockerProd.sh", "podman:dev": "podman-compose --file docker-compose.yml --file docker-compose.dev.yml up --build", "email-dev": "email dev --dir ./src/templates/emails --port 3777", - "check-deps": "npx npm-check" + "check-deps": "npx npm-check", + "sentry:sourcemaps": "sentry-cli sourcemaps inject --org desci-labs --project nodes-backend ./dist && sentry-cli sourcemaps upload --org desci-labs --project nodes-backend ./dist" }, "dependencies": { "@automerge/automerge-repo": "^1.0.19", @@ -68,7 +69,8 @@ "@prisma/client": "4.10.1", "@react-email/components": "0.0.15", "@sendgrid/mail": "^7.7.0", - "@sentry/node": "^7.12.0", + "@sentry/cli": "^2.35.0", + "@sentry/node": "^8.29.0", "@sentry/tracing": "^7.12.0", "@types/lodash-es": "^4.17.12", "@types/mkdirp": "^1.0.2", @@ -182,4 +184,4 @@ "prisma": { "seed": "node --no-warnings=ExperimentalWarning --loader ts-node/esm prisma/seed.ts" } -} +} \ No newline at end of file diff --git a/desci-server/src/server.ts b/desci-server/src/server.ts index 392fecc1a..a84f90f26 100644 --- a/desci-server/src/server.ts +++ b/desci-server/src/server.ts @@ -230,9 +230,7 @@ class AppServer { // We recommend adjusting this value in production tracesSampleRate: 1.0, }); - this.app.use(Sentry.Handlers.requestHandler()); - this.app.use(Sentry.Handlers.tracingHandler()); - this.app.use(Sentry.Handlers.errorHandler()); + Sentry.setupExpressErrorHandler(this.app); } else { logger.info('[DeSci Nodes] Telemetry disabled'); } diff --git a/desci-server/tsconfig.json b/desci-server/tsconfig.json index 6b32eb774..c0d0c4e60 100755 --- a/desci-server/tsconfig.json +++ b/desci-server/tsconfig.json @@ -13,6 +13,7 @@ // "verbatimModuleSyntax": true, "lib": ["esnext", "dom"], + "outDir": "./dist", "removeComments": true, "emitDecoratorMetadata": true, @@ -21,14 +22,23 @@ "noImplicitReturns": true, "noFallthroughCasesInSwitch": true, "skipLibCheck": true, + // dagConcat.cjs requires this "allowJs": true, - "inlineSourceMap": true, + "paths": { // Overrides a built-in Response type "express": ["./src/types/express"] }, - "jsx": "react" + + "jsx": "react", + "sourceMap": true, + "inlineSources": true, + + // Set `sourceRoot` to "/" to strip the build path prefix + // from generated source code references. + // This improves issue grouping in Sentry. + "sourceRoot": "/" }, "include": ["./src/**/*.tsx", "./src/**/*.ts", "./src/**/*.cjs", "src/utils/dagConcat.ts"], "exclude": ["test/**/*.ts"], diff --git a/desci-server/yarn.lock b/desci-server/yarn.lock index 0385be942..9909ed205 100644 --- a/desci-server/yarn.lock +++ b/desci-server/yarn.lock @@ -3605,7 +3605,21 @@ dependencies: "@opentelemetry/api" "^1.0.0" -"@opentelemetry/api@1.x": +"@opentelemetry/api-logs@0.52.1": + version "0.52.1" + resolved "https://registry.yarnpkg.com/@opentelemetry/api-logs/-/api-logs-0.52.1.tgz#52906375da4d64c206b0c4cb8ffa209214654ecc" + integrity sha512-qnSqB2DQ9TPP96dl8cDubDvrUyWc0/sK81xHTK8eSUspzDM3bsewX903qclQFvVhgStjRWdC5bLb3kQqMkfV5A== + dependencies: + "@opentelemetry/api" "^1.0.0" + +"@opentelemetry/api-logs@0.53.0": + version "0.53.0" + resolved "https://registry.yarnpkg.com/@opentelemetry/api-logs/-/api-logs-0.53.0.tgz#c478cbd8120ec2547b64edfa03a552cfe42170be" + integrity sha512-8HArjKx+RaAI8uEIgcORbZIPklyh1YLjPSBus8hjRmvLi6DeFzgOcdZ7KwPabKj8mXF8dX0hyfAyGfycz0DbFw== + dependencies: + "@opentelemetry/api" "^1.0.0" + +"@opentelemetry/api@1.x", "@opentelemetry/api@^1.8", "@opentelemetry/api@^1.9.0": version "1.9.0" resolved "https://registry.yarnpkg.com/@opentelemetry/api/-/api-1.9.0.tgz#d03eba68273dc0f7509e2a3d5cba21eae10379fe" integrity sha512-3giAOQvZiH5F9bMlMiv8+GSPMeqg0dbaeo58/0SlA9sxSqZhnUtxzX9/2FzyhS9sWQf5S0GJE0AKBrFqjpeYcg== @@ -3674,6 +3688,11 @@ resolved "https://registry.yarnpkg.com/@opentelemetry/context-async-hooks/-/context-async-hooks-1.8.0.tgz#6141ff59f7c07fac8eda3f9f208b6aaf06893471" integrity sha512-ueLmocbWDi1aoU4IPdOQyt4qz/Dx+NYyU4qoa3d683usbnkDLUXYXJFfKIMPFV2BbrI5qtnpTtzErCKewoM8aw== +"@opentelemetry/context-async-hooks@^1.25.1": + version "1.26.0" + resolved "https://registry.yarnpkg.com/@opentelemetry/context-async-hooks/-/context-async-hooks-1.26.0.tgz#fa92f722cf685685334bba95f258d3ef9fce60f6" + integrity sha512-HedpXXYzzbaoutw6DFLWLDket2FwLkLpil4hGCZ1xYEIMTcivdfwEOISgdbLEWyG3HW52gTq2V9mOVJrONgiwg== + "@opentelemetry/core@1.14.0": version "1.14.0" resolved "https://registry.yarnpkg.com/@opentelemetry/core/-/core-1.14.0.tgz#64e876b29cb736c984d54164cd47433f513eafd3" @@ -3702,6 +3721,13 @@ dependencies: "@opentelemetry/semantic-conventions" "1.25.0" +"@opentelemetry/core@1.26.0", "@opentelemetry/core@^1.1.0", "@opentelemetry/core@^1.25.1": + version "1.26.0" + resolved "https://registry.yarnpkg.com/@opentelemetry/core/-/core-1.26.0.tgz#7d84265aaa850ed0ca5813f97d831155be42b328" + integrity sha512-1iKxXXE8415Cdv0yjG3G6hQnB5eVEsJce3QaawX8SjDn0mAS0ZM8fAbZZJD4ajvhC15cePvosSCut404KrIIvQ== + dependencies: + "@opentelemetry/semantic-conventions" "1.27.0" + "@opentelemetry/core@1.8.0": version "1.8.0" resolved "https://registry.yarnpkg.com/@opentelemetry/core/-/core-1.8.0.tgz#cca18594dd48ded6dc0d08c7e789c79af0315934" @@ -3933,6 +3959,16 @@ "@opentelemetry/instrumentation" "^0.40.0" "@opentelemetry/semantic-conventions" "^1.0.0" +"@opentelemetry/instrumentation-connect@0.39.0": + version "0.39.0" + resolved "https://registry.yarnpkg.com/@opentelemetry/instrumentation-connect/-/instrumentation-connect-0.39.0.tgz#32bdbaac464cba061c95df6c850ee81efdd86f8b" + integrity sha512-pGBiKevLq7NNglMgqzmeKczF4XQMTOUOTkK8afRHMZMnrK3fcETyTH7lVaSozwiOM3Ws+SuEmXZT7DYrrhxGlg== + dependencies: + "@opentelemetry/core" "^1.8.0" + "@opentelemetry/instrumentation" "^0.53.0" + "@opentelemetry/semantic-conventions" "^1.27.0" + "@types/connect" "3.4.36" + "@opentelemetry/instrumentation-connect@^0.31.4": version "0.31.4" resolved "https://registry.yarnpkg.com/@opentelemetry/instrumentation-connect/-/instrumentation-connect-0.31.4.tgz#c1693d26f103dc133cb6a9708cc9ed2fda288a52" @@ -3959,6 +3995,15 @@ "@opentelemetry/semantic-conventions" "^1.0.0" semver "^7.3.2" +"@opentelemetry/instrumentation-express@0.42.0": + version "0.42.0" + resolved "https://registry.yarnpkg.com/@opentelemetry/instrumentation-express/-/instrumentation-express-0.42.0.tgz#279f195aa66baee2b98623a16666c6229c8e7564" + integrity sha512-YNcy7ZfGnLsVEqGXQPT+S0G1AE46N21ORY7i7yUQyfhGAL4RBjnZUqefMI0NwqIl6nGbr1IpF0rZGoN8Q7x12Q== + dependencies: + "@opentelemetry/core" "^1.8.0" + "@opentelemetry/instrumentation" "^0.53.0" + "@opentelemetry/semantic-conventions" "^1.27.0" + "@opentelemetry/instrumentation-express@^0.32.4": version "0.32.4" resolved "https://registry.yarnpkg.com/@opentelemetry/instrumentation-express/-/instrumentation-express-0.32.4.tgz#bced338cc6c2a5aeb3433f12302c0460207c7090" @@ -3969,6 +4014,15 @@ "@opentelemetry/semantic-conventions" "^1.0.0" "@types/express" "4.17.13" +"@opentelemetry/instrumentation-fastify@0.39.0": + version "0.39.0" + resolved "https://registry.yarnpkg.com/@opentelemetry/instrumentation-fastify/-/instrumentation-fastify-0.39.0.tgz#96a040e4944daf77c53a8fe5a128bc3b2568e4aa" + integrity sha512-SS9uSlKcsWZabhBp2szErkeuuBDgxOUlllwkS92dVaWRnMmwysPhcEgHKB8rUe3BHg/GnZC1eo1hbTZv4YhfoA== + dependencies: + "@opentelemetry/core" "^1.8.0" + "@opentelemetry/instrumentation" "^0.53.0" + "@opentelemetry/semantic-conventions" "^1.27.0" + "@opentelemetry/instrumentation-fastify@^0.31.4": version "0.31.4" resolved "https://registry.yarnpkg.com/@opentelemetry/instrumentation-fastify/-/instrumentation-fastify-0.31.4.tgz#d3a17a190ba0b258330423982f7437c66e8f2b70" @@ -3978,6 +4032,14 @@ "@opentelemetry/instrumentation" "^0.40.0" "@opentelemetry/semantic-conventions" "^1.0.0" +"@opentelemetry/instrumentation-fs@0.15.0": + version "0.15.0" + resolved "https://registry.yarnpkg.com/@opentelemetry/instrumentation-fs/-/instrumentation-fs-0.15.0.tgz#41658507860f39fee5209bca961cea8d24ca2a83" + integrity sha512-JWVKdNLpu1skqZQA//jKOcKdJC66TWKqa2FUFq70rKohvaSq47pmXlnabNO+B/BvLfmidfiaN35XakT5RyMl2Q== + dependencies: + "@opentelemetry/core" "^1.8.0" + "@opentelemetry/instrumentation" "^0.53.0" + "@opentelemetry/instrumentation-fs@^0.7.4": version "0.7.4" resolved "https://registry.yarnpkg.com/@opentelemetry/instrumentation-fs/-/instrumentation-fs-0.7.4.tgz#28a15842fc9b8d373f87c7fbf560049717f58156" @@ -3987,6 +4049,13 @@ "@opentelemetry/instrumentation" "^0.40.0" "@opentelemetry/semantic-conventions" "^1.0.0" +"@opentelemetry/instrumentation-generic-pool@0.39.0": + version "0.39.0" + resolved "https://registry.yarnpkg.com/@opentelemetry/instrumentation-generic-pool/-/instrumentation-generic-pool-0.39.0.tgz#2b9af16ad82d5cbe67125c0125753cecd162a728" + integrity sha512-y4v8Y+tSfRB3NNBvHjbjrn7rX/7sdARG7FuK6zR8PGb28CTa0kHpEGCJqvL9L8xkTNvTXo+lM36ajFGUaK1aNw== + dependencies: + "@opentelemetry/instrumentation" "^0.53.0" + "@opentelemetry/instrumentation-generic-pool@^0.31.4": version "0.31.4" resolved "https://registry.yarnpkg.com/@opentelemetry/instrumentation-generic-pool/-/instrumentation-generic-pool-0.31.4.tgz#049efa886f666c9e21cf0f32c06ef45642cbf992" @@ -3996,6 +4065,13 @@ "@opentelemetry/semantic-conventions" "^1.0.0" "@types/generic-pool" "^3.1.9" +"@opentelemetry/instrumentation-graphql@0.43.0": + version "0.43.0" + resolved "https://registry.yarnpkg.com/@opentelemetry/instrumentation-graphql/-/instrumentation-graphql-0.43.0.tgz#71bb94ea775c70dbd388c739b397ec1418f3f170" + integrity sha512-aI3YMmC2McGd8KW5du1a2gBA0iOMOGLqg4s9YjzwbjFwjlmMNFSK1P3AIg374GWg823RPUGfVTIgZ/juk9CVOA== + dependencies: + "@opentelemetry/instrumentation" "^0.53.0" + "@opentelemetry/instrumentation-graphql@^0.34.3": version "0.34.3" resolved "https://registry.yarnpkg.com/@opentelemetry/instrumentation-graphql/-/instrumentation-graphql-0.34.3.tgz#f55cb9223f616a27c8fa4303ee8c8b8f64059ddd" @@ -4011,6 +4087,15 @@ "@opentelemetry/instrumentation" "0.40.0" "@opentelemetry/semantic-conventions" "1.14.0" +"@opentelemetry/instrumentation-hapi@0.41.0": + version "0.41.0" + resolved "https://registry.yarnpkg.com/@opentelemetry/instrumentation-hapi/-/instrumentation-hapi-0.41.0.tgz#de8711907256d8fae1b5faf71fc825cef4a7ddbb" + integrity sha512-jKDrxPNXDByPlYcMdZjNPYCvw0SQJjN+B1A+QH+sx+sAHsKSAf9hwFiJSrI6C4XdOls43V/f/fkp9ITkHhKFbQ== + dependencies: + "@opentelemetry/core" "^1.8.0" + "@opentelemetry/instrumentation" "^0.53.0" + "@opentelemetry/semantic-conventions" "^1.27.0" + "@opentelemetry/instrumentation-hapi@^0.31.4": version "0.31.4" resolved "https://registry.yarnpkg.com/@opentelemetry/instrumentation-hapi/-/instrumentation-hapi-0.31.4.tgz#df54ed4d36618f5adff0235bd95e68ae0da7ecd0" @@ -4021,6 +4106,16 @@ "@opentelemetry/semantic-conventions" "^1.0.0" "@types/hapi__hapi" "20.0.9" +"@opentelemetry/instrumentation-http@0.53.0": + version "0.53.0" + resolved "https://registry.yarnpkg.com/@opentelemetry/instrumentation-http/-/instrumentation-http-0.53.0.tgz#0d806adf1b3aba036bc46e16162e3c0dbb8a6b60" + integrity sha512-H74ErMeDuZfj7KgYCTOFGWF5W9AfaPnqLQQxeFq85+D29wwV2yqHbz2IKLYpkOh7EI6QwDEl7rZCIxjJLyc/CQ== + dependencies: + "@opentelemetry/core" "1.26.0" + "@opentelemetry/instrumentation" "0.53.0" + "@opentelemetry/semantic-conventions" "1.27.0" + semver "^7.5.2" + "@opentelemetry/instrumentation-http@^0.40.0": version "0.40.0" resolved "https://registry.yarnpkg.com/@opentelemetry/instrumentation-http/-/instrumentation-http-0.40.0.tgz#ed4206ea96d64b5fd83b796f027642e42dca0cd1" @@ -4031,6 +4126,15 @@ "@opentelemetry/semantic-conventions" "1.14.0" semver "^7.3.5" +"@opentelemetry/instrumentation-ioredis@0.43.0": + version "0.43.0" + resolved "https://registry.yarnpkg.com/@opentelemetry/instrumentation-ioredis/-/instrumentation-ioredis-0.43.0.tgz#dbadabaeefc4cb47c406f878444f1bcac774fa89" + integrity sha512-i3Dke/LdhZbiUAEImmRG3i7Dimm/BD7t8pDDzwepSvIQ6s2X6FPia7561gw+64w+nx0+G9X14D7rEfaMEmmjig== + dependencies: + "@opentelemetry/instrumentation" "^0.53.0" + "@opentelemetry/redis-common" "^0.36.2" + "@opentelemetry/semantic-conventions" "^1.27.0" + "@opentelemetry/instrumentation-ioredis@^0.34.3": version "0.34.3" resolved "https://registry.yarnpkg.com/@opentelemetry/instrumentation-ioredis/-/instrumentation-ioredis-0.34.3.tgz#95fb4b6ff2b5eb29e01ee8d36ec24c69f2996019" @@ -4049,6 +4153,15 @@ "@opentelemetry/instrumentation" "^0.40.0" "@opentelemetry/semantic-conventions" "^1.0.0" +"@opentelemetry/instrumentation-koa@0.43.0": + version "0.43.0" + resolved "https://registry.yarnpkg.com/@opentelemetry/instrumentation-koa/-/instrumentation-koa-0.43.0.tgz#963fd192a1b5f6cbae5dabf4ec82e3105cbb23b1" + integrity sha512-lDAhSnmoTIN6ELKmLJBplXzT/Jqs5jGZehuG22EdSMaTwgjMpxMDI1YtlKEhiWPWkrz5LUsd0aOO0ZRc9vn3AQ== + dependencies: + "@opentelemetry/core" "^1.8.0" + "@opentelemetry/instrumentation" "^0.53.0" + "@opentelemetry/semantic-conventions" "^1.27.0" + "@opentelemetry/instrumentation-koa@^0.34.6": version "0.34.6" resolved "https://registry.yarnpkg.com/@opentelemetry/instrumentation-koa/-/instrumentation-koa-0.34.6.tgz#88f2ab16f94f7c41bcd4b3487c254f9374a438c1" @@ -4076,6 +4189,15 @@ "@opentelemetry/semantic-conventions" "^1.0.0" "@types/memcached" "^2.2.6" +"@opentelemetry/instrumentation-mongodb@0.47.0": + version "0.47.0" + resolved "https://registry.yarnpkg.com/@opentelemetry/instrumentation-mongodb/-/instrumentation-mongodb-0.47.0.tgz#f8107d878281433905e717f223fb4c0f10356a7b" + integrity sha512-yqyXRx2SulEURjgOQyJzhCECSh5i1uM49NUaq9TqLd6fA7g26OahyJfsr9NE38HFqGRHpi4loyrnfYGdrsoVjQ== + dependencies: + "@opentelemetry/instrumentation" "^0.53.0" + "@opentelemetry/sdk-metrics" "^1.9.1" + "@opentelemetry/semantic-conventions" "^1.27.0" + "@opentelemetry/instrumentation-mongodb@^0.35.0": version "0.35.0" resolved "https://registry.yarnpkg.com/@opentelemetry/instrumentation-mongodb/-/instrumentation-mongodb-0.35.0.tgz#6ec571ef1c2ad8c88724ace826fdaf060dc8076a" @@ -4085,6 +4207,15 @@ "@opentelemetry/sdk-metrics" "^1.9.1" "@opentelemetry/semantic-conventions" "^1.0.0" +"@opentelemetry/instrumentation-mongoose@0.42.0": + version "0.42.0" + resolved "https://registry.yarnpkg.com/@opentelemetry/instrumentation-mongoose/-/instrumentation-mongoose-0.42.0.tgz#375afd21adfcd897a8f521c1ffd2d91e6a428705" + integrity sha512-AnWv+RaR86uG3qNEMwt3plKX1ueRM7AspfszJYVkvkehiicC3bHQA6vWdb6Zvy5HAE14RyFbu9+2hUUjR2NSyg== + dependencies: + "@opentelemetry/core" "^1.8.0" + "@opentelemetry/instrumentation" "^0.53.0" + "@opentelemetry/semantic-conventions" "^1.27.0" + "@opentelemetry/instrumentation-mongoose@^0.32.4": version "0.32.4" resolved "https://registry.yarnpkg.com/@opentelemetry/instrumentation-mongoose/-/instrumentation-mongoose-0.32.4.tgz#f421d477264abd46e66d78ac65ca59f98c39b07c" @@ -4094,6 +4225,15 @@ "@opentelemetry/instrumentation" "^0.40.0" "@opentelemetry/semantic-conventions" "^1.0.0" +"@opentelemetry/instrumentation-mysql2@0.41.0": + version "0.41.0" + resolved "https://registry.yarnpkg.com/@opentelemetry/instrumentation-mysql2/-/instrumentation-mysql2-0.41.0.tgz#6377b6e2d2487fd88e1d79aa03658db6c8d51651" + integrity sha512-REQB0x+IzVTpoNgVmy5b+UnH1/mDByrneimP6sbDHkp1j8QOl1HyWOrBH/6YWR0nrbU3l825Em5PlybjT3232g== + dependencies: + "@opentelemetry/instrumentation" "^0.53.0" + "@opentelemetry/semantic-conventions" "^1.27.0" + "@opentelemetry/sql-common" "^0.40.1" + "@opentelemetry/instrumentation-mysql2@^0.33.4": version "0.33.4" resolved "https://registry.yarnpkg.com/@opentelemetry/instrumentation-mysql2/-/instrumentation-mysql2-0.33.4.tgz#fd69e38d1b5eefff6e4362fc257e60c5bec5a10f" @@ -4102,6 +4242,15 @@ "@opentelemetry/instrumentation" "^0.40.0" "@opentelemetry/semantic-conventions" "^1.0.0" +"@opentelemetry/instrumentation-mysql@0.41.0": + version "0.41.0" + resolved "https://registry.yarnpkg.com/@opentelemetry/instrumentation-mysql/-/instrumentation-mysql-0.41.0.tgz#2d50691ead5219774bd36d66c35d5b4681485dd7" + integrity sha512-jnvrV6BsQWyHS2qb2fkfbfSb1R/lmYwqEZITwufuRl37apTopswu9izc0b1CYRp/34tUG/4k/V39PND6eyiNvw== + dependencies: + "@opentelemetry/instrumentation" "^0.53.0" + "@opentelemetry/semantic-conventions" "^1.27.0" + "@types/mysql" "2.15.26" + "@opentelemetry/instrumentation-mysql@^0.33.3": version "0.33.3" resolved "https://registry.yarnpkg.com/@opentelemetry/instrumentation-mysql/-/instrumentation-mysql-0.33.3.tgz#1f09c9cd19d971c2d5f142bb83c35f25c72975d9" @@ -4111,6 +4260,14 @@ "@opentelemetry/semantic-conventions" "^1.0.0" "@types/mysql" "2.15.19" +"@opentelemetry/instrumentation-nestjs-core@0.40.0": + version "0.40.0" + resolved "https://registry.yarnpkg.com/@opentelemetry/instrumentation-nestjs-core/-/instrumentation-nestjs-core-0.40.0.tgz#2c0e6405b56caaec32747d55c57ff9a034668ea8" + integrity sha512-WF1hCUed07vKmf5BzEkL0wSPinqJgH7kGzOjjMAiTGacofNXjb/y4KQ8loj2sNsh5C/NN7s1zxQuCgbWbVTGKg== + dependencies: + "@opentelemetry/instrumentation" "^0.53.0" + "@opentelemetry/semantic-conventions" "^1.27.0" + "@opentelemetry/instrumentation-nestjs-core@^0.32.5": version "0.32.5" resolved "https://registry.yarnpkg.com/@opentelemetry/instrumentation-nestjs-core/-/instrumentation-nestjs-core-0.32.5.tgz#ed4f81651f141a298b3a8d6107f50bc47b66004b" @@ -4127,6 +4284,17 @@ "@opentelemetry/instrumentation" "^0.40.0" "@opentelemetry/semantic-conventions" "^1.0.0" +"@opentelemetry/instrumentation-pg@0.44.0": + version "0.44.0" + resolved "https://registry.yarnpkg.com/@opentelemetry/instrumentation-pg/-/instrumentation-pg-0.44.0.tgz#1e97a0aeb2dca068ee23ce75884a0a0063a7ce3f" + integrity sha512-oTWVyzKqXud1BYEGX1loo2o4k4vaU1elr3vPO8NZolrBtFvQ34nx4HgUaexUDuEog00qQt+MLR5gws/p+JXMLQ== + dependencies: + "@opentelemetry/instrumentation" "^0.53.0" + "@opentelemetry/semantic-conventions" "^1.27.0" + "@opentelemetry/sql-common" "^0.40.1" + "@types/pg" "8.6.1" + "@types/pg-pool" "2.0.6" + "@opentelemetry/instrumentation-pg@^0.35.3": version "0.35.3" resolved "https://registry.yarnpkg.com/@opentelemetry/instrumentation-pg/-/instrumentation-pg-0.35.3.tgz#47b29891e2be797a2148e699bb43094fdf33a281" @@ -4145,6 +4313,15 @@ dependencies: "@opentelemetry/instrumentation" "^0.40.0" +"@opentelemetry/instrumentation-redis-4@0.42.0": + version "0.42.0" + resolved "https://registry.yarnpkg.com/@opentelemetry/instrumentation-redis-4/-/instrumentation-redis-4-0.42.0.tgz#fc01104cfe884c7546385eaae03c57a47edd19d1" + integrity sha512-NaD+t2JNcOzX/Qa7kMy68JbmoVIV37fT/fJYzLKu2Wwd+0NCxt+K2OOsOakA8GVg8lSpFdbx4V/suzZZ2Pvdjg== + dependencies: + "@opentelemetry/instrumentation" "^0.53.0" + "@opentelemetry/redis-common" "^0.36.2" + "@opentelemetry/semantic-conventions" "^1.27.0" + "@opentelemetry/instrumentation-redis-4@^0.34.6": version "0.34.6" resolved "https://registry.yarnpkg.com/@opentelemetry/instrumentation-redis-4/-/instrumentation-redis-4-0.34.6.tgz#2503f33b60f2cbe3311558fc95037d348e020575" @@ -4224,6 +4401,41 @@ semver "^7.3.2" shimmer "^1.2.1" +"@opentelemetry/instrumentation@0.53.0", "@opentelemetry/instrumentation@^0.53.0": + version "0.53.0" + resolved "https://registry.yarnpkg.com/@opentelemetry/instrumentation/-/instrumentation-0.53.0.tgz#e6369e4015eb5112468a4d45d38dcada7dad892d" + integrity sha512-DMwg0hy4wzf7K73JJtl95m/e0boSoWhH07rfvHvYzQtBD3Bmv0Wc1x733vyZBqmFm8OjJD0/pfiUg1W3JjFX0A== + dependencies: + "@opentelemetry/api-logs" "0.53.0" + "@types/shimmer" "^1.2.0" + import-in-the-middle "^1.8.1" + require-in-the-middle "^7.1.1" + semver "^7.5.2" + shimmer "^1.2.1" + +"@opentelemetry/instrumentation@^0.46.0": + version "0.46.0" + resolved "https://registry.yarnpkg.com/@opentelemetry/instrumentation/-/instrumentation-0.46.0.tgz#a8a252306f82e2eace489312798592a14eb9830e" + integrity sha512-a9TijXZZbk0vI5TGLZl+0kxyFfrXHhX6Svtz7Pp2/VBlCSKrazuULEyoJQrOknJyFWNMEmbbJgOciHCCpQcisw== + dependencies: + "@types/shimmer" "^1.0.2" + import-in-the-middle "1.7.1" + require-in-the-middle "^7.1.1" + semver "^7.5.2" + shimmer "^1.2.1" + +"@opentelemetry/instrumentation@^0.49 || ^0.50 || ^0.51 || ^0.52.0": + version "0.52.1" + resolved "https://registry.yarnpkg.com/@opentelemetry/instrumentation/-/instrumentation-0.52.1.tgz#2e7e46a38bd7afbf03cf688c862b0b43418b7f48" + integrity sha512-uXJbYU/5/MBHjMp1FqrILLRuiJCs3Ofk0MeRDk8g1S1gD47U8X3JnSwcMO1rtRo1x1a7zKaQHaoYu49p/4eSKw== + dependencies: + "@opentelemetry/api-logs" "0.52.1" + "@types/shimmer" "^1.0.2" + import-in-the-middle "^1.8.1" + require-in-the-middle "^7.1.1" + semver "^7.5.2" + shimmer "^1.2.1" + "@opentelemetry/otlp-exporter-base@0.34.0": version "0.34.0" resolved "https://registry.yarnpkg.com/@opentelemetry/otlp-exporter-base/-/otlp-exporter-base-0.34.0.tgz#c6020b63590d4b8ac3833eda345a6f582fa014b1" @@ -4362,6 +4574,11 @@ resolved "https://registry.yarnpkg.com/@opentelemetry/redis-common/-/redis-common-0.35.1.tgz#01356f6845d4f9f9fdfd2c4c562a74316d2d24d3" integrity sha512-qLXe7h9VzFLx3LaizFiUlpuohCRyvHlDW5b9synE6omHKTZr/n0EHEdmhp3GezBeAqMGI+q499Mht4SmStaSqQ== +"@opentelemetry/redis-common@^0.36.2": + version "0.36.2" + resolved "https://registry.yarnpkg.com/@opentelemetry/redis-common/-/redis-common-0.36.2.tgz#906ac8e4d804d4109f3ebd5c224ac988276fdc47" + integrity sha512-faYX1N0gpLhej/6nyp6bgRjzAKXn5GOEMYY7YhciSfCoITAktLUtQ36d24QEWNA1/WA1y6qQunCe0OhHRkVl9g== + "@opentelemetry/resource-detector-alibaba-cloud@^0.27.7": version "0.27.7" resolved "https://registry.yarnpkg.com/@opentelemetry/resource-detector-alibaba-cloud/-/resource-detector-alibaba-cloud-0.27.7.tgz#9eccdbf3b70eb891dcbd8f36a8019610ce838254" @@ -4429,6 +4646,14 @@ "@opentelemetry/core" "1.25.0" "@opentelemetry/semantic-conventions" "1.25.0" +"@opentelemetry/resources@1.26.0", "@opentelemetry/resources@^1.25.1": + version "1.26.0" + resolved "https://registry.yarnpkg.com/@opentelemetry/resources/-/resources-1.26.0.tgz#da4c7366018bd8add1f3aa9c91c6ac59fd503cef" + integrity sha512-CPNYchBE7MBecCSVy0HKpUISEeJOniWqcHaAHpmasZ3j9o6V3AyBzhRc90jdmemq0HOxDr6ylhUbDhBqqPpeNw== + dependencies: + "@opentelemetry/core" "1.26.0" + "@opentelemetry/semantic-conventions" "1.27.0" + "@opentelemetry/resources@1.8.0": version "1.8.0" resolved "https://registry.yarnpkg.com/@opentelemetry/resources/-/resources-1.8.0.tgz#260be9742cf7bceccc0db928d8ca8d64391acfe3" @@ -4561,6 +4786,15 @@ "@opentelemetry/resources" "1.8.0" "@opentelemetry/semantic-conventions" "1.8.0" +"@opentelemetry/sdk-trace-base@^1.22", "@opentelemetry/sdk-trace-base@^1.25.1": + version "1.26.0" + resolved "https://registry.yarnpkg.com/@opentelemetry/sdk-trace-base/-/sdk-trace-base-1.26.0.tgz#0c913bc6d2cfafd901de330e4540952269ae579c" + integrity sha512-olWQldtvbK4v22ymrKLbIcBi9L2SpMO84sCPY54IVsJhP9fRsxJT194C/AVaAuJzLE30EdhhM1VmvVYR7az+cw== + dependencies: + "@opentelemetry/core" "1.26.0" + "@opentelemetry/resources" "1.26.0" + "@opentelemetry/semantic-conventions" "1.27.0" + "@opentelemetry/sdk-trace-base@^1.23.0": version "1.25.0" resolved "https://registry.yarnpkg.com/@opentelemetry/sdk-trace-base/-/sdk-trace-base-1.25.0.tgz#263f9ce19001c5cd7a814d0eb40ebc6469ae763d" @@ -4623,11 +4857,23 @@ resolved "https://registry.yarnpkg.com/@opentelemetry/semantic-conventions/-/semantic-conventions-1.25.0.tgz#390eb4d42a29c66bdc30066af9035645e9bb7270" integrity sha512-M+kkXKRAIAiAP6qYyesfrC5TOmDpDVtsxuGfPcqd9B/iBrac+E14jYwrgm0yZBUIbIP2OnqC3j+UgkXLm1vxUQ== +"@opentelemetry/semantic-conventions@1.27.0", "@opentelemetry/semantic-conventions@^1.17.0", "@opentelemetry/semantic-conventions@^1.25.1", "@opentelemetry/semantic-conventions@^1.27.0": + version "1.27.0" + resolved "https://registry.yarnpkg.com/@opentelemetry/semantic-conventions/-/semantic-conventions-1.27.0.tgz#1a857dcc95a5ab30122e04417148211e6f945e6c" + integrity sha512-sAay1RrB+ONOem0OZanAR1ZI/k7yDpnOQSQmTMuGImUQb2y8EbSaCJ94FQluM74xoU03vlb2d2U90hZluL6nQg== + "@opentelemetry/semantic-conventions@1.8.0": version "1.8.0" resolved "https://registry.yarnpkg.com/@opentelemetry/semantic-conventions/-/semantic-conventions-1.8.0.tgz#fe2aa90e6df050a11cd57f5c0f47b0641fd2cad3" integrity sha512-TYh1MRcm4JnvpqtqOwT9WYaBYY4KERHdToxs/suDTLviGRsQkIjS5yYROTYTSJQUnYLOn/TuOh5GoMwfLSU+Ew== +"@opentelemetry/sql-common@^0.40.1": + version "0.40.1" + resolved "https://registry.yarnpkg.com/@opentelemetry/sql-common/-/sql-common-0.40.1.tgz#93fbc48d8017449f5b3c3274f2268a08af2b83b6" + integrity sha512-nSDlnHSqzC3pXn/wZEZVLuAuJ1MYMXPBwtv2qAbCa3847SaHItdE7SzUq/Jtb0KZmh1zfAbNi3AAMjztTT4Ugg== + dependencies: + "@opentelemetry/core" "^1.1.0" + "@penseapp/discord-notification@^2.0.9": version "2.0.9" resolved "https://registry.yarnpkg.com/@penseapp/discord-notification/-/discord-notification-2.0.9.tgz#0a52bb2eda2c575e076ee00476fd8dc717023a67" @@ -4758,6 +5004,15 @@ resolved "https://registry.yarnpkg.com/@prisma/engines/-/engines-4.10.1.tgz#c7062747f254e5d5fce98a8cae566c25f9f29fb2" integrity sha512-B3tcTxjx196nuAu1GOTKO9cGPUgTFHYRdkPkTS4m5ptb2cejyBlH9X7GOfSt3xlI7p4zAJDshJP4JJivCg9ouA== +"@prisma/instrumentation@5.19.1": + version "5.19.1" + resolved "https://registry.yarnpkg.com/@prisma/instrumentation/-/instrumentation-5.19.1.tgz#146319cf85f22b7a43296f0f40cfeac55516e66e" + integrity sha512-VLnzMQq7CWroL5AeaW0Py2huiNKeoMfCH3SUxstdzPrlWQi6UQ9UrfcbUkNHlVFqOMacqy8X/8YtE0kuKDpD9w== + dependencies: + "@opentelemetry/api" "^1.8" + "@opentelemetry/instrumentation" "^0.49 || ^0.50 || ^0.51 || ^0.52.0" + "@opentelemetry/sdk-trace-base" "^1.22" + "@protobufjs/aspromise@^1.1.1", "@protobufjs/aspromise@^1.1.2": version "1.1.2" resolved "https://registry.yarnpkg.com/@protobufjs/aspromise/-/aspromise-1.1.2.tgz#9b8b0cc663d669a7d8f6f5d0893a14d348f30fbf" @@ -5360,6 +5615,60 @@ "@sentry/types" "7.106.1" "@sentry/utils" "7.106.1" +"@sentry/cli-darwin@2.35.0": + version "2.35.0" + resolved "https://registry.yarnpkg.com/@sentry/cli-darwin/-/cli-darwin-2.35.0.tgz#4bc9a07690f0de75d930ba47f4655f6465191768" + integrity sha512-dRtDaASkB1ncSbCLMIL8bxki4dPMimSdYz74XOUJ5IvDVVzEInEO7PqvyOj/cyafB+1FSNudaZ90ZRvsNN1Maw== + +"@sentry/cli-linux-arm64@2.35.0": + version "2.35.0" + resolved "https://registry.yarnpkg.com/@sentry/cli-linux-arm64/-/cli-linux-arm64-2.35.0.tgz#bad8a45b81d2b317f702991783a503f566b2294e" + integrity sha512-NpyVz2lQWWkMa9GZkt0m4cA/wsgYnWOE6Z+4ePUGjbOIG3Ws9DLaHjYxUUYI79kxfbVCp7wLo1S6kOkj+M1Dlw== + +"@sentry/cli-linux-arm@2.35.0": + version "2.35.0" + resolved "https://registry.yarnpkg.com/@sentry/cli-linux-arm/-/cli-linux-arm-2.35.0.tgz#dacfc219876f5dce3d8c65dab7128ea3e493f561" + integrity sha512-zNL+/HnepZ4/MkIS8wfoUQxSa+k6r0DSSdX1TpDH5436u+3LB5rfCTBfZ624DWHKMoXX+1dI+rWSi+zL8QFMsg== + +"@sentry/cli-linux-i686@2.35.0": + version "2.35.0" + resolved "https://registry.yarnpkg.com/@sentry/cli-linux-i686/-/cli-linux-i686-2.35.0.tgz#d0e6401b60b0a4b6c3578998995ba6cb31c1bf20" + integrity sha512-vIYwZVqx+kYZdPsenIm+UqjSCKe9Q2Aof6kzrzW0DPR1WyqIWbWG4NbiugiPTiuA1dLjUjYpGP8wyIqb8hxv4w== + +"@sentry/cli-linux-x64@2.35.0": + version "2.35.0" + resolved "https://registry.yarnpkg.com/@sentry/cli-linux-x64/-/cli-linux-x64-2.35.0.tgz#a1e8e7bff960ed8916b4cc9c0ef75a057e30f989" + integrity sha512-7Wy5QNt6wZ8EaxEbHqP0DEiyUcXRVItRt9jzhpa2nCaawL+fwDOQCjUkHGsdIC+y14UqA+er9CaPCSp8sA6Vaw== + +"@sentry/cli-win32-i686@2.35.0": + version "2.35.0" + resolved "https://registry.yarnpkg.com/@sentry/cli-win32-i686/-/cli-win32-i686-2.35.0.tgz#c1b090f7c740c5b22d1019ca48a84f58cd4b2670" + integrity sha512-XDcBUtO5A9elH+xgFNs6NBjkMBnz0sZLo5DU7LE77qKXULnlLeJ63eZD1ukQIRPvxEDsIEPOllRweLuAlUMDtw== + +"@sentry/cli-win32-x64@2.35.0": + version "2.35.0" + resolved "https://registry.yarnpkg.com/@sentry/cli-win32-x64/-/cli-win32-x64-2.35.0.tgz#f592af483da239be846e556f57f5c6fc7dc1dc54" + integrity sha512-86yHO+31qAXUeAdSCH7MNodn/cn/9xd2fTrxjtfNZWO0pX0jW91sCdomfBxhu5b977cyV9gNcqeBbc9XSIKIIA== + +"@sentry/cli@^2.35.0": + version "2.35.0" + resolved "https://registry.yarnpkg.com/@sentry/cli/-/cli-2.35.0.tgz#5514eb8f5808bc70707ffa186156f8ff7ca5971e" + integrity sha512-7sHRJViEgHTfEXf+HD1Fb2cwmnxlILmb2NNxghP2vvrgC2PhuwuJU7AX4zg7HjJgxH9HBmnn4AJskDujaJ/6cQ== + dependencies: + https-proxy-agent "^5.0.0" + node-fetch "^2.6.7" + progress "^2.0.3" + proxy-from-env "^1.1.0" + which "^2.0.2" + optionalDependencies: + "@sentry/cli-darwin" "2.35.0" + "@sentry/cli-linux-arm" "2.35.0" + "@sentry/cli-linux-arm64" "2.35.0" + "@sentry/cli-linux-i686" "2.35.0" + "@sentry/cli-linux-x64" "2.35.0" + "@sentry/cli-win32-i686" "2.35.0" + "@sentry/cli-win32-x64" "2.35.0" + "@sentry/core@7.106.1": version "7.106.1" resolved "https://registry.yarnpkg.com/@sentry/core/-/core-7.106.1.tgz#d4470f2a2f8e0c24e3afe4d7f83f98f5d2858605" @@ -5368,15 +5677,60 @@ "@sentry/types" "7.106.1" "@sentry/utils" "7.106.1" -"@sentry/node@^7.12.0": - version "7.106.1" - resolved "https://registry.yarnpkg.com/@sentry/node/-/node-7.106.1.tgz#8728fd79b8575ef0678a3a47f928c2830c9c9b6e" - integrity sha512-KB2Lkb9WqocD/gbKIZCk2mQQmx+G3khI9ChJUw6GJzd5mvdQ5xxr4/yQKIHR6L9z3oGWBno9/Xc8Aw9s3ZwGwQ== +"@sentry/core@8.29.0": + version "8.29.0" + resolved "https://registry.yarnpkg.com/@sentry/core/-/core-8.29.0.tgz#52032ece2d7b60f3775f10189c27e26b1cebdbca" + integrity sha512-scMbZaJ0Ov8NPgWn86EdjhyTLrhvRVbTxjg0imJAvhIvRbblH3xyqye/17Qnk2fOp8TNDOl7TBZHi0NCFQ5HUw== + dependencies: + "@sentry/types" "8.29.0" + "@sentry/utils" "8.29.0" + +"@sentry/node@^8.29.0": + version "8.29.0" + resolved "https://registry.yarnpkg.com/@sentry/node/-/node-8.29.0.tgz#6e462b8802356a630c56733dc795a4035464c4ab" + integrity sha512-RCKpWR6DUWmlxtms10MRXwJZRrFt1a2P38FjwEEahcdcK1R6wB8GPf0GO4JnJAiw6oeM0MERSqLIcSLT8+FxtA== + dependencies: + "@opentelemetry/api" "^1.9.0" + "@opentelemetry/context-async-hooks" "^1.25.1" + "@opentelemetry/core" "^1.25.1" + "@opentelemetry/instrumentation" "^0.53.0" + "@opentelemetry/instrumentation-connect" "0.39.0" + "@opentelemetry/instrumentation-express" "0.42.0" + "@opentelemetry/instrumentation-fastify" "0.39.0" + "@opentelemetry/instrumentation-fs" "0.15.0" + "@opentelemetry/instrumentation-generic-pool" "0.39.0" + "@opentelemetry/instrumentation-graphql" "0.43.0" + "@opentelemetry/instrumentation-hapi" "0.41.0" + "@opentelemetry/instrumentation-http" "0.53.0" + "@opentelemetry/instrumentation-ioredis" "0.43.0" + "@opentelemetry/instrumentation-koa" "0.43.0" + "@opentelemetry/instrumentation-mongodb" "0.47.0" + "@opentelemetry/instrumentation-mongoose" "0.42.0" + "@opentelemetry/instrumentation-mysql" "0.41.0" + "@opentelemetry/instrumentation-mysql2" "0.41.0" + "@opentelemetry/instrumentation-nestjs-core" "0.40.0" + "@opentelemetry/instrumentation-pg" "0.44.0" + "@opentelemetry/instrumentation-redis-4" "0.42.0" + "@opentelemetry/resources" "^1.25.1" + "@opentelemetry/sdk-trace-base" "^1.25.1" + "@opentelemetry/semantic-conventions" "^1.25.1" + "@prisma/instrumentation" "5.19.1" + "@sentry/core" "8.29.0" + "@sentry/opentelemetry" "8.29.0" + "@sentry/types" "8.29.0" + "@sentry/utils" "8.29.0" + import-in-the-middle "^1.11.0" + optionalDependencies: + opentelemetry-instrumentation-fetch-node "1.2.3" + +"@sentry/opentelemetry@8.29.0": + version "8.29.0" + resolved "https://registry.yarnpkg.com/@sentry/opentelemetry/-/opentelemetry-8.29.0.tgz#6ae54c640155925fc42ac86f37d125f9bb983794" + integrity sha512-MtfjDMUuKFYlyw9hZohp9xnphz+6QosyHb2zCV3e/fANoA53FDxmg/Co7haMohUCiOwwJPytUmSQQaP0nyL2Uw== dependencies: - "@sentry-internal/tracing" "7.106.1" - "@sentry/core" "7.106.1" - "@sentry/types" "7.106.1" - "@sentry/utils" "7.106.1" + "@sentry/core" "8.29.0" + "@sentry/types" "8.29.0" + "@sentry/utils" "8.29.0" "@sentry/tracing@^7.12.0": version "7.106.1" @@ -5390,6 +5744,11 @@ resolved "https://registry.yarnpkg.com/@sentry/types/-/types-7.106.1.tgz#ea7c6b9090790e600c4f907f1c8bf94c8db2ecc4" integrity sha512-g3OcyAHGugBwkQP4fZYCCZqF2ng9K7yQc9FVngKq/y7PwHm84epXdYYGDGgfQOIC1d5/GMaPxmzI5IIrZexzkg== +"@sentry/types@8.29.0": + version "8.29.0" + resolved "https://registry.yarnpkg.com/@sentry/types/-/types-8.29.0.tgz#c19e43524b8e7766028f4da8f02eddcc33518541" + integrity sha512-j4gX3ctzgD4xVWllXAhm6M+kHFEvrFoUPFq60X/pgkjsWCocGuhtNfB0rW43ICG8hCnlz8IYl7O7b8V8qY7SPg== + "@sentry/utils@7.106.1": version "7.106.1" resolved "https://registry.yarnpkg.com/@sentry/utils/-/utils-7.106.1.tgz#7761ed50d489286dd1e482570c498f675445ce82" @@ -5397,6 +5756,13 @@ dependencies: "@sentry/types" "7.106.1" +"@sentry/utils@8.29.0": + version "8.29.0" + resolved "https://registry.yarnpkg.com/@sentry/utils/-/utils-8.29.0.tgz#d4a36643369e30ba62ef8f40f149420a100f64bb" + integrity sha512-nb93/m3SjQChQJFqJj3oNW3Rz/12yrT7jypTCire3c2hpYWG2uR5n8VY9UUMTA6HLNvdom6tckK7p3bXGXlF0w== + dependencies: + "@sentry/types" "8.29.0" + "@sideway/address@^4.1.5": version "4.1.5" resolved "https://registry.yarnpkg.com/@sideway/address/-/address-4.1.5.tgz#4bc149a0076623ced99ca8208ba780d65a99b9d5" @@ -6711,6 +7077,13 @@ dependencies: "@types/node" "*" +"@types/connect@3.4.36": + version "3.4.36" + resolved "https://registry.yarnpkg.com/@types/connect/-/connect-3.4.36.tgz#e511558c15a39cb29bd5357eebb57bd1459cd1ab" + integrity sha512-P63Zd/JUGq+PdrM1lv0Wv5SBYeA2+CORvbrXbngriYY0jzLUWfQMQQxOhjONEz/wlHOAxOdY7CY65rgQdTjq2w== + dependencies: + "@types/node" "*" + "@types/content-disposition@*": version "0.5.8" resolved "https://registry.yarnpkg.com/@types/content-disposition/-/content-disposition-0.5.8.tgz#6742a5971f490dc41e59d277eee71361fea0b537" @@ -7034,6 +7407,13 @@ dependencies: "@types/node" "*" +"@types/mysql@2.15.26": + version "2.15.26" + resolved "https://registry.yarnpkg.com/@types/mysql/-/mysql-2.15.26.tgz#f0de1484b9e2354d587e7d2bd17a873cc8300836" + integrity sha512-DSLCOXhkvfS5WNNPbfn2KdICAmk8lLc+/PNvnPnF7gOdMZCxopXduqv0OQ13y/yA/zXTSikZZqVgybUxOEg6YQ== + dependencies: + "@types/node" "*" + "@types/node@*", "@types/node@>=10.0.0", "@types/node@>=13.7.0", "@types/node@^20.10.4": version "20.11.27" resolved "https://registry.yarnpkg.com/@types/node/-/node-20.11.27.tgz#debe5cfc8a507dd60fe2a3b4875b1604f215c2ac" @@ -7089,6 +7469,13 @@ dependencies: "@types/pg" "*" +"@types/pg-pool@2.0.6": + version "2.0.6" + resolved "https://registry.yarnpkg.com/@types/pg-pool/-/pg-pool-2.0.6.tgz#1376d9dc5aec4bb2ec67ce28d7e9858227403c77" + integrity sha512-TaAUE5rq2VQYxab5Ts7WZhKNmuN78Q6PiFonTDdpbx8a1H0M1vhy3rhiMjl+e2iHmogyMw7jZF4FrE6eJUy5HQ== + dependencies: + "@types/pg" "*" + "@types/pg@*": version "8.11.2" resolved "https://registry.yarnpkg.com/@types/pg/-/pg-8.11.2.tgz#e5c306601d2e0cc54c0801cc61a41761c8a95c92" @@ -7191,6 +7578,11 @@ resolved "https://registry.yarnpkg.com/@types/shimmer/-/shimmer-1.0.5.tgz#491d8984d4510e550bfeb02d518791d7f59d2b88" integrity sha512-9Hp0ObzwwO57DpLFF0InUjUm/II8GmKAvzbefxQTihCb7KI6yc9yzf0nLc4mVdby5N4DRCgQM2wCup9KTieeww== +"@types/shimmer@^1.2.0": + version "1.2.0" + resolved "https://registry.yarnpkg.com/@types/shimmer/-/shimmer-1.2.0.tgz#9b706af96fa06416828842397a70dfbbf1c14ded" + integrity sha512-UE7oxhQLLd9gub6JKIAhDq06T0F6FnztwMNRvYgjeQSBeMc1ZG/tA47EwfduvkuQS8apbkM/lpLpWsaCeYsXVg== + "@types/superagent@*": version "8.1.4" resolved "https://registry.yarnpkg.com/@types/superagent/-/superagent-8.1.4.tgz#f8290d1b7d6081f84f3047851c190c4a3c8cdb21" @@ -7532,6 +7924,11 @@ acorn-import-assertions@^1.9.0: resolved "https://registry.yarnpkg.com/acorn-import-assertions/-/acorn-import-assertions-1.9.0.tgz#507276249d684797c84e0734ef84860334cfb1ac" integrity sha512-cmMwop9x+8KFhxvKrKfPYmN6/pKTYYHBqLa0DfvVZcKMJWNyWLnaqND7dx/qn66R7ewM1UX5XMaDVP5wlVTaVA== +acorn-import-attributes@^1.9.5: + version "1.9.5" + resolved "https://registry.yarnpkg.com/acorn-import-attributes/-/acorn-import-attributes-1.9.5.tgz#7eb1557b1ba05ef18b5ed0ec67591bfab04688ef" + integrity sha512-n02Vykv5uA3eHGM/Z2dQrcD56kL8TyDb2p1+0P83PClMnC/nc+anbQRhIOWnSq4Ke/KvDPrY3C9hDtC/A3eHnQ== + acorn-jsx@^5.3.1: version "5.3.2" resolved "https://registry.yarnpkg.com/acorn-jsx/-/acorn-jsx-5.3.2.tgz#7ed5bb55908b3b2f1bc55c6af1653bada7f07937" @@ -8726,6 +9123,11 @@ cipher-base@^1.0.0, cipher-base@^1.0.1, cipher-base@^1.0.3: inherits "^2.0.1" safe-buffer "^5.0.1" +cjs-module-lexer@^1.2.2: + version "1.4.1" + resolved "https://registry.yarnpkg.com/cjs-module-lexer/-/cjs-module-lexer-1.4.1.tgz#707413784dbb3a72aa11c2f2b042a0bef4004170" + integrity sha512-cuSVIHi9/9E/+821Qjdvngor+xpnlwnuwIyZOaLmHBVdXL+gP+I6QQB9VkO7RI77YIcTV+S1W9AreJ5eN63JBA== + classic-level@^1.2.0: version "1.4.1" resolved "https://registry.yarnpkg.com/classic-level/-/classic-level-1.4.1.tgz#169ecf9f9c6200ad42a98c8576af449c1badbaee" @@ -9367,6 +9769,13 @@ debug@^4.3.3: dependencies: ms "2.1.2" +debug@^4.3.5: + version "4.3.7" + resolved "https://registry.yarnpkg.com/debug/-/debug-4.3.7.tgz#87945b4151a011d76d95a198d7111c865c360a52" + integrity sha512-Er2nc/H7RrMXZBFCEim6TCmMk02Z8vLC2Rbi1KEBggpo0fS6l0S1nnapwmIi3yW/+GOJap1Krg4w0Hg80oCqgQ== + dependencies: + ms "^2.1.3" + decamelize-keys@^1.1.0: version "1.1.1" resolved "https://registry.yarnpkg.com/decamelize-keys/-/decamelize-keys-1.1.1.tgz#04a2d523b2f18d80d0158a43b895d56dff8d19d8" @@ -11538,6 +11947,26 @@ import-in-the-middle@1.3.5: dependencies: module-details-from-path "^1.0.3" +import-in-the-middle@1.7.1: + version "1.7.1" + resolved "https://registry.yarnpkg.com/import-in-the-middle/-/import-in-the-middle-1.7.1.tgz#3e111ff79c639d0bde459bd7ba29dd9fdf357364" + integrity sha512-1LrZPDtW+atAxH42S6288qyDFNQ2YCty+2mxEPRtfazH6Z5QwkaBSTS2ods7hnVJioF6rkRfNoA6A/MstpFXLg== + dependencies: + acorn "^8.8.2" + acorn-import-assertions "^1.9.0" + cjs-module-lexer "^1.2.2" + module-details-from-path "^1.0.3" + +import-in-the-middle@^1.11.0, import-in-the-middle@^1.8.1: + version "1.11.0" + resolved "https://registry.yarnpkg.com/import-in-the-middle/-/import-in-the-middle-1.11.0.tgz#a94c4925b8da18256cde3b3b7b38253e6ca5e708" + integrity sha512-5DimNQGoe0pLUHbR9qK84iWaWjjbsxiqXnw6Qz64+azRgleqv9k2kTt5fw7QsOpmaGYtuxxursnPPsnTKEx10Q== + dependencies: + acorn "^8.8.2" + acorn-import-attributes "^1.9.5" + cjs-module-lexer "^1.2.2" + module-details-from-path "^1.0.3" + import-meta-resolve@^4.0.0: version "4.0.0" resolved "https://registry.yarnpkg.com/import-meta-resolve/-/import-meta-resolve-4.0.0.tgz#0b1195915689f60ab00f830af0f15cc841e8919e" @@ -13515,7 +13944,7 @@ node-domexception@^1.0.0: resolved "https://registry.yarnpkg.com/node-domexception/-/node-domexception-1.0.0.tgz#6888db46a1f71c0b76b3f7555016b63fe64766e5" integrity sha512-/jKZoMpw0F8GRwl4/eLROPA3cfcXtLApP0QzLmUT/HuPCZWyB7IY9ZrMeKw2O/nFIqPQB3PVM9aYm0F312AXDQ== -node-fetch@^2.6.1, node-fetch@^2.6.12, node-fetch@^2.6.8, node-fetch@^2.6.9: +node-fetch@^2.6.1, node-fetch@^2.6.12, node-fetch@^2.6.7, node-fetch@^2.6.8, node-fetch@^2.6.9: version "2.7.0" resolved "https://registry.yarnpkg.com/node-fetch/-/node-fetch-2.7.0.tgz#d0f0fa6e3e2dc1d27efcd8ad99d550bda94d187d" integrity sha512-c4FRfUm/dbcWZ7U+1Wq0AwCyFL+3nt2bEw05wfxSz+DWpWsitgmSgYmy2dQdWyKC1694ELPqMs/YzUSNozLt8A== @@ -13815,6 +14244,14 @@ onetime@^5.1.0, onetime@^5.1.2: dependencies: mimic-fn "^2.1.0" +opentelemetry-instrumentation-fetch-node@1.2.3: + version "1.2.3" + resolved "https://registry.yarnpkg.com/opentelemetry-instrumentation-fetch-node/-/opentelemetry-instrumentation-fetch-node-1.2.3.tgz#beb24048bdccb1943ba2a5bbadca68020e448ea7" + integrity sha512-Qb11T7KvoCevMaSeuamcLsAD+pZnavkhDnlVL0kRozfhl42dKG5Q3anUklAFKJZjY3twLR+BnRa6DlwwkIE/+A== + dependencies: + "@opentelemetry/instrumentation" "^0.46.0" + "@opentelemetry/semantic-conventions" "^1.17.0" + opentracing@^0.14.4: version "0.14.7" resolved "https://registry.yarnpkg.com/opentracing/-/opentracing-0.14.7.tgz#25d472bd0296dc0b64d7b94cbc995219031428f5" @@ -14470,7 +14907,7 @@ progress-events@^1.0.0: resolved "https://registry.yarnpkg.com/progress-events/-/progress-events-1.0.0.tgz#34f5e8fdb5dae3561837b22672d1e02277bb2109" integrity sha512-zIB6QDrSbPfRg+33FZalluFIowkbV5Xh1xSuetjG+rlC5he6u2dc6VQJ0TbMdlN3R1RHdpOqxEFMKTnQ+itUwA== -progress@^2.0.0: +progress@^2.0.0, progress@^2.0.3: version "2.0.3" resolved "https://registry.yarnpkg.com/progress/-/progress-2.0.3.tgz#7e8cf8d8f5b8f239c1bc68beb4eb78567d572ef8" integrity sha512-7PiHtLll5LdnKIMw100I+8xJXR5gW2QwWYkT6iJva0bXitZKa/XMrSbdmg3r2Xnaidz9Qumd0VPaMrZlF9V9sA== @@ -15007,6 +15444,15 @@ require-in-the-middle@^7.1.0: module-details-from-path "^1.0.3" resolve "^1.22.1" +require-in-the-middle@^7.1.1: + version "7.4.0" + resolved "https://registry.yarnpkg.com/require-in-the-middle/-/require-in-the-middle-7.4.0.tgz#606977820d4b5f9be75e5a108ce34cfed25b3bb4" + integrity sha512-X34iHADNbNDfr6OTStIAHWSAvvKQRYgLO6duASaVf7J2VA3lvmNYboAHOuLC2huav1IwgZJtyEcJCKVzFxOSMQ== + dependencies: + debug "^4.3.5" + module-details-from-path "^1.0.3" + resolve "^1.22.8" + require-main-filename@^2.0.0: version "2.0.0" resolved "https://registry.yarnpkg.com/require-main-filename/-/require-main-filename-2.0.0.tgz#d0b329ecc7cc0f61649f62215be69af54aa8989b" @@ -15042,7 +15488,7 @@ resolve-global@1.0.0, resolve-global@^1.0.0: dependencies: global-dirs "^0.1.1" -resolve@^1.1.6, resolve@^1.1.7, resolve@^1.10.0, resolve@^1.20.0, resolve@^1.22.1, resolve@^1.22.2, resolve@^1.22.4: +resolve@^1.1.6, resolve@^1.1.7, resolve@^1.10.0, resolve@^1.20.0, resolve@^1.22.1, resolve@^1.22.2, resolve@^1.22.4, resolve@^1.22.8: version "1.22.8" resolved "https://registry.yarnpkg.com/resolve/-/resolve-1.22.8.tgz#b6c87a9f2aa06dfab52e3d70ac8cde321fa5a48d" integrity sha512-oKWePCxqpd6FlLvGV1VU0x7bkPmmCNolxzjMf4NczoDnQcIWrAF+cPtZn5i6n+RfD2d9i0tzpKnG6Yk168yIyw== @@ -15283,6 +15729,11 @@ semver@^7.2.1, semver@^7.3.2, semver@^7.3.4, semver@^7.3.5, semver@^7.3.8, semve dependencies: lru-cache "^6.0.0" +semver@^7.5.2: + version "7.6.3" + resolved "https://registry.yarnpkg.com/semver/-/semver-7.6.3.tgz#980f7b5550bc175fb4dc09403085627f9eb33143" + integrity sha512-oVekP1cKtI+CTDvHWYFUcMtsK/00wmAEfyqKfNdARm8u1wNVhSgaX7A8d4UuIlUI5e84iEwOhs7ZPYRmzU9U6A== + semver@~7.0.0: version "7.0.0" resolved "https://registry.yarnpkg.com/semver/-/semver-7.0.0.tgz#5f3ca35761e47e05b206c6daff2cf814f0316b8e" @@ -15756,16 +16207,7 @@ string-template@~0.2.1: resolved "https://registry.yarnpkg.com/string-template/-/string-template-0.2.1.tgz#42932e598a352d01fc22ec3367d9d84eec6c9add" integrity sha512-Yptehjogou2xm4UJbxJ4CxgZx12HBfeystp0y3x7s4Dj32ltVVG1Gg8YhKjHZkHicuKpZX/ffilA8505VbUbpw== -"string-width-cjs@npm:string-width@^4.2.0": - version "4.2.3" - resolved "https://registry.yarnpkg.com/string-width/-/string-width-4.2.3.tgz#269c7117d27b05ad2e536830a8ec895ef9c6d010" - integrity sha512-wKyQRQpjJ0sIp62ErSZdGsjMJWsap5oRNihHhu6G7JVO/9jIB6UyevL+tXuOqrng8j/cxKTWyWUwvSTriiZz/g== - dependencies: - emoji-regex "^8.0.0" - is-fullwidth-code-point "^3.0.0" - strip-ansi "^6.0.1" - -"string-width@^1.0.2 || 2 || 3 || 4", string-width@^4.1.0, string-width@^4.2.0, string-width@^4.2.3: +"string-width-cjs@npm:string-width@^4.2.0", "string-width@^1.0.2 || 2 || 3 || 4", string-width@^4.1.0, string-width@^4.2.0, string-width@^4.2.3: version "4.2.3" resolved "https://registry.yarnpkg.com/string-width/-/string-width-4.2.3.tgz#269c7117d27b05ad2e536830a8ec895ef9c6d010" integrity sha512-wKyQRQpjJ0sIp62ErSZdGsjMJWsap5oRNihHhu6G7JVO/9jIB6UyevL+tXuOqrng8j/cxKTWyWUwvSTriiZz/g== @@ -15838,7 +16280,7 @@ stringify-object@3.3.0: is-obj "^1.0.1" is-regexp "^1.0.0" -"strip-ansi-cjs@npm:strip-ansi@^6.0.1": +"strip-ansi-cjs@npm:strip-ansi@^6.0.1", strip-ansi@^6.0.0, strip-ansi@^6.0.1: version "6.0.1" resolved "https://registry.yarnpkg.com/strip-ansi/-/strip-ansi-6.0.1.tgz#9e26c63d30f53443e9489495b2105d37b67a85d9" integrity sha512-Y38VPSHcqkFrCpFnQ9vuSXmquuv5oXOKpGeT6aGrr3o3Gc9AlVa6JBfUSOCnbxGGZF+/0ooI7KrPuUSztUdU5A== @@ -15852,13 +16294,6 @@ strip-ansi@^3.0.0: dependencies: ansi-regex "^2.0.0" -strip-ansi@^6.0.0, strip-ansi@^6.0.1: - version "6.0.1" - resolved "https://registry.yarnpkg.com/strip-ansi/-/strip-ansi-6.0.1.tgz#9e26c63d30f53443e9489495b2105d37b67a85d9" - integrity sha512-Y38VPSHcqkFrCpFnQ9vuSXmquuv5oXOKpGeT6aGrr3o3Gc9AlVa6JBfUSOCnbxGGZF+/0ooI7KrPuUSztUdU5A== - dependencies: - ansi-regex "^5.0.1" - strip-ansi@^7.0.1: version "7.1.0" resolved "https://registry.yarnpkg.com/strip-ansi/-/strip-ansi-7.1.0.tgz#d5b6568ca689d8561370b0707685d22434faff45" @@ -16894,7 +17329,7 @@ workerpool@6.2.1: resolved "https://registry.yarnpkg.com/workerpool/-/workerpool-6.2.1.tgz#46fc150c17d826b86a008e5a4508656777e9c343" integrity sha512-ILEIE97kDZvF9Wb9f6h5aXK4swSlKGUcOEGiIYb2OOu/IrDU9iwj0fD//SsA6E5ibwJxpEvhullJY4Sl4GcpAw== -"wrap-ansi-cjs@npm:wrap-ansi@^7.0.0": +"wrap-ansi-cjs@npm:wrap-ansi@^7.0.0", wrap-ansi@^7.0.0: version "7.0.0" resolved "https://registry.yarnpkg.com/wrap-ansi/-/wrap-ansi-7.0.0.tgz#67e145cff510a6a6984bdf1152911d69d2eb9e43" integrity sha512-YVGIj2kamLSTxw6NsZjoBxfSwsn0ycdesmc4p+Q21c5zPuZ1pl+NfxVdxPtdHvmNVOQ6XSYG4AUtyt/Fi7D16Q== @@ -16912,15 +17347,6 @@ wrap-ansi@^6.2.0: string-width "^4.1.0" strip-ansi "^6.0.0" -wrap-ansi@^7.0.0: - version "7.0.0" - resolved "https://registry.yarnpkg.com/wrap-ansi/-/wrap-ansi-7.0.0.tgz#67e145cff510a6a6984bdf1152911d69d2eb9e43" - integrity sha512-YVGIj2kamLSTxw6NsZjoBxfSwsn0ycdesmc4p+Q21c5zPuZ1pl+NfxVdxPtdHvmNVOQ6XSYG4AUtyt/Fi7D16Q== - dependencies: - ansi-styles "^4.0.0" - string-width "^4.1.0" - strip-ansi "^6.0.0" - wrap-ansi@^8.1.0: version "8.1.0" resolved "https://registry.yarnpkg.com/wrap-ansi/-/wrap-ansi-8.1.0.tgz#56dc22368ee570face1b49819975d9b9a5ead214" From 2c9efb1e93f4fd0e5737f91dd42075bc742bddb2 Mon Sep 17 00:00:00 2001 From: Sina Iman Date: Mon, 9 Sep 2024 15:45:27 +0200 Subject: [PATCH 02/81] fix env --- .github/workflows/build-server.yaml | 1 + 1 file changed, 1 insertion(+) diff --git a/.github/workflows/build-server.yaml b/.github/workflows/build-server.yaml index 31341a659..5b9558ebe 100644 --- a/.github/workflows/build-server.yaml +++ b/.github/workflows/build-server.yaml @@ -23,6 +23,7 @@ env: AWS_ACCOUNT_ID: ${{ secrets.AWS_ACCOUNT_ID }} AWS_ACCESS_KEY_ID: ${{ secrets.AWS_ACCESS_KEY_ID }} AWS_SECRET_ACCESS_KEY: ${{ secrets.AWS_SECRET_ACCESS_KEY }} + SENTRY_AUTH_TOKEN: ${{ secrets.SENTRY_AUTH_TOKEN }} CONTAINER_IMAGE: desci-server DOCKER_BUILDKIT: 1 From 633a2a36def96c16d0ebe35a61199ad2c8adb4be Mon Sep 17 00:00:00 2001 From: Sina Iman Date: Mon, 9 Sep 2024 15:54:43 +0200 Subject: [PATCH 03/81] add sentry build step --- .github/workflows/build-server.yaml | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/.github/workflows/build-server.yaml b/.github/workflows/build-server.yaml index 5b9558ebe..c4676434d 100644 --- a/.github/workflows/build-server.yaml +++ b/.github/workflows/build-server.yaml @@ -58,6 +58,10 @@ jobs: echo "{\"proxies\":[{\"address\":\"\"}]}" > desci-server/src/desci-contracts-config/unknown-research-object.json echo "{\"proxies\":[{\"address\":\"\"}]}" > desci-server/src/desci-contracts-config/unknown-dpid.json + - name: Set up Sentry CLI + run: | + sentry-cli --version + - name: Run tests run: | cd desci-server && export DOCKER_BUILDKIT=1 && yarn --ignore-engines && yarn test @@ -114,6 +118,10 @@ jobs: echo "{\"proxies\":[{\"address\":\"\"}]}" > desci-server/src/desci-contracts-config/unknown-research-object.json echo "{\"proxies\":[{\"address\":\"\"}]}" > desci-server/src/desci-contracts-config/unknown-dpid.json + - name: Set up Sentry CLI + run: | + sentry-cli --version + - name: Build and tag the image (DEV) if: github.ref == 'refs/heads/develop' run: | From b1b957a6b547881b3f6f152404683485950d66c9 Mon Sep 17 00:00:00 2001 From: Sina Iman Date: Tue, 10 Sep 2024 01:53:35 +0200 Subject: [PATCH 04/81] add sentry build step --- .github/workflows/build-and-test.yaml | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/.github/workflows/build-and-test.yaml b/.github/workflows/build-and-test.yaml index 567ab7bc8..b355ee139 100644 --- a/.github/workflows/build-and-test.yaml +++ b/.github/workflows/build-and-test.yaml @@ -55,6 +55,10 @@ jobs: echo "{\"proxies\":[{\"address\":\"\"}]}" > desci-server/src/desci-contracts-config/unknown-research-object.json echo "{\"proxies\":[{\"address\":\"\"}]}" > desci-server/src/desci-contracts-config/unknown-dpid.json + - name: Set up Sentry CLI + run: | + sentry-cli --version + - name: Run tests run: | cd desci-server && export DOCKER_BUILDKIT=1 && yarn --ignore-engines && yarn test From dd604cdd948413d039a728cff381ac5844a49a5c Mon Sep 17 00:00:00 2001 From: Sina Iman Date: Tue, 10 Sep 2024 02:06:40 +0200 Subject: [PATCH 05/81] add sentry build step --- .github/workflows/build-and-test.yaml | 1 + 1 file changed, 1 insertion(+) diff --git a/.github/workflows/build-and-test.yaml b/.github/workflows/build-and-test.yaml index b355ee139..a18e84a65 100644 --- a/.github/workflows/build-and-test.yaml +++ b/.github/workflows/build-and-test.yaml @@ -57,6 +57,7 @@ jobs: - name: Set up Sentry CLI run: | + npm install -g @sentry/cli sentry-cli --version - name: Run tests From 53387638a0fc369a446a14f24c35db557f4f7277 Mon Sep 17 00:00:00 2001 From: Sina Iman Date: Wed, 11 Sep 2024 17:38:33 +0200 Subject: [PATCH 06/81] sentry cli token --- .github/workflows/build-and-test.yaml | 1 + 1 file changed, 1 insertion(+) diff --git a/.github/workflows/build-and-test.yaml b/.github/workflows/build-and-test.yaml index a18e84a65..ea996bc75 100644 --- a/.github/workflows/build-and-test.yaml +++ b/.github/workflows/build-and-test.yaml @@ -22,6 +22,7 @@ env: AWS_SECRET_ACCESS_KEY: ${{ secrets.AWS_SECRET_ACCESS_KEY }} CONTAINER_IMAGE: desci-server DOCKER_BUILDKIT: 1 + SENTRY_AUTH_TOKEN: ${{ secrets.SENTRY_AUTH_TOKEN }} jobs: build-and-test: From 456c62bfa12dac218ae02b20b29da1edd29edf45 Mon Sep 17 00:00:00 2001 From: Sina Iman Date: Wed, 11 Sep 2024 20:19:21 +0200 Subject: [PATCH 07/81] sentry cli token --- .github/workflows/build-and-test.yaml | 1 + 1 file changed, 1 insertion(+) diff --git a/.github/workflows/build-and-test.yaml b/.github/workflows/build-and-test.yaml index ea996bc75..9b3eb3d9e 100644 --- a/.github/workflows/build-and-test.yaml +++ b/.github/workflows/build-and-test.yaml @@ -60,6 +60,7 @@ jobs: run: | npm install -g @sentry/cli sentry-cli --version + sentry-cli login --auth-token $SENTRY_AUTH_TOKEN - name: Run tests run: | From 34148db0e2e7d3c6c6a00ce48c0841b95e78445a Mon Sep 17 00:00:00 2001 From: Sina Iman Date: Sun, 15 Sep 2024 18:13:56 +0200 Subject: [PATCH 08/81] dont autorun sentry on yarn build --- desci-server/package.json | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/desci-server/package.json b/desci-server/package.json index 7077dab2d..abbcf4d5f 100755 --- a/desci-server/package.json +++ b/desci-server/package.json @@ -25,7 +25,7 @@ "script:seed-social-data": "debug=* node --no-warnings --enable-source-maps --loader ts-node/esm ./src/scripts/seed-social-data.ts", "script:DESTRUCTIVE-clear-social-data": "debug=* node --no-warnings --enable-source-maps --loader ts-node/esm ./src/scripts/DESTRUCTIVE-clear-social-data.ts", "script:seed-community-member": "debug=* node --no-warnings --enable-source-maps --loader ts-node/esm ./src/scripts/seed-community-members.ts", - "build": "rimraf dist && tsc && yarn copy-files && yarn sentry:sourcemaps", + "build": "rimraf dist && tsc && yarn copy-files", "copy-files": "copyfiles -u 1 src/**/*.cjs dist/", "generate": "npx prisma generate", "migrate:local": "DATABASE_URL=postgresql://walter:white@localhost:5433/boilerplate npx prisma migrate dev", @@ -184,4 +184,4 @@ "prisma": { "seed": "node --no-warnings=ExperimentalWarning --loader ts-node/esm prisma/seed.ts" } -} \ No newline at end of file +} From 9628bf77474b488616e75e07b8bc0911c21b4837 Mon Sep 17 00:00:00 2001 From: m0ar Date: Thu, 12 Sep 2024 18:28:41 +0200 Subject: [PATCH 09/81] compose: disable broken grobid healthcheck --- docker-compose.dev.yml | 21 +++++++++++++++------ 1 file changed, 15 insertions(+), 6 deletions(-) diff --git a/docker-compose.dev.yml b/docker-compose.dev.yml index 94e07ce89..7bf43dd70 100755 --- a/docker-compose.dev.yml +++ b/docker-compose.dev.yml @@ -63,7 +63,7 @@ services: graph_node: condition: service_started redis: - condition: service_started + condition: service_healthy # - nodes_media # UNCOMMENT FOR LOCAL DEV OF nodes-media links: - db_postgres @@ -173,6 +173,11 @@ services: redis: image: "redis:7-alpine" container_name: "redis_cache" + healthcheck: + test: [ "CMD", "redis-cli", "ping" ] + interval: 5s + timeout: 1s + retries: 5 ports: - "6379:6379" volumes: @@ -224,11 +229,6 @@ services: - "8070:8070" environment: - JAVA_OPTS=-Xmx2G -Xms2G - healthcheck: - test: ["CMD", "curl", "-f", "http://localhost:8070/api/isalive"] - interval: 30s - timeout: 10s - retries: 5 dpid_resolver: image: descilabs/dpid-resolver @@ -241,6 +241,12 @@ services: OPTIMISM_RPC_URL: http://host.docker.internal:8545 CERAMIC_URL: http://host.docker.internal:7007 IPFS_GATEWAY: http://host.docker.internal:8089/ipfs + REDIS_HOST: http://host.docker.internal + REDIS_PORT: 6379 + # How long to store anchored commit info (default 24 hours) + CACHE_TTL_ANCHORED: 86400 + # How long to store pending commit info + CACHE_TTL_PENDING: 300 restart: on-failure ports: - "5460:5460" @@ -258,3 +264,6 @@ services: condition: service_healthy ceramic: condition: service_healthy + redis: + condition: service_healthy + From 3bcf7969332cfca674053d94b74e7c9ab11f39e5 Mon Sep 17 00:00:00 2001 From: Sina Iman Date: Tue, 17 Sep 2024 00:38:41 +0200 Subject: [PATCH 10/81] run sentry? --- .github/workflows/build-server.yaml | 1 + desci-server/package.json | 4 ++-- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/.github/workflows/build-server.yaml b/.github/workflows/build-server.yaml index c4676434d..b25936ff2 100644 --- a/.github/workflows/build-server.yaml +++ b/.github/workflows/build-server.yaml @@ -121,6 +121,7 @@ jobs: - name: Set up Sentry CLI run: | sentry-cli --version + sentry-cli login --auth-token $SENTRY_AUTH_TOKEN - name: Build and tag the image (DEV) if: github.ref == 'refs/heads/develop' diff --git a/desci-server/package.json b/desci-server/package.json index abbcf4d5f..739b8e4aa 100755 --- a/desci-server/package.json +++ b/desci-server/package.json @@ -25,7 +25,7 @@ "script:seed-social-data": "debug=* node --no-warnings --enable-source-maps --loader ts-node/esm ./src/scripts/seed-social-data.ts", "script:DESTRUCTIVE-clear-social-data": "debug=* node --no-warnings --enable-source-maps --loader ts-node/esm ./src/scripts/DESTRUCTIVE-clear-social-data.ts", "script:seed-community-member": "debug=* node --no-warnings --enable-source-maps --loader ts-node/esm ./src/scripts/seed-community-members.ts", - "build": "rimraf dist && tsc && yarn copy-files", + "build": "rimraf dist && tsc && yarn copy-files; if [ \"$SENTRY_AUTH_TOKEN\" ]; then yarn sentry:sourcemaps; else echo 'SENTRY_AUTH_TOKEN not set, sourcemaps will not upload'; fi", "copy-files": "copyfiles -u 1 src/**/*.cjs dist/", "generate": "npx prisma generate", "migrate:local": "DATABASE_URL=postgresql://walter:white@localhost:5433/boilerplate npx prisma migrate dev", @@ -51,7 +51,7 @@ "podman:dev": "podman-compose --file docker-compose.yml --file docker-compose.dev.yml up --build", "email-dev": "email dev --dir ./src/templates/emails --port 3777", "check-deps": "npx npm-check", - "sentry:sourcemaps": "sentry-cli sourcemaps inject --org desci-labs --project nodes-backend ./dist && sentry-cli sourcemaps upload --org desci-labs --project nodes-backend ./dist" + "sentry:sourcemaps": "sentry-cli sourcemaps inject --org desci-labs --project nodes-backend ./dist && sentry-cli sourcemaps upload --org desci-labs --project nodes-backend ./dist && echo 'Sentry sourcemaps uploaded'" }, "dependencies": { "@automerge/automerge-repo": "^1.0.19", From 8c055543a8342c8cea16e244a668e4c7714e9bed Mon Sep 17 00:00:00 2001 From: Sina Iman Date: Tue, 17 Sep 2024 00:46:42 +0200 Subject: [PATCH 11/81] echo sentrytoken to env for build --- .github/workflows/build-and-test.yaml | 2 ++ 1 file changed, 2 insertions(+) diff --git a/.github/workflows/build-and-test.yaml b/.github/workflows/build-and-test.yaml index 9b3eb3d9e..181bf3e8e 100644 --- a/.github/workflows/build-and-test.yaml +++ b/.github/workflows/build-and-test.yaml @@ -61,6 +61,8 @@ jobs: npm install -g @sentry/cli sentry-cli --version sentry-cli login --auth-token $SENTRY_AUTH_TOKEN + # append to .env + echo "\nSENTRY_AUTH_TOKEN=$SENTRY_AUTH" >> .env - name: Run tests run: | From 6594d3ce8596fb20179c5e5b3a85b43b4b73fdb8 Mon Sep 17 00:00:00 2001 From: Sina Iman Date: Tue, 17 Sep 2024 00:54:04 +0200 Subject: [PATCH 12/81] fix newline --- .github/workflows/build-and-test.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/build-and-test.yaml b/.github/workflows/build-and-test.yaml index 181bf3e8e..75808b2e8 100644 --- a/.github/workflows/build-and-test.yaml +++ b/.github/workflows/build-and-test.yaml @@ -62,7 +62,7 @@ jobs: sentry-cli --version sentry-cli login --auth-token $SENTRY_AUTH_TOKEN # append to .env - echo "\nSENTRY_AUTH_TOKEN=$SENTRY_AUTH" >> .env + echo -e "\nSENTRY_AUTH_TOKEN=$SENTRY_AUTH" >> .env - name: Run tests run: | From 2c3fddde39f3b2928a5637e8af006178cdfe500b Mon Sep 17 00:00:00 2001 From: Sina Iman Date: Tue, 17 Sep 2024 01:02:24 +0200 Subject: [PATCH 13/81] add sentry token to inner env --- .github/workflows/build-and-test.yaml | 1 + 1 file changed, 1 insertion(+) diff --git a/.github/workflows/build-and-test.yaml b/.github/workflows/build-and-test.yaml index 75808b2e8..7b4a08242 100644 --- a/.github/workflows/build-and-test.yaml +++ b/.github/workflows/build-and-test.yaml @@ -63,6 +63,7 @@ jobs: sentry-cli login --auth-token $SENTRY_AUTH_TOKEN # append to .env echo -e "\nSENTRY_AUTH_TOKEN=$SENTRY_AUTH" >> .env + echo -e "\nSENTRY_AUTH_TOKEN=$SENTRY_AUTH" >> ./desci-server/.env - name: Run tests run: | From 8c14ce63e5167c64c615c8a680af8caec90a6fea Mon Sep 17 00:00:00 2001 From: Sina Iman Date: Tue, 17 Sep 2024 01:14:48 +0200 Subject: [PATCH 14/81] test build --- .github/workflows/build-and-test.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/build-and-test.yaml b/.github/workflows/build-and-test.yaml index 7b4a08242..ae1f22605 100644 --- a/.github/workflows/build-and-test.yaml +++ b/.github/workflows/build-and-test.yaml @@ -63,7 +63,7 @@ jobs: sentry-cli login --auth-token $SENTRY_AUTH_TOKEN # append to .env echo -e "\nSENTRY_AUTH_TOKEN=$SENTRY_AUTH" >> .env - echo -e "\nSENTRY_AUTH_TOKEN=$SENTRY_AUTH" >> ./desci-server/.env + yarn build - name: Run tests run: | From ddc75324ded90170eedd041acab4b748817d9e96 Mon Sep 17 00:00:00 2001 From: Sina Iman Date: Tue, 17 Sep 2024 01:19:42 +0200 Subject: [PATCH 15/81] test build --- .github/workflows/build-and-test.yaml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/build-and-test.yaml b/.github/workflows/build-and-test.yaml index ae1f22605..179b4ac83 100644 --- a/.github/workflows/build-and-test.yaml +++ b/.github/workflows/build-and-test.yaml @@ -62,8 +62,8 @@ jobs: sentry-cli --version sentry-cli login --auth-token $SENTRY_AUTH_TOKEN # append to .env - echo -e "\nSENTRY_AUTH_TOKEN=$SENTRY_AUTH" >> .env - yarn build + echo -e "\nSENTRY_AUTH_TOKEN=$SENTRY_AUTH" >> desci-server/.env + cd desci-server && yarn build - name: Run tests run: | From 01b095117ea4841bb706c7f45643e5a84a9ca8e1 Mon Sep 17 00:00:00 2001 From: Sina Iman Date: Tue, 17 Sep 2024 02:10:21 +0200 Subject: [PATCH 16/81] use correct index and default context novelty sort --- .../src/controllers/search/multiQuery.ts | 19 ++++++++----------- .../src/services/ElasticSearchService.ts | 8 ++++---- 2 files changed, 12 insertions(+), 15 deletions(-) diff --git a/desci-server/src/controllers/search/multiQuery.ts b/desci-server/src/controllers/search/multiQuery.ts index 476b70ea3..e35225243 100644 --- a/desci-server/src/controllers/search/multiQuery.ts +++ b/desci-server/src/controllers/search/multiQuery.ts @@ -58,7 +58,8 @@ export const multiQuery = async ( }); } - const primaryEntity = 'works'; // Hard coded for now to not affect results without a 'works' query. + let primaryEntity = 'works'; // Hard coded for now to not affect results without a 'works' query. + // const primaryEntity = Object.keys(validEntityQueries[0])[0]; const esQueries = validEntityQueries.map((q) => { @@ -71,24 +72,20 @@ export const multiQuery = async ( const esSort = buildSortQuery(primaryEntity, sort.field, sort.order); const esBoolQuery = buildBoolQuery(esQueries, filters); - const searchTermIsNonEmpty = Object.values(queries).some((q) => q['works'].length > 0); + const searchTermIsNonEmpty = Object.values(queries).some((q) => q['works']?.length > 0); // if search term is empty and there is no other sorting, then sort by content novelty and date if (!searchTermIsNonEmpty && sort.field === 'relevance') { esSort.push({ - _script: { - type: 'number', - script: { - lang: 'painless', - source: - "params._source.containsKey('content_novelty_percentile') ? params._source['content_novelty_percentile'] : 0", - }, - order: 'desc', - }, + content_novelty_percentile: { order: 'desc', missing: '_last' }, }); esSort.push({ publication_year: { order: 'desc' } }); } + if (primaryEntity === 'works') { + primaryEntity = 'works_opt'; + } + const finalQuery = { index: primaryEntity, body: { diff --git a/desci-server/src/services/ElasticSearchService.ts b/desci-server/src/services/ElasticSearchService.ts index fd89e4c69..5cd7c4a5a 100644 --- a/desci-server/src/services/ElasticSearchService.ts +++ b/desci-server/src/services/ElasticSearchService.ts @@ -62,7 +62,7 @@ export const RELEVANT_FIELDS = { }; type SortOrder = 'asc' | 'desc'; -type SortField = { [field: string]: { order: SortOrder; missing?: string; type?: string; script?: any } }; +type SortField = { [field: string]: { order: SortOrder; missing?: string | number; type?: string; script?: any } }; const baseSort: SortField[] = [{ _score: { order: 'desc' } }]; @@ -202,7 +202,7 @@ function buildFilter(filter: Filter) { nested: { path: filter.field.split('.')[0], query: { - match_phrase: { [filter.field]: value }, + match_phrase: { [filter.field]: { query: value, analyzer: 'edge_ngram_analyzer' } }, }, }, })); @@ -221,12 +221,12 @@ function buildFilter(filter: Filter) { nested: { path: fieldParts[0], query: { - match_phrase: { [filter.field]: filter.value }, + match_phrase: { [filter.field]: { query: filter.value, analyzer: 'edge_ngram_analyzer' } }, }, }, }; } - return { match_phrase: { [filter.field]: filter.value } }; + return { match_phrase: { [filter.field]: { query: filter.value, analyzer: 'edge_ngram_analyzer' } } }; case 'match': const matchQuery = { match: { From be7088cc22dcae153dfa2a093dde0be30a282cb5 Mon Sep 17 00:00:00 2001 From: Sina Iman Date: Tue, 17 Sep 2024 03:30:29 +0200 Subject: [PATCH 17/81] added concepts, made exceptions for nesting institutions for new index --- desci-server/src/controllers/search/multiQuery.ts | 4 ++-- desci-server/src/services/ElasticSearchService.ts | 12 +++++++----- 2 files changed, 9 insertions(+), 7 deletions(-) diff --git a/desci-server/src/controllers/search/multiQuery.ts b/desci-server/src/controllers/search/multiQuery.ts index e35225243..071a3e98b 100644 --- a/desci-server/src/controllers/search/multiQuery.ts +++ b/desci-server/src/controllers/search/multiQuery.ts @@ -75,11 +75,11 @@ export const multiQuery = async ( const searchTermIsNonEmpty = Object.values(queries).some((q) => q['works']?.length > 0); // if search term is empty and there is no other sorting, then sort by content novelty and date - if (!searchTermIsNonEmpty && sort.field === 'relevance') { + if (sort.field === 'relevance') { esSort.push({ content_novelty_percentile: { order: 'desc', missing: '_last' }, }); - esSort.push({ publication_year: { order: 'desc' } }); + // esSort.push({ publication_year: { order: 'desc' } }); } if (primaryEntity === 'works') { diff --git a/desci-server/src/services/ElasticSearchService.ts b/desci-server/src/services/ElasticSearchService.ts index 5cd7c4a5a..ea157334e 100644 --- a/desci-server/src/services/ElasticSearchService.ts +++ b/desci-server/src/services/ElasticSearchService.ts @@ -233,12 +233,12 @@ function buildFilter(filter: Filter) { [filter.field]: { query: filter.value, operator: filter.matchLogic || 'or', - ...(filter.fuzziness && { fuzziness: filter.fuzziness }), + // ...(filter.fuzziness && { fuzziness: filter.fuzziness }), }, }, }; - if (filter.field.includes('.')) { + if (filter.field.includes('.') && !filter.field.includes('institutions')) { const [nestedPath, nestedField] = filter.field.split('.'); return { nested: { @@ -261,12 +261,14 @@ function getRelevantFields(entity: string) { if (entity === 'works') return RELEVANT_FIELDS.works; if (entity === 'authors') return RELEVANT_FIELDS.authors; if (entity === 'topics') return RELEVANT_FIELDS.topics; + if (entity === 'concepts') return RELEVANT_FIELDS.concepts; if (entity === 'subfields') return RELEVANT_FIELDS.subfields; if (entity === 'institutions') return RELEVANT_FIELDS.institutions; if (entity === 'sources') return RELEVANT_FIELDS.sources; if (entity === 'autocomplete_full') return RELEVANT_FIELDS.autocomplete_full; if (entity === 'works_authors') return RELEVANT_FIELDS.denorm_authors; if (entity === 'works_fields') return RELEVANT_FIELDS.denorm_fields; + if (entity === 'works_concepts') return RELEVANT_FIELDS.denorm_concepts; if (entity === 'works_topics') return RELEVANT_FIELDS.denorm_topics; if (entity === 'works_countries') return RELEVANT_FIELDS.denorm_countries; if (entity === 'works_institutions') return RELEVANT_FIELDS.denorm_institutions; @@ -285,7 +287,7 @@ export function buildMultiMatchQuery( let multiMatchQuery: QueryDslQueryContainer; - if (entity.startsWith('works_')) { + if (entity.startsWith('works_') && !fields[0]?.includes('institutions')) { const nestedField = fields[0]?.split('.')[0]; multiMatchQuery = { nested: { @@ -295,7 +297,7 @@ export function buildMultiMatchQuery( query: query, fields: fields, type: 'best_fields', - fuzziness: fuzzy, // Retained fuzziness + // fuzziness: fuzzy, // Retained fuzziness }, }, }, @@ -306,7 +308,7 @@ export function buildMultiMatchQuery( query: query, fields: fields, type: 'best_fields', - fuzziness: fuzzy, // Retained fuzziness + // fuzziness: fuzzy, // Retained fuzziness }, }; } From 54ebbd7313f4ebd22d725459c288ffd212198448 Mon Sep 17 00:00:00 2001 From: m0ar Date: Tue, 17 Sep 2024 13:44:36 +0200 Subject: [PATCH 18/81] compose: sync kubo with live deployments, bump ceramic to 6.4.0 --- docker-compose.dev.yml | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/docker-compose.dev.yml b/docker-compose.dev.yml index 7bf43dd70..2be51c7fe 100755 --- a/docker-compose.dev.yml +++ b/docker-compose.dev.yml @@ -121,7 +121,7 @@ services: # EXPERIMENTAL_SUBGRAPH_VERSION_SWITCHING_MODE: synced ipfs: - image: ipfs/kubo:v0.24.0 + image: ipfs/kubo:v0.26.0 container_name: "ipfs" environment: IPFS_SWARM_KEY: "/key/swarm/psk/1.0.0/\n/base16/\n9d002c50635a479d29dcc0ccb49d862952a0dcc52baddd253167adcd496c8d04" @@ -147,7 +147,7 @@ services: timeout: 2s ipfs_public: - image: ipfs/kubo:v0.24.0 + image: ipfs/kubo:v0.26.0 container_name: "ipfs_public" ports: - "5002:5001" @@ -184,7 +184,7 @@ services: - ./local-data/redis:/data ceramic: - image: ceramicnetwork/js-ceramic:5.16.0 + image: ceramicnetwork/js-ceramic:6.4.0 container_name: ceramic ports: - "7007:7007" From 7d43c7f5c5cf1898cc1338f065d8226ddf4cef43 Mon Sep 17 00:00:00 2001 From: m0ar Date: Tue, 17 Sep 2024 16:02:32 +0200 Subject: [PATCH 19/81] ceramic: bump to 6.4.0, enable prometheus endpoints, enable historical sync --- ceramic-k8s/ceramic_deployment_dev.yaml | 8 ++++---- ceramic-k8s/ceramic_deployment_prod.yaml | 8 ++++---- 2 files changed, 8 insertions(+), 8 deletions(-) diff --git a/ceramic-k8s/ceramic_deployment_dev.yaml b/ceramic-k8s/ceramic_deployment_dev.yaml index c2fbb5b5c..c18556a28 100644 --- a/ceramic-k8s/ceramic_deployment_dev.yaml +++ b/ceramic-k8s/ceramic_deployment_dev.yaml @@ -32,7 +32,7 @@ spec: {{- end -}} {{- with secret "secrets/desci-server/dev/db" -}} - echo "{\"anchor\":{\"ethereum-rpc-url\":\"{{ .Data.ceramic_rpc }}\"},\"http-api\":{\"cors-allowed-origins\":[\".*\"],\"admin-dids\":[\"did:key:z6MktbKJrMnhVJ37QFTo12911ycm2juKDUzWHDVETu9s5a9T\"]},\"ipfs\":{\"mode\":\"remote\",\"host\":\"http://public-ceramic-ipfs-dev-service-internal.default.svc.cluster.local:5001\"},\"logger\":{\"log-level\":0},\"metrics\":{\"metrics-exporter-enabled\":false,\"metrics-port\":9090},\"network\":{\"name\":\"testnet-clay\"},\"node\":{},\"state-store\":{\"mode\":\"s3\",\"s3-bucket\":\"ceramic-node-dev-prime2\"},\"indexing\":{\"db\":\"{{ .Data.ceramic_url }}\",\"allow-queries-before-historical-sync\":true,\"models\":[]}}" > daemon.config.json + echo "{\"anchor\":{\"ethereum-rpc-url\":\"{{ .data.ceramic_rpc }}\"},\"http-api\":{\"cors-allowed-origins\":[\".*\"],\"admin-dids\":[\"did:key:z6mktbkjrmnhvj37qfto12911ycm2jukduzwhdvetu9s5a9t\"]},\"ipfs\":{\"mode\":\"remote\",\"host\":\"http://public-ceramic-ipfs-dev-service-internal.default.svc.cluster.local:5001\"},\"logger\":{\"log-level\":0},\"metrics\":{\"prometheus-exporter-enabled\":true,\"prometheus-exporter-port\":9464},\"network\":{\"name\":\"testnet-clay\"},\"node\":{},\"state-store\":{\"mode\":\"s3\",\"s3-bucket\":\"ceramic-node-dev-prime2\"},\"indexing\":{\"db\":\"{{ .data.ceramic_url }}\",\"allow-queries-before-historical-sync\":true,\"enable-historical-sync\":true}}" > daemon.config.json export NODE_ENV=production export CERAMIC_PUBSUB_QPS_LIMIT=500 echo "envset"; @@ -41,7 +41,7 @@ spec: App: JsCeramicDev spec: containers: - - image: ceramicnetwork/js-ceramic:5.16.0 + - image: ceramicnetwork/js-ceramic:6.4.0 name: js-ceramic-dev command: ["/bin/bash", "-c"] args: @@ -51,10 +51,10 @@ spec: name: http-api resources: limits: - cpu: "0.7" + cpu: 2 memory: 4Gi requests: - cpu: "0.6" + cpu: 1 memory: 4Gi # # restart pod after failureThreshold*periodSeconds total seconds livenessProbe: diff --git a/ceramic-k8s/ceramic_deployment_prod.yaml b/ceramic-k8s/ceramic_deployment_prod.yaml index 376b6a0d6..fd8b64d5a 100644 --- a/ceramic-k8s/ceramic_deployment_prod.yaml +++ b/ceramic-k8s/ceramic_deployment_prod.yaml @@ -53,7 +53,7 @@ spec: vault.hashicorp.com/agent-inject-secret-config: secrets/desci-server/production/db vault.hashicorp.com/agent-inject-template-config: | {{- with secret "secrets/desci-server/production/db" -}} - echo "{\"anchor\":{\"auth-method\":\"did\",\"ethereum-rpc-url\":\"{{ .Data.ceramic_rpc }}\"},\"node\":{\"privateSeedUrl\":\"inplace:ed25519#{{ .Data.ceramic_cas_pkey }}\"},\"http-api\":{\"cors-allowed-origins\":[\".*\"],\"admin-dids\":[\"did:key:z6MktbKJrMnhVJ37QFTo12911ycm2juKDUzWHDVETu9s5a9T\"]},\"ipfs\":{\"mode\":\"remote\",\"host\":\"http://public-ceramic-ipfs-prod-service-internal.default.svc.cluster.local:5001\"},\"logger\":{\"log-level\":0},\"metrics\":{\"metrics-exporter-enabled\":false,\"metrics-port\":9090},\"network\":{\"name\":\"mainnet\"},\"state-store\":{\"mode\":\"fs\",\"local-directory\":\"/root/.ceramic/statestore\"},\"indexing\":{\"db\":\"{{ .Data.ceramic_url }}\",\"allow-queries-before-historical-sync\":true,\"models\":[]}}" > daemon.config.json + echo "{\"anchor\":{\"auth-method\":\"did\",\"ethereum-rpc-url\":\"{{ .Data.ceramic_rpc }}\"},\"node\":{\"privateSeedUrl\":\"inplace:ed25519#{{ .Data.ceramic_cas_pkey }}\"},\"http-api\":{\"cors-allowed-origins\":[\".*\"],\"admin-dids\":[\"did:key:z6MktbKJrMnhVJ37QFTo12911ycm2juKDUzWHDVETu9s5a9T\"]},\"ipfs\":{\"mode\":\"remote\",\"host\":\"http://public-ceramic-ipfs-prod-service-internal.default.svc.cluster.local:5001\"},\"logger\":{\"log-level\":0},\"metrics\":{\"prometheus-exporter-enabled\":true,\"prometheus-exporter-port\":9464},\"network\":{\"name\":\"mainnet\"},\"state-store\":{\"mode\":\"fs\",\"local-directory\":\"/root/.ceramic/statestore\"},\"indexing\":{\"db\":\"{{ .Data.ceramic_url }}\",\"allow-queries-before-historical-sync\":true,\"enable-historical-sync\":true}}" > daemon.config.json export NODE_ENV=production export CERAMIC_PUBSUB_QPS_LIMIT=500 echo "envset"; @@ -62,7 +62,7 @@ spec: App: JsCeramicProd spec: containers: - - image: ceramicnetwork/js-ceramic:5.16.0 + - image: ceramicnetwork/js-ceramic:6.4.0 name: js-ceramic-prod command: ["/bin/bash", "-c"] volumeMounts: @@ -75,10 +75,10 @@ spec: name: http-api resources: limits: - cpu: "0.7" + cpu: 2 memory: 4Gi requests: - cpu: "0.6" + cpu: 1 memory: 4Gi # # restart pod after failureThreshold*periodSeconds total seconds livenessProbe: From ea75555d600863958dc7ff035dcd7b5281fd7b3b Mon Sep 17 00:00:00 2001 From: m0ar Date: Tue, 17 Sep 2024 16:13:39 +0200 Subject: [PATCH 20/81] ceramic: fix accidental lowercasing of dev config --- ceramic-k8s/ceramic_deployment_dev.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ceramic-k8s/ceramic_deployment_dev.yaml b/ceramic-k8s/ceramic_deployment_dev.yaml index c18556a28..3463b4c8b 100644 --- a/ceramic-k8s/ceramic_deployment_dev.yaml +++ b/ceramic-k8s/ceramic_deployment_dev.yaml @@ -32,7 +32,7 @@ spec: {{- end -}} {{- with secret "secrets/desci-server/dev/db" -}} - echo "{\"anchor\":{\"ethereum-rpc-url\":\"{{ .data.ceramic_rpc }}\"},\"http-api\":{\"cors-allowed-origins\":[\".*\"],\"admin-dids\":[\"did:key:z6mktbkjrmnhvj37qfto12911ycm2jukduzwhdvetu9s5a9t\"]},\"ipfs\":{\"mode\":\"remote\",\"host\":\"http://public-ceramic-ipfs-dev-service-internal.default.svc.cluster.local:5001\"},\"logger\":{\"log-level\":0},\"metrics\":{\"prometheus-exporter-enabled\":true,\"prometheus-exporter-port\":9464},\"network\":{\"name\":\"testnet-clay\"},\"node\":{},\"state-store\":{\"mode\":\"s3\",\"s3-bucket\":\"ceramic-node-dev-prime2\"},\"indexing\":{\"db\":\"{{ .data.ceramic_url }}\",\"allow-queries-before-historical-sync\":true,\"enable-historical-sync\":true}}" > daemon.config.json + echo "{\"anchor\":{\"ethereum-rpc-url\":\"{{ .Data.ceramic_rpc }}\"},\"http-api\":{\"cors-allowed-origins\":[\".*\"],\"admin-dids\":[\"did:key:z6MktbKJrMnhVJ37QFTo12911ycm2juKDUzWHDVETu9s5a9T\"]},\"ipfs\":{\"mode\":\"remote\",\"host\":\"http://public-ceramic-ipfs-dev-service-internal.default.svc.cluster.local:5001\"},\"logger\":{\"log-level\":0},\"metrics\":{\"prometheus-exporter-enabled\":true,\"prometheus-exporter-port\":9464},\"network\":{\"name\":\"testnet-clay\"},\"node\":{},\"state-store\":{\"mode\":\"s3\",\"s3-bucket\":\"ceramic-node-dev-prime2\"},\"indexing\":{\"db\":\"{{ .Data.ceramic_url }}\",\"allow-queries-before-historical-sync\":true,\"enable-historical-sync\":true}}" > daemon.config.json export NODE_ENV=production export CERAMIC_PUBSUB_QPS_LIMIT=500 echo "envset"; From 98e96e8f6b6f49c0c5ec71e49168725a50d81309 Mon Sep 17 00:00:00 2001 From: kadami <86646883+kadamidev@users.noreply.github.com> Date: Tue, 17 Sep 2024 19:39:33 +0000 Subject: [PATCH 21/81] field autocomplete fixed --- desci-server/src/controllers/search/query.ts | 2 +- desci-server/src/services/ElasticSearchService.ts | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/desci-server/src/controllers/search/query.ts b/desci-server/src/controllers/search/query.ts index e8b292efe..5bbfb05ac 100644 --- a/desci-server/src/controllers/search/query.ts +++ b/desci-server/src/controllers/search/query.ts @@ -73,7 +73,7 @@ export const singleQuery = async ( } if (entity === 'fields') { - searchEntity = 'subfields'; // Overwrite as fields are accessible via 'topics' index + searchEntity = 'subfields'; // Overwrite as fields are accessible via 'subfields' index logger.info( { entity, searchEntity }, `Entity provided is '${entity}', overwriting with '${searchEntity}' because ${entity} is accessible in that index.`, diff --git a/desci-server/src/services/ElasticSearchService.ts b/desci-server/src/services/ElasticSearchService.ts index ea157334e..95488b02c 100644 --- a/desci-server/src/services/ElasticSearchService.ts +++ b/desci-server/src/services/ElasticSearchService.ts @@ -32,7 +32,7 @@ export const RELEVANT_FIELDS = { works: ['title', 'abstract'], authors: ['display_name', 'orcid', 'last_known_institution', 'authors.affiliation'], topics: ['display_name'], - subfields: ['subfield_display_name'], + fields: ['subfield_display_name'], concepts: ['display_name'], sources: ['display_name', 'publisher', 'issn_l', 'issn'], autocomplete_full: ['title', 'publisher', 'primary_id'], @@ -262,7 +262,7 @@ function getRelevantFields(entity: string) { if (entity === 'authors') return RELEVANT_FIELDS.authors; if (entity === 'topics') return RELEVANT_FIELDS.topics; if (entity === 'concepts') return RELEVANT_FIELDS.concepts; - if (entity === 'subfields') return RELEVANT_FIELDS.subfields; + if (entity === 'fields') return RELEVANT_FIELDS.fields; if (entity === 'institutions') return RELEVANT_FIELDS.institutions; if (entity === 'sources') return RELEVANT_FIELDS.sources; if (entity === 'autocomplete_full') return RELEVANT_FIELDS.autocomplete_full; From 0bd0a96671940852da1ca8fbb0ad2f10b04c889b Mon Sep 17 00:00:00 2001 From: m0ar Date: Wed, 18 Sep 2024 16:51:29 +0200 Subject: [PATCH 22/81] ceramic: turn off historical sync --- ceramic-k8s/ceramic_deployment_dev.yaml | 2 +- ceramic-k8s/ceramic_deployment_prod.yaml | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/ceramic-k8s/ceramic_deployment_dev.yaml b/ceramic-k8s/ceramic_deployment_dev.yaml index 3463b4c8b..58946e7ec 100644 --- a/ceramic-k8s/ceramic_deployment_dev.yaml +++ b/ceramic-k8s/ceramic_deployment_dev.yaml @@ -32,7 +32,7 @@ spec: {{- end -}} {{- with secret "secrets/desci-server/dev/db" -}} - echo "{\"anchor\":{\"ethereum-rpc-url\":\"{{ .Data.ceramic_rpc }}\"},\"http-api\":{\"cors-allowed-origins\":[\".*\"],\"admin-dids\":[\"did:key:z6MktbKJrMnhVJ37QFTo12911ycm2juKDUzWHDVETu9s5a9T\"]},\"ipfs\":{\"mode\":\"remote\",\"host\":\"http://public-ceramic-ipfs-dev-service-internal.default.svc.cluster.local:5001\"},\"logger\":{\"log-level\":0},\"metrics\":{\"prometheus-exporter-enabled\":true,\"prometheus-exporter-port\":9464},\"network\":{\"name\":\"testnet-clay\"},\"node\":{},\"state-store\":{\"mode\":\"s3\",\"s3-bucket\":\"ceramic-node-dev-prime2\"},\"indexing\":{\"db\":\"{{ .Data.ceramic_url }}\",\"allow-queries-before-historical-sync\":true,\"enable-historical-sync\":true}}" > daemon.config.json + echo "{\"anchor\":{\"ethereum-rpc-url\":\"{{ .Data.ceramic_rpc }}\"},\"http-api\":{\"cors-allowed-origins\":[\".*\"],\"admin-dids\":[\"did:key:z6MktbKJrMnhVJ37QFTo12911ycm2juKDUzWHDVETu9s5a9T\"]},\"ipfs\":{\"mode\":\"remote\",\"host\":\"http://public-ceramic-ipfs-dev-service-internal.default.svc.cluster.local:5001\"},\"logger\":{\"log-level\":0},\"metrics\":{\"prometheus-exporter-enabled\":true,\"prometheus-exporter-port\":9464},\"network\":{\"name\":\"testnet-clay\"},\"node\":{},\"state-store\":{\"mode\":\"s3\",\"s3-bucket\":\"ceramic-node-dev-prime2\"},\"indexing\":{\"db\":\"{{ .Data.ceramic_url }}\",\"allow-queries-before-historical-sync\":true}}" > daemon.config.json export NODE_ENV=production export CERAMIC_PUBSUB_QPS_LIMIT=500 echo "envset"; diff --git a/ceramic-k8s/ceramic_deployment_prod.yaml b/ceramic-k8s/ceramic_deployment_prod.yaml index fd8b64d5a..ce84fecec 100644 --- a/ceramic-k8s/ceramic_deployment_prod.yaml +++ b/ceramic-k8s/ceramic_deployment_prod.yaml @@ -53,7 +53,7 @@ spec: vault.hashicorp.com/agent-inject-secret-config: secrets/desci-server/production/db vault.hashicorp.com/agent-inject-template-config: | {{- with secret "secrets/desci-server/production/db" -}} - echo "{\"anchor\":{\"auth-method\":\"did\",\"ethereum-rpc-url\":\"{{ .Data.ceramic_rpc }}\"},\"node\":{\"privateSeedUrl\":\"inplace:ed25519#{{ .Data.ceramic_cas_pkey }}\"},\"http-api\":{\"cors-allowed-origins\":[\".*\"],\"admin-dids\":[\"did:key:z6MktbKJrMnhVJ37QFTo12911ycm2juKDUzWHDVETu9s5a9T\"]},\"ipfs\":{\"mode\":\"remote\",\"host\":\"http://public-ceramic-ipfs-prod-service-internal.default.svc.cluster.local:5001\"},\"logger\":{\"log-level\":0},\"metrics\":{\"prometheus-exporter-enabled\":true,\"prometheus-exporter-port\":9464},\"network\":{\"name\":\"mainnet\"},\"state-store\":{\"mode\":\"fs\",\"local-directory\":\"/root/.ceramic/statestore\"},\"indexing\":{\"db\":\"{{ .Data.ceramic_url }}\",\"allow-queries-before-historical-sync\":true,\"enable-historical-sync\":true}}" > daemon.config.json + echo "{\"anchor\":{\"auth-method\":\"did\",\"ethereum-rpc-url\":\"{{ .Data.ceramic_rpc }}\"},\"node\":{\"privateSeedUrl\":\"inplace:ed25519#{{ .Data.ceramic_cas_pkey }}\"},\"http-api\":{\"cors-allowed-origins\":[\".*\"],\"admin-dids\":[\"did:key:z6MktbKJrMnhVJ37QFTo12911ycm2juKDUzWHDVETu9s5a9T\"]},\"ipfs\":{\"mode\":\"remote\",\"host\":\"http://public-ceramic-ipfs-prod-service-internal.default.svc.cluster.local:5001\"},\"logger\":{\"log-level\":0},\"metrics\":{\"prometheus-exporter-enabled\":true,\"prometheus-exporter-port\":9464},\"network\":{\"name\":\"mainnet\"},\"state-store\":{\"mode\":\"fs\",\"local-directory\":\"/root/.ceramic/statestore\"},\"indexing\":{\"db\":\"{{ .Data.ceramic_url }}\",\"allow-queries-before-historical-sync\":true}}" > daemon.config.json export NODE_ENV=production export CERAMIC_PUBSUB_QPS_LIMIT=500 echo "envset"; From 8f6980413adad97b44cad183385facd7b91e2b81 Mon Sep 17 00:00:00 2001 From: m0ar Date: Wed, 18 Sep 2024 16:51:58 +0200 Subject: [PATCH 23/81] contracts: add final alias registry migration logs --- ...nc_prod_Wed,_11_Sep_2024_12:38:13_GMT.json | 3683 ++++++++++++++++ ...nc_prod_Wed,_18_Sep_2024_13:04:23_GMT.json | 3716 +++++++++++++++++ 2 files changed, 7399 insertions(+) create mode 100644 desci-contracts/migration-data/aliasRegistrySync_prod_Wed,_11_Sep_2024_12:38:13_GMT.json create mode 100644 desci-contracts/migration-data/aliasRegistrySync_prod_Wed,_18_Sep_2024_13:04:23_GMT.json diff --git a/desci-contracts/migration-data/aliasRegistrySync_prod_Wed,_11_Sep_2024_12:38:13_GMT.json b/desci-contracts/migration-data/aliasRegistrySync_prod_Wed,_11_Sep_2024_12:38:13_GMT.json new file mode 100644 index 000000000..924a7a08c --- /dev/null +++ b/desci-contracts/migration-data/aliasRegistrySync_prod_Wed,_11_Sep_2024_12:38:13_GMT.json @@ -0,0 +1,3683 @@ +[ + { + "dpid": "0", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreie2idd2yuwibppujafgtfc6cczopht4q47y563q4paml2me2dsh6y", + "time": 1675737468 + } + ], + "validationError": false + }, + { + "dpid": "1", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreigbp7bahnrxujbz5uu3j6hzmyimq7wijkucwyi4bc5tbvka5xw3wq", + "time": 1675781796 + }, + { + "cid": "bafkreigwzsizb76b62ln5xnhhqeypxhyqwwyp56zcprl52siut2q7h2lky", + "time": 1682818404 + }, + { + "cid": "bafkreigwzsizb76b62ln5xnhhqeypxhyqwwyp56zcprl52siut2q7h2lky", + "time": 1682818608 + } + ], + "validationError": false + }, + { + "dpid": "2", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreihlsxjw3gzrikm2att6sd2yty4qx37z3fgmzokrm6fd3oony2qqby", + "time": 1676095440 + }, + { + "cid": "bafkreigvalv7basyqxn57b5ittssieecsccy7qaypmy6s7egr2o5tcqnda", + "time": 1676096820 + } + ], + "validationError": false + }, + { + "dpid": "3", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreiancsq3yywjzkoyevwhn4hxyzgcfbdb72jspegmwy6uacd2cztpra", + "time": 1676725008 + } + ], + "validationError": false + }, + { + "dpid": "4", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreick32zk4ennjwwy7vqva7wpjo2w5d4fkwhg7hkrdjk63xq5r6gup4", + "time": 1676988612 + } + ], + "validationError": false + }, + { + "dpid": "5", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreihra4e2ejsm7yqra4wmo2ww43j4ndvylfsrv5obobkl2k666baram", + "time": 1676996292 + } + ], + "validationError": false + }, + { + "dpid": "6", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreiee7atuqdvq7dtxf2msslelz2ubst2g64oigetxunn352ryqvuoti", + "time": 1677066240 + } + ], + "validationError": false + }, + { + "dpid": "7", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreidi2idvbbbg5y6iuf3bnbdo7gkyzgoz3hik2hghr3rl3gd7nplnwe", + "time": 1677080820 + }, + { + "cid": "bafkreicyvzgk632l2zn55dkbscjrwrlrxlckrxjhpxn6kiv4roegwzprpi", + "time": 1677081012 + } + ], + "validationError": false + }, + { + "dpid": "8", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreibnhuq4tliestyutqxrfco4wwr3gxyrp7dlydxvgkddo6euet5yyu", + "time": 1677144720 + } + ], + "validationError": false + }, + { + "dpid": "9", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreigjjlyedw3l7yfunjhaooe226hemiqz7pkeqb3arfmwvujknaa7pe", + "time": 1677230328 + } + ], + "validationError": false + }, + { + "dpid": "10", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreihbcdgctujsajvlhbbcghfkg766pprlgatvujzkw6utteryn737wi", + "time": 1677510672 + }, + { + "cid": "bafkreif6omh6d2nosj7exr4gybupz3i6owb7ig7mfha23bebzbbzgtj3ty", + "time": 1677511224 + } + ], + "validationError": false + }, + { + "dpid": "11", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreig75cxpsu2zhnkej7nwqszduw6l32luo3opikzsqa5wpfchnl7sua", + "time": 1678309056 + } + ], + "validationError": false + }, + { + "dpid": "12", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreigvec6jtxth3eessemov7x62wjhtfpfihdleanekwx5l47rkxclcu", + "time": 1678771692 + } + ], + "validationError": false + }, + { + "dpid": "13", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreienztazc23yp5ejvwymgekqf2kmx6foasxul7yzt6w5crjwceqsea", + "time": 1678814328 + }, + { + "cid": "bafkreid4yx77dkhlbmx2gqwwki6y2rjmuybnqkxqmxnoyjtx7uhgdkdeu4", + "time": 1680117252 + } + ], + "validationError": false + }, + { + "dpid": "14", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreiasx7tcckutok7a7yk7ej2pv6bolo5naihlk2gny6tpykcfvzxqm4", + "time": 1679014104 + } + ], + "validationError": false + }, + { + "dpid": "15", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreifjuqlmsnnr2vlhwxrjsgu5zczwgodqjuzmo4kzgpzzu5zn42ivby", + "time": 1679219244 + }, + { + "cid": "bafkreiar3d6vkcyvfnk7kfhu4yrvul6hsn4fnjrwgq7wbl27t4e3ehfhwq", + "time": 1679219328 + }, + { + "cid": "bafkreiar3d6vkcyvfnk7kfhu4yrvul6hsn4fnjrwgq7wbl27t4e3ehfhwq", + "time": 1679219484 + } + ], + "validationError": false + }, + { + "dpid": "16", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreig27rnst73rqnqgtesyo32xhrhaqtdxbvtdohwnjdzua7cyapghbu", + "time": 1679343324 + } + ], + "validationError": false + }, + { + "dpid": "17", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreigggibyev5x4w3tcydslfl3j5g2fl2sabfcxvdzqeajzfg3tqignq", + "time": 1679409324 + } + ], + "validationError": false + }, + { + "dpid": "18", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreigghoctitgbpsjl6elgjkdlpu26t6zon7gqfx7cuhprsyykcjgvee", + "time": 1679409744 + } + ], + "validationError": false + }, + { + "dpid": "19", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreicvdmmzw7tyaa7dkaikb7dcowjjbu3cv76rhvxqdbzm7gcg4inrfq", + "time": 1679539764 + } + ], + "validationError": false + }, + { + "dpid": "20", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreie6bxf7u3z45sn2amk7ocsjihloiecfncmwsgvqoamqjnczfwnexy", + "time": 1679540424 + }, + { + "cid": "bafkreibnxznsx2xwdasyhjr2epkypjohuvz5qy35iu2elyoygjnfbk7im4", + "time": 1680554796 + } + ], + "validationError": false + }, + { + "dpid": "21", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreiecholb67ldemsvyr7js2x6dewjnsylvpk47ejyhrokkbnqbl4i4y", + "time": 1679637204 + }, + { + "cid": "bafkreih6jpxxvs5ruwhfms7t4kg3qv27x6cf4qn7rzoffcjhgctjjcn7my", + "time": 1679637252 + }, + { + "cid": "bafkreih6jpxxvs5ruwhfms7t4kg3qv27x6cf4qn7rzoffcjhgctjjcn7my", + "time": 1679637288 + } + ], + "validationError": false + }, + { + "dpid": "22", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreid4d4543faobctzfxh53tfa7u2q7jwqll7g3o52b6ko2vxbq6gya4", + "time": 1679658768 + } + ], + "validationError": false + }, + { + "dpid": "23", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreifzp4vuudwvek33rcft2rd2szjrimey7yezcsbm2awkx2tjsunwwi", + "time": 1680567024 + } + ], + "validationError": false + }, + { + "dpid": "24", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreicqcgfswelv7jvt3o5mirsrwbegst354jzl5znfhsysfi5kwa5oem", + "time": 1681191960 + } + ], + "validationError": false + }, + { + "dpid": "25", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreiai7ekqchod7c7na6bsc5aeicugtqr2ai4jhdyjal4ukzzjdoxdoi", + "time": 1681495752 + } + ], + "validationError": false + }, + { + "dpid": "26", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreiasg744hrz2h6tkkw4a2z55orh33v5rs2j62mx3arsuqxa5dppyzq", + "time": 1681497684 + }, + { + "cid": "bafkreicbh5ytfk7ohfa7tw44q5nmjkzmqseiesoskwcjntwc6apx7ifyyi", + "time": 1681497900 + } + ], + "validationError": false + }, + { + "dpid": "27", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreiehj4xqrpk5m6sdemt5nv6ktb5uxp6ihmg3apdwiu6xhkjzlcmuka", + "time": 1681505184 + } + ], + "validationError": false + }, + { + "dpid": "28", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreihmuuks36pyt5quuvjbxkhyu6lhdf3sfbqvfii6j2gemwpu2uc67q", + "time": 1681506588 + } + ], + "validationError": false + }, + { + "dpid": "29", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreigifwmh35byvn2yzg2vojm6r6qpjyoce6dfdsacmch336adgqmyee", + "time": 1681736556 + }, + { + "cid": "bafkreicxifdkouaya7pzrj2upqft2c637t6awklqjsbd76dfog42hxvlqu", + "time": 1681736628 + } + ], + "validationError": false + }, + { + "dpid": "30", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreidtjqvqyoq7ehafmy7vvhjlewgtxkxaqr7anwtwtgkzvlogmfwaey", + "time": 1681761420 + }, + { + "cid": "bafkreif6imae7ikphst6f2opahy2bn4qnm3srzj4rmnpdhrqtykwr6c4yu", + "time": 1681762272 + } + ], + "validationError": false + }, + { + "dpid": "31", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreiahcqh7zzoz27gzh2chwto2u5kabmf2vmca3xbmzrlmgoqucrmfky", + "time": 1681805808 + } + ], + "validationError": false + }, + { + "dpid": "32", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreiaakpmpc5jr4bp3puzzpdjv5nh3maunzbaug2p335ngmdfsfekkxe", + "time": 1681830960 + } + ], + "validationError": false + }, + { + "dpid": "33", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreic2zkjdknqf5kfelzzstfovdwuc2dolbaej7eduedn6md7rpfo27y", + "time": 1682014560 + } + ], + "validationError": false + }, + { + "dpid": "34", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreibkbhhedb3yazc6rze6772ouoymv3yy5vqmilmwi6eq7yuw3n6tue", + "time": 1682144088 + } + ], + "validationError": false + }, + { + "dpid": "35", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreih4kylr5z5oppj6wprw2luiyngsn3xq324kfbiku4ehi42dess4oi", + "time": 1682534976 + }, + { + "cid": "bafkreidasu577tdw76nprafzy7oa42nlr6gcyk45agx3tawrw3zyxu7mva", + "time": 1682746284 + }, + { + "cid": "bafkreieaozkgywz6vonai3kmhr6cct5jjpeau3lhy2zrb2ft3dsnudaxym", + "time": 1682813004 + } + ], + "validationError": false + }, + { + "dpid": "36", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreifc4so5xny7vpkj62oejlxlnh2zp6w76idbvx3mi2t5nkhxpbenbe", + "time": 1682670864 + } + ], + "validationError": false + }, + { + "dpid": "37", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreiadoa3b3hvlzpfliappjvhzoacqst2tnu5x7cjvhwcdjhplqakmmy", + "time": 1682793228 + }, + { + "cid": "bafkreiad7vwyvhxpgy5i6azrynsnu5g2x5ef7iwjafbnnvukkbc7dvygru", + "time": 1682793408 + } + ], + "validationError": false + }, + { + "dpid": "38", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreiagyoholq6ypx4pdby56vfzq7a44q3sn6esvho7wcf6m4eghpcjoa", + "time": 1682813880 + }, + { + "cid": "bafkreiapfszw7l5sysx2hgophrztwyeonpppem2xxwbujhhwa5kipypyky", + "time": 1682814000 + }, + { + "cid": "bafkreiapfszw7l5sysx2hgophrztwyeonpppem2xxwbujhhwa5kipypyky", + "time": 1682822136 + } + ], + "validationError": false + }, + { + "dpid": "39", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreiayluo2hglsq2qfahpzwqopgwaad7bqxma5we6l2bqzs2zfvk6eka", + "time": 1682820648 + }, + { + "cid": "bafkreiayluo2hglsq2qfahpzwqopgwaad7bqxma5we6l2bqzs2zfvk6eka", + "time": 1682821080 + }, + { + "cid": "bafkreiero2ggetbv2g5voe4yg7lr53cl7aocrcdbn5ndz754ani2c4xwye", + "time": 1682849124 + } + ], + "validationError": false + }, + { + "dpid": "40", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreih3uvxd3entelbnsrhijwkperswmy4d27cjvx2fnurjqqjzvp7v54", + "time": 1682821224 + } + ], + "validationError": false + }, + { + "dpid": "41", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreihesv24wbwkhgjeplqi7lu2rm5d75o6es3krxbj4rfmhk3bcxavhe", + "time": 1682854224 + }, + { + "cid": "bafkreifmd5ucm3ypfkph7klhghsgyvfinkrwxw6uuiwpdjoarmxotflwaa", + "time": 1682854344 + } + ], + "validationError": false + }, + { + "dpid": "42", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreie46ed23xpsfgxasdbhzq4zrni5v4dv3lbohasnqkgmohq4g6bjam", + "time": 1682856480 + } + ], + "validationError": false + }, + { + "dpid": "43", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreigumcdo4dafutywplrgg7xgo6swf2qygljyzwktsafuhvednvpmhy", + "time": 1682951112 + } + ], + "validationError": false + }, + { + "dpid": "44", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreihqpbdqrgnp6mebwfcqqt3izgreiw4zgiw42zmkezipmktv777itu", + "time": 1682962248 + } + ], + "validationError": false + }, + { + "dpid": "45", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreihfrfianmcigzvnnetxkzwlcgza75dsah7ab5anx43phu3mke3uky", + "time": 1682993892 + } + ], + "validationError": false + }, + { + "dpid": "46", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreia2nvcwknooiu6t6ywob4dhd6exb3aamogse4n7kkydybjaugdr6u", + "time": 1683053508 + }, + { + "cid": "bafkreih5koqw5nvxucidlihwfslknj674oeuroclit74rkaqpe4mq6xuka", + "time": 1683222132 + }, + { + "cid": "bafkreif3d644utirvwvkmukcrhg64palp3r4xociwsn6b6o2hxmkdxalby", + "time": 1683227616 + }, + { + "cid": "bafkreibn3jhdlsdsonv25t7i2bwtrbkl3jzwjbnnwylpeih3jmmzdhsfmi", + "time": 1683298680 + }, + { + "cid": "bafkreiepot62powegf7tt73gyiz24facsdloywggattt2asz5y4eaqhkyi", + "time": 1683299940 + }, + { + "cid": "bafkreihge5qw7sc3mqc4wkf4cgpv6udtvrgipfxwyph7dhlyu6bkkt7tfq", + "time": 1705420740 + } + ], + "validationError": false + }, + { + "dpid": "47", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreia7orsrr4pwxe5m2gnklknpc25kjs7gnzemofki3aeh6ydh4hkfju", + "time": 1683222948 + } + ], + "validationError": false + }, + { + "dpid": "48", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreieahbi5tzb2od7nb2j5up4ooiglvh2lty2bgcrwjc3km7fnsplaxu", + "time": 1683232692 + } + ], + "validationError": false + }, + { + "dpid": "49", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreiet6onaozwmqyflpbjsa7f6f5jkhou5n3vxxkxmkgalhnr54bzftu", + "time": 1683236460 + }, + { + "cid": "bafkreibp3hplo3b2hfetbrargv2gv2dkx3kfqfsqbxhkuved2k2nebxcpa", + "time": 1683236760 + }, + { + "cid": "bafkreigym3lzf2ruzd3r23mflxjzafqfxoi5bncru3t4ky35vfaubbke34", + "time": 1683236760 + }, + { + "cid": "bafkreife4uk2mkecur54sq774ybtrka5l4gd5777j5cjjscfmx4vcqnfbm", + "time": 1683237288 + } + ], + "validationError": false + }, + { + "dpid": "50", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreibroag6m5tps4srrtdxbfq74sskvpfu4sbhadhkh3vfonjrlmsvda", + "time": 1683886968 + } + ], + "validationError": false + }, + { + "dpid": "51", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreiheezwrynuxo6gnjd2pmahkcw3wstooxs6fvaflpjouewmh4qi3aa", + "time": 1683930000 + }, + { + "cid": "bafkreiasjo5wzkkk2s56tvdkmbe56vj4j7gyq345vnqpwvnvwozzhtkxfq", + "time": 1683931428 + } + ], + "validationError": false + }, + { + "dpid": "52", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreicxw5tzwajvwa757ihut3hvlgnfbpu7fa4oxfvvlssu4rikfrtmv4", + "time": 1684412244 + } + ], + "validationError": false + }, + { + "dpid": "53", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreia7yjdhq6tdxjtwyr4ajfhxypq3jxbo5augryzzeos7cqrbyy6jmi", + "time": 1684862784 + }, + { + "cid": "bafkreifutouvscu3pbsaabgxdxqfd6zaphkcuei6i3fibdeefmrh4oujby", + "time": 1686612108 + } + ], + "validationError": false + }, + { + "dpid": "54", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreigtfrsogce5ixgj4dvjgvj2qgjsujs5g4sa64svziiyz6j2bajise", + "time": 1685098464 + }, + { + "cid": "bafkreihocw2lexz7nz4sfwmy576guhbecxnzq4wfltnx5twqn2clng3ewu", + "time": 1685098776 + } + ], + "validationError": false + }, + { + "dpid": "55", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreicup2qewrwovkkgk5bun4vpws7cbq3qnv2rbt7truyw54owvtwovm", + "time": 1685442360 + } + ], + "validationError": false + }, + { + "dpid": "56", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreieis5ac2evezkciy26fvswybmyyarfnrlvyh7p5acvbhcsceayorq", + "time": 1685444172 + }, + { + "cid": "bafkreid6ibvbiblu6vviuc3l6ivmpmpdbj2rzt625capmi4igns2r7k4ue", + "time": 1685448060 + } + ], + "validationError": false + }, + { + "dpid": "57", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreiaulqrzufg3qnw55rwzqtn5h2cvsawdunrfwt4j32ywt6oswi5bfm", + "time": 1685525952 + } + ], + "validationError": false + }, + { + "dpid": "58", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreidlxqbem5m3kgtntq6243vujhuyvt2s72ry2k5uy4f6hmjwbezdje", + "time": 1685526132 + }, + { + "cid": "bafkreib2gln7ztcpt6z7q7yo6isznl6lam4zv74hwslwhplh6g55re26lm", + "time": 1685536224 + } + ], + "validationError": false + }, + { + "dpid": "59", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreigj2svt7njv2nxznzm42pisbjgpfjzhoorlcsryjlx5coa2klssku", + "time": 1685613060 + }, + { + "cid": "bafkreigvuao6ogwtnr2oknvxl3a5mtulhats7dqsiuturbxnnablevorai", + "time": 1685613240 + } + ], + "validationError": false + }, + { + "dpid": "60", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreiefsjhlwr6bcq4nscdoz2q2tkca5i7ocxgtn5nxggkf2lr5a2z2lq", + "time": 1685613216 + }, + { + "cid": "bafkreifmohd57nd6xbcjrc3b6dxgpycgijleopks7hrmza4t23dvqxd2au", + "time": 1685613708 + } + ], + "validationError": false + }, + { + "dpid": "61", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreid5vwbe6ri74rgtdevbjznreexoedsocftjqgpopx3bih656jwzni", + "time": 1685614104 + } + ], + "validationError": false + }, + { + "dpid": "62", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreiapjbbsrowag6txt3wuilla2vp6dhhijkylklmvdzc4es3qb27buq", + "time": 1685615388 + } + ], + "validationError": false + }, + { + "dpid": "63", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreicjmhgi5sbjvo2i3nzwfkwfmahgipbyq6iasekibgqpl75cdiqdsi", + "time": 1685615724 + } + ], + "validationError": false + }, + { + "dpid": "64", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreib2rkswbatx7qqcnymxcajqrgrywfzlsiischsrfowhbd5vjfskfi", + "time": 1685719428 + } + ], + "validationError": false + }, + { + "dpid": "65", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreifdylfaiep4lc4544mow5aiq4vg37buebiybfx5wyznfi4pov6qri", + "time": 1686220584 + } + ], + "validationError": false + }, + { + "dpid": "66", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreibelil5fgqul2o3chxv7g7xmdqkv2krqkv6r6mdbiw72vcqp4wxky", + "time": 1687805292 + }, + { + "cid": "bafkreiefvtk6gcvlxq3hw3lkxcjjy5aqkaxyu4swucs2wd3imjhi2yfdpm", + "time": 1687805484 + } + ], + "validationError": false + }, + { + "dpid": "67", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreiazlufpwemnsbzscuycou7gi5m7t2p4yxbxvozkvxex47uczuokba", + "time": 1687807524 + }, + { + "cid": "bafkreidupix2c3fizisuv2z6tluypvssf6solprgnmev6ul6vp6dprwop4", + "time": 1687808232 + } + ], + "validationError": false + }, + { + "dpid": "68", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreihakt3w53hwvneg2o3e4xysgegwk5j5rs6mug6ywlwb2bmprm4wzy", + "time": 1687812132 + } + ], + "validationError": false + }, + { + "dpid": "69", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreigfelcudmytsq2s2j4wcy3j7tsyatpnffpcthf6zz7q5wa4snafdm", + "time": 1687812804 + } + ], + "validationError": false + }, + { + "dpid": "70", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreicandi5eh3gwuxwlq6k6fpeuurnbpbx33q3ijndg44go2p5ekni3y", + "time": 1687817568 + } + ], + "validationError": false + }, + { + "dpid": "71", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreibb5g5ujmxeve56ktnuolb7rrncmbgedtrjemeshn6rxbrhn4uepe", + "time": 1688024628 + }, + { + "cid": "bafkreiddtartrk6isrs3j5ltx6nkcv437jsu62vc6ew3cwvxk3msebzg5e", + "time": 1688024676 + } + ], + "validationError": false + }, + { + "dpid": "72", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreicj4c44gghcoy2ztvwe32fmbv7cuvty2hv2y4ndrnd6ghrl3ciaea", + "time": 1688552688 + } + ], + "validationError": false + }, + { + "dpid": "73", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreifdgjfu3g4qddc7g5kvnk3lshkuyfau7o2qle5ut5msptulbxsqme", + "time": 1688720808 + }, + { + "cid": "bafkreifdgjfu3g4qddc7g5kvnk3lshkuyfau7o2qle5ut5msptulbxsqme", + "time": 1689009768 + } + ], + "validationError": false + }, + { + "dpid": "74", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreifqxkjzypbtz7snjp3ghjrv56bd5umihchpwfppnoz67tcmhuq7wi", + "time": 1689041640 + } + ], + "validationError": false + }, + { + "dpid": "75", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreibtsll3aq2bynvlxnqh6nxafzdm4cpiovr3bcncbkzjcy32xalp7i", + "time": 1689294216 + } + ], + "validationError": false + }, + { + "dpid": "76", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreiatjdpouudloenzdzb7d3e5pogruvwbhurcnm2g5h64jmkpk2uebe", + "time": 1689518988 + }, + { + "cid": "bafkreigg3xk6ojueylnninvwsrw62nqpt7pyjnz6thaipbydb5ltclctly", + "time": 1692182952 + }, + { + "cid": "bafkreicrggm7jpxgaj2vgydvefuravrs2bh4emlt6eadx3zsbubtpulmcq", + "time": 1692330000 + }, + { + "cid": "bafkreifgfzjltrvcz3qixyjkiubgms2r3figm37euwxzbi6pvej2me6tje", + "time": 1701997248 + }, + { + "cid": "bafkreic4wiuatha4wclfbwft4vaeeqifrbb2f3tqm4eoajommogudbvswu", + "time": 1702000140 + }, + { + "cid": "bafkreicraffpobz3k5rzdmigl5tzklihwuim4kwe7xl5uulmfrkr4uvm2u", + "time": 1702045680 + }, + { + "cid": "bafkreidtkraxowlx26oz5g6qyfuawhx5nroil4a4mo6ywa7knfel7ft2dq", + "time": 1702045944 + } + ], + "validationError": false + }, + { + "dpid": "77", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreiaqxrcrai2j2lpk2moare5abq4vtyhxk6m5jxo5fbqkrsy24kdm7q", + "time": 1691492520 + }, + { + "cid": "bafkreihjozked2lgpgtdcuvzejanhnm65sccwglgblxfdg3cwi72vlrtvq", + "time": 1691493636 + }, + { + "cid": "bafkreieodz3e4kzbnlg4nka5pwrgafwuuemfuejxqa5dpdaqlgt6bjs7fm", + "time": 1691496348 + } + ], + "validationError": false + }, + { + "dpid": "78", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreifixmk6tierh6qompfouk63r6clg5jbeuvwherrxacq4uoedk4o5q", + "time": 1691501736 + } + ], + "validationError": false + }, + { + "dpid": "79", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreibtuuiejhyxu4zr2od34biucedhlmqdmqem6v2ruqu6ov2kgsfnfa", + "time": 1692472464 + } + ], + "validationError": false + }, + { + "dpid": "80", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreiawwe6os5lxye3hojdmwgcdt4nrs7xwfqy3p3vuv7xolhbnc2nqaq", + "time": 1693245804 + }, + { + "cid": "bafkreichlzplxpphzyoo3mnjg6tm2e4uplpm4d2q667a6dbz6xhctvktai", + "time": 1693246872 + } + ], + "validationError": false + }, + { + "dpid": "81", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreieefydw5dajtfgz5xqecgyyqxt7kzzyibihy4dvnrtwakaahkn34y", + "time": 1693246440 + }, + { + "cid": "bafkreicpdjfhoxg3gyc2xn63ppbxf7a7wvehkl4h34dapqeqekfetwunme", + "time": 1700147784 + } + ], + "validationError": false + }, + { + "dpid": "82", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreicmvrritjqe4eatfkix3k6kgxz7oxlxengyfhg7rkubpagmxymiqa", + "time": 1693247148 + } + ], + "validationError": false + }, + { + "dpid": "83", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreia6ccnzt76b23xkq7slvzxgebltmlkmvcbvr77nzfyca7wpq6qkru", + "time": 1693247616 + }, + { + "cid": "bafkreidrb3cry4mh6fcik54rotatfnz2mapg3olcsxqpodgdbecrh5iu54", + "time": 1700147268 + } + ], + "validationError": false + }, + { + "dpid": "84", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreibgfpmyizfiu6mpmdcn6aqvqrli72za72ccrxsim24nhtfv3cqb7m", + "time": 1693248192 + }, + { + "cid": "bafkreidfksyvtp5vjzoczjupn6h6h72dcr2p2rm63l7l5qwn6sq6d2nyjy", + "time": 1700146980 + } + ], + "validationError": false + }, + { + "dpid": "85", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreichgcyenem343rn3cgpyymyicdgoe7vgkev7z7bccskncaux7rxt4", + "time": 1693248672 + }, + { + "cid": "bafkreiejwrzg3vtvrvxm75dzgmk3736v4wrhl6uin64hzq76oekbkqi2ci", + "time": 1700146392 + } + ], + "validationError": false + }, + { + "dpid": "86", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreihxqrtbvhxg3w2nu3ahpcu2it6qvnmca4xb72vq4w27er3v4rsjgi", + "time": 1693249560 + }, + { + "cid": "bafkreidlqc6jfns3ftpxoopx7etmfqp75xwoptd6es36xir2fl4nkvmx6i", + "time": 1700145552 + } + ], + "validationError": false + }, + { + "dpid": "87", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreidlb227q7gvv622itmewvsdli726msbjgtsoufaepsaajrc66d27u", + "time": 1693249908 + }, + { + "cid": "bafkreibaiviks6ed4yuwaidz4zzerlhmlkbdcxucky74ah4nu37cm443lm", + "time": 1700146176 + } + ], + "validationError": false + }, + { + "dpid": "88", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreibdpyr6vlsifgi3cebv7ip26ynplllfzpekxz4zfj7xna7uolpjgy", + "time": 1693250244 + }, + { + "cid": "bafkreif7e3nkqyrpa6pkhlnv7sdrwkgyct7fhgzqsteo457kpa46wuflhe", + "time": 1700146776 + } + ], + "validationError": false + }, + { + "dpid": "89", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreidp3ed42l6cizgero5c7zfmxpmwp5hkc4tx6uz7mgioxsep4wb6rm", + "time": 1693251900 + } + ], + "validationError": false + }, + { + "dpid": "90", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreiaw34rnu36p2ccawj3gopyxgl64qj3dc3ip3pzvfh5anzrvmu4z5u", + "time": 1694114940 + }, + { + "cid": "bafkreidk7ihar3swjjf46wtttjl52govxa256725urm5upcefu4wfvnxpm", + "time": 1694187648 + }, + { + "cid": "bafkreic6n2x6jlvss4iepnkkb4o4wre4nezbbff7kw46mz2egtzxast5xe", + "time": 1695653376 + } + ], + "validationError": false + }, + { + "dpid": "91", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreigpcnierfxljhffgj4d6oyuwec4pcbkbjys6goaggw75rcobd6vnu", + "time": 1694197140 + }, + { + "cid": "bafkreidtiuwpwyewgjp3r5a7shvzgir7pvbeguxlv6zebpdbxrraialhxu", + "time": 1695653220 + } + ], + "validationError": false + }, + { + "dpid": "92", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreicqezpklsjtuszjnsekc2dcyadgtbcfouhlc57vclrwco45gzbul4", + "time": 1695218412 + } + ], + "validationError": false + }, + { + "dpid": "93", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreie2p56t2d3i762v3bow3jweile6fmryt2qlcjq3cmkz7kpqtaic2a", + "time": 1695246144 + } + ], + "validationError": false + }, + { + "dpid": "94", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreiaqnt5raa6b4ujpkgd4veg73rtp5csn6fwxrckbhq4mkrl7ws63dy", + "time": 1695246324 + } + ], + "validationError": false + }, + { + "dpid": "95", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreied6xbi65zwpzqiiaqnhq3cdq42c7yqrx6sd32ncv6avkovcb6f6y", + "time": 1695324696 + } + ], + "validationError": false + }, + { + "dpid": "96", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreigurq54verb4sihjuonnx2pbo77lbjlviol2jfjxxgyzzko7o42ka", + "time": 1695816576 + } + ], + "validationError": false + }, + { + "dpid": "97", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreig76u6of7za2h5pdphz2ztsl5xdsgg2vrsh2dximjx3q2aszfjq6m", + "time": 1696295376 + }, + { + "cid": "bafkreig76u6of7za2h5pdphz2ztsl5xdsgg2vrsh2dximjx3q2aszfjq6m", + "time": 1696296012 + }, + { + "cid": "bafkreigul3gpywn3nes5jjxsh2ddfue4lg37ftg7sdqctmzxqp7cxdw3iy", + "time": 1696299000 + }, + { + "cid": "bafkreigul3gpywn3nes5jjxsh2ddfue4lg37ftg7sdqctmzxqp7cxdw3iy", + "time": 1696299600 + }, + { + "cid": "bafkreigul3gpywn3nes5jjxsh2ddfue4lg37ftg7sdqctmzxqp7cxdw3iy", + "time": 1696299876 + }, + { + "cid": "bafkreigul3gpywn3nes5jjxsh2ddfue4lg37ftg7sdqctmzxqp7cxdw3iy", + "time": 1696299912 + }, + { + "cid": "bafkreigul3gpywn3nes5jjxsh2ddfue4lg37ftg7sdqctmzxqp7cxdw3iy", + "time": 1696299996 + }, + { + "cid": "bafkreigul3gpywn3nes5jjxsh2ddfue4lg37ftg7sdqctmzxqp7cxdw3iy", + "time": 1696440036 + }, + { + "cid": "bafkreigul3gpywn3nes5jjxsh2ddfue4lg37ftg7sdqctmzxqp7cxdw3iy", + "time": 1696440996 + }, + { + "cid": "bafkreifcfaudesj7f5jxjn3fecovikw6khhvvspxhc4b5rca6swcdvhdca", + "time": 1696459560 + }, + { + "cid": "bafkreifcfaudesj7f5jxjn3fecovikw6khhvvspxhc4b5rca6swcdvhdca", + "time": 1696459584 + }, + { + "cid": "bafkreifcfaudesj7f5jxjn3fecovikw6khhvvspxhc4b5rca6swcdvhdca", + "time": 1696466724 + }, + { + "cid": "bafkreifcfaudesj7f5jxjn3fecovikw6khhvvspxhc4b5rca6swcdvhdca", + "time": 1696466820 + }, + { + "cid": "bafkreifcfaudesj7f5jxjn3fecovikw6khhvvspxhc4b5rca6swcdvhdca", + "time": 1696466964 + }, + { + "cid": "bafkreifcfaudesj7f5jxjn3fecovikw6khhvvspxhc4b5rca6swcdvhdca", + "time": 1696468416 + }, + { + "cid": "bafkreifcfaudesj7f5jxjn3fecovikw6khhvvspxhc4b5rca6swcdvhdca", + "time": 1696479552 + }, + { + "cid": "bafkreifcfaudesj7f5jxjn3fecovikw6khhvvspxhc4b5rca6swcdvhdca", + "time": 1696480608 + }, + { + "cid": "bafkreifcfaudesj7f5jxjn3fecovikw6khhvvspxhc4b5rca6swcdvhdca", + "time": 1696480764 + }, + { + "cid": "bafkreifcfaudesj7f5jxjn3fecovikw6khhvvspxhc4b5rca6swcdvhdca", + "time": 1696480884 + }, + { + "cid": "bafkreifcfaudesj7f5jxjn3fecovikw6khhvvspxhc4b5rca6swcdvhdca", + "time": 1696481172 + }, + { + "cid": "bafkreiciddswj3e6ho5of7x7a7liaqehnwqeg35w3cp3l5knv6k2tdlswa", + "time": 1696594740 + } + ], + "validationError": false + }, + { + "dpid": "98", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreicsn4qia64pf7eim7sjggvmnggqadmfmrrcm5gecbpfdzxwzlk7i4", + "time": 1696303560 + }, + { + "cid": "bafkreicsn4qia64pf7eim7sjggvmnggqadmfmrrcm5gecbpfdzxwzlk7i4", + "time": 1696303944 + } + ], + "validationError": false + }, + { + "dpid": "99", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreibx7segie7e5ttf2x4j3vuarqbsjfrnakn6srf6myqadz3kbimqhe", + "time": 1696336296 + }, + { + "cid": "bafkreibx7segie7e5ttf2x4j3vuarqbsjfrnakn6srf6myqadz3kbimqhe", + "time": 1696469268 + }, + { + "cid": "bafkreibx7segie7e5ttf2x4j3vuarqbsjfrnakn6srf6myqadz3kbimqhe", + "time": 1696536756 + }, + { + "cid": "bafkreibx7segie7e5ttf2x4j3vuarqbsjfrnakn6srf6myqadz3kbimqhe", + "time": 1696536804 + }, + { + "cid": "bafkreibx7segie7e5ttf2x4j3vuarqbsjfrnakn6srf6myqadz3kbimqhe", + "time": 1696536828 + }, + { + "cid": "bafkreibx7segie7e5ttf2x4j3vuarqbsjfrnakn6srf6myqadz3kbimqhe", + "time": 1696536888 + }, + { + "cid": "bafkreibx7segie7e5ttf2x4j3vuarqbsjfrnakn6srf6myqadz3kbimqhe", + "time": 1696536912 + }, + { + "cid": "bafkreibx7segie7e5ttf2x4j3vuarqbsjfrnakn6srf6myqadz3kbimqhe", + "time": 1696536936 + }, + { + "cid": "bafkreibx7segie7e5ttf2x4j3vuarqbsjfrnakn6srf6myqadz3kbimqhe", + "time": 1696536972 + } + ], + "validationError": false + }, + { + "dpid": "100", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreib2fs7g7yawpqeyjzatsv3bip5p6xr27pnblzjase3zyr4ixtbu6a", + "time": 1696506528 + }, + { + "cid": "bafkreihirj6fsasmvqmzngnyqitl6fpt3ljapgwx7dpfelgvruqsu7smw4", + "time": 1696507296 + }, + { + "cid": "bafkreid5osij2amlc67sm7uzqp22j7y3dn6lseyuy72oh64z5rqoh5qity", + "time": 1696840824 + } + ], + "validationError": false + }, + { + "dpid": "101", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreiaoby2dmz4sljyhxsizjj2yd2jvbzz2vsywii3vp6xqi4rjefxl4q", + "time": 1696589760 + } + ], + "validationError": false + }, + { + "dpid": "102", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreiceiefmvnwozgtpvvwv5exwsdxm36yl5ovunmcnjx5kjtcqvm6lwe", + "time": 1696605300 + } + ], + "validationError": false + }, + { + "dpid": "103", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreif6p22atw6ekbaxkrnfmetfdqtnhldaqw6qtqiqc7lqbus6aizru4", + "time": 1696841976 + } + ], + "validationError": false + }, + { + "dpid": "104", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreiautwruptenrd4xbq5actpbmirrxprmnnxyxf37ixblmcynebjaqq", + "time": 1696842144 + }, + { + "cid": "bafkreie37zoipwpgqrupcmxfnhqfqpztumhcurzb27rfasa5ipao32w3ia", + "time": 1697792352 + }, + { + "cid": "bafkreiebcm7batu7zyp4aw6pzisbkldtlqsghh5jhczhkh63lxgjxp5wte", + "time": 1698779592 + } + ], + "validationError": false + }, + { + "dpid": "105", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreig33qp67gaov32ibvtb5gqtcnfrntrsrbzst2lcgrgnkbu4hbtcj4", + "time": 1696842444 + }, + { + "cid": "bafkreig33qp67gaov32ibvtb5gqtcnfrntrsrbzst2lcgrgnkbu4hbtcj4", + "time": 1698911760 + } + ], + "validationError": false + }, + { + "dpid": "106", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreibbbm7623bsdoftewbedqd3peny6zhqpt6tjgx67ouf6hhvbv2idi", + "time": 1696941732 + }, + { + "cid": "bafkreihemsbpld4yuzrn4ckrlriyq5ortlkycxx74ayfugnoce7oetsmam", + "time": 1696942104 + }, + { + "cid": "bafkreic4gpc3k5mrttk57w6k5fvtgvubvh6xfwgmubecx53b55xsxoavxe", + "time": 1696944228 + }, + { + "cid": "bafkreickteh2tt3oy43o42ikwei6tppghmtbkockk22a3niovi57ugor7q", + "time": 1696961232 + } + ], + "validationError": false + }, + { + "dpid": "107", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreicgst5gqckb4bzduzxqhn2v5an2xjnmhv6qwscwtn3gjhuplpv3jm", + "time": 1697040396 + } + ], + "validationError": false + }, + { + "dpid": "108", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreifzh36eve7dsmbebnvxhpalxdgcjcur7anxllzyfwnmetlsvq2f54", + "time": 1697792640 + } + ], + "validationError": false + }, + { + "dpid": "109", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreibiziudxe62de7g443yl453tpnky25ujrcdhuaudtwq7hxrrr6q3m", + "time": 1698054684 + } + ], + "validationError": false + }, + { + "dpid": "110", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreic65maz27f7atu7a4euzl6jv4c2kz66ddvcxuhdajl4i4l27uwwii", + "time": 1698079308 + }, + { + "cid": "bafkreic65maz27f7atu7a4euzl6jv4c2kz66ddvcxuhdajl4i4l27uwwii", + "time": 1698323460 + } + ], + "validationError": false + }, + { + "dpid": "111", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreiejskdyqkcsnvcl6njkivjvptts656x3qvr64nsjdnx6pcn6bdht4", + "time": 1698177444 + }, + { + "cid": "bafkreialaclllbtsaxzdhbbut4mk57xh4r7bsj56cb44fockdxokcznbk4", + "time": 1698178344 + } + ], + "validationError": false + }, + { + "dpid": "112", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreictzmcsbe3bkmb7vyludvy7q37brvsw6q7xayblyn45r23n7ru224", + "time": 1698747720 + }, + { + "cid": "bafkreifpbperacf57typaumiauqsf3kcmljgm7ehu2vjmlflwepddpeth4", + "time": 1698747864 + } + ], + "validationError": false + }, + { + "dpid": "113", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreig2nlksggv4ghb24xw7ng23klrttx3kiu3tdlnsa2gcn2zacpmxa4", + "time": 1698782484 + } + ], + "validationError": false + }, + { + "dpid": "114", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreibsaosbasq6er4o2mkovemlp6tgppyeudue6lsx6dbznba56omd6e", + "time": 1698782652 + } + ], + "validationError": false + }, + { + "dpid": "115", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreiaqt4amqtdha2affz4caq6qrl3uzk4zutwfnzcc6ba5ziw6itc2ty", + "time": 1699355412 + }, + { + "cid": "bafkreichmxylugiwhtrhomfjc7njdmp6isfivmdsflhmuzenzxnyl76m5i", + "time": 1699355784 + } + ], + "validationError": false + }, + { + "dpid": "116", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreid4spqoyg2mk2r7bcju6vkxsgtcx2fl27tyivtvrvnwlqgn26udn4", + "time": 1699608000 + }, + { + "cid": "bafkreiejv6ymnxxum5c67qpkvp2eevgy7rgksq7vhzgyfxg5riwl33lzqe", + "time": 1699887960 + }, + { + "cid": "bafkreibechybrdrnwlsg3unh2pgxg2jgekg653h37e4xzc3wazyzcjzegq", + "time": 1699954776 + } + ], + "validationError": false + }, + { + "dpid": "117", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreiepbbtkhudgspd6dr4rnckaqwdenedehsvppkyakute6z36bplgpy", + "time": 1699954800 + }, + { + "cid": "bafkreids7cf6gagvaxbmammx6ekl4e3xwhcyw33vkqmy5ml2m4epvpjwua", + "time": 1700053860 + } + ], + "validationError": false + }, + { + "dpid": "118", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreihv7uzjstazrksvrdwrt6j3oqiw73oqi2krvwlzojbo5yhrfrpcu4", + "time": 1699979532 + }, + { + "cid": "bafkreifwnjaykar4vdhcpyimr73hklty7nqnm77u37rzmdyhldtlleycfy", + "time": 1702053972 + } + ], + "validationError": false + }, + { + "dpid": "119", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreifisxmqzztc3zgleheiakn4xn5w7ze6ap5iynom46djxue54nvk5i", + "time": 1699983900 + }, + { + "cid": "bafkreihhg6k56gey42vldxac36u3ueleq4nzrm2zw5fxfcdmwcdrfyjpci", + "time": 1699984152 + } + ], + "validationError": false + }, + { + "dpid": "120", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreifonv6z5enzbl44kwvh3i3m5stmagckblhfp4skmilmt72ff3dthe", + "time": 1699984440 + } + ], + "validationError": false + }, + { + "dpid": "121", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreig7g2zbirxw3spdxicv6igvu4t2frzdbipzh4q2lp7a7vzsnktdym", + "time": 1699984896 + } + ], + "validationError": false + }, + { + "dpid": "122", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreidhtfpm7qcv36eklavzuhq7dxbfq7a2o3ovv6q55qubyr7xnvpnm4", + "time": 1700005716 + } + ], + "validationError": false + }, + { + "dpid": "123", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreifuyc6nxavordwnewceq6tdzbzs4u5u7eiohs2lflwabdmhrrcxtm", + "time": 1700006352 + } + ], + "validationError": false + }, + { + "dpid": "124", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreiccwsruwcne5ctm4bdarr6772xgxqdcy3jg66rthmd5iaq2hnexgi", + "time": 1700046408 + }, + { + "cid": "bafkreihi36k65e6jlytud7hcvtxru2xbkphtxbdu3xx2pkm53qwb5mjzge", + "time": 1700046432 + }, + { + "cid": "bafkreiezsp3ibhch3wf4arb4ies65exfex2isowpfsrrlq6pyvatiexr5q", + "time": 1700046552 + } + ], + "validationError": false + }, + { + "dpid": "125", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreidsdl7s6pqakmfhfvcauof7ovylegxa5nwp2dxuxd5rbb27vsk4d4", + "time": 1700057772 + }, + { + "cid": "bafkreidjcemwjx3ljeuja3lety52fksvk2ojukxkxudbnwu7kgse2zz3tm", + "time": 1700058384 + } + ], + "validationError": false + }, + { + "dpid": "126", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreib6z6ysfnyw6k6ly7cpdp7qjcjbbvjoffn4ppiarimmk33sbxuoy4", + "time": 1700059584 + } + ], + "validationError": false + }, + { + "dpid": "127", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreibqnmfw4jhrjk4ggz63kqtti7rzxroutotrrey2j37a3ad2wfuojm", + "time": 1700063400 + }, + { + "cid": "bafkreifgaoapp6ku2zt3awb3svh3ol75stczvu2bon373bit4whaneb2lm", + "time": 1700063832 + }, + { + "cid": "bafkreibbb2gkxihablys2fjtrecr2tvfbujyulblivfqn4jsl6hyx5dghy", + "time": 1708492476 + } + ], + "validationError": false + }, + { + "dpid": "128", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreihjgheci62x27bgduapkcmwbxldpwyk5af5kqvbpq2nmfmtfxdmmm", + "time": 1700063832 + } + ], + "validationError": false + }, + { + "dpid": "129", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreigtnznzipcb6j4ufpnmde3e66pzl53n7etkxjj4waorkc2vfzban4", + "time": 1700754096 + } + ], + "validationError": false + }, + { + "dpid": "130", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreiaiwepaj5h3ueggcvsp7rs6zsu5emvcbxg4aantq43mjrvkb46t5i", + "time": 1701434724 + } + ], + "validationError": false + }, + { + "dpid": "131", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreidw5k6li7ex6goxdky37t6obgd3472rbgygmvu5rnf6iiptrqkmiy", + "time": 1701702708 + }, + { + "cid": "bafkreiaa4eh2bmuwlutgnvnbbd64npfqdlzxzc75li5pzhlmdkrvj5qjrq", + "time": 1701703056 + } + ], + "validationError": false + }, + { + "dpid": "132", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreifqxy2ie6a5gwqwjdrjzpuer3d5dwb4sauljj6coojnzprlvfes2e", + "time": 1701788316 + } + ], + "validationError": false + }, + { + "dpid": "133", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreifyxvaek2nsdtke62wviupn7qqtgzeucrpe5c66lrycvtvestkkau", + "time": 1701795900 + } + ], + "validationError": false + }, + { + "dpid": "134", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreigu4xxysvqtf6cicat3iheugi6g45vsgnptbrht6p6om3txvsttye", + "time": 1701872976 + } + ], + "validationError": false + }, + { + "dpid": "135", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreihf45jsg5rnkpv2mz2wwpf5w3u6ixu765a5hckam3j3fbl5i2tgbq", + "time": 1701875664 + } + ], + "validationError": false + }, + { + "dpid": "136", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreih5g3pbinh264nuwgvsuerueucgpacv5ytill4sbxt7zsexgfntqi", + "time": 1702142316 + }, + { + "cid": "bafkreiaitokvbuwllmihafculxuniwiydtl2cuuuhqbmkuvpk62uuhmu4e", + "time": 1702145736 + }, + { + "cid": "bafkreifyo3tzgp3bp7a7zwxym6lskt567rdvjn4t334dczglkvgbpglla4", + "time": 1702202688 + }, + { + "cid": "bafkreif4yaj5za2adpy3wmklbstwpaciobl3j4uwcwrwcri7bbkcvwik6q", + "time": 1708382904 + } + ], + "validationError": false + }, + { + "dpid": "137", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreiebtockthsjrwsikbjshzdikjsa3j35avolyabw2zl5nxd4np2qa4", + "time": 1702430448 + }, + { + "cid": "bafkreig5muvzq5a5whji264zbzpkd452kqiswo4on3b3waibrwcte6n2jq", + "time": 1702439796 + }, + { + "cid": "bafkreie7zyrvboq3ygb3tm74qkuvbldwq3ocdltnz6lngud3s2fpdaquiy", + "time": 1711224288 + }, + { + "cid": "bafkreie7zyrvboq3ygb3tm74qkuvbldwq3ocdltnz6lngud3s2fpdaquiy", + "time": 1711224408 + } + ], + "validationError": false + }, + { + "dpid": "138", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreiezlcl57kasksq7hwdqxsffpqloek4jbr4vrvausbg6ozsrnwnkfq", + "time": 1702512600 + }, + { + "cid": "bafkreifxevx7yu5noaquu4bojmyl6pubqotkp4wsbjpd6vbz3neuk7nlxu", + "time": 1707153744 + } + ], + "validationError": false + }, + { + "dpid": "139", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreictkrrk3arfcy4rstvjjtpwrw3yf7wdgxepf5z2cmjuiv2igkdlnm", + "time": 1702512876 + } + ], + "validationError": false + }, + { + "dpid": "140", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreibz4nvkwdmqxmtxefklebrqrhbbhias3bvt7moko5jgw6hopkhwga", + "time": 1702513068 + }, + { + "cid": "bafkreifbhbxfm6s6djz5taz5buthqlpy2cruaysfnixojzubwgkprsbq4i", + "time": 1708801020 + } + ], + "validationError": false + }, + { + "dpid": "141", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreifkjw3mjt4ib4dhjjpn2sbv3oqf4c5mcf5n7zlggynvvqlwksdxay", + "time": 1702513164 + }, + { + "cid": "bafkreiabv34brs4dnbivmzfyggc2ryaxs7zlb3x3zh2ynie53suktlitva", + "time": 1708802436 + }, + { + "cid": "bafkreiabv34brs4dnbivmzfyggc2ryaxs7zlb3x3zh2ynie53suktlitva", + "time": 1708802436 + } + ], + "validationError": false + }, + { + "dpid": "142", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreidll4iaylvaplqqqotp3e7bolx3qgqnjkzliplbhdz7v7dcrdn65q", + "time": 1702513344 + }, + { + "cid": "bafkreieszmyc5ph43ft77gk4pj5emhuy53if6vjbeejzxbrtusxb3ouq54", + "time": 1708802160 + } + ], + "validationError": false + }, + { + "dpid": "143", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreidjonu3vhm5vd5fogs3zrjzq3qcajjkpvwwj43gdqn2swiops5glm", + "time": 1702513392 + }, + { + "cid": "bafkreih25vwbntxxybpsxctpg5eqi6f7ewcwzqzpklifbfqffcrbs65k64", + "time": 1708802052 + } + ], + "validationError": false + }, + { + "dpid": "144", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreieogvypbmg7vgut2f76b33kql6cw4vstzm4f7asoenfzh2rudpekm", + "time": 1702513452 + }, + { + "cid": "bafkreib3b6ztd5tyebhjtxsj4dpl2nw3bipejak5n3zz7u7ta3et2ghyoq", + "time": 1708801908 + } + ], + "validationError": false + }, + { + "dpid": "145", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreibbu3bk7ucli5yaikmcwdduigaien2dqb2bzq4af6ufzrmu6vswty", + "time": 1702513524 + }, + { + "cid": "bafkreig2mtcbf6eu2vraqmy5ftukn4i6fgeiwfou2znswwss5sarsotmcm", + "time": 1708801680 + } + ], + "validationError": false + }, + { + "dpid": "146", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreied3q6xs3itsgvjgeybu5cnmuuds2puklksrhfvy4ofjddo3nkyle", + "time": 1702513584 + } + ], + "validationError": false + }, + { + "dpid": "147", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreiapkcqpkavfwqc4id5mb7e46n3f5nr5uig4ik7bwaxk7a5tox2ztq", + "time": 1702513620 + }, + { + "cid": "bafkreifxvagntjqfpzrigsjfajflqatzk4dogq56lqotaqjv7d3iugdrtm", + "time": 1708801212 + }, + { + "cid": "bafkreifxvagntjqfpzrigsjfajflqatzk4dogq56lqotaqjv7d3iugdrtm", + "time": 1708801236 + } + ], + "validationError": false + }, + { + "dpid": "148", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreibgprhlr22zfwgrm7y3kx4jxslpozqp4pmofsrj5tbqpkaxi5glpe", + "time": 1702559448 + }, + { + "cid": "bafkreieqjqllffddjuraswoq4pm5d5cd5eu2knqe6yie7rj6aufujtct4e", + "time": 1702907160 + } + ], + "validationError": false + }, + { + "dpid": "149", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreigcc2l7aay34i5zeot5wjvpspdpwp6ipfzffs3cnnpbpt7c2gqu6i", + "time": 1703003448 + }, + { + "cid": "bafkreig6lp6265u42llqh6hkzxc54hmyfea7ax7gewg7tdyvthieotmwpy", + "time": 1703003868 + }, + { + "cid": "bafkreici3wzz7njqigyo7ebzwn3kibxgwjr43ihowwebl4exmfy75tkpjm", + "time": 1703072388 + }, + { + "cid": "bafkreicgxdcypaq5tmmrrva3tl7k2un47pfolg3mox72j5k65zitsukfii", + "time": 1707406116 + }, + { + "cid": "bafkreie7j6ji7ynh5d5yoldoxfevak55nkmcx5h7v3c6h4xy7le25sbgke", + "time": 1709143824 + }, + { + "cid": "bafkreic4vm34jfrdp3qu7bx7np3qhvrxlwx5gkn3kf3c4pv6mzbavc3twu", + "time": 1716286500 + }, + { + "cid": "bafkreidsqfd326zx3svaszqm76arwjsonwxpzer24keqt7lv3bpgt5guzu", + "time": 1717067124 + }, + { + "cid": "bafkreid5jzrqitombqlytxoyb36q5avzmxkmxl2nyidtv3pho5godqxbim", + "time": 1717607268 + }, + { + "cid": "bafkreid5jzrqitombqlytxoyb36q5avzmxkmxl2nyidtv3pho5godqxbim", + "time": 1717607316 + } + ], + "validationError": false + }, + { + "dpid": "150", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreif3aoauxavq7sxibkysi4kemqdwbcez4cjtmzoou46bj44r2rc3sa", + "time": 1703205816 + } + ], + "validationError": false + }, + { + "dpid": "151", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreicqe2blgjarm3bg6jon5sjvmu773bnuajfnkmlnvo5hd5uj2yr234", + "time": 1703212224 + } + ], + "validationError": false + }, + { + "dpid": "152", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreifiy2ipxllse5z6kspsspgt247eadivoij736j3yehwe6cy5rn6ny", + "time": 1705091376 + }, + { + "cid": "bafkreihvutuhtiehsoyc66u7a7bncnqfhoosynejagkykkfwa7gkr2rsta", + "time": 1705091496 + }, + { + "cid": "bafkreiekobyktiisailjk2sauqxembzyqe26z7i7mxkl6xidhhlb62wnyi", + "time": 1706832732 + } + ], + "validationError": false + }, + { + "dpid": "153", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreigr54hmercrddm2nnyo46yfn3w466zeoawph7k23swzr5v6lobcjm", + "time": 1705491780 + } + ], + "validationError": false + }, + { + "dpid": "154", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreidzawjc7uaskxy2a55gfd3pjqssl5v6nfqj4ghziglbdfuk3arfri", + "time": 1705579488 + } + ], + "validationError": false + }, + { + "dpid": "155", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreieqqvt2bx34g44zombuj254dzqng5l4bjc33vnuduiaklfjf7jrza", + "time": 1706550924 + }, + { + "cid": "bafkreih4hi7mhwe3uwmf2xa4lfpgmqlt4o5vagzqqr3c54alnnl5wr3r4q", + "time": 1712673828 + }, + { + "cid": "bafkreicamnoitiweehqqlvfa6xmoq7qoooz7kvbuhqy3tdoralmjgwrju4", + "time": 1712674440 + }, + { + "cid": "bafkreidl3wopg6piqc5xba3tvtfcxsvldxcudax4mmwzjtgwsu4hj6t5je", + "time": 1712765676 + } + ], + "validationError": false + }, + { + "dpid": "156", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreibhuuogniwgsozq6zqgpfg622ktaz4e4xtspvxv6be7zoaknlp7oi", + "time": 1706735148 + }, + { + "cid": "bafkreicmyxjhueivvlucnysc5sgmdnxgsmn5wryaodmdwl7xhku5o4dwki", + "time": 1706737632 + } + ], + "validationError": false + }, + { + "dpid": "157", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreificypwhqbtu4acdrxgbzdrpbw5dncxrcwtskrebhv53trsk23ive", + "time": 1706738172 + } + ], + "validationError": false + }, + { + "dpid": "158", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreigmgjpsfxzshdvozllx3m6s5ubiulcx7yumhe7armganzdiu42feu", + "time": 1706834520 + } + ], + "validationError": false + }, + { + "dpid": "159", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreifl7hhai6p5podahrcse5ocklgf2qdayw33raeaugk4cjgugroupq", + "time": 1707473772 + } + ], + "validationError": false + }, + { + "dpid": "160", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreifjtpqkpatgmy4jpmhsepfvpv2gmiofgyh6qpinfnstyrsufickua", + "time": 1707644916 + }, + { + "cid": "bafkreif2hl47drgqwb6qay5dbdmmm4ivbcfus3wromwaho2wxine6niudm", + "time": 1707645552 + }, + { + "cid": "bafkreihopqbkiidgwszltgcx3cp3n5m3vkfcyqf5tktaf7zpikdwqkpkmu", + "time": 1707646572 + }, + { + "cid": "bafkreih7n6cnpgftyn3paqmvvd3bfm7hna7qqgwlqhcpldjtdwabvg5syq", + "time": 1711656132 + } + ], + "validationError": false + }, + { + "dpid": "161", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreialnzhaztvhuvwkzpqlst7w3yttviws5tcpdnwvggdmxnx2ydzere", + "time": 1707848244 + } + ], + "validationError": false + }, + { + "dpid": "162", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreieowcw35rvuvocaupds5fsremm4h6j3cris5sscfjun4o2e4bccla", + "time": 1707967356 + } + ], + "validationError": false + }, + { + "dpid": "163", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreif4554qs4ppds7364pfeqla623ebon5nlvs5m53ecw4jhdkmtnfre", + "time": 1707967740 + } + ], + "validationError": false + }, + { + "dpid": "164", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreidn5fdrmh62nc4r3g5paqija32flksc23evsc5akqoqftkwfeqm2i", + "time": 1708094712 + }, + { + "cid": "bafkreibpaflwrfhygpheciwlemvahtkkwdgg35dnevu25rid46iae2ws6i", + "time": 1708453920 + }, + { + "cid": "bafkreif7javbr3hrnuwmoggv7dtprs7axcsdldsqpwmpfcdizy5bk2tfxa", + "time": 1708514124 + } + ], + "validationError": false + }, + { + "dpid": "165", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreicv2zf35h43m656h2734du5ynp2zctedwxkgwtbhubg34oenhhexa", + "time": 1708109700 + } + ], + "validationError": false + }, + { + "dpid": "166", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreibfvwqckon265lpmjuinzlg6ebzo4s6dtgh7invz2prf766bvuodm", + "time": 1708372176 + } + ], + "validationError": false + }, + { + "dpid": "167", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreige2oxxkk4rboadjcxlvwbvlun3e4xmrxp4qtqvdmjdfzhptuyf5a", + "time": 1708458984 + } + ], + "validationError": false + }, + { + "dpid": "168", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreiftjc6urzlqlcffupjwnezhfash4tlvgy2qnstu2vpp6tdk4zpmma", + "time": 1708493796 + }, + { + "cid": "bafkreic4hj66auaehgtgoz6zzks2w2r7lsxhrisjuh7dbfipvgmkhfpace", + "time": 1708690584 + } + ], + "validationError": false + }, + { + "dpid": "169", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreidguz57tkqtmta44oov6jkgxxeg635asddp2belouydyxjndukspi", + "time": 1708495980 + } + ], + "validationError": false + }, + { + "dpid": "170", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreidyakyvrrmovwk4ddfw2fxtgkl3f4coef75pybncmoa55jnlxx6tm", + "time": 1708501884 + } + ], + "validationError": false + }, + { + "dpid": "171", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreibtajzmf7ty7hhyclz4aj5f74mktbj4liyhobvs3qr7nebqprl2yi", + "time": 1708516896 + } + ], + "validationError": false + }, + { + "dpid": "172", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreicenejlzy2ygk6vflo4xhr7hjqe22nz5f354afoo5pc65d6qf2ojq", + "time": 1708523184 + } + ], + "validationError": false + }, + { + "dpid": "173", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreie23vmvink27bqo7qzzsdng4ho22uhrgoscencr7s4itekrzreahy", + "time": 1708531344 + }, + { + "cid": "bafkreie23vmvink27bqo7qzzsdng4ho22uhrgoscencr7s4itekrzreahy", + "time": 1708531620 + }, + { + "cid": "bafkreie23vmvink27bqo7qzzsdng4ho22uhrgoscencr7s4itekrzreahy", + "time": 1708531992 + }, + { + "cid": "bafkreie23vmvink27bqo7qzzsdng4ho22uhrgoscencr7s4itekrzreahy", + "time": 1708532064 + } + ], + "validationError": false + }, + { + "dpid": "174", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreidobtwdrk7dulyc6dghfr6zylbfisjwbs6l6ahd6qfkfdavs76dpa", + "time": 1708602732 + } + ], + "validationError": false + }, + { + "dpid": "175", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreignopdmerljfo6nzpq2hj5zr5g7h3wajjxthpuikxjpsdbco4tavm", + "time": 1708619376 + }, + { + "cid": "bafkreiae65pw54dt5vx75oenehagushpi2sh42c3zqld7der3ircmfyqam", + "time": 1708653516 + }, + { + "cid": "bafkreihm7iuibrdzlr5uyrhhkyijboyheeujettcihcgmegrna43mmvs6a", + "time": 1708672332 + }, + { + "cid": "bafkreicjzr7d4odl6dzvx3acnng3cwq5sptcjn5wbqeep4juymadohagfi", + "time": 1708674912 + }, + { + "cid": "bafkreihdgbp3rrimo3sfayouabpfy5awspr6lues5rj5pjld2mcwi5ftsm", + "time": 1708729500 + }, + { + "cid": "bafkreidpouvko3ht6dkhplrx44r4cbycx4irvw6mnunven3x2mll5kgaie", + "time": 1708890600 + } + ], + "validationError": false + }, + { + "dpid": "176", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreidwx6vv43n4vyd2gvnc7a7hoalg3nj6ncuxtzete7bay6lgkdjrji", + "time": 1708695348 + }, + { + "cid": "bafkreibjcr22ex3uibpoxf3fpzriafscmbivizzkqrjx7iqh5qbkg4oizq", + "time": 1708695612 + } + ], + "validationError": false + }, + { + "dpid": "177", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreihnul5baol6hg5vsq6sokqwbm5txyb5honlphs3rpjklc4d7pj4qi", + "time": 1708882260 + } + ], + "validationError": false + }, + { + "dpid": "178", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreibnvu2kmntm4p2ttebfqukas5hdzzthyahkkgxizihb4f3fwvszoy", + "time": 1708900272 + }, + { + "cid": "bafkreibax2nwfvcmewzi4muxbtywulni6zvvihnipob3hvweohuu3lmawu", + "time": 1708900680 + }, + { + "cid": "bafkreiaicia5j7xdpo5gr3nukomg7kylxpnyfiguflr7ff5z6v45rbg3om", + "time": 1708909188 + } + ], + "validationError": false + }, + { + "dpid": "179", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreiekmumtbr6fg6ksitwx3744knbituhthjis3mnd5facdbqc6526fy", + "time": 1708930572 + } + ], + "validationError": false + }, + { + "dpid": "180", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreihyn2pm7mqzcjabytkoszcetquu4q6zouwaeqhp6bavvlmijqvj2m", + "time": 1708965960 + }, + { + "cid": "bafkreigksvcw5f67h2kzbxnndwf47ch74nb4vbniepacjt6y5nm74ote4m", + "time": 1708966848 + }, + { + "cid": "bafkreifhzq76yqo66hcvcj2e7554odbcppblavfrobmyuxynaj2wv2ydlm", + "time": 1708974048 + } + ], + "validationError": false + }, + { + "dpid": "181", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreieqzlofquf3yakkfcqwzzg77ea6qrirnbli6iedpeo5zk2hktedfe", + "time": 1709032560 + } + ], + "validationError": false + }, + { + "dpid": "182", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreidjaowinhp5e3m6ikq32mfgqg5mqw6ttzccngl5aa2imyryscenjq", + "time": 1709070444 + }, + { + "cid": "bafkreidjaowinhp5e3m6ikq32mfgqg5mqw6ttzccngl5aa2imyryscenjq", + "time": 1709070600 + } + ], + "validationError": false + }, + { + "dpid": "183", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreihfy4ibvcrdxlq3n6y6ahskxglvyhskwugy7xwi4amk4dcek7hvvi", + "time": 1709074644 + } + ], + "validationError": false + }, + { + "dpid": "184", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreif4pg7ph3qxuj4yoapw4tez3jxt52m5fhp7nkd3q2ai4xrwva46oq", + "time": 1709709132 + } + ], + "validationError": false + }, + { + "dpid": "185", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreibbt24dc64gwzwhcjtyha5qsdvmj4ztlkbhg7p7s74hjpdlrveo5a", + "time": 1709710296 + } + ], + "validationError": false + }, + { + "dpid": "186", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreiezmycqcs3426uhlpamwfidxlt72njmc22cuma47fxx5e3oi7zrpq", + "time": 1709713596 + } + ], + "validationError": false + }, + { + "dpid": "187", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreiemcbfxzi5v3sjiztw4zqs7ngbbirmbcza2sxag4ur4gx3jc57weu", + "time": 1709713968 + } + ], + "validationError": false + }, + { + "dpid": "188", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreifc7blw4sfdrqqyinooyk2zajg4kvobazfpxmmyxhky67xyrtg2bi", + "time": 1709717856 + } + ], + "validationError": false + }, + { + "dpid": "189", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreib5w5wqatnhuuekzdmqe33ci4jmczwtcw235mdugsk6sbjkewhycq", + "time": 1709718156 + } + ], + "validationError": false + }, + { + "dpid": "190", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreidlwnin6u3lbb5me7gsaomtrz3xfxruteb3oqvng2isup6dq2md2u", + "time": 1710044316 + } + ], + "validationError": false + }, + { + "dpid": "191", + "owner": "0xec29aCa1a8740B8C5e2e06EBB52290700B9a2c40", + "versions": [ + { + "cid": "bafkreiekjqv27pmrf3tk6tn4mimvbivhtln7jefgjmzeui6vm43oes2giy", + "time": 1711113468 + }, + { + "cid": "bafkreiekjqv27pmrf3tk6tn4mimvbivhtln7jefgjmzeui6vm43oes2giy", + "time": 1711115796 + }, + { + "cid": "bafkreiekjqv27pmrf3tk6tn4mimvbivhtln7jefgjmzeui6vm43oes2giy", + "time": 1711118604 + } + ], + "validationError": false + }, + { + "dpid": "192", + "owner": "0x955bcC4a744f7a63c064bcDCb41d3da32ab59fA2", + "versions": [ + { + "cid": "bafkreif7cyujbmdodoxfmvwg7vtllo57eqyl4jqx2ldugcdgbn4l37aide", + "time": 1711224600 + } + ], + "validationError": false + }, + { + "dpid": "193", + "owner": "0xBaf4a58783150abaAec703E43e6cca151D4Ff475", + "versions": [ + { + "cid": "bafkreifxdilgiuozcbyxrbmyij3rh5a75br7ree7finitlfgpdgsuovbu4", + "time": 1711371324 + } + ], + "validationError": false + }, + { + "dpid": "194", + "owner": "0xBaf4a58783150abaAec703E43e6cca151D4Ff475", + "versions": [ + { + "cid": "bafkreibir2ytu4y3ckuntnyq4bd2hn7e7v4st4qznhmymulunoag6htkli", + "time": 1711371840 + } + ], + "validationError": false + }, + { + "dpid": "195", + "owner": "0xBaf4a58783150abaAec703E43e6cca151D4Ff475", + "versions": [ + { + "cid": "bafkreibwwiqyfdk57mulox3kkndbjzrpauwifhjlx4a5mcd3xyghi3phnm", + "time": 1711372188 + }, + { + "cid": "bafkreibwwiqyfdk57mulox3kkndbjzrpauwifhjlx4a5mcd3xyghi3phnm", + "time": 1711372224 + } + ], + "validationError": false + }, + { + "dpid": "196", + "owner": "0xBaf4a58783150abaAec703E43e6cca151D4Ff475", + "versions": [ + { + "cid": "bafkreib2bldqjixzqdxfgawln7nkmho7au4cu4vpp3luyziih6i5v24fyu", + "time": 1711372332 + } + ], + "validationError": false + }, + { + "dpid": "197", + "owner": "0xBaf4a58783150abaAec703E43e6cca151D4Ff475", + "versions": [ + { + "cid": "bafkreibckw6mcb7w6ocnrftdcj5ua2ynp44athn37uj5a2luejt4sbag74", + "time": 1711372704 + } + ], + "validationError": false + }, + { + "dpid": "198", + "owner": "0xBaf4a58783150abaAec703E43e6cca151D4Ff475", + "versions": [ + { + "cid": "bafkreig2oyjlgt2tm5o5w66lroxithj2yyokcgiirlqgtxi2rx5fmcnl3u", + "time": 1711373136 + } + ], + "validationError": false + }, + { + "dpid": "199", + "owner": "0xBaf4a58783150abaAec703E43e6cca151D4Ff475", + "versions": [ + { + "cid": "bafkreia6bshsvigqmwl6gczqkekbe6n5vrm5oqk4mlpqxzuqvm6pnvcz4u", + "time": 1711373508 + } + ], + "validationError": false + }, + { + "dpid": "200", + "owner": "0xBaf4a58783150abaAec703E43e6cca151D4Ff475", + "versions": [ + { + "cid": "bafkreiaj3hoxxa6ejl6wbbxmj5yyvwgjbxqcwvutbuffjdmz6bjo4aeuua", + "time": 1711373664 + }, + { + "cid": "bafkreihuphbjewu6gy7bhu3pojq4wzauo4eysrjwf2yjqxauakfm2oycwa", + "time": 1711895628 + } + ], + "validationError": false + }, + { + "dpid": "201", + "owner": "0xBaf4a58783150abaAec703E43e6cca151D4Ff475", + "versions": [ + { + "cid": "bafkreib75qhje5orxp6x73krgk4gxs4zjma235jakvaz7nmjmidxotqvay", + "time": 1711373808 + }, + { + "cid": "bafkreidfhctv5tsybphthhsi64pvjtnfqal6u4yio7ntuossddyoeqktle", + "time": 1711895736 + } + ], + "validationError": false + }, + { + "dpid": "202", + "owner": "0x93aF2e3057F7A1dEec2bEDaB92014372529917b2", + "versions": [ + { + "cid": "bafkreihw7nmfo37bcnovdiuarejedgnesfbjcrx6yfylnapsruv3cxmwca", + "time": 1711379508 + }, + { + "cid": "bafkreig7tkfx63cprx4p62exwlob3fdpnbz67732yivzjvvp4upvqvtaue", + "time": 1711388652 + }, + { + "cid": "bafkreiefzc365jagtqbqlay6enzcetdqntxmpnamknxvub523cbqe5vhii", + "time": 1711535616 + } + ], + "validationError": false + }, + { + "dpid": "203", + "owner": "0x711E9b9e8aD75CBD3AC024a8e4Aeeff59AfBae6c", + "versions": [ + { + "cid": "bafkreicatliyp3ucb74vsyjutro5gj3f4ido7g2g3lpqq44mejhnft4nhe", + "time": 1711480872 + } + ], + "validationError": false + }, + { + "dpid": "204", + "owner": "0x711E9b9e8aD75CBD3AC024a8e4Aeeff59AfBae6c", + "versions": [ + { + "cid": "bafkreihzsc3ukfifnwrn2pwbi7nslahwducpjpanw6whgnmlqrzmzudboa", + "time": 1711483248 + } + ], + "validationError": false + }, + { + "dpid": "205", + "owner": "0x711E9b9e8aD75CBD3AC024a8e4Aeeff59AfBae6c", + "versions": [ + { + "cid": "bafkreib72txikuh4u63nb3jtsxj4r3q7cdeaaq7lzwejqjchminj7smhhu", + "time": 1711484040 + } + ], + "validationError": false + }, + { + "dpid": "206", + "owner": "0xDAF8752DDcCE8a6B709aa271e7Efc60F75CDDF64", + "versions": [ + { + "cid": "bafkreigwpvacu6jfho5bn3dh6kddxjxcz3tmp5ukglfds2vgqbetburmyu", + "time": 1711485180 + } + ], + "validationError": false + }, + { + "dpid": "207", + "owner": "0x3946A420ac849229918AE4C27e4CED2299646b03", + "versions": [ + { + "cid": "bafkreif5vmdusp7spdvopv6gtiaywnxf566hvxqj4y5xajxslad5hjoomq", + "time": 1712129772 + }, + { + "cid": "bafkreianwyrn4e57d5ebpnrxnxnwc7j7t6x7sbm3tyib7gzu4dugt23qlu", + "time": 1712130636 + }, + { + "cid": "bafkreihn7si3rxrrgwie53k4w4nuaztmq3eajbvv2gdesfos3bgpdjgl2i", + "time": 1712134152 + }, + { + "cid": "bafkreiawd2bsrkwxrsqfsxuxgxbilgs3zzbosdruplsklludfmuprszgli", + "time": 1712143392 + }, + { + "cid": "bafkreiggmuv3uk6ndhpnwdttis55lvoq5um6bgc3v2drqkxviul6l7wp5i", + "time": 1720800036 + } + ], + "validationError": false + }, + { + "dpid": "208", + "owner": "0xF84bb22037D7977f78FefFBA75D1dda938B73E2e", + "versions": [ + { + "cid": "bafkreicjmmge75m2pcqhi2iiae5ab2byztxbcnyukyljje7s3nefbsmdwe", + "time": 1713698724 + } + ], + "validationError": false + }, + { + "dpid": "209", + "owner": "0xF84bb22037D7977f78FefFBA75D1dda938B73E2e", + "versions": [ + { + "cid": "bafkreidye2q5xg5mqqbfup32fvs7hkg3lpwbcl3kojzu67vmtnavopwrea", + "time": 1714405584 + } + ], + "validationError": false + }, + { + "dpid": "210", + "owner": "0x72Dc927773e3d453Fff9B083C45eBE9d256Db16E", + "versions": [ + { + "cid": "bafkreifbpagid6fj4gp2z3qbynl7w676ulpnv5lqgibhyf6a4ckgdzdt7y", + "time": 1714769952 + } + ], + "validationError": false + }, + { + "dpid": "211", + "owner": "0x9381995264d304e514Ad3Dfe5eF8C79341D1C5b7", + "versions": [ + { + "cid": "bafkreibm2j2doneeuabi6crd3bguaj3ua4c6hpwrtfzje762noq63rkrhy", + "time": 1715358132 + }, + { + "cid": "bafkreibm2j2doneeuabi6crd3bguaj3ua4c6hpwrtfzje762noq63rkrhy", + "time": 1715358684 + }, + { + "cid": "bafkreih3nstwkg6iakafg45kwshw6db4hhshsuhkwruebe5ziydzevmney", + "time": 1715866908 + }, + { + "cid": "bafkreih3nstwkg6iakafg45kwshw6db4hhshsuhkwruebe5ziydzevmney", + "time": 1715868780 + }, + { + "cid": "bafkreih3nstwkg6iakafg45kwshw6db4hhshsuhkwruebe5ziydzevmney", + "time": 1715978748 + }, + { + "cid": "bafkreifgflgcb7ldns2k5eobjqzo566zt4d7hisqzo3tav5flyc7sprpyq", + "time": 1716021840 + } + ], + "validationError": false + }, + { + "dpid": "212", + "owner": "0x48801eB4DD5e49A9849055ddfD2388f704d96701", + "versions": [ + { + "cid": "bafkreic7t74rbgla2l5jv6dafmtccpzqkechgweeyqqs7tsyemvc3jefae", + "time": 1715851488 + } + ], + "validationError": false + }, + { + "dpid": "213", + "owner": "0x08E424b69851b7b210bA3E5E4233Ca6fcc1ADEdb", + "versions": [ + { + "cid": "bafkreiezhimuxptmz5n6yimve6ydawge4ghihw3r7u45ky65c2ryaqqmce", + "time": 1716409680 + }, + { + "cid": "bafkreia6tgjva2f2bgjs4x3w5t53iiauj6c72o3nurztlc5pzcnicuciou", + "time": 1716826812 + } + ], + "validationError": false + }, + { + "dpid": "214", + "owner": "0x0F81A4d0553f09767027B4c15D0C374B939Cd5F1", + "versions": [ + { + "cid": "bafkreih7ayew5fbjl6qswqxhczbnpvjocbrh25sndnausewyvzyqfqfn3i", + "time": 1717068456 + } + ], + "validationError": false + }, + { + "dpid": "215", + "owner": "0xBaf4a58783150abaAec703E43e6cca151D4Ff475", + "versions": [ + { + "cid": "bafkreiamkomiad6wgakicshmb2jbttwkzvl3pvz7dg3dk4limjudjs7fze", + "time": 1719238548 + }, + { + "cid": "bafkreicgr4sw55zkzcvsymlbzuwycyumbaxbddsfs4fmpqgop26ao6kwai", + "time": 1719239016 + }, + { + "cid": "bafkreifwdyyytjgeptaobon4zcagur6kqtozfhj2r3p345bbdk4wisyahy", + "time": 1719495228 + } + ], + "validationError": false + }, + { + "dpid": "216", + "owner": "0xBaf4a58783150abaAec703E43e6cca151D4Ff475", + "versions": [ + { + "cid": "bafkreiahiziyaeq433h3kcujkgiiv5ttk3ouls6clr66o3t6dfaecmjleq", + "time": 1719238956 + }, + { + "cid": "bafkreidanmyotk43oz67oai5fmavt3voi7bhrqa2ppkdevqjd6nig3e5t4", + "time": 1719493716 + } + ], + "validationError": false + }, + { + "dpid": "217", + "owner": "0xBaf4a58783150abaAec703E43e6cca151D4Ff475", + "versions": [ + { + "cid": "bafkreif2l2vqwzocmgmfyy2ejvrqd5uhhrzkqk45hthwcw4mt4oz7i4u7q", + "time": 1719239808 + }, + { + "cid": "bafkreibyobujs3ljgpz6kidhgizhzh3tkwcts3s6526uliej7mu7k5ieei", + "time": 1719495156 + } + ], + "validationError": false + }, + { + "dpid": "218", + "owner": "0xBaf4a58783150abaAec703E43e6cca151D4Ff475", + "versions": [ + { + "cid": "bafkreigldutspcrrahapdsj7sr4zrikxirwsjbqvrcuzlwwyuk2zhtho2e", + "time": 1719240072 + }, + { + "cid": "bafkreib3hywyhrvxw6ylpypft3prqj2hncm633usbaqweithafwe3jvi2i", + "time": 1719495060 + } + ], + "validationError": false + }, + { + "dpid": "219", + "owner": "0xBaf4a58783150abaAec703E43e6cca151D4Ff475", + "versions": [ + { + "cid": "bafkreifkiw3ckd6n6nkzhx3benfz2ct4acqrq3kaepv2dod4b3twwnxsti", + "time": 1719242676 + }, + { + "cid": "bafkreiahnaq2grg2wxie6xjxjhs3mxxefj5juk3sdidd2tqbsxirsbvmvy", + "time": 1719494904 + } + ], + "validationError": false + }, + { + "dpid": "220", + "owner": "0xBaf4a58783150abaAec703E43e6cca151D4Ff475", + "versions": [ + { + "cid": "bafkreift27e5crnj2osffmq6rmbrxaade74cang4gjwwo6eurf5owodm2a", + "time": 1719242796 + }, + { + "cid": "bafkreihipjsqsyjogf77z2wxssqnw5p62yiwcezxytl5psjlg7wjlm2o7e", + "time": 1719494712 + } + ], + "validationError": false + }, + { + "dpid": "221", + "owner": "0xBaf4a58783150abaAec703E43e6cca151D4Ff475", + "versions": [ + { + "cid": "bafkreic6ief4i2lfgi7mz27nqxn7usvs7huh77nmzpactmi63v6dbzv2nq", + "time": 1719243324 + }, + { + "cid": "bafkreia4rjywplbsrr5jc6u4hwcihmyhdvaupfwulzkguepk3tysom4gc4", + "time": 1719494292 + }, + { + "cid": "bafkreih2r7rwkqlqiuvwr6mh34rd5iw6jvxjbgzjkgulygrpzucyrax574", + "time": 1719494592 + } + ], + "validationError": false + }, + { + "dpid": "222", + "owner": "0xBaf4a58783150abaAec703E43e6cca151D4Ff475", + "versions": [ + { + "cid": "bafkreiaurllsr2nc4ejbuq2dc35aftk3din4l7fumw2csslajq43e67tsa", + "time": 1719243792 + }, + { + "cid": "bafkreienghzp4rhpx2debrkbdczjskgsagy6s4rj3ifkoxvwf665xeuoda", + "time": 1719494220 + } + ], + "validationError": false + }, + { + "dpid": "223", + "owner": "0xBaf4a58783150abaAec703E43e6cca151D4Ff475", + "versions": [ + { + "cid": "bafkreig2zp6cnz2sifbdtwliamt2edelxvdioc5bph4pxetkvknfvavfvi", + "time": 1719244032 + }, + { + "cid": "bafkreiazl42wr4sbwqfv5pomstrytrywuugd7no2jjg4db4nk6seaxhj3i", + "time": 1719494136 + } + ], + "validationError": false + }, + { + "dpid": "224", + "owner": "0xBaf4a58783150abaAec703E43e6cca151D4Ff475", + "versions": [ + { + "cid": "bafkreicuitjqpveaxjoqil77g5l2apesvrmowym5p5n4b4xbneh5eonaay", + "time": 1719244260 + }, + { + "cid": "bafkreicyfbgky3jn6uacvq4rxpuxshq4pnp4q5zvti774jxcxbxud3rsq4", + "time": 1719493992 + } + ], + "validationError": false + }, + { + "dpid": "225", + "owner": "0xec29aCa1a8740B8C5e2e06EBB52290700B9a2c40", + "versions": [ + { + "cid": "bafkreigj5nyp6r7mp4s5agcakjvywlha5bx2giq2zlsmu2kgobaazdynsm", + "time": 1720477056 + } + ], + "validationError": false + }, + { + "dpid": "226", + "owner": "0xec29aCa1a8740B8C5e2e06EBB52290700B9a2c40", + "versions": [ + { + "cid": "bafkreieifs7wq7ncnefnatondlbgmrasevdcav2ep2pyyzfiniugvpt5za", + "time": 1720477920 + } + ], + "validationError": false + }, + { + "dpid": "227", + "owner": "0xec29aCa1a8740B8C5e2e06EBB52290700B9a2c40", + "versions": [ + { + "cid": "bafkreifxgx4nqbzerud4vdmkovjfe5zsac6nc2iq5z3v4tkrbobbnwfnsi", + "time": 1720479012 + } + ], + "validationError": false + }, + { + "dpid": "228", + "owner": "0xec29aCa1a8740B8C5e2e06EBB52290700B9a2c40", + "versions": [ + { + "cid": "bafkreiho2ipglkfppftalyrhyfj63a65sw262n3ewsao7lpo26mz6mthzq", + "time": 1720479528 + } + ], + "validationError": false + }, + { + "dpid": "229", + "owner": "0xec29aCa1a8740B8C5e2e06EBB52290700B9a2c40", + "versions": [ + { + "cid": "bafkreigy2hlajf2isrzvczia47pel6cxuqiiqjh4ujniwyqe4xtzymbbdy", + "time": 1720480932 + } + ], + "validationError": false + }, + { + "dpid": "230", + "owner": "0xec29aCa1a8740B8C5e2e06EBB52290700B9a2c40", + "versions": [ + { + "cid": "bafkreig3qftvjkfmq4jk7rsypm7adm7cphe2osfz6oy4z6dvu6lkzxbhyy", + "time": 1720481844 + }, + { + "cid": "bafkreig3qftvjkfmq4jk7rsypm7adm7cphe2osfz6oy4z6dvu6lkzxbhyy", + "time": 1720481904 + } + ], + "validationError": false + }, + { + "dpid": "231", + "owner": "0xec29aCa1a8740B8C5e2e06EBB52290700B9a2c40", + "versions": [ + { + "cid": "bafkreic2jjxgxaynqfopxjwm24buwebpq7isnfz36igifm7bkc6gjohjje", + "time": 1720482384 + } + ], + "validationError": false + }, + { + "dpid": "232", + "owner": "0x7Ec8AFDDE28349671f2ea8B57FaD53e200F301ff", + "versions": [ + { + "cid": "bafkreiez35iuhs7gpr2ky5gmtrjtnz42nz3rvuwpfenxeztcqff5r43bh4", + "time": 1720508196 + }, + { + "cid": "bafkreidscaetshms3qnxppft6cqpoumpwgojpa7p3uew7xyfdomjyz5ole", + "time": 1720508592 + } + ], + "validationError": false + }, + { + "dpid": "233", + "owner": "0x0F81A4d0553f09767027B4c15D0C374B939Cd5F1", + "versions": [ + { + "cid": "bafkreihtajz6kf4lpa5dvxkcq76jxwz2zriobhwxq626bjym62wefclxre", + "time": 1720556076 + } + ], + "validationError": false + }, + { + "dpid": "234", + "owner": "0xec29aCa1a8740B8C5e2e06EBB52290700B9a2c40", + "versions": [ + { + "cid": "bafkreih4l7hom74jktxdlz53fczdz2ndq55k4mc3twnpwfcfsh5eh6inra", + "time": 1720619364 + } + ], + "validationError": false + }, + { + "dpid": "235", + "owner": "0xec29aCa1a8740B8C5e2e06EBB52290700B9a2c40", + "versions": [ + { + "cid": "bafkreidhaox2zpaossjmvjuhjgn5qvoifshwsen37lt6kmxwzrauplbvji", + "time": 1720620312 + } + ], + "validationError": false + }, + { + "dpid": "236", + "owner": "0xec29aCa1a8740B8C5e2e06EBB52290700B9a2c40", + "versions": [ + { + "cid": "bafkreidls5s6z26sdii7b2hpbuaxrrrcooq7meirxsoikv753zs5hkbbr4", + "time": 1720630032 + } + ], + "validationError": false + }, + { + "dpid": "237", + "owner": "0xec29aCa1a8740B8C5e2e06EBB52290700B9a2c40", + "versions": [ + { + "cid": "bafkreic6soeg2nlerfsf75n3ehr2dzcpn5rl3iyecpbv6pdcgcvh3av6ey", + "time": 1720632864 + } + ], + "validationError": false + }, + { + "dpid": "238", + "owner": "0x0F81A4d0553f09767027B4c15D0C374B939Cd5F1", + "versions": [ + { + "cid": "bafkreigzinwo3bxv7jwdh5r6brshvscxklyqi3gapll7ytfo2isqwtszum", + "time": 1720712652 + }, + { + "cid": "bafkreifv32nvd7vdnsonsahzcqu3cibpous7yqgfkrjcp56oqmqz2viayy", + "time": 1720779696 + } + ], + "validationError": false + }, + { + "dpid": "239", + "owner": "0x8AB466539A0d6D4C13dd21cAC63BE7e56AA77203", + "versions": [ + { + "cid": "bafkreibj4lzkysx5poxqnblmw7llxccqetsl6hkwsp3djokuoe4fdkfi2y", + "time": 1720824228 + }, + { + "cid": "bafkreicyfh4xnhodppgb57xjetltjewmqemu34gh7oft4b4qgf6cn5u6ry", + "time": 1722247104 + } + ], + "validationError": false + }, + { + "dpid": "240", + "owner": "0x81A1EA5A462ba21A328d206d4c15A7Af8812ad3c", + "versions": [ + { + "cid": "bafkreie7vwam62su32yyx2fk5z73zzlrhrtkyyg7nmpad3tbcsmu7znvni", + "time": 1721114028 + } + ], + "validationError": false + }, + { + "dpid": "241", + "owner": "0x0F81A4d0553f09767027B4c15D0C374B939Cd5F1", + "versions": [ + { + "cid": "bafkreihtsyrdpbxzlglorp26vtstwd44swdsnnwpfuq2zfk7s5nd75lgki", + "time": 1721133336 + } + ], + "validationError": false + }, + { + "dpid": "242", + "owner": "0xec29aCa1a8740B8C5e2e06EBB52290700B9a2c40", + "versions": [ + { + "cid": "bafkreihmmjbmdi2a2nsh7i5wx64yj23lmwtcsj5tvp5s5vn26jcye7sk4i", + "time": 1721225160 + } + ], + "validationError": false + }, + { + "dpid": "243", + "owner": "0x0F81A4d0553f09767027B4c15D0C374B939Cd5F1", + "versions": [ + { + "cid": "bafkreiebbnincejhfok3ojh3ynpohjgnuczjf3aret4ye3lbn7i4awaede", + "time": 1721389728 + } + ], + "validationError": false + }, + { + "dpid": "244", + "owner": "0x8AB466539A0d6D4C13dd21cAC63BE7e56AA77203", + "versions": [ + { + "cid": "bafkreiei3m5wzddkcvw4ae2w7hrgytfaq6l5iwz5joqlu4uydbg5jt2yw4", + "time": 1721470692 + } + ], + "validationError": false + }, + { + "dpid": "245", + "owner": "0xec29aCa1a8740B8C5e2e06EBB52290700B9a2c40", + "versions": [ + { + "cid": "bafkreiady6yrkve6zryofryqsw3hmfxihtyjetdykpw54r7rqaew45gfum", + "time": 1722248736 + } + ], + "validationError": false + }, + { + "dpid": "246", + "owner": "0xec29aCa1a8740B8C5e2e06EBB52290700B9a2c40", + "versions": [ + { + "cid": "bafkreibhbbtogpv7i2rl2q64wpwaj42lzg23b7fxpmeixh3hblaw6djhki", + "time": 1722604140 + }, + { + "cid": "bafkreihizommq35uxz2kjhchvoqccv2wygtkne37flt46gqo3w66lj3gb4", + "time": 1722604176 + } + ], + "validationError": false + }, + { + "dpid": "247", + "owner": "0x0F81A4d0553f09767027B4c15D0C374B939Cd5F1", + "versions": [ + { + "cid": "bafkreidzb55z7hc3fkusx3mp4flf4vnqdpox6qtu2g7kotx2hkxka23csq", + "time": 1722615504 + }, + { + "cid": "bafkreiewgihawmxepbvqgyeejbdj6jt4ngctjgcxj4gj3lhutjorbvu5yq", + "time": 1722615792 + }, + { + "cid": "bafkreiaizfnyvkio7x5gp6ouxkwii2b5wgcfyoifq63geltx7t54e7v76i", + "time": 1722615960 + }, + { + "cid": "bafkreiczi7o53yitcp6at4as3tf6kybsaijzmiwmchrq3nagoii452giva", + "time": 1723117044 + }, + { + "cid": "bafkreid34dafmffnznmrtzzs6j5syqcpqmexkz6miflrcwpwms3scbkjzi", + "time": 1723117896 + }, + { + "cid": "bafkreiagnknv2rpimw5oifsdi3krjuj4vb44yllgpkzuq4o36e7ptfqvky", + "time": 1723117980 + } + ], + "validationError": false + }, + { + "dpid": "248", + "owner": "0xDd4d86BA6D539E8d8d7A2C03947A34c326A229A1", + "versions": [ + { + "cid": "bafkreibcag5sqogsn2c53dq6gczjwgsssya3n2nleav422kwbutzzes3kq", + "time": 1722625668 + }, + { + "cid": "bafkreidef6dpqp2axnl5ljbt7pj7kga4r6fvdgcm6n5zgyheeaplewl4wy", + "time": 1723734708 + } + ], + "validationError": false + }, + { + "dpid": "249", + "owner": "0x8AB466539A0d6D4C13dd21cAC63BE7e56AA77203", + "versions": [ + { + "cid": "bafkreih7yx4muokp6ubr4yr3nsxys2hvkyple2rephzuta75rpipsvihmq", + "time": 1722902496 + } + ], + "validationError": false + }, + { + "dpid": "250", + "owner": "0x8FeEAAae1DB031E5F980F5E63fDbb277731e500e", + "versions": [ + { + "cid": "bafkreicn4qjzej4zkuny7nx2af4n5gvxmzahave35dr5venluu67c3u6dq", + "time": 1723641024 + }, + { + "cid": "bafkreiaazjxzipoaeds6bep3p2v25vdjxchqoc745wvbk5pmgo4bzssw7i", + "time": 1723641480 + } + ], + "validationError": false + }, + { + "dpid": "251", + "owner": "0x9381995264d304e514Ad3Dfe5eF8C79341D1C5b7", + "versions": [ + { + "cid": "bafkreid3bvy6oziqj2zfeiqfnehdqpuga32qoihjyna66vronfm3bdfgqu", + "time": 1723713348 + }, + { + "cid": "bafkreic5xloudqnuf43koxpjrh2m44hpedj4bfuff7fkhwypqhv6jkhq3a", + "time": 1723713684 + } + ], + "validationError": false + }, + { + "dpid": "252", + "owner": "0x9381995264d304e514Ad3Dfe5eF8C79341D1C5b7", + "versions": [ + { + "cid": "bafkreiaekzuxotos4txt44hpa6q6hdjma6wkxvyeolhugop6tjepiodl6y", + "time": 1723714416 + } + ], + "validationError": false + }, + { + "dpid": "253", + "owner": "0xE862E2C1ca94eAcfEDe3c95a217c15EF0086a29D", + "versions": [ + { + "cid": "bafkreihvzdunfsz72j7omwgiodczdy3dgeefdreheeeky5ylwh7p3fukbm", + "time": 1723714680 + }, + { + "cid": "bafkreidaskevgai2slqseovb44bk6bnw6fzz6epgnrejoluvzyoesajgue", + "time": 1723714764 + }, + { + "cid": "bafkreieopbdp733cjbtm2bfavi6kq55coumdrmoc7bvouk2uqthjvxuapy", + "time": 1723714872 + } + ], + "validationError": false + }, + { + "dpid": "254", + "owner": "0x26c61658d7BE9125bCf5A55b3bE01198bE49f61f", + "versions": [ + { + "cid": "bafkreihsgmtkyfl5x74zn5qdcuwvqvbxuxneiv7gdgsdoysudvv6fvesjy", + "time": 1724164476 + } + ], + "validationError": false + }, + { + "dpid": "255", + "owner": "0xec29aCa1a8740B8C5e2e06EBB52290700B9a2c40", + "versions": [ + { + "cid": "bafkreib6m33xstvn7dzzax4oq4jqgyov65snapnie3weggvebfmmovkgg4", + "time": 1725279660 + } + ], + "validationError": false + }, + { + "dpid": "256", + "owner": "0xec29aCa1a8740B8C5e2e06EBB52290700B9a2c40", + "versions": [ + { + "cid": "bafkreihftqk76djohkehs4ulekkmoxbfjsdzha3dki5dcwpsf3tikwjlhe", + "time": 1725976920 + } + ], + "validationError": false + }, + { + "dpid": "257", + "owner": "0xec29aCa1a8740B8C5e2e06EBB52290700B9a2c40", + "versions": [ + { + "cid": "bafkreibubpwuwyiwfm7nc5fprgnnl6hdeejb7jntx64qsvbnktm3i4t36u", + "time": 1725977004 + } + ], + "validationError": false + }, + { + "dpid": "258", + "owner": "0xec29aCa1a8740B8C5e2e06EBB52290700B9a2c40", + "versions": [ + { + "cid": "bafkreibaq3t5lj5pcx7t6z2x6enrefywmn7ayjcjegpub36zpdhxj4yavy", + "time": 1725977076 + }, + { + "cid": "bafkreiexwmkpzktjhyfln6zilql6jfqz7ksigsxvgk4fdgvggxrdzctcc4", + "time": 1725977220 + } + ], + "validationError": false + } +] \ No newline at end of file diff --git a/desci-contracts/migration-data/aliasRegistrySync_prod_Wed,_18_Sep_2024_13:04:23_GMT.json b/desci-contracts/migration-data/aliasRegistrySync_prod_Wed,_18_Sep_2024_13:04:23_GMT.json new file mode 100644 index 000000000..32db70ff1 --- /dev/null +++ b/desci-contracts/migration-data/aliasRegistrySync_prod_Wed,_18_Sep_2024_13:04:23_GMT.json @@ -0,0 +1,3716 @@ +[ + { + "dpid": "0", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreie2idd2yuwibppujafgtfc6cczopht4q47y563q4paml2me2dsh6y", + "time": 1675737468 + } + ], + "validationError": false + }, + { + "dpid": "1", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreigbp7bahnrxujbz5uu3j6hzmyimq7wijkucwyi4bc5tbvka5xw3wq", + "time": 1675781796 + }, + { + "cid": "bafkreigwzsizb76b62ln5xnhhqeypxhyqwwyp56zcprl52siut2q7h2lky", + "time": 1682818404 + }, + { + "cid": "bafkreigwzsizb76b62ln5xnhhqeypxhyqwwyp56zcprl52siut2q7h2lky", + "time": 1682818608 + } + ], + "validationError": false + }, + { + "dpid": "2", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreihlsxjw3gzrikm2att6sd2yty4qx37z3fgmzokrm6fd3oony2qqby", + "time": 1676095440 + }, + { + "cid": "bafkreigvalv7basyqxn57b5ittssieecsccy7qaypmy6s7egr2o5tcqnda", + "time": 1676096820 + } + ], + "validationError": false + }, + { + "dpid": "3", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreiancsq3yywjzkoyevwhn4hxyzgcfbdb72jspegmwy6uacd2cztpra", + "time": 1676725008 + } + ], + "validationError": false + }, + { + "dpid": "4", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreick32zk4ennjwwy7vqva7wpjo2w5d4fkwhg7hkrdjk63xq5r6gup4", + "time": 1676988612 + } + ], + "validationError": false + }, + { + "dpid": "5", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreihra4e2ejsm7yqra4wmo2ww43j4ndvylfsrv5obobkl2k666baram", + "time": 1676996292 + } + ], + "validationError": false + }, + { + "dpid": "6", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreiee7atuqdvq7dtxf2msslelz2ubst2g64oigetxunn352ryqvuoti", + "time": 1677066240 + } + ], + "validationError": false + }, + { + "dpid": "7", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreidi2idvbbbg5y6iuf3bnbdo7gkyzgoz3hik2hghr3rl3gd7nplnwe", + "time": 1677080820 + }, + { + "cid": "bafkreicyvzgk632l2zn55dkbscjrwrlrxlckrxjhpxn6kiv4roegwzprpi", + "time": 1677081012 + } + ], + "validationError": false + }, + { + "dpid": "8", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreibnhuq4tliestyutqxrfco4wwr3gxyrp7dlydxvgkddo6euet5yyu", + "time": 1677144720 + } + ], + "validationError": false + }, + { + "dpid": "9", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreigjjlyedw3l7yfunjhaooe226hemiqz7pkeqb3arfmwvujknaa7pe", + "time": 1677230328 + } + ], + "validationError": false + }, + { + "dpid": "10", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreihbcdgctujsajvlhbbcghfkg766pprlgatvujzkw6utteryn737wi", + "time": 1677510672 + }, + { + "cid": "bafkreif6omh6d2nosj7exr4gybupz3i6owb7ig7mfha23bebzbbzgtj3ty", + "time": 1677511224 + } + ], + "validationError": false + }, + { + "dpid": "11", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreig75cxpsu2zhnkej7nwqszduw6l32luo3opikzsqa5wpfchnl7sua", + "time": 1678309056 + } + ], + "validationError": false + }, + { + "dpid": "12", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreigvec6jtxth3eessemov7x62wjhtfpfihdleanekwx5l47rkxclcu", + "time": 1678771692 + } + ], + "validationError": false + }, + { + "dpid": "13", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreienztazc23yp5ejvwymgekqf2kmx6foasxul7yzt6w5crjwceqsea", + "time": 1678814328 + }, + { + "cid": "bafkreid4yx77dkhlbmx2gqwwki6y2rjmuybnqkxqmxnoyjtx7uhgdkdeu4", + "time": 1680117252 + } + ], + "validationError": false + }, + { + "dpid": "14", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreiasx7tcckutok7a7yk7ej2pv6bolo5naihlk2gny6tpykcfvzxqm4", + "time": 1679014104 + } + ], + "validationError": false + }, + { + "dpid": "15", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreifjuqlmsnnr2vlhwxrjsgu5zczwgodqjuzmo4kzgpzzu5zn42ivby", + "time": 1679219244 + }, + { + "cid": "bafkreiar3d6vkcyvfnk7kfhu4yrvul6hsn4fnjrwgq7wbl27t4e3ehfhwq", + "time": 1679219328 + }, + { + "cid": "bafkreiar3d6vkcyvfnk7kfhu4yrvul6hsn4fnjrwgq7wbl27t4e3ehfhwq", + "time": 1679219484 + } + ], + "validationError": false + }, + { + "dpid": "16", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreig27rnst73rqnqgtesyo32xhrhaqtdxbvtdohwnjdzua7cyapghbu", + "time": 1679343324 + } + ], + "validationError": false + }, + { + "dpid": "17", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreigggibyev5x4w3tcydslfl3j5g2fl2sabfcxvdzqeajzfg3tqignq", + "time": 1679409324 + } + ], + "validationError": false + }, + { + "dpid": "18", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreigghoctitgbpsjl6elgjkdlpu26t6zon7gqfx7cuhprsyykcjgvee", + "time": 1679409744 + } + ], + "validationError": false + }, + { + "dpid": "19", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreicvdmmzw7tyaa7dkaikb7dcowjjbu3cv76rhvxqdbzm7gcg4inrfq", + "time": 1679539764 + } + ], + "validationError": false + }, + { + "dpid": "20", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreie6bxf7u3z45sn2amk7ocsjihloiecfncmwsgvqoamqjnczfwnexy", + "time": 1679540424 + }, + { + "cid": "bafkreibnxznsx2xwdasyhjr2epkypjohuvz5qy35iu2elyoygjnfbk7im4", + "time": 1680554796 + } + ], + "validationError": false + }, + { + "dpid": "21", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreiecholb67ldemsvyr7js2x6dewjnsylvpk47ejyhrokkbnqbl4i4y", + "time": 1679637204 + }, + { + "cid": "bafkreih6jpxxvs5ruwhfms7t4kg3qv27x6cf4qn7rzoffcjhgctjjcn7my", + "time": 1679637252 + }, + { + "cid": "bafkreih6jpxxvs5ruwhfms7t4kg3qv27x6cf4qn7rzoffcjhgctjjcn7my", + "time": 1679637288 + } + ], + "validationError": false + }, + { + "dpid": "22", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreid4d4543faobctzfxh53tfa7u2q7jwqll7g3o52b6ko2vxbq6gya4", + "time": 1679658768 + } + ], + "validationError": false + }, + { + "dpid": "23", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreifzp4vuudwvek33rcft2rd2szjrimey7yezcsbm2awkx2tjsunwwi", + "time": 1680567024 + } + ], + "validationError": false + }, + { + "dpid": "24", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreicqcgfswelv7jvt3o5mirsrwbegst354jzl5znfhsysfi5kwa5oem", + "time": 1681191960 + } + ], + "validationError": false + }, + { + "dpid": "25", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreiai7ekqchod7c7na6bsc5aeicugtqr2ai4jhdyjal4ukzzjdoxdoi", + "time": 1681495752 + } + ], + "validationError": false + }, + { + "dpid": "26", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreiasg744hrz2h6tkkw4a2z55orh33v5rs2j62mx3arsuqxa5dppyzq", + "time": 1681497684 + }, + { + "cid": "bafkreicbh5ytfk7ohfa7tw44q5nmjkzmqseiesoskwcjntwc6apx7ifyyi", + "time": 1681497900 + } + ], + "validationError": false + }, + { + "dpid": "27", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreiehj4xqrpk5m6sdemt5nv6ktb5uxp6ihmg3apdwiu6xhkjzlcmuka", + "time": 1681505184 + } + ], + "validationError": false + }, + { + "dpid": "28", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreihmuuks36pyt5quuvjbxkhyu6lhdf3sfbqvfii6j2gemwpu2uc67q", + "time": 1681506588 + } + ], + "validationError": false + }, + { + "dpid": "29", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreigifwmh35byvn2yzg2vojm6r6qpjyoce6dfdsacmch336adgqmyee", + "time": 1681736556 + }, + { + "cid": "bafkreicxifdkouaya7pzrj2upqft2c637t6awklqjsbd76dfog42hxvlqu", + "time": 1681736628 + } + ], + "validationError": false + }, + { + "dpid": "30", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreidtjqvqyoq7ehafmy7vvhjlewgtxkxaqr7anwtwtgkzvlogmfwaey", + "time": 1681761420 + }, + { + "cid": "bafkreif6imae7ikphst6f2opahy2bn4qnm3srzj4rmnpdhrqtykwr6c4yu", + "time": 1681762272 + } + ], + "validationError": false + }, + { + "dpid": "31", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreiahcqh7zzoz27gzh2chwto2u5kabmf2vmca3xbmzrlmgoqucrmfky", + "time": 1681805808 + } + ], + "validationError": false + }, + { + "dpid": "32", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreiaakpmpc5jr4bp3puzzpdjv5nh3maunzbaug2p335ngmdfsfekkxe", + "time": 1681830960 + } + ], + "validationError": false + }, + { + "dpid": "33", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreic2zkjdknqf5kfelzzstfovdwuc2dolbaej7eduedn6md7rpfo27y", + "time": 1682014560 + } + ], + "validationError": false + }, + { + "dpid": "34", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreibkbhhedb3yazc6rze6772ouoymv3yy5vqmilmwi6eq7yuw3n6tue", + "time": 1682144088 + } + ], + "validationError": false + }, + { + "dpid": "35", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreih4kylr5z5oppj6wprw2luiyngsn3xq324kfbiku4ehi42dess4oi", + "time": 1682534976 + }, + { + "cid": "bafkreidasu577tdw76nprafzy7oa42nlr6gcyk45agx3tawrw3zyxu7mva", + "time": 1682746284 + }, + { + "cid": "bafkreieaozkgywz6vonai3kmhr6cct5jjpeau3lhy2zrb2ft3dsnudaxym", + "time": 1682813004 + } + ], + "validationError": false + }, + { + "dpid": "36", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreifc4so5xny7vpkj62oejlxlnh2zp6w76idbvx3mi2t5nkhxpbenbe", + "time": 1682670864 + } + ], + "validationError": false + }, + { + "dpid": "37", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreiadoa3b3hvlzpfliappjvhzoacqst2tnu5x7cjvhwcdjhplqakmmy", + "time": 1682793228 + }, + { + "cid": "bafkreiad7vwyvhxpgy5i6azrynsnu5g2x5ef7iwjafbnnvukkbc7dvygru", + "time": 1682793408 + } + ], + "validationError": false + }, + { + "dpid": "38", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreiagyoholq6ypx4pdby56vfzq7a44q3sn6esvho7wcf6m4eghpcjoa", + "time": 1682813880 + }, + { + "cid": "bafkreiapfszw7l5sysx2hgophrztwyeonpppem2xxwbujhhwa5kipypyky", + "time": 1682814000 + }, + { + "cid": "bafkreiapfszw7l5sysx2hgophrztwyeonpppem2xxwbujhhwa5kipypyky", + "time": 1682822136 + } + ], + "validationError": false + }, + { + "dpid": "39", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreiayluo2hglsq2qfahpzwqopgwaad7bqxma5we6l2bqzs2zfvk6eka", + "time": 1682820648 + }, + { + "cid": "bafkreiayluo2hglsq2qfahpzwqopgwaad7bqxma5we6l2bqzs2zfvk6eka", + "time": 1682821080 + }, + { + "cid": "bafkreiero2ggetbv2g5voe4yg7lr53cl7aocrcdbn5ndz754ani2c4xwye", + "time": 1682849124 + } + ], + "validationError": false + }, + { + "dpid": "40", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreih3uvxd3entelbnsrhijwkperswmy4d27cjvx2fnurjqqjzvp7v54", + "time": 1682821224 + } + ], + "validationError": false + }, + { + "dpid": "41", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreihesv24wbwkhgjeplqi7lu2rm5d75o6es3krxbj4rfmhk3bcxavhe", + "time": 1682854224 + }, + { + "cid": "bafkreifmd5ucm3ypfkph7klhghsgyvfinkrwxw6uuiwpdjoarmxotflwaa", + "time": 1682854344 + } + ], + "validationError": false + }, + { + "dpid": "42", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreie46ed23xpsfgxasdbhzq4zrni5v4dv3lbohasnqkgmohq4g6bjam", + "time": 1682856480 + } + ], + "validationError": false + }, + { + "dpid": "43", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreigumcdo4dafutywplrgg7xgo6swf2qygljyzwktsafuhvednvpmhy", + "time": 1682951112 + } + ], + "validationError": false + }, + { + "dpid": "44", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreihqpbdqrgnp6mebwfcqqt3izgreiw4zgiw42zmkezipmktv777itu", + "time": 1682962248 + } + ], + "validationError": false + }, + { + "dpid": "45", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreihfrfianmcigzvnnetxkzwlcgza75dsah7ab5anx43phu3mke3uky", + "time": 1682993892 + } + ], + "validationError": false + }, + { + "dpid": "46", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreia2nvcwknooiu6t6ywob4dhd6exb3aamogse4n7kkydybjaugdr6u", + "time": 1683053508 + }, + { + "cid": "bafkreih5koqw5nvxucidlihwfslknj674oeuroclit74rkaqpe4mq6xuka", + "time": 1683222132 + }, + { + "cid": "bafkreif3d644utirvwvkmukcrhg64palp3r4xociwsn6b6o2hxmkdxalby", + "time": 1683227616 + }, + { + "cid": "bafkreibn3jhdlsdsonv25t7i2bwtrbkl3jzwjbnnwylpeih3jmmzdhsfmi", + "time": 1683298680 + }, + { + "cid": "bafkreiepot62powegf7tt73gyiz24facsdloywggattt2asz5y4eaqhkyi", + "time": 1683299940 + }, + { + "cid": "bafkreihge5qw7sc3mqc4wkf4cgpv6udtvrgipfxwyph7dhlyu6bkkt7tfq", + "time": 1705420740 + } + ], + "validationError": false + }, + { + "dpid": "47", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreia7orsrr4pwxe5m2gnklknpc25kjs7gnzemofki3aeh6ydh4hkfju", + "time": 1683222948 + } + ], + "validationError": false + }, + { + "dpid": "48", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreieahbi5tzb2od7nb2j5up4ooiglvh2lty2bgcrwjc3km7fnsplaxu", + "time": 1683232692 + } + ], + "validationError": false + }, + { + "dpid": "49", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreiet6onaozwmqyflpbjsa7f6f5jkhou5n3vxxkxmkgalhnr54bzftu", + "time": 1683236460 + }, + { + "cid": "bafkreibp3hplo3b2hfetbrargv2gv2dkx3kfqfsqbxhkuved2k2nebxcpa", + "time": 1683236760 + }, + { + "cid": "bafkreigym3lzf2ruzd3r23mflxjzafqfxoi5bncru3t4ky35vfaubbke34", + "time": 1683236760 + }, + { + "cid": "bafkreife4uk2mkecur54sq774ybtrka5l4gd5777j5cjjscfmx4vcqnfbm", + "time": 1683237288 + } + ], + "validationError": false + }, + { + "dpid": "50", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreibroag6m5tps4srrtdxbfq74sskvpfu4sbhadhkh3vfonjrlmsvda", + "time": 1683886968 + } + ], + "validationError": false + }, + { + "dpid": "51", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreiheezwrynuxo6gnjd2pmahkcw3wstooxs6fvaflpjouewmh4qi3aa", + "time": 1683930000 + }, + { + "cid": "bafkreiasjo5wzkkk2s56tvdkmbe56vj4j7gyq345vnqpwvnvwozzhtkxfq", + "time": 1683931428 + } + ], + "validationError": false + }, + { + "dpid": "52", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreicxw5tzwajvwa757ihut3hvlgnfbpu7fa4oxfvvlssu4rikfrtmv4", + "time": 1684412244 + } + ], + "validationError": false + }, + { + "dpid": "53", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreia7yjdhq6tdxjtwyr4ajfhxypq3jxbo5augryzzeos7cqrbyy6jmi", + "time": 1684862784 + }, + { + "cid": "bafkreifutouvscu3pbsaabgxdxqfd6zaphkcuei6i3fibdeefmrh4oujby", + "time": 1686612108 + } + ], + "validationError": false + }, + { + "dpid": "54", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreigtfrsogce5ixgj4dvjgvj2qgjsujs5g4sa64svziiyz6j2bajise", + "time": 1685098464 + }, + { + "cid": "bafkreihocw2lexz7nz4sfwmy576guhbecxnzq4wfltnx5twqn2clng3ewu", + "time": 1685098776 + } + ], + "validationError": false + }, + { + "dpid": "55", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreicup2qewrwovkkgk5bun4vpws7cbq3qnv2rbt7truyw54owvtwovm", + "time": 1685442360 + } + ], + "validationError": false + }, + { + "dpid": "56", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreieis5ac2evezkciy26fvswybmyyarfnrlvyh7p5acvbhcsceayorq", + "time": 1685444172 + }, + { + "cid": "bafkreid6ibvbiblu6vviuc3l6ivmpmpdbj2rzt625capmi4igns2r7k4ue", + "time": 1685448060 + } + ], + "validationError": false + }, + { + "dpid": "57", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreiaulqrzufg3qnw55rwzqtn5h2cvsawdunrfwt4j32ywt6oswi5bfm", + "time": 1685525952 + } + ], + "validationError": false + }, + { + "dpid": "58", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreidlxqbem5m3kgtntq6243vujhuyvt2s72ry2k5uy4f6hmjwbezdje", + "time": 1685526132 + }, + { + "cid": "bafkreib2gln7ztcpt6z7q7yo6isznl6lam4zv74hwslwhplh6g55re26lm", + "time": 1685536224 + } + ], + "validationError": false + }, + { + "dpid": "59", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreigj2svt7njv2nxznzm42pisbjgpfjzhoorlcsryjlx5coa2klssku", + "time": 1685613060 + }, + { + "cid": "bafkreigvuao6ogwtnr2oknvxl3a5mtulhats7dqsiuturbxnnablevorai", + "time": 1685613240 + } + ], + "validationError": false + }, + { + "dpid": "60", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreiefsjhlwr6bcq4nscdoz2q2tkca5i7ocxgtn5nxggkf2lr5a2z2lq", + "time": 1685613216 + }, + { + "cid": "bafkreifmohd57nd6xbcjrc3b6dxgpycgijleopks7hrmza4t23dvqxd2au", + "time": 1685613708 + } + ], + "validationError": false + }, + { + "dpid": "61", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreid5vwbe6ri74rgtdevbjznreexoedsocftjqgpopx3bih656jwzni", + "time": 1685614104 + } + ], + "validationError": false + }, + { + "dpid": "62", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreiapjbbsrowag6txt3wuilla2vp6dhhijkylklmvdzc4es3qb27buq", + "time": 1685615388 + } + ], + "validationError": false + }, + { + "dpid": "63", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreicjmhgi5sbjvo2i3nzwfkwfmahgipbyq6iasekibgqpl75cdiqdsi", + "time": 1685615724 + } + ], + "validationError": false + }, + { + "dpid": "64", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreib2rkswbatx7qqcnymxcajqrgrywfzlsiischsrfowhbd5vjfskfi", + "time": 1685719428 + } + ], + "validationError": false + }, + { + "dpid": "65", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreifdylfaiep4lc4544mow5aiq4vg37buebiybfx5wyznfi4pov6qri", + "time": 1686220584 + } + ], + "validationError": false + }, + { + "dpid": "66", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreibelil5fgqul2o3chxv7g7xmdqkv2krqkv6r6mdbiw72vcqp4wxky", + "time": 1687805292 + }, + { + "cid": "bafkreiefvtk6gcvlxq3hw3lkxcjjy5aqkaxyu4swucs2wd3imjhi2yfdpm", + "time": 1687805484 + } + ], + "validationError": false + }, + { + "dpid": "67", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreiazlufpwemnsbzscuycou7gi5m7t2p4yxbxvozkvxex47uczuokba", + "time": 1687807524 + }, + { + "cid": "bafkreidupix2c3fizisuv2z6tluypvssf6solprgnmev6ul6vp6dprwop4", + "time": 1687808232 + } + ], + "validationError": false + }, + { + "dpid": "68", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreihakt3w53hwvneg2o3e4xysgegwk5j5rs6mug6ywlwb2bmprm4wzy", + "time": 1687812132 + } + ], + "validationError": false + }, + { + "dpid": "69", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreigfelcudmytsq2s2j4wcy3j7tsyatpnffpcthf6zz7q5wa4snafdm", + "time": 1687812804 + } + ], + "validationError": false + }, + { + "dpid": "70", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreicandi5eh3gwuxwlq6k6fpeuurnbpbx33q3ijndg44go2p5ekni3y", + "time": 1687817568 + } + ], + "validationError": false + }, + { + "dpid": "71", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreibb5g5ujmxeve56ktnuolb7rrncmbgedtrjemeshn6rxbrhn4uepe", + "time": 1688024628 + }, + { + "cid": "bafkreiddtartrk6isrs3j5ltx6nkcv437jsu62vc6ew3cwvxk3msebzg5e", + "time": 1688024676 + } + ], + "validationError": false + }, + { + "dpid": "72", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreicj4c44gghcoy2ztvwe32fmbv7cuvty2hv2y4ndrnd6ghrl3ciaea", + "time": 1688552688 + } + ], + "validationError": false + }, + { + "dpid": "73", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreifdgjfu3g4qddc7g5kvnk3lshkuyfau7o2qle5ut5msptulbxsqme", + "time": 1688720808 + }, + { + "cid": "bafkreifdgjfu3g4qddc7g5kvnk3lshkuyfau7o2qle5ut5msptulbxsqme", + "time": 1689009768 + } + ], + "validationError": false + }, + { + "dpid": "74", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreifqxkjzypbtz7snjp3ghjrv56bd5umihchpwfppnoz67tcmhuq7wi", + "time": 1689041640 + } + ], + "validationError": false + }, + { + "dpid": "75", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreibtsll3aq2bynvlxnqh6nxafzdm4cpiovr3bcncbkzjcy32xalp7i", + "time": 1689294216 + } + ], + "validationError": false + }, + { + "dpid": "76", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreiatjdpouudloenzdzb7d3e5pogruvwbhurcnm2g5h64jmkpk2uebe", + "time": 1689518988 + }, + { + "cid": "bafkreigg3xk6ojueylnninvwsrw62nqpt7pyjnz6thaipbydb5ltclctly", + "time": 1692182952 + }, + { + "cid": "bafkreicrggm7jpxgaj2vgydvefuravrs2bh4emlt6eadx3zsbubtpulmcq", + "time": 1692330000 + }, + { + "cid": "bafkreifgfzjltrvcz3qixyjkiubgms2r3figm37euwxzbi6pvej2me6tje", + "time": 1701997248 + }, + { + "cid": "bafkreic4wiuatha4wclfbwft4vaeeqifrbb2f3tqm4eoajommogudbvswu", + "time": 1702000140 + }, + { + "cid": "bafkreicraffpobz3k5rzdmigl5tzklihwuim4kwe7xl5uulmfrkr4uvm2u", + "time": 1702045680 + }, + { + "cid": "bafkreidtkraxowlx26oz5g6qyfuawhx5nroil4a4mo6ywa7knfel7ft2dq", + "time": 1702045944 + } + ], + "validationError": false + }, + { + "dpid": "77", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreiaqxrcrai2j2lpk2moare5abq4vtyhxk6m5jxo5fbqkrsy24kdm7q", + "time": 1691492520 + }, + { + "cid": "bafkreihjozked2lgpgtdcuvzejanhnm65sccwglgblxfdg3cwi72vlrtvq", + "time": 1691493636 + }, + { + "cid": "bafkreieodz3e4kzbnlg4nka5pwrgafwuuemfuejxqa5dpdaqlgt6bjs7fm", + "time": 1691496348 + } + ], + "validationError": false + }, + { + "dpid": "78", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreifixmk6tierh6qompfouk63r6clg5jbeuvwherrxacq4uoedk4o5q", + "time": 1691501736 + } + ], + "validationError": false + }, + { + "dpid": "79", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreibtuuiejhyxu4zr2od34biucedhlmqdmqem6v2ruqu6ov2kgsfnfa", + "time": 1692472464 + } + ], + "validationError": false + }, + { + "dpid": "80", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreiawwe6os5lxye3hojdmwgcdt4nrs7xwfqy3p3vuv7xolhbnc2nqaq", + "time": 1693245804 + }, + { + "cid": "bafkreichlzplxpphzyoo3mnjg6tm2e4uplpm4d2q667a6dbz6xhctvktai", + "time": 1693246872 + } + ], + "validationError": false + }, + { + "dpid": "81", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreieefydw5dajtfgz5xqecgyyqxt7kzzyibihy4dvnrtwakaahkn34y", + "time": 1693246440 + }, + { + "cid": "bafkreicpdjfhoxg3gyc2xn63ppbxf7a7wvehkl4h34dapqeqekfetwunme", + "time": 1700147784 + } + ], + "validationError": false + }, + { + "dpid": "82", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreicmvrritjqe4eatfkix3k6kgxz7oxlxengyfhg7rkubpagmxymiqa", + "time": 1693247148 + } + ], + "validationError": false + }, + { + "dpid": "83", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreia6ccnzt76b23xkq7slvzxgebltmlkmvcbvr77nzfyca7wpq6qkru", + "time": 1693247616 + }, + { + "cid": "bafkreidrb3cry4mh6fcik54rotatfnz2mapg3olcsxqpodgdbecrh5iu54", + "time": 1700147268 + } + ], + "validationError": false + }, + { + "dpid": "84", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreibgfpmyizfiu6mpmdcn6aqvqrli72za72ccrxsim24nhtfv3cqb7m", + "time": 1693248192 + }, + { + "cid": "bafkreidfksyvtp5vjzoczjupn6h6h72dcr2p2rm63l7l5qwn6sq6d2nyjy", + "time": 1700146980 + } + ], + "validationError": false + }, + { + "dpid": "85", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreichgcyenem343rn3cgpyymyicdgoe7vgkev7z7bccskncaux7rxt4", + "time": 1693248672 + }, + { + "cid": "bafkreiejwrzg3vtvrvxm75dzgmk3736v4wrhl6uin64hzq76oekbkqi2ci", + "time": 1700146392 + } + ], + "validationError": false + }, + { + "dpid": "86", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreihxqrtbvhxg3w2nu3ahpcu2it6qvnmca4xb72vq4w27er3v4rsjgi", + "time": 1693249560 + }, + { + "cid": "bafkreidlqc6jfns3ftpxoopx7etmfqp75xwoptd6es36xir2fl4nkvmx6i", + "time": 1700145552 + } + ], + "validationError": false + }, + { + "dpid": "87", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreidlb227q7gvv622itmewvsdli726msbjgtsoufaepsaajrc66d27u", + "time": 1693249908 + }, + { + "cid": "bafkreibaiviks6ed4yuwaidz4zzerlhmlkbdcxucky74ah4nu37cm443lm", + "time": 1700146176 + } + ], + "validationError": false + }, + { + "dpid": "88", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreibdpyr6vlsifgi3cebv7ip26ynplllfzpekxz4zfj7xna7uolpjgy", + "time": 1693250244 + }, + { + "cid": "bafkreif7e3nkqyrpa6pkhlnv7sdrwkgyct7fhgzqsteo457kpa46wuflhe", + "time": 1700146776 + } + ], + "validationError": false + }, + { + "dpid": "89", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreidp3ed42l6cizgero5c7zfmxpmwp5hkc4tx6uz7mgioxsep4wb6rm", + "time": 1693251900 + } + ], + "validationError": false + }, + { + "dpid": "90", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreiaw34rnu36p2ccawj3gopyxgl64qj3dc3ip3pzvfh5anzrvmu4z5u", + "time": 1694114940 + }, + { + "cid": "bafkreidk7ihar3swjjf46wtttjl52govxa256725urm5upcefu4wfvnxpm", + "time": 1694187648 + }, + { + "cid": "bafkreic6n2x6jlvss4iepnkkb4o4wre4nezbbff7kw46mz2egtzxast5xe", + "time": 1695653376 + } + ], + "validationError": false + }, + { + "dpid": "91", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreigpcnierfxljhffgj4d6oyuwec4pcbkbjys6goaggw75rcobd6vnu", + "time": 1694197140 + }, + { + "cid": "bafkreidtiuwpwyewgjp3r5a7shvzgir7pvbeguxlv6zebpdbxrraialhxu", + "time": 1695653220 + } + ], + "validationError": false + }, + { + "dpid": "92", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreicqezpklsjtuszjnsekc2dcyadgtbcfouhlc57vclrwco45gzbul4", + "time": 1695218412 + } + ], + "validationError": false + }, + { + "dpid": "93", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreie2p56t2d3i762v3bow3jweile6fmryt2qlcjq3cmkz7kpqtaic2a", + "time": 1695246144 + } + ], + "validationError": false + }, + { + "dpid": "94", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreiaqnt5raa6b4ujpkgd4veg73rtp5csn6fwxrckbhq4mkrl7ws63dy", + "time": 1695246324 + } + ], + "validationError": false + }, + { + "dpid": "95", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreied6xbi65zwpzqiiaqnhq3cdq42c7yqrx6sd32ncv6avkovcb6f6y", + "time": 1695324696 + } + ], + "validationError": false + }, + { + "dpid": "96", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreigurq54verb4sihjuonnx2pbo77lbjlviol2jfjxxgyzzko7o42ka", + "time": 1695816576 + } + ], + "validationError": false + }, + { + "dpid": "97", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreig76u6of7za2h5pdphz2ztsl5xdsgg2vrsh2dximjx3q2aszfjq6m", + "time": 1696295376 + }, + { + "cid": "bafkreig76u6of7za2h5pdphz2ztsl5xdsgg2vrsh2dximjx3q2aszfjq6m", + "time": 1696296012 + }, + { + "cid": "bafkreigul3gpywn3nes5jjxsh2ddfue4lg37ftg7sdqctmzxqp7cxdw3iy", + "time": 1696299000 + }, + { + "cid": "bafkreigul3gpywn3nes5jjxsh2ddfue4lg37ftg7sdqctmzxqp7cxdw3iy", + "time": 1696299600 + }, + { + "cid": "bafkreigul3gpywn3nes5jjxsh2ddfue4lg37ftg7sdqctmzxqp7cxdw3iy", + "time": 1696299876 + }, + { + "cid": "bafkreigul3gpywn3nes5jjxsh2ddfue4lg37ftg7sdqctmzxqp7cxdw3iy", + "time": 1696299912 + }, + { + "cid": "bafkreigul3gpywn3nes5jjxsh2ddfue4lg37ftg7sdqctmzxqp7cxdw3iy", + "time": 1696299996 + }, + { + "cid": "bafkreigul3gpywn3nes5jjxsh2ddfue4lg37ftg7sdqctmzxqp7cxdw3iy", + "time": 1696440036 + }, + { + "cid": "bafkreigul3gpywn3nes5jjxsh2ddfue4lg37ftg7sdqctmzxqp7cxdw3iy", + "time": 1696440996 + }, + { + "cid": "bafkreifcfaudesj7f5jxjn3fecovikw6khhvvspxhc4b5rca6swcdvhdca", + "time": 1696459560 + }, + { + "cid": "bafkreifcfaudesj7f5jxjn3fecovikw6khhvvspxhc4b5rca6swcdvhdca", + "time": 1696459584 + }, + { + "cid": "bafkreifcfaudesj7f5jxjn3fecovikw6khhvvspxhc4b5rca6swcdvhdca", + "time": 1696466724 + }, + { + "cid": "bafkreifcfaudesj7f5jxjn3fecovikw6khhvvspxhc4b5rca6swcdvhdca", + "time": 1696466820 + }, + { + "cid": "bafkreifcfaudesj7f5jxjn3fecovikw6khhvvspxhc4b5rca6swcdvhdca", + "time": 1696466964 + }, + { + "cid": "bafkreifcfaudesj7f5jxjn3fecovikw6khhvvspxhc4b5rca6swcdvhdca", + "time": 1696468416 + }, + { + "cid": "bafkreifcfaudesj7f5jxjn3fecovikw6khhvvspxhc4b5rca6swcdvhdca", + "time": 1696479552 + }, + { + "cid": "bafkreifcfaudesj7f5jxjn3fecovikw6khhvvspxhc4b5rca6swcdvhdca", + "time": 1696480608 + }, + { + "cid": "bafkreifcfaudesj7f5jxjn3fecovikw6khhvvspxhc4b5rca6swcdvhdca", + "time": 1696480764 + }, + { + "cid": "bafkreifcfaudesj7f5jxjn3fecovikw6khhvvspxhc4b5rca6swcdvhdca", + "time": 1696480884 + }, + { + "cid": "bafkreifcfaudesj7f5jxjn3fecovikw6khhvvspxhc4b5rca6swcdvhdca", + "time": 1696481172 + }, + { + "cid": "bafkreiciddswj3e6ho5of7x7a7liaqehnwqeg35w3cp3l5knv6k2tdlswa", + "time": 1696594740 + } + ], + "validationError": false + }, + { + "dpid": "98", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreicsn4qia64pf7eim7sjggvmnggqadmfmrrcm5gecbpfdzxwzlk7i4", + "time": 1696303560 + }, + { + "cid": "bafkreicsn4qia64pf7eim7sjggvmnggqadmfmrrcm5gecbpfdzxwzlk7i4", + "time": 1696303944 + } + ], + "validationError": false + }, + { + "dpid": "99", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreibx7segie7e5ttf2x4j3vuarqbsjfrnakn6srf6myqadz3kbimqhe", + "time": 1696336296 + }, + { + "cid": "bafkreibx7segie7e5ttf2x4j3vuarqbsjfrnakn6srf6myqadz3kbimqhe", + "time": 1696469268 + }, + { + "cid": "bafkreibx7segie7e5ttf2x4j3vuarqbsjfrnakn6srf6myqadz3kbimqhe", + "time": 1696536756 + }, + { + "cid": "bafkreibx7segie7e5ttf2x4j3vuarqbsjfrnakn6srf6myqadz3kbimqhe", + "time": 1696536804 + }, + { + "cid": "bafkreibx7segie7e5ttf2x4j3vuarqbsjfrnakn6srf6myqadz3kbimqhe", + "time": 1696536828 + }, + { + "cid": "bafkreibx7segie7e5ttf2x4j3vuarqbsjfrnakn6srf6myqadz3kbimqhe", + "time": 1696536888 + }, + { + "cid": "bafkreibx7segie7e5ttf2x4j3vuarqbsjfrnakn6srf6myqadz3kbimqhe", + "time": 1696536912 + }, + { + "cid": "bafkreibx7segie7e5ttf2x4j3vuarqbsjfrnakn6srf6myqadz3kbimqhe", + "time": 1696536936 + }, + { + "cid": "bafkreibx7segie7e5ttf2x4j3vuarqbsjfrnakn6srf6myqadz3kbimqhe", + "time": 1696536972 + } + ], + "validationError": false + }, + { + "dpid": "100", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreib2fs7g7yawpqeyjzatsv3bip5p6xr27pnblzjase3zyr4ixtbu6a", + "time": 1696506528 + }, + { + "cid": "bafkreihirj6fsasmvqmzngnyqitl6fpt3ljapgwx7dpfelgvruqsu7smw4", + "time": 1696507296 + }, + { + "cid": "bafkreid5osij2amlc67sm7uzqp22j7y3dn6lseyuy72oh64z5rqoh5qity", + "time": 1696840824 + } + ], + "validationError": false + }, + { + "dpid": "101", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreiaoby2dmz4sljyhxsizjj2yd2jvbzz2vsywii3vp6xqi4rjefxl4q", + "time": 1696589760 + } + ], + "validationError": false + }, + { + "dpid": "102", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreiceiefmvnwozgtpvvwv5exwsdxm36yl5ovunmcnjx5kjtcqvm6lwe", + "time": 1696605300 + } + ], + "validationError": false + }, + { + "dpid": "103", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreif6p22atw6ekbaxkrnfmetfdqtnhldaqw6qtqiqc7lqbus6aizru4", + "time": 1696841976 + } + ], + "validationError": false + }, + { + "dpid": "104", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreiautwruptenrd4xbq5actpbmirrxprmnnxyxf37ixblmcynebjaqq", + "time": 1696842144 + }, + { + "cid": "bafkreie37zoipwpgqrupcmxfnhqfqpztumhcurzb27rfasa5ipao32w3ia", + "time": 1697792352 + }, + { + "cid": "bafkreiebcm7batu7zyp4aw6pzisbkldtlqsghh5jhczhkh63lxgjxp5wte", + "time": 1698779592 + } + ], + "validationError": false + }, + { + "dpid": "105", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreig33qp67gaov32ibvtb5gqtcnfrntrsrbzst2lcgrgnkbu4hbtcj4", + "time": 1696842444 + }, + { + "cid": "bafkreig33qp67gaov32ibvtb5gqtcnfrntrsrbzst2lcgrgnkbu4hbtcj4", + "time": 1698911760 + } + ], + "validationError": false + }, + { + "dpid": "106", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreibbbm7623bsdoftewbedqd3peny6zhqpt6tjgx67ouf6hhvbv2idi", + "time": 1696941732 + }, + { + "cid": "bafkreihemsbpld4yuzrn4ckrlriyq5ortlkycxx74ayfugnoce7oetsmam", + "time": 1696942104 + }, + { + "cid": "bafkreic4gpc3k5mrttk57w6k5fvtgvubvh6xfwgmubecx53b55xsxoavxe", + "time": 1696944228 + }, + { + "cid": "bafkreickteh2tt3oy43o42ikwei6tppghmtbkockk22a3niovi57ugor7q", + "time": 1696961232 + } + ], + "validationError": false + }, + { + "dpid": "107", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreicgst5gqckb4bzduzxqhn2v5an2xjnmhv6qwscwtn3gjhuplpv3jm", + "time": 1697040396 + } + ], + "validationError": false + }, + { + "dpid": "108", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreifzh36eve7dsmbebnvxhpalxdgcjcur7anxllzyfwnmetlsvq2f54", + "time": 1697792640 + } + ], + "validationError": false + }, + { + "dpid": "109", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreibiziudxe62de7g443yl453tpnky25ujrcdhuaudtwq7hxrrr6q3m", + "time": 1698054684 + } + ], + "validationError": false + }, + { + "dpid": "110", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreic65maz27f7atu7a4euzl6jv4c2kz66ddvcxuhdajl4i4l27uwwii", + "time": 1698079308 + }, + { + "cid": "bafkreic65maz27f7atu7a4euzl6jv4c2kz66ddvcxuhdajl4i4l27uwwii", + "time": 1698323460 + } + ], + "validationError": false + }, + { + "dpid": "111", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreiejskdyqkcsnvcl6njkivjvptts656x3qvr64nsjdnx6pcn6bdht4", + "time": 1698177444 + }, + { + "cid": "bafkreialaclllbtsaxzdhbbut4mk57xh4r7bsj56cb44fockdxokcznbk4", + "time": 1698178344 + } + ], + "validationError": false + }, + { + "dpid": "112", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreictzmcsbe3bkmb7vyludvy7q37brvsw6q7xayblyn45r23n7ru224", + "time": 1698747720 + }, + { + "cid": "bafkreifpbperacf57typaumiauqsf3kcmljgm7ehu2vjmlflwepddpeth4", + "time": 1698747864 + } + ], + "validationError": false + }, + { + "dpid": "113", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreig2nlksggv4ghb24xw7ng23klrttx3kiu3tdlnsa2gcn2zacpmxa4", + "time": 1698782484 + } + ], + "validationError": false + }, + { + "dpid": "114", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreibsaosbasq6er4o2mkovemlp6tgppyeudue6lsx6dbznba56omd6e", + "time": 1698782652 + } + ], + "validationError": false + }, + { + "dpid": "115", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreiaqt4amqtdha2affz4caq6qrl3uzk4zutwfnzcc6ba5ziw6itc2ty", + "time": 1699355412 + }, + { + "cid": "bafkreichmxylugiwhtrhomfjc7njdmp6isfivmdsflhmuzenzxnyl76m5i", + "time": 1699355784 + } + ], + "validationError": false + }, + { + "dpid": "116", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreid4spqoyg2mk2r7bcju6vkxsgtcx2fl27tyivtvrvnwlqgn26udn4", + "time": 1699608000 + }, + { + "cid": "bafkreiejv6ymnxxum5c67qpkvp2eevgy7rgksq7vhzgyfxg5riwl33lzqe", + "time": 1699887960 + }, + { + "cid": "bafkreibechybrdrnwlsg3unh2pgxg2jgekg653h37e4xzc3wazyzcjzegq", + "time": 1699954776 + } + ], + "validationError": false + }, + { + "dpid": "117", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreiepbbtkhudgspd6dr4rnckaqwdenedehsvppkyakute6z36bplgpy", + "time": 1699954800 + }, + { + "cid": "bafkreids7cf6gagvaxbmammx6ekl4e3xwhcyw33vkqmy5ml2m4epvpjwua", + "time": 1700053860 + } + ], + "validationError": false + }, + { + "dpid": "118", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreihv7uzjstazrksvrdwrt6j3oqiw73oqi2krvwlzojbo5yhrfrpcu4", + "time": 1699979532 + }, + { + "cid": "bafkreifwnjaykar4vdhcpyimr73hklty7nqnm77u37rzmdyhldtlleycfy", + "time": 1702053972 + } + ], + "validationError": false + }, + { + "dpid": "119", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreifisxmqzztc3zgleheiakn4xn5w7ze6ap5iynom46djxue54nvk5i", + "time": 1699983900 + }, + { + "cid": "bafkreihhg6k56gey42vldxac36u3ueleq4nzrm2zw5fxfcdmwcdrfyjpci", + "time": 1699984152 + } + ], + "validationError": false + }, + { + "dpid": "120", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreifonv6z5enzbl44kwvh3i3m5stmagckblhfp4skmilmt72ff3dthe", + "time": 1699984440 + } + ], + "validationError": false + }, + { + "dpid": "121", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreig7g2zbirxw3spdxicv6igvu4t2frzdbipzh4q2lp7a7vzsnktdym", + "time": 1699984896 + } + ], + "validationError": false + }, + { + "dpid": "122", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreidhtfpm7qcv36eklavzuhq7dxbfq7a2o3ovv6q55qubyr7xnvpnm4", + "time": 1700005716 + } + ], + "validationError": false + }, + { + "dpid": "123", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreifuyc6nxavordwnewceq6tdzbzs4u5u7eiohs2lflwabdmhrrcxtm", + "time": 1700006352 + } + ], + "validationError": false + }, + { + "dpid": "124", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreiccwsruwcne5ctm4bdarr6772xgxqdcy3jg66rthmd5iaq2hnexgi", + "time": 1700046408 + }, + { + "cid": "bafkreihi36k65e6jlytud7hcvtxru2xbkphtxbdu3xx2pkm53qwb5mjzge", + "time": 1700046432 + }, + { + "cid": "bafkreiezsp3ibhch3wf4arb4ies65exfex2isowpfsrrlq6pyvatiexr5q", + "time": 1700046552 + } + ], + "validationError": false + }, + { + "dpid": "125", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreidsdl7s6pqakmfhfvcauof7ovylegxa5nwp2dxuxd5rbb27vsk4d4", + "time": 1700057772 + }, + { + "cid": "bafkreidjcemwjx3ljeuja3lety52fksvk2ojukxkxudbnwu7kgse2zz3tm", + "time": 1700058384 + } + ], + "validationError": false + }, + { + "dpid": "126", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreib6z6ysfnyw6k6ly7cpdp7qjcjbbvjoffn4ppiarimmk33sbxuoy4", + "time": 1700059584 + } + ], + "validationError": false + }, + { + "dpid": "127", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreibqnmfw4jhrjk4ggz63kqtti7rzxroutotrrey2j37a3ad2wfuojm", + "time": 1700063400 + }, + { + "cid": "bafkreifgaoapp6ku2zt3awb3svh3ol75stczvu2bon373bit4whaneb2lm", + "time": 1700063832 + }, + { + "cid": "bafkreibbb2gkxihablys2fjtrecr2tvfbujyulblivfqn4jsl6hyx5dghy", + "time": 1708492476 + } + ], + "validationError": false + }, + { + "dpid": "128", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreihjgheci62x27bgduapkcmwbxldpwyk5af5kqvbpq2nmfmtfxdmmm", + "time": 1700063832 + } + ], + "validationError": false + }, + { + "dpid": "129", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreigtnznzipcb6j4ufpnmde3e66pzl53n7etkxjj4waorkc2vfzban4", + "time": 1700754096 + } + ], + "validationError": false + }, + { + "dpid": "130", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreiaiwepaj5h3ueggcvsp7rs6zsu5emvcbxg4aantq43mjrvkb46t5i", + "time": 1701434724 + } + ], + "validationError": false + }, + { + "dpid": "131", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreidw5k6li7ex6goxdky37t6obgd3472rbgygmvu5rnf6iiptrqkmiy", + "time": 1701702708 + }, + { + "cid": "bafkreiaa4eh2bmuwlutgnvnbbd64npfqdlzxzc75li5pzhlmdkrvj5qjrq", + "time": 1701703056 + } + ], + "validationError": false + }, + { + "dpid": "132", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreifqxy2ie6a5gwqwjdrjzpuer3d5dwb4sauljj6coojnzprlvfes2e", + "time": 1701788316 + } + ], + "validationError": false + }, + { + "dpid": "133", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreifyxvaek2nsdtke62wviupn7qqtgzeucrpe5c66lrycvtvestkkau", + "time": 1701795900 + } + ], + "validationError": false + }, + { + "dpid": "134", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreigu4xxysvqtf6cicat3iheugi6g45vsgnptbrht6p6om3txvsttye", + "time": 1701872976 + } + ], + "validationError": false + }, + { + "dpid": "135", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreihf45jsg5rnkpv2mz2wwpf5w3u6ixu765a5hckam3j3fbl5i2tgbq", + "time": 1701875664 + } + ], + "validationError": false + }, + { + "dpid": "136", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreih5g3pbinh264nuwgvsuerueucgpacv5ytill4sbxt7zsexgfntqi", + "time": 1702142316 + }, + { + "cid": "bafkreiaitokvbuwllmihafculxuniwiydtl2cuuuhqbmkuvpk62uuhmu4e", + "time": 1702145736 + }, + { + "cid": "bafkreifyo3tzgp3bp7a7zwxym6lskt567rdvjn4t334dczglkvgbpglla4", + "time": 1702202688 + }, + { + "cid": "bafkreif4yaj5za2adpy3wmklbstwpaciobl3j4uwcwrwcri7bbkcvwik6q", + "time": 1708382904 + } + ], + "validationError": false + }, + { + "dpid": "137", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreiebtockthsjrwsikbjshzdikjsa3j35avolyabw2zl5nxd4np2qa4", + "time": 1702430448 + }, + { + "cid": "bafkreig5muvzq5a5whji264zbzpkd452kqiswo4on3b3waibrwcte6n2jq", + "time": 1702439796 + }, + { + "cid": "bafkreie7zyrvboq3ygb3tm74qkuvbldwq3ocdltnz6lngud3s2fpdaquiy", + "time": 1711224288 + }, + { + "cid": "bafkreie7zyrvboq3ygb3tm74qkuvbldwq3ocdltnz6lngud3s2fpdaquiy", + "time": 1711224408 + } + ], + "validationError": false + }, + { + "dpid": "138", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreiezlcl57kasksq7hwdqxsffpqloek4jbr4vrvausbg6ozsrnwnkfq", + "time": 1702512600 + }, + { + "cid": "bafkreifxevx7yu5noaquu4bojmyl6pubqotkp4wsbjpd6vbz3neuk7nlxu", + "time": 1707153744 + } + ], + "validationError": false + }, + { + "dpid": "139", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreictkrrk3arfcy4rstvjjtpwrw3yf7wdgxepf5z2cmjuiv2igkdlnm", + "time": 1702512876 + } + ], + "validationError": false + }, + { + "dpid": "140", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreibz4nvkwdmqxmtxefklebrqrhbbhias3bvt7moko5jgw6hopkhwga", + "time": 1702513068 + }, + { + "cid": "bafkreifbhbxfm6s6djz5taz5buthqlpy2cruaysfnixojzubwgkprsbq4i", + "time": 1708801020 + } + ], + "validationError": false + }, + { + "dpid": "141", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreifkjw3mjt4ib4dhjjpn2sbv3oqf4c5mcf5n7zlggynvvqlwksdxay", + "time": 1702513164 + }, + { + "cid": "bafkreiabv34brs4dnbivmzfyggc2ryaxs7zlb3x3zh2ynie53suktlitva", + "time": 1708802436 + }, + { + "cid": "bafkreiabv34brs4dnbivmzfyggc2ryaxs7zlb3x3zh2ynie53suktlitva", + "time": 1708802436 + } + ], + "validationError": false + }, + { + "dpid": "142", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreidll4iaylvaplqqqotp3e7bolx3qgqnjkzliplbhdz7v7dcrdn65q", + "time": 1702513344 + }, + { + "cid": "bafkreieszmyc5ph43ft77gk4pj5emhuy53if6vjbeejzxbrtusxb3ouq54", + "time": 1708802160 + } + ], + "validationError": false + }, + { + "dpid": "143", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreidjonu3vhm5vd5fogs3zrjzq3qcajjkpvwwj43gdqn2swiops5glm", + "time": 1702513392 + }, + { + "cid": "bafkreih25vwbntxxybpsxctpg5eqi6f7ewcwzqzpklifbfqffcrbs65k64", + "time": 1708802052 + } + ], + "validationError": false + }, + { + "dpid": "144", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreieogvypbmg7vgut2f76b33kql6cw4vstzm4f7asoenfzh2rudpekm", + "time": 1702513452 + }, + { + "cid": "bafkreib3b6ztd5tyebhjtxsj4dpl2nw3bipejak5n3zz7u7ta3et2ghyoq", + "time": 1708801908 + } + ], + "validationError": false + }, + { + "dpid": "145", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreibbu3bk7ucli5yaikmcwdduigaien2dqb2bzq4af6ufzrmu6vswty", + "time": 1702513524 + }, + { + "cid": "bafkreig2mtcbf6eu2vraqmy5ftukn4i6fgeiwfou2znswwss5sarsotmcm", + "time": 1708801680 + } + ], + "validationError": false + }, + { + "dpid": "146", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreied3q6xs3itsgvjgeybu5cnmuuds2puklksrhfvy4ofjddo3nkyle", + "time": 1702513584 + } + ], + "validationError": false + }, + { + "dpid": "147", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreiapkcqpkavfwqc4id5mb7e46n3f5nr5uig4ik7bwaxk7a5tox2ztq", + "time": 1702513620 + }, + { + "cid": "bafkreifxvagntjqfpzrigsjfajflqatzk4dogq56lqotaqjv7d3iugdrtm", + "time": 1708801212 + }, + { + "cid": "bafkreifxvagntjqfpzrigsjfajflqatzk4dogq56lqotaqjv7d3iugdrtm", + "time": 1708801236 + } + ], + "validationError": false + }, + { + "dpid": "148", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreibgprhlr22zfwgrm7y3kx4jxslpozqp4pmofsrj5tbqpkaxi5glpe", + "time": 1702559448 + }, + { + "cid": "bafkreieqjqllffddjuraswoq4pm5d5cd5eu2knqe6yie7rj6aufujtct4e", + "time": 1702907160 + } + ], + "validationError": false + }, + { + "dpid": "149", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreigcc2l7aay34i5zeot5wjvpspdpwp6ipfzffs3cnnpbpt7c2gqu6i", + "time": 1703003448 + }, + { + "cid": "bafkreig6lp6265u42llqh6hkzxc54hmyfea7ax7gewg7tdyvthieotmwpy", + "time": 1703003868 + }, + { + "cid": "bafkreici3wzz7njqigyo7ebzwn3kibxgwjr43ihowwebl4exmfy75tkpjm", + "time": 1703072388 + }, + { + "cid": "bafkreicgxdcypaq5tmmrrva3tl7k2un47pfolg3mox72j5k65zitsukfii", + "time": 1707406116 + }, + { + "cid": "bafkreie7j6ji7ynh5d5yoldoxfevak55nkmcx5h7v3c6h4xy7le25sbgke", + "time": 1709143824 + }, + { + "cid": "bafkreic4vm34jfrdp3qu7bx7np3qhvrxlwx5gkn3kf3c4pv6mzbavc3twu", + "time": 1716286500 + }, + { + "cid": "bafkreidsqfd326zx3svaszqm76arwjsonwxpzer24keqt7lv3bpgt5guzu", + "time": 1717067124 + }, + { + "cid": "bafkreid5jzrqitombqlytxoyb36q5avzmxkmxl2nyidtv3pho5godqxbim", + "time": 1717607268 + }, + { + "cid": "bafkreid5jzrqitombqlytxoyb36q5avzmxkmxl2nyidtv3pho5godqxbim", + "time": 1717607316 + } + ], + "validationError": false + }, + { + "dpid": "150", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreif3aoauxavq7sxibkysi4kemqdwbcez4cjtmzoou46bj44r2rc3sa", + "time": 1703205816 + } + ], + "validationError": false + }, + { + "dpid": "151", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreicqe2blgjarm3bg6jon5sjvmu773bnuajfnkmlnvo5hd5uj2yr234", + "time": 1703212224 + } + ], + "validationError": false + }, + { + "dpid": "152", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreifiy2ipxllse5z6kspsspgt247eadivoij736j3yehwe6cy5rn6ny", + "time": 1705091376 + }, + { + "cid": "bafkreihvutuhtiehsoyc66u7a7bncnqfhoosynejagkykkfwa7gkr2rsta", + "time": 1705091496 + }, + { + "cid": "bafkreiekobyktiisailjk2sauqxembzyqe26z7i7mxkl6xidhhlb62wnyi", + "time": 1706832732 + } + ], + "validationError": false + }, + { + "dpid": "153", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreigr54hmercrddm2nnyo46yfn3w466zeoawph7k23swzr5v6lobcjm", + "time": 1705491780 + } + ], + "validationError": false + }, + { + "dpid": "154", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreidzawjc7uaskxy2a55gfd3pjqssl5v6nfqj4ghziglbdfuk3arfri", + "time": 1705579488 + } + ], + "validationError": false + }, + { + "dpid": "155", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreieqqvt2bx34g44zombuj254dzqng5l4bjc33vnuduiaklfjf7jrza", + "time": 1706550924 + }, + { + "cid": "bafkreih4hi7mhwe3uwmf2xa4lfpgmqlt4o5vagzqqr3c54alnnl5wr3r4q", + "time": 1712673828 + }, + { + "cid": "bafkreicamnoitiweehqqlvfa6xmoq7qoooz7kvbuhqy3tdoralmjgwrju4", + "time": 1712674440 + }, + { + "cid": "bafkreidl3wopg6piqc5xba3tvtfcxsvldxcudax4mmwzjtgwsu4hj6t5je", + "time": 1712765676 + } + ], + "validationError": false + }, + { + "dpid": "156", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreibhuuogniwgsozq6zqgpfg622ktaz4e4xtspvxv6be7zoaknlp7oi", + "time": 1706735148 + }, + { + "cid": "bafkreicmyxjhueivvlucnysc5sgmdnxgsmn5wryaodmdwl7xhku5o4dwki", + "time": 1706737632 + } + ], + "validationError": false + }, + { + "dpid": "157", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreificypwhqbtu4acdrxgbzdrpbw5dncxrcwtskrebhv53trsk23ive", + "time": 1706738172 + } + ], + "validationError": false + }, + { + "dpid": "158", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreigmgjpsfxzshdvozllx3m6s5ubiulcx7yumhe7armganzdiu42feu", + "time": 1706834520 + } + ], + "validationError": false + }, + { + "dpid": "159", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreifl7hhai6p5podahrcse5ocklgf2qdayw33raeaugk4cjgugroupq", + "time": 1707473772 + } + ], + "validationError": false + }, + { + "dpid": "160", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreifjtpqkpatgmy4jpmhsepfvpv2gmiofgyh6qpinfnstyrsufickua", + "time": 1707644916 + }, + { + "cid": "bafkreif2hl47drgqwb6qay5dbdmmm4ivbcfus3wromwaho2wxine6niudm", + "time": 1707645552 + }, + { + "cid": "bafkreihopqbkiidgwszltgcx3cp3n5m3vkfcyqf5tktaf7zpikdwqkpkmu", + "time": 1707646572 + }, + { + "cid": "bafkreih7n6cnpgftyn3paqmvvd3bfm7hna7qqgwlqhcpldjtdwabvg5syq", + "time": 1711656132 + } + ], + "validationError": false + }, + { + "dpid": "161", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreialnzhaztvhuvwkzpqlst7w3yttviws5tcpdnwvggdmxnx2ydzere", + "time": 1707848244 + } + ], + "validationError": false + }, + { + "dpid": "162", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreieowcw35rvuvocaupds5fsremm4h6j3cris5sscfjun4o2e4bccla", + "time": 1707967356 + } + ], + "validationError": false + }, + { + "dpid": "163", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreif4554qs4ppds7364pfeqla623ebon5nlvs5m53ecw4jhdkmtnfre", + "time": 1707967740 + } + ], + "validationError": false + }, + { + "dpid": "164", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreidn5fdrmh62nc4r3g5paqija32flksc23evsc5akqoqftkwfeqm2i", + "time": 1708094712 + }, + { + "cid": "bafkreibpaflwrfhygpheciwlemvahtkkwdgg35dnevu25rid46iae2ws6i", + "time": 1708453920 + }, + { + "cid": "bafkreif7javbr3hrnuwmoggv7dtprs7axcsdldsqpwmpfcdizy5bk2tfxa", + "time": 1708514124 + } + ], + "validationError": false + }, + { + "dpid": "165", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreicv2zf35h43m656h2734du5ynp2zctedwxkgwtbhubg34oenhhexa", + "time": 1708109700 + } + ], + "validationError": false + }, + { + "dpid": "166", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreibfvwqckon265lpmjuinzlg6ebzo4s6dtgh7invz2prf766bvuodm", + "time": 1708372176 + } + ], + "validationError": false + }, + { + "dpid": "167", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreige2oxxkk4rboadjcxlvwbvlun3e4xmrxp4qtqvdmjdfzhptuyf5a", + "time": 1708458984 + } + ], + "validationError": false + }, + { + "dpid": "168", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreiftjc6urzlqlcffupjwnezhfash4tlvgy2qnstu2vpp6tdk4zpmma", + "time": 1708493796 + }, + { + "cid": "bafkreic4hj66auaehgtgoz6zzks2w2r7lsxhrisjuh7dbfipvgmkhfpace", + "time": 1708690584 + } + ], + "validationError": false + }, + { + "dpid": "169", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreidguz57tkqtmta44oov6jkgxxeg635asddp2belouydyxjndukspi", + "time": 1708495980 + } + ], + "validationError": false + }, + { + "dpid": "170", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreidyakyvrrmovwk4ddfw2fxtgkl3f4coef75pybncmoa55jnlxx6tm", + "time": 1708501884 + } + ], + "validationError": false + }, + { + "dpid": "171", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreibtajzmf7ty7hhyclz4aj5f74mktbj4liyhobvs3qr7nebqprl2yi", + "time": 1708516896 + } + ], + "validationError": false + }, + { + "dpid": "172", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreicenejlzy2ygk6vflo4xhr7hjqe22nz5f354afoo5pc65d6qf2ojq", + "time": 1708523184 + } + ], + "validationError": false + }, + { + "dpid": "173", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreie23vmvink27bqo7qzzsdng4ho22uhrgoscencr7s4itekrzreahy", + "time": 1708531344 + }, + { + "cid": "bafkreie23vmvink27bqo7qzzsdng4ho22uhrgoscencr7s4itekrzreahy", + "time": 1708531620 + }, + { + "cid": "bafkreie23vmvink27bqo7qzzsdng4ho22uhrgoscencr7s4itekrzreahy", + "time": 1708531992 + }, + { + "cid": "bafkreie23vmvink27bqo7qzzsdng4ho22uhrgoscencr7s4itekrzreahy", + "time": 1708532064 + } + ], + "validationError": false + }, + { + "dpid": "174", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreidobtwdrk7dulyc6dghfr6zylbfisjwbs6l6ahd6qfkfdavs76dpa", + "time": 1708602732 + } + ], + "validationError": false + }, + { + "dpid": "175", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreignopdmerljfo6nzpq2hj5zr5g7h3wajjxthpuikxjpsdbco4tavm", + "time": 1708619376 + }, + { + "cid": "bafkreiae65pw54dt5vx75oenehagushpi2sh42c3zqld7der3ircmfyqam", + "time": 1708653516 + }, + { + "cid": "bafkreihm7iuibrdzlr5uyrhhkyijboyheeujettcihcgmegrna43mmvs6a", + "time": 1708672332 + }, + { + "cid": "bafkreicjzr7d4odl6dzvx3acnng3cwq5sptcjn5wbqeep4juymadohagfi", + "time": 1708674912 + }, + { + "cid": "bafkreihdgbp3rrimo3sfayouabpfy5awspr6lues5rj5pjld2mcwi5ftsm", + "time": 1708729500 + }, + { + "cid": "bafkreidpouvko3ht6dkhplrx44r4cbycx4irvw6mnunven3x2mll5kgaie", + "time": 1708890600 + } + ], + "validationError": false + }, + { + "dpid": "176", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreidwx6vv43n4vyd2gvnc7a7hoalg3nj6ncuxtzete7bay6lgkdjrji", + "time": 1708695348 + }, + { + "cid": "bafkreibjcr22ex3uibpoxf3fpzriafscmbivizzkqrjx7iqh5qbkg4oizq", + "time": 1708695612 + } + ], + "validationError": false + }, + { + "dpid": "177", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreihnul5baol6hg5vsq6sokqwbm5txyb5honlphs3rpjklc4d7pj4qi", + "time": 1708882260 + } + ], + "validationError": false + }, + { + "dpid": "178", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreibnvu2kmntm4p2ttebfqukas5hdzzthyahkkgxizihb4f3fwvszoy", + "time": 1708900272 + }, + { + "cid": "bafkreibax2nwfvcmewzi4muxbtywulni6zvvihnipob3hvweohuu3lmawu", + "time": 1708900680 + }, + { + "cid": "bafkreiaicia5j7xdpo5gr3nukomg7kylxpnyfiguflr7ff5z6v45rbg3om", + "time": 1708909188 + } + ], + "validationError": false + }, + { + "dpid": "179", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreiekmumtbr6fg6ksitwx3744knbituhthjis3mnd5facdbqc6526fy", + "time": 1708930572 + } + ], + "validationError": false + }, + { + "dpid": "180", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreihyn2pm7mqzcjabytkoszcetquu4q6zouwaeqhp6bavvlmijqvj2m", + "time": 1708965960 + }, + { + "cid": "bafkreigksvcw5f67h2kzbxnndwf47ch74nb4vbniepacjt6y5nm74ote4m", + "time": 1708966848 + }, + { + "cid": "bafkreifhzq76yqo66hcvcj2e7554odbcppblavfrobmyuxynaj2wv2ydlm", + "time": 1708974048 + } + ], + "validationError": false + }, + { + "dpid": "181", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreieqzlofquf3yakkfcqwzzg77ea6qrirnbli6iedpeo5zk2hktedfe", + "time": 1709032560 + } + ], + "validationError": false + }, + { + "dpid": "182", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreidjaowinhp5e3m6ikq32mfgqg5mqw6ttzccngl5aa2imyryscenjq", + "time": 1709070444 + }, + { + "cid": "bafkreidjaowinhp5e3m6ikq32mfgqg5mqw6ttzccngl5aa2imyryscenjq", + "time": 1709070600 + } + ], + "validationError": false + }, + { + "dpid": "183", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreihfy4ibvcrdxlq3n6y6ahskxglvyhskwugy7xwi4amk4dcek7hvvi", + "time": 1709074644 + } + ], + "validationError": false + }, + { + "dpid": "184", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreif4pg7ph3qxuj4yoapw4tez3jxt52m5fhp7nkd3q2ai4xrwva46oq", + "time": 1709709132 + } + ], + "validationError": false + }, + { + "dpid": "185", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreibbt24dc64gwzwhcjtyha5qsdvmj4ztlkbhg7p7s74hjpdlrveo5a", + "time": 1709710296 + } + ], + "validationError": false + }, + { + "dpid": "186", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreiezmycqcs3426uhlpamwfidxlt72njmc22cuma47fxx5e3oi7zrpq", + "time": 1709713596 + } + ], + "validationError": false + }, + { + "dpid": "187", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreiemcbfxzi5v3sjiztw4zqs7ngbbirmbcza2sxag4ur4gx3jc57weu", + "time": 1709713968 + } + ], + "validationError": false + }, + { + "dpid": "188", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreifc7blw4sfdrqqyinooyk2zajg4kvobazfpxmmyxhky67xyrtg2bi", + "time": 1709717856 + } + ], + "validationError": false + }, + { + "dpid": "189", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreib5w5wqatnhuuekzdmqe33ci4jmczwtcw235mdugsk6sbjkewhycq", + "time": 1709718156 + } + ], + "validationError": false + }, + { + "dpid": "190", + "owner": "0xF0C6957a0CaFf18D4a18E1CE99b769d20026685e", + "versions": [ + { + "cid": "bafkreidlwnin6u3lbb5me7gsaomtrz3xfxruteb3oqvng2isup6dq2md2u", + "time": 1710044316 + } + ], + "validationError": false + }, + { + "dpid": "191", + "owner": "0xec29aCa1a8740B8C5e2e06EBB52290700B9a2c40", + "versions": [ + { + "cid": "bafkreiekjqv27pmrf3tk6tn4mimvbivhtln7jefgjmzeui6vm43oes2giy", + "time": 1711113468 + }, + { + "cid": "bafkreiekjqv27pmrf3tk6tn4mimvbivhtln7jefgjmzeui6vm43oes2giy", + "time": 1711115796 + }, + { + "cid": "bafkreiekjqv27pmrf3tk6tn4mimvbivhtln7jefgjmzeui6vm43oes2giy", + "time": 1711118604 + } + ], + "validationError": false + }, + { + "dpid": "192", + "owner": "0x955bcC4a744f7a63c064bcDCb41d3da32ab59fA2", + "versions": [ + { + "cid": "bafkreif7cyujbmdodoxfmvwg7vtllo57eqyl4jqx2ldugcdgbn4l37aide", + "time": 1711224600 + } + ], + "validationError": false + }, + { + "dpid": "193", + "owner": "0xBaf4a58783150abaAec703E43e6cca151D4Ff475", + "versions": [ + { + "cid": "bafkreifxdilgiuozcbyxrbmyij3rh5a75br7ree7finitlfgpdgsuovbu4", + "time": 1711371324 + } + ], + "validationError": false + }, + { + "dpid": "194", + "owner": "0xBaf4a58783150abaAec703E43e6cca151D4Ff475", + "versions": [ + { + "cid": "bafkreibir2ytu4y3ckuntnyq4bd2hn7e7v4st4qznhmymulunoag6htkli", + "time": 1711371840 + } + ], + "validationError": false + }, + { + "dpid": "195", + "owner": "0xBaf4a58783150abaAec703E43e6cca151D4Ff475", + "versions": [ + { + "cid": "bafkreibwwiqyfdk57mulox3kkndbjzrpauwifhjlx4a5mcd3xyghi3phnm", + "time": 1711372188 + }, + { + "cid": "bafkreibwwiqyfdk57mulox3kkndbjzrpauwifhjlx4a5mcd3xyghi3phnm", + "time": 1711372224 + } + ], + "validationError": false + }, + { + "dpid": "196", + "owner": "0xBaf4a58783150abaAec703E43e6cca151D4Ff475", + "versions": [ + { + "cid": "bafkreib2bldqjixzqdxfgawln7nkmho7au4cu4vpp3luyziih6i5v24fyu", + "time": 1711372332 + } + ], + "validationError": false + }, + { + "dpid": "197", + "owner": "0xBaf4a58783150abaAec703E43e6cca151D4Ff475", + "versions": [ + { + "cid": "bafkreibckw6mcb7w6ocnrftdcj5ua2ynp44athn37uj5a2luejt4sbag74", + "time": 1711372704 + } + ], + "validationError": false + }, + { + "dpid": "198", + "owner": "0xBaf4a58783150abaAec703E43e6cca151D4Ff475", + "versions": [ + { + "cid": "bafkreig2oyjlgt2tm5o5w66lroxithj2yyokcgiirlqgtxi2rx5fmcnl3u", + "time": 1711373136 + } + ], + "validationError": false + }, + { + "dpid": "199", + "owner": "0xBaf4a58783150abaAec703E43e6cca151D4Ff475", + "versions": [ + { + "cid": "bafkreia6bshsvigqmwl6gczqkekbe6n5vrm5oqk4mlpqxzuqvm6pnvcz4u", + "time": 1711373508 + } + ], + "validationError": false + }, + { + "dpid": "200", + "owner": "0xBaf4a58783150abaAec703E43e6cca151D4Ff475", + "versions": [ + { + "cid": "bafkreiaj3hoxxa6ejl6wbbxmj5yyvwgjbxqcwvutbuffjdmz6bjo4aeuua", + "time": 1711373664 + }, + { + "cid": "bafkreihuphbjewu6gy7bhu3pojq4wzauo4eysrjwf2yjqxauakfm2oycwa", + "time": 1711895628 + } + ], + "validationError": false + }, + { + "dpid": "201", + "owner": "0xBaf4a58783150abaAec703E43e6cca151D4Ff475", + "versions": [ + { + "cid": "bafkreib75qhje5orxp6x73krgk4gxs4zjma235jakvaz7nmjmidxotqvay", + "time": 1711373808 + }, + { + "cid": "bafkreidfhctv5tsybphthhsi64pvjtnfqal6u4yio7ntuossddyoeqktle", + "time": 1711895736 + } + ], + "validationError": false + }, + { + "dpid": "202", + "owner": "0x93aF2e3057F7A1dEec2bEDaB92014372529917b2", + "versions": [ + { + "cid": "bafkreihw7nmfo37bcnovdiuarejedgnesfbjcrx6yfylnapsruv3cxmwca", + "time": 1711379508 + }, + { + "cid": "bafkreig7tkfx63cprx4p62exwlob3fdpnbz67732yivzjvvp4upvqvtaue", + "time": 1711388652 + }, + { + "cid": "bafkreiefzc365jagtqbqlay6enzcetdqntxmpnamknxvub523cbqe5vhii", + "time": 1711535616 + } + ], + "validationError": false + }, + { + "dpid": "203", + "owner": "0x711E9b9e8aD75CBD3AC024a8e4Aeeff59AfBae6c", + "versions": [ + { + "cid": "bafkreicatliyp3ucb74vsyjutro5gj3f4ido7g2g3lpqq44mejhnft4nhe", + "time": 1711480872 + } + ], + "validationError": false + }, + { + "dpid": "204", + "owner": "0x711E9b9e8aD75CBD3AC024a8e4Aeeff59AfBae6c", + "versions": [ + { + "cid": "bafkreihzsc3ukfifnwrn2pwbi7nslahwducpjpanw6whgnmlqrzmzudboa", + "time": 1711483248 + } + ], + "validationError": false + }, + { + "dpid": "205", + "owner": "0x711E9b9e8aD75CBD3AC024a8e4Aeeff59AfBae6c", + "versions": [ + { + "cid": "bafkreib72txikuh4u63nb3jtsxj4r3q7cdeaaq7lzwejqjchminj7smhhu", + "time": 1711484040 + } + ], + "validationError": false + }, + { + "dpid": "206", + "owner": "0xDAF8752DDcCE8a6B709aa271e7Efc60F75CDDF64", + "versions": [ + { + "cid": "bafkreigwpvacu6jfho5bn3dh6kddxjxcz3tmp5ukglfds2vgqbetburmyu", + "time": 1711485180 + } + ], + "validationError": false + }, + { + "dpid": "207", + "owner": "0x3946A420ac849229918AE4C27e4CED2299646b03", + "versions": [ + { + "cid": "bafkreif5vmdusp7spdvopv6gtiaywnxf566hvxqj4y5xajxslad5hjoomq", + "time": 1712129772 + }, + { + "cid": "bafkreianwyrn4e57d5ebpnrxnxnwc7j7t6x7sbm3tyib7gzu4dugt23qlu", + "time": 1712130636 + }, + { + "cid": "bafkreihn7si3rxrrgwie53k4w4nuaztmq3eajbvv2gdesfos3bgpdjgl2i", + "time": 1712134152 + }, + { + "cid": "bafkreiawd2bsrkwxrsqfsxuxgxbilgs3zzbosdruplsklludfmuprszgli", + "time": 1712143392 + }, + { + "cid": "bafkreiggmuv3uk6ndhpnwdttis55lvoq5um6bgc3v2drqkxviul6l7wp5i", + "time": 1720800036 + } + ], + "validationError": false + }, + { + "dpid": "208", + "owner": "0xF84bb22037D7977f78FefFBA75D1dda938B73E2e", + "versions": [ + { + "cid": "bafkreicjmmge75m2pcqhi2iiae5ab2byztxbcnyukyljje7s3nefbsmdwe", + "time": 1713698724 + } + ], + "validationError": false + }, + { + "dpid": "209", + "owner": "0xF84bb22037D7977f78FefFBA75D1dda938B73E2e", + "versions": [ + { + "cid": "bafkreidye2q5xg5mqqbfup32fvs7hkg3lpwbcl3kojzu67vmtnavopwrea", + "time": 1714405584 + } + ], + "validationError": false + }, + { + "dpid": "210", + "owner": "0x72Dc927773e3d453Fff9B083C45eBE9d256Db16E", + "versions": [ + { + "cid": "bafkreifbpagid6fj4gp2z3qbynl7w676ulpnv5lqgibhyf6a4ckgdzdt7y", + "time": 1714769952 + } + ], + "validationError": false + }, + { + "dpid": "211", + "owner": "0x9381995264d304e514Ad3Dfe5eF8C79341D1C5b7", + "versions": [ + { + "cid": "bafkreibm2j2doneeuabi6crd3bguaj3ua4c6hpwrtfzje762noq63rkrhy", + "time": 1715358132 + }, + { + "cid": "bafkreibm2j2doneeuabi6crd3bguaj3ua4c6hpwrtfzje762noq63rkrhy", + "time": 1715358684 + }, + { + "cid": "bafkreih3nstwkg6iakafg45kwshw6db4hhshsuhkwruebe5ziydzevmney", + "time": 1715866908 + }, + { + "cid": "bafkreih3nstwkg6iakafg45kwshw6db4hhshsuhkwruebe5ziydzevmney", + "time": 1715868780 + }, + { + "cid": "bafkreih3nstwkg6iakafg45kwshw6db4hhshsuhkwruebe5ziydzevmney", + "time": 1715978748 + }, + { + "cid": "bafkreifgflgcb7ldns2k5eobjqzo566zt4d7hisqzo3tav5flyc7sprpyq", + "time": 1716021840 + } + ], + "validationError": false + }, + { + "dpid": "212", + "owner": "0x48801eB4DD5e49A9849055ddfD2388f704d96701", + "versions": [ + { + "cid": "bafkreic7t74rbgla2l5jv6dafmtccpzqkechgweeyqqs7tsyemvc3jefae", + "time": 1715851488 + } + ], + "validationError": false + }, + { + "dpid": "213", + "owner": "0x08E424b69851b7b210bA3E5E4233Ca6fcc1ADEdb", + "versions": [ + { + "cid": "bafkreiezhimuxptmz5n6yimve6ydawge4ghihw3r7u45ky65c2ryaqqmce", + "time": 1716409680 + }, + { + "cid": "bafkreia6tgjva2f2bgjs4x3w5t53iiauj6c72o3nurztlc5pzcnicuciou", + "time": 1716826812 + } + ], + "validationError": false + }, + { + "dpid": "214", + "owner": "0x0F81A4d0553f09767027B4c15D0C374B939Cd5F1", + "versions": [ + { + "cid": "bafkreih7ayew5fbjl6qswqxhczbnpvjocbrh25sndnausewyvzyqfqfn3i", + "time": 1717068456 + } + ], + "validationError": false + }, + { + "dpid": "215", + "owner": "0xBaf4a58783150abaAec703E43e6cca151D4Ff475", + "versions": [ + { + "cid": "bafkreiamkomiad6wgakicshmb2jbttwkzvl3pvz7dg3dk4limjudjs7fze", + "time": 1719238548 + }, + { + "cid": "bafkreicgr4sw55zkzcvsymlbzuwycyumbaxbddsfs4fmpqgop26ao6kwai", + "time": 1719239016 + }, + { + "cid": "bafkreifwdyyytjgeptaobon4zcagur6kqtozfhj2r3p345bbdk4wisyahy", + "time": 1719495228 + } + ], + "validationError": false + }, + { + "dpid": "216", + "owner": "0xBaf4a58783150abaAec703E43e6cca151D4Ff475", + "versions": [ + { + "cid": "bafkreiahiziyaeq433h3kcujkgiiv5ttk3ouls6clr66o3t6dfaecmjleq", + "time": 1719238956 + }, + { + "cid": "bafkreidanmyotk43oz67oai5fmavt3voi7bhrqa2ppkdevqjd6nig3e5t4", + "time": 1719493716 + } + ], + "validationError": false + }, + { + "dpid": "217", + "owner": "0xBaf4a58783150abaAec703E43e6cca151D4Ff475", + "versions": [ + { + "cid": "bafkreif2l2vqwzocmgmfyy2ejvrqd5uhhrzkqk45hthwcw4mt4oz7i4u7q", + "time": 1719239808 + }, + { + "cid": "bafkreibyobujs3ljgpz6kidhgizhzh3tkwcts3s6526uliej7mu7k5ieei", + "time": 1719495156 + } + ], + "validationError": false + }, + { + "dpid": "218", + "owner": "0xBaf4a58783150abaAec703E43e6cca151D4Ff475", + "versions": [ + { + "cid": "bafkreigldutspcrrahapdsj7sr4zrikxirwsjbqvrcuzlwwyuk2zhtho2e", + "time": 1719240072 + }, + { + "cid": "bafkreib3hywyhrvxw6ylpypft3prqj2hncm633usbaqweithafwe3jvi2i", + "time": 1719495060 + } + ], + "validationError": false + }, + { + "dpid": "219", + "owner": "0xBaf4a58783150abaAec703E43e6cca151D4Ff475", + "versions": [ + { + "cid": "bafkreifkiw3ckd6n6nkzhx3benfz2ct4acqrq3kaepv2dod4b3twwnxsti", + "time": 1719242676 + }, + { + "cid": "bafkreiahnaq2grg2wxie6xjxjhs3mxxefj5juk3sdidd2tqbsxirsbvmvy", + "time": 1719494904 + } + ], + "validationError": false + }, + { + "dpid": "220", + "owner": "0xBaf4a58783150abaAec703E43e6cca151D4Ff475", + "versions": [ + { + "cid": "bafkreift27e5crnj2osffmq6rmbrxaade74cang4gjwwo6eurf5owodm2a", + "time": 1719242796 + }, + { + "cid": "bafkreihipjsqsyjogf77z2wxssqnw5p62yiwcezxytl5psjlg7wjlm2o7e", + "time": 1719494712 + } + ], + "validationError": false + }, + { + "dpid": "221", + "owner": "0xBaf4a58783150abaAec703E43e6cca151D4Ff475", + "versions": [ + { + "cid": "bafkreic6ief4i2lfgi7mz27nqxn7usvs7huh77nmzpactmi63v6dbzv2nq", + "time": 1719243324 + }, + { + "cid": "bafkreia4rjywplbsrr5jc6u4hwcihmyhdvaupfwulzkguepk3tysom4gc4", + "time": 1719494292 + }, + { + "cid": "bafkreih2r7rwkqlqiuvwr6mh34rd5iw6jvxjbgzjkgulygrpzucyrax574", + "time": 1719494592 + } + ], + "validationError": false + }, + { + "dpid": "222", + "owner": "0xBaf4a58783150abaAec703E43e6cca151D4Ff475", + "versions": [ + { + "cid": "bafkreiaurllsr2nc4ejbuq2dc35aftk3din4l7fumw2csslajq43e67tsa", + "time": 1719243792 + }, + { + "cid": "bafkreienghzp4rhpx2debrkbdczjskgsagy6s4rj3ifkoxvwf665xeuoda", + "time": 1719494220 + } + ], + "validationError": false + }, + { + "dpid": "223", + "owner": "0xBaf4a58783150abaAec703E43e6cca151D4Ff475", + "versions": [ + { + "cid": "bafkreig2zp6cnz2sifbdtwliamt2edelxvdioc5bph4pxetkvknfvavfvi", + "time": 1719244032 + }, + { + "cid": "bafkreiazl42wr4sbwqfv5pomstrytrywuugd7no2jjg4db4nk6seaxhj3i", + "time": 1719494136 + } + ], + "validationError": false + }, + { + "dpid": "224", + "owner": "0xBaf4a58783150abaAec703E43e6cca151D4Ff475", + "versions": [ + { + "cid": "bafkreicuitjqpveaxjoqil77g5l2apesvrmowym5p5n4b4xbneh5eonaay", + "time": 1719244260 + }, + { + "cid": "bafkreicyfbgky3jn6uacvq4rxpuxshq4pnp4q5zvti774jxcxbxud3rsq4", + "time": 1719493992 + } + ], + "validationError": false + }, + { + "dpid": "225", + "owner": "0xec29aCa1a8740B8C5e2e06EBB52290700B9a2c40", + "versions": [ + { + "cid": "bafkreigj5nyp6r7mp4s5agcakjvywlha5bx2giq2zlsmu2kgobaazdynsm", + "time": 1720477056 + } + ], + "validationError": false + }, + { + "dpid": "226", + "owner": "0xec29aCa1a8740B8C5e2e06EBB52290700B9a2c40", + "versions": [ + { + "cid": "bafkreieifs7wq7ncnefnatondlbgmrasevdcav2ep2pyyzfiniugvpt5za", + "time": 1720477920 + } + ], + "validationError": false + }, + { + "dpid": "227", + "owner": "0xec29aCa1a8740B8C5e2e06EBB52290700B9a2c40", + "versions": [ + { + "cid": "bafkreifxgx4nqbzerud4vdmkovjfe5zsac6nc2iq5z3v4tkrbobbnwfnsi", + "time": 1720479012 + } + ], + "validationError": false + }, + { + "dpid": "228", + "owner": "0xec29aCa1a8740B8C5e2e06EBB52290700B9a2c40", + "versions": [ + { + "cid": "bafkreiho2ipglkfppftalyrhyfj63a65sw262n3ewsao7lpo26mz6mthzq", + "time": 1720479528 + } + ], + "validationError": false + }, + { + "dpid": "229", + "owner": "0xec29aCa1a8740B8C5e2e06EBB52290700B9a2c40", + "versions": [ + { + "cid": "bafkreigy2hlajf2isrzvczia47pel6cxuqiiqjh4ujniwyqe4xtzymbbdy", + "time": 1720480932 + } + ], + "validationError": false + }, + { + "dpid": "230", + "owner": "0xec29aCa1a8740B8C5e2e06EBB52290700B9a2c40", + "versions": [ + { + "cid": "bafkreig3qftvjkfmq4jk7rsypm7adm7cphe2osfz6oy4z6dvu6lkzxbhyy", + "time": 1720481844 + }, + { + "cid": "bafkreig3qftvjkfmq4jk7rsypm7adm7cphe2osfz6oy4z6dvu6lkzxbhyy", + "time": 1720481904 + } + ], + "validationError": false + }, + { + "dpid": "231", + "owner": "0xec29aCa1a8740B8C5e2e06EBB52290700B9a2c40", + "versions": [ + { + "cid": "bafkreic2jjxgxaynqfopxjwm24buwebpq7isnfz36igifm7bkc6gjohjje", + "time": 1720482384 + } + ], + "validationError": false + }, + { + "dpid": "232", + "owner": "0x7Ec8AFDDE28349671f2ea8B57FaD53e200F301ff", + "versions": [ + { + "cid": "bafkreiez35iuhs7gpr2ky5gmtrjtnz42nz3rvuwpfenxeztcqff5r43bh4", + "time": 1720508196 + }, + { + "cid": "bafkreidscaetshms3qnxppft6cqpoumpwgojpa7p3uew7xyfdomjyz5ole", + "time": 1720508592 + } + ], + "validationError": false + }, + { + "dpid": "233", + "owner": "0x0F81A4d0553f09767027B4c15D0C374B939Cd5F1", + "versions": [ + { + "cid": "bafkreihtajz6kf4lpa5dvxkcq76jxwz2zriobhwxq626bjym62wefclxre", + "time": 1720556076 + } + ], + "validationError": false + }, + { + "dpid": "234", + "owner": "0xec29aCa1a8740B8C5e2e06EBB52290700B9a2c40", + "versions": [ + { + "cid": "bafkreih4l7hom74jktxdlz53fczdz2ndq55k4mc3twnpwfcfsh5eh6inra", + "time": 1720619364 + } + ], + "validationError": false + }, + { + "dpid": "235", + "owner": "0xec29aCa1a8740B8C5e2e06EBB52290700B9a2c40", + "versions": [ + { + "cid": "bafkreidhaox2zpaossjmvjuhjgn5qvoifshwsen37lt6kmxwzrauplbvji", + "time": 1720620312 + } + ], + "validationError": false + }, + { + "dpid": "236", + "owner": "0xec29aCa1a8740B8C5e2e06EBB52290700B9a2c40", + "versions": [ + { + "cid": "bafkreidls5s6z26sdii7b2hpbuaxrrrcooq7meirxsoikv753zs5hkbbr4", + "time": 1720630032 + } + ], + "validationError": false + }, + { + "dpid": "237", + "owner": "0xec29aCa1a8740B8C5e2e06EBB52290700B9a2c40", + "versions": [ + { + "cid": "bafkreic6soeg2nlerfsf75n3ehr2dzcpn5rl3iyecpbv6pdcgcvh3av6ey", + "time": 1720632864 + } + ], + "validationError": false + }, + { + "dpid": "238", + "owner": "0x0F81A4d0553f09767027B4c15D0C374B939Cd5F1", + "versions": [ + { + "cid": "bafkreigzinwo3bxv7jwdh5r6brshvscxklyqi3gapll7ytfo2isqwtszum", + "time": 1720712652 + }, + { + "cid": "bafkreifv32nvd7vdnsonsahzcqu3cibpous7yqgfkrjcp56oqmqz2viayy", + "time": 1720779696 + } + ], + "validationError": false + }, + { + "dpid": "239", + "owner": "0x8AB466539A0d6D4C13dd21cAC63BE7e56AA77203", + "versions": [ + { + "cid": "bafkreibj4lzkysx5poxqnblmw7llxccqetsl6hkwsp3djokuoe4fdkfi2y", + "time": 1720824228 + }, + { + "cid": "bafkreicyfh4xnhodppgb57xjetltjewmqemu34gh7oft4b4qgf6cn5u6ry", + "time": 1722247104 + } + ], + "validationError": false + }, + { + "dpid": "240", + "owner": "0x81A1EA5A462ba21A328d206d4c15A7Af8812ad3c", + "versions": [ + { + "cid": "bafkreie7vwam62su32yyx2fk5z73zzlrhrtkyyg7nmpad3tbcsmu7znvni", + "time": 1721114028 + } + ], + "validationError": false + }, + { + "dpid": "241", + "owner": "0x0F81A4d0553f09767027B4c15D0C374B939Cd5F1", + "versions": [ + { + "cid": "bafkreihtsyrdpbxzlglorp26vtstwd44swdsnnwpfuq2zfk7s5nd75lgki", + "time": 1721133336 + } + ], + "validationError": false + }, + { + "dpid": "242", + "owner": "0xec29aCa1a8740B8C5e2e06EBB52290700B9a2c40", + "versions": [ + { + "cid": "bafkreihmmjbmdi2a2nsh7i5wx64yj23lmwtcsj5tvp5s5vn26jcye7sk4i", + "time": 1721225160 + } + ], + "validationError": false + }, + { + "dpid": "243", + "owner": "0x0F81A4d0553f09767027B4c15D0C374B939Cd5F1", + "versions": [ + { + "cid": "bafkreiebbnincejhfok3ojh3ynpohjgnuczjf3aret4ye3lbn7i4awaede", + "time": 1721389728 + } + ], + "validationError": false + }, + { + "dpid": "244", + "owner": "0x8AB466539A0d6D4C13dd21cAC63BE7e56AA77203", + "versions": [ + { + "cid": "bafkreiei3m5wzddkcvw4ae2w7hrgytfaq6l5iwz5joqlu4uydbg5jt2yw4", + "time": 1721470692 + } + ], + "validationError": false + }, + { + "dpid": "245", + "owner": "0xec29aCa1a8740B8C5e2e06EBB52290700B9a2c40", + "versions": [ + { + "cid": "bafkreiady6yrkve6zryofryqsw3hmfxihtyjetdykpw54r7rqaew45gfum", + "time": 1722248736 + } + ], + "validationError": false + }, + { + "dpid": "246", + "owner": "0xec29aCa1a8740B8C5e2e06EBB52290700B9a2c40", + "versions": [ + { + "cid": "bafkreibhbbtogpv7i2rl2q64wpwaj42lzg23b7fxpmeixh3hblaw6djhki", + "time": 1722604140 + }, + { + "cid": "bafkreihizommq35uxz2kjhchvoqccv2wygtkne37flt46gqo3w66lj3gb4", + "time": 1722604176 + } + ], + "validationError": false + }, + { + "dpid": "247", + "owner": "0x0F81A4d0553f09767027B4c15D0C374B939Cd5F1", + "versions": [ + { + "cid": "bafkreidzb55z7hc3fkusx3mp4flf4vnqdpox6qtu2g7kotx2hkxka23csq", + "time": 1722615504 + }, + { + "cid": "bafkreiewgihawmxepbvqgyeejbdj6jt4ngctjgcxj4gj3lhutjorbvu5yq", + "time": 1722615792 + }, + { + "cid": "bafkreiaizfnyvkio7x5gp6ouxkwii2b5wgcfyoifq63geltx7t54e7v76i", + "time": 1722615960 + }, + { + "cid": "bafkreiczi7o53yitcp6at4as3tf6kybsaijzmiwmchrq3nagoii452giva", + "time": 1723117044 + }, + { + "cid": "bafkreid34dafmffnznmrtzzs6j5syqcpqmexkz6miflrcwpwms3scbkjzi", + "time": 1723117896 + }, + { + "cid": "bafkreiagnknv2rpimw5oifsdi3krjuj4vb44yllgpkzuq4o36e7ptfqvky", + "time": 1723117980 + } + ], + "validationError": false + }, + { + "dpid": "248", + "owner": "0xDd4d86BA6D539E8d8d7A2C03947A34c326A229A1", + "versions": [ + { + "cid": "bafkreibcag5sqogsn2c53dq6gczjwgsssya3n2nleav422kwbutzzes3kq", + "time": 1722625668 + }, + { + "cid": "bafkreidef6dpqp2axnl5ljbt7pj7kga4r6fvdgcm6n5zgyheeaplewl4wy", + "time": 1723734708 + } + ], + "validationError": false + }, + { + "dpid": "249", + "owner": "0x8AB466539A0d6D4C13dd21cAC63BE7e56AA77203", + "versions": [ + { + "cid": "bafkreih7yx4muokp6ubr4yr3nsxys2hvkyple2rephzuta75rpipsvihmq", + "time": 1722902496 + } + ], + "validationError": false + }, + { + "dpid": "250", + "owner": "0x8FeEAAae1DB031E5F980F5E63fDbb277731e500e", + "versions": [ + { + "cid": "bafkreicn4qjzej4zkuny7nx2af4n5gvxmzahave35dr5venluu67c3u6dq", + "time": 1723641024 + }, + { + "cid": "bafkreiaazjxzipoaeds6bep3p2v25vdjxchqoc745wvbk5pmgo4bzssw7i", + "time": 1723641480 + } + ], + "validationError": false + }, + { + "dpid": "251", + "owner": "0x9381995264d304e514Ad3Dfe5eF8C79341D1C5b7", + "versions": [ + { + "cid": "bafkreid3bvy6oziqj2zfeiqfnehdqpuga32qoihjyna66vronfm3bdfgqu", + "time": 1723713348 + }, + { + "cid": "bafkreic5xloudqnuf43koxpjrh2m44hpedj4bfuff7fkhwypqhv6jkhq3a", + "time": 1723713684 + } + ], + "validationError": false + }, + { + "dpid": "252", + "owner": "0x9381995264d304e514Ad3Dfe5eF8C79341D1C5b7", + "versions": [ + { + "cid": "bafkreiaekzuxotos4txt44hpa6q6hdjma6wkxvyeolhugop6tjepiodl6y", + "time": 1723714416 + } + ], + "validationError": false + }, + { + "dpid": "253", + "owner": "0xE862E2C1ca94eAcfEDe3c95a217c15EF0086a29D", + "versions": [ + { + "cid": "bafkreihvzdunfsz72j7omwgiodczdy3dgeefdreheeeky5ylwh7p3fukbm", + "time": 1723714680 + }, + { + "cid": "bafkreidaskevgai2slqseovb44bk6bnw6fzz6epgnrejoluvzyoesajgue", + "time": 1723714764 + }, + { + "cid": "bafkreieopbdp733cjbtm2bfavi6kq55coumdrmoc7bvouk2uqthjvxuapy", + "time": 1723714872 + } + ], + "validationError": false + }, + { + "dpid": "254", + "owner": "0x26c61658d7BE9125bCf5A55b3bE01198bE49f61f", + "versions": [ + { + "cid": "bafkreihsgmtkyfl5x74zn5qdcuwvqvbxuxneiv7gdgsdoysudvv6fvesjy", + "time": 1724164476 + } + ], + "validationError": false + }, + { + "dpid": "255", + "owner": "0xec29aCa1a8740B8C5e2e06EBB52290700B9a2c40", + "versions": [ + { + "cid": "bafkreib6m33xstvn7dzzax4oq4jqgyov65snapnie3weggvebfmmovkgg4", + "time": 1725279660 + } + ], + "validationError": false + }, + { + "dpid": "256", + "owner": "0xec29aCa1a8740B8C5e2e06EBB52290700B9a2c40", + "versions": [ + { + "cid": "bafkreihftqk76djohkehs4ulekkmoxbfjsdzha3dki5dcwpsf3tikwjlhe", + "time": 1725976920 + } + ], + "validationError": false + }, + { + "dpid": "257", + "owner": "0xec29aCa1a8740B8C5e2e06EBB52290700B9a2c40", + "versions": [ + { + "cid": "bafkreibubpwuwyiwfm7nc5fprgnnl6hdeejb7jntx64qsvbnktm3i4t36u", + "time": 1725977004 + } + ], + "validationError": false + }, + { + "dpid": "258", + "owner": "0xec29aCa1a8740B8C5e2e06EBB52290700B9a2c40", + "versions": [ + { + "cid": "bafkreibaq3t5lj5pcx7t6z2x6enrefywmn7ayjcjegpub36zpdhxj4yavy", + "time": 1725977076 + }, + { + "cid": "bafkreiexwmkpzktjhyfln6zilql6jfqz7ksigsxvgk4fdgvggxrdzctcc4", + "time": 1725977220 + } + ], + "validationError": false + }, + { + "dpid": "259", + "owner": "0xec29aCa1a8740B8C5e2e06EBB52290700B9a2c40", + "versions": [ + { + "cid": "bafkreibmeg5cpt5y35skwlnpgxtxjpmvitpqvvcnsturqh7deleluuf6mq", + "time": 1726068540 + } + ], + "validationError": false + }, + { + "dpid": "260", + "owner": "0xec29aCa1a8740B8C5e2e06EBB52290700B9a2c40", + "versions": [ + { + "cid": "bafkreigynm73fvge4cyusgzm3gu5p4zzrs2od77rttk5uiitmg5txsfuim", + "time": 1726068864 + } + ], + "validationError": false + }, + { + "dpid": "261", + "owner": "0x270f0c834A6ceCe776c3b522b6Ac9F40cf57d347", + "versions": [ + { + "cid": "bafkreihfgjlfyafl52p4d3o4w2vj443ufujeidb357pmtaipkqeyrqjvne", + "time": 1726290384 + } + ], + "validationError": false + } +] \ No newline at end of file From c79fd02cc061148fad02c0bbf994568c79f2651e Mon Sep 17 00:00:00 2001 From: kadami <86646883+kadamidev@users.noreply.github.com> Date: Thu, 19 Sep 2024 12:40:13 +0000 Subject: [PATCH 24/81] adjust term query, support nested vals --- desci-server/src/controllers/search/types.ts | 2 +- .../src/services/ElasticSearchService.ts | 26 +++++++++++++++---- 2 files changed, 22 insertions(+), 6 deletions(-) diff --git a/desci-server/src/controllers/search/types.ts b/desci-server/src/controllers/search/types.ts index 1bdcf4ac3..6d565f6bd 100644 --- a/desci-server/src/controllers/search/types.ts +++ b/desci-server/src/controllers/search/types.ts @@ -16,7 +16,7 @@ export type Filter = { fuzziness?: number | 'AUTO'; } & ( | { type: 'range'; operator: ComparisonOperator; value: number | string } - | { type: 'term'; value: string | number | boolean } + | { type: 'term'; value: string | number | boolean | string[] } | { type: 'match'; value: string; matchLogic?: MatchLogic; fuzziness?: number | 'AUTO' } | { type: 'match_phrase'; value: string | string[]; matchLogic?: MatchLogic } | { type: 'exists' } diff --git a/desci-server/src/services/ElasticSearchService.ts b/desci-server/src/services/ElasticSearchService.ts index 95488b02c..492369b8f 100644 --- a/desci-server/src/services/ElasticSearchService.ts +++ b/desci-server/src/services/ElasticSearchService.ts @@ -191,11 +191,27 @@ function buildFilter(filter: Filter) { }, }; case 'term': - return { - term: { - [filter.field]: filter.value, - }, - }; + const termFieldParts = filter.field.split('.'); + const isNested = termFieldParts.length > 1; + const queryType = Array.isArray(filter.value) ? 'terms' : 'term'; + let valFormatted = filter.value; + if (Array.isArray(valFormatted)) { + valFormatted = valFormatted.map((v) => (typeof v === 'string' ? v.toLowerCase() : v)); + } else if (typeof valFormatted === 'string') { + valFormatted = valFormatted.toLowerCase(); + } + + const query = { [queryType]: { [filter.field]: valFormatted } }; + + if (isNested) { + return { + nested: { + path: termFieldParts[0], + query: query, + }, + }; + } + return query; case 'match_phrase': if (Array.isArray(filter.value)) { const queries = filter.value.map((value) => ({ From 9e9a39fc0cf676878a6482f5de8968aaaf830b5c Mon Sep 17 00:00:00 2001 From: m0ar Date: Thu, 19 Sep 2024 17:32:34 +0200 Subject: [PATCH 25/81] nodes-lib: override DID EIP155 namespace in SIWE message to match stream controller --- nodes-lib/package.json | 4 ++-- nodes-lib/src/codex.ts | 25 +++++++++++++++++++++---- nodes-lib/src/util/signing.ts | 4 +++- 3 files changed, 26 insertions(+), 7 deletions(-) diff --git a/nodes-lib/package.json b/nodes-lib/package.json index bd3d3d739..1debe7631 100644 --- a/nodes-lib/package.json +++ b/nodes-lib/package.json @@ -1,6 +1,6 @@ { "name": "@desci-labs/nodes-lib", - "version": "0.0.10", + "version": "0.0.11-rc1", "homepage": "https://github.com/desci-labs/nodes#readme", "description": "Stand-alone client library for interacting with desci-server", "repository": { @@ -49,4 +49,4 @@ "vitest": "^1.2.1", "vitest-github-actions-reporter": "^0.11.1" } -} +} \ No newline at end of file diff --git a/nodes-lib/src/codex.ts b/nodes-lib/src/codex.ts index 848f589ba..6a34fe296 100644 --- a/nodes-lib/src/codex.ts +++ b/nodes-lib/src/codex.ts @@ -40,20 +40,37 @@ export const codexPublish = async ( const ceramic = newCeramicClient(nodeUrl); const compose = newComposeClient({ ceramic }); + const existingStreamID = prepublishResult.ceramicStream; + + let controller: string | undefined; + let controllerChainID: string | undefined; + if (existingStreamID) { + const stream = await ceramic.loadStream(existingStreamID); + controller = stream.state.metadata.controllers[0]; + controllerChainID = controller.match(/eip155:(\d+):/)?.[1] + }; + if (didOrSigner instanceof Signer) { compose.setDID( // Wrangle a DID out of the signer for Ceramic auth - await authorizedSessionDidFromSigner(didOrSigner, compose.resources) + await authorizedSessionDidFromSigner(didOrSigner, compose.resources, controllerChainID) ); } else { + // NOTE: for a signer we can check and pass the controller EIP155 chainID, but we can't edit that if it's a preauthorized DID + if (didOrSigner.parent !== controller) { + console.warn( + `[nodes-lib::codex] DID and controller mismatch, is the chainID set correctly?`, + { didParent: didOrSigner.parent, streamController: controller }, + ); + }; compose.setDID(didOrSigner); }; // If we know about a stream already, let's assume we backfilled it initially - if (prepublishResult.ceramicStream) { - console.log(LOG_CTX, `publishing to known stream ${prepublishResult.ceramicStream}...`); + if (existingStreamID) { + console.log(LOG_CTX, `publishing to known stream ${existingStreamID}...`); const ro = await updateResearchObject(compose, { - id: prepublishResult.ceramicStream, + id: existingStreamID, title: prepublishResult.updatedManifest.title, manifest: prepublishResult.updatedManifestCid, }); diff --git a/nodes-lib/src/util/signing.ts b/nodes-lib/src/util/signing.ts index bd193e6f8..333f5dd8b 100644 --- a/nodes-lib/src/util/signing.ts +++ b/nodes-lib/src/util/signing.ts @@ -66,6 +66,8 @@ const getManualSignatureAuthMethod = ( export const authorizedSessionDidFromSigner = async ( signer: Signer, resources: string[], + /** Force a particular chainID to match controller EIP155 prefix in `dids:validateJWS` */ + chainIdOverride?: string, ) => { // Fuckery to get the inner provider for a metamask signer const externalProvider = (signer.provider as providers.Web3Provider)?.provider; @@ -74,7 +76,7 @@ export const authorizedSessionDidFromSigner = async ( const address = await signer.getAddress(); const network = await jsonRpcProvider.getNetwork(); - const chainId = `eip155:${network.chainId}`; + const chainId = `eip155:${chainIdOverride ?? network.chainId}`; const caipAccountId = new AccountId({ address, chainId }); let authMethod: AuthMethod; From b00e1d81672d00a4f96c6be5d1053855bc221097 Mon Sep 17 00:00:00 2001 From: Sina Iman Date: Fri, 20 Sep 2024 00:34:15 +0200 Subject: [PATCH 26/81] adjust resourcing for repo --- desci-repo/kubernetes/deployment_dev.yaml | 2 +- desci-repo/kubernetes/deployment_prod.yaml | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/desci-repo/kubernetes/deployment_dev.yaml b/desci-repo/kubernetes/deployment_dev.yaml index 376fb2588..da90a38c1 100644 --- a/desci-repo/kubernetes/deployment_dev.yaml +++ b/desci-repo/kubernetes/deployment_dev.yaml @@ -67,7 +67,7 @@ spec: name: ws-api resources: limits: - cpu: '2' + cpu: '4' memory: 16Gi requests: cpu: '1' diff --git a/desci-repo/kubernetes/deployment_prod.yaml b/desci-repo/kubernetes/deployment_prod.yaml index a48e23ca7..799d505d6 100755 --- a/desci-repo/kubernetes/deployment_prod.yaml +++ b/desci-repo/kubernetes/deployment_prod.yaml @@ -68,9 +68,9 @@ spec: name: ws-api resources: limits: - cpu: '2' + cpu: '4' memory: 16Gi requests: - cpu: '1' + cpu: '2' memory: 8Gi serviceAccountName: 'vault-auth' From d3c4daa637f401280acd1d0fdb1a8191ec53a7c4 Mon Sep 17 00:00:00 2001 From: kadami <86646883+kadamidev@users.noreply.github.com> Date: Fri, 20 Sep 2024 20:52:29 +0000 Subject: [PATCH 27/81] fix check on nested fields for filtering --- .../src/services/ElasticSearchService.ts | 33 ++++++++++++------- 1 file changed, 22 insertions(+), 11 deletions(-) diff --git a/desci-server/src/services/ElasticSearchService.ts b/desci-server/src/services/ElasticSearchService.ts index 492369b8f..100732aa3 100644 --- a/desci-server/src/services/ElasticSearchService.ts +++ b/desci-server/src/services/ElasticSearchService.ts @@ -61,6 +61,8 @@ export const RELEVANT_FIELDS = { ], }; +const NESTED_WORKS_ENTITIES = ['authors', 'best_locations', 'concepts', 'locations', 'topics', 'sources']; + type SortOrder = 'asc' | 'desc'; type SortField = { [field: string]: { order: SortOrder; missing?: string | number; type?: string; script?: any } }; @@ -192,7 +194,7 @@ function buildFilter(filter: Filter) { }; case 'term': const termFieldParts = filter.field.split('.'); - const isNested = termFieldParts.length > 1; + const isNested = NESTED_WORKS_ENTITIES.includes(termFieldParts[0]); const queryType = Array.isArray(filter.value) ? 'terms' : 'term'; let valFormatted = filter.value; if (Array.isArray(valFormatted)) { @@ -213,15 +215,24 @@ function buildFilter(filter: Filter) { } return query; case 'match_phrase': + const fieldParts = filter.field.split('.'); + const isNestedMatchPhrase = NESTED_WORKS_ENTITIES.includes(fieldParts[0]); + if (Array.isArray(filter.value)) { - const queries = filter.value.map((value) => ({ - nested: { - path: filter.field.split('.')[0], - query: { - match_phrase: { [filter.field]: { query: value, analyzer: 'edge_ngram_analyzer' } }, - }, - }, - })); + const queries = filter.value.map((value) => { + if (isNestedMatchPhrase) { + return { + nested: { + path: fieldParts[0], + query: { + match_phrase: { [filter.field]: { query: value, analyzer: 'edge_ngram_analyzer' } }, + }, + }, + }; + } else { + return { match_phrase: { [filter.field]: { query: value, analyzer: 'edge_ngram_analyzer' } } }; + } + }); return { bool: { @@ -231,8 +242,7 @@ function buildFilter(filter: Filter) { }; } - const fieldParts = filter.field.split('.'); - if (fieldParts.length > 1) { + if (isNestedMatchPhrase) { return { nested: { path: fieldParts[0], @@ -242,6 +252,7 @@ function buildFilter(filter: Filter) { }, }; } + return { match_phrase: { [filter.field]: { query: filter.value, analyzer: 'edge_ngram_analyzer' } } }; case 'match': const matchQuery = { From 0137f4c887b05bc1fdd29aaf252da443298efec1 Mon Sep 17 00:00:00 2001 From: shadrach-tayo Date: Sat, 21 Sep 2024 01:23:30 -0500 Subject: [PATCH 28/81] add community control plane(admin) routes, control plane route data validation and schemas, controllers and implement createCommunity api --- .../controllers/admin/communities/index.ts | 65 ++++++++++ desci-server/src/core/ApiResponse.ts | 9 +- desci-server/src/middleware/validator.ts | 3 +- desci-server/src/routes/v1/admin.ts | 18 --- .../src/routes/v1/admin/communities/index.ts | 113 ++++++++++++++++++ .../src/routes/v1/admin/communities/schema.ts | 66 ++++++++++ desci-server/src/routes/v1/admin/index.ts | 22 ++++ desci-server/src/routes/v1/index.ts | 2 +- desci-server/src/services/Communities.ts | 18 ++- desci-server/src/services/data/processing.ts | 35 +++++- desci-server/src/types/ProcessEnv.d.ts | 1 + 11 files changed, 327 insertions(+), 25 deletions(-) create mode 100644 desci-server/src/controllers/admin/communities/index.ts delete mode 100644 desci-server/src/routes/v1/admin.ts create mode 100644 desci-server/src/routes/v1/admin/communities/index.ts create mode 100644 desci-server/src/routes/v1/admin/communities/schema.ts create mode 100644 desci-server/src/routes/v1/admin/index.ts diff --git a/desci-server/src/controllers/admin/communities/index.ts b/desci-server/src/controllers/admin/communities/index.ts new file mode 100644 index 000000000..eab4bb6bd --- /dev/null +++ b/desci-server/src/controllers/admin/communities/index.ts @@ -0,0 +1,65 @@ +import { NextFunction, Request, Response } from 'express'; +import { z } from 'zod'; + +import { + asyncMap, + BadRequestError, + communityService, + logger as parentLogger, + SuccessMessageResponse, + SuccessResponse, +} from '../../../internal.js'; +import { addCommunitySchema } from '../../../routes/v1/admin/communities/schema.js'; +import { processUploadToIpfs } from '../../../services/data/processing.js'; + +const logger = parentLogger.child({ module: 'Admin/Communities/controller' }); + +export const todoApi = async (_req: Request, res: Response, next: NextFunction) => { + new SuccessMessageResponse().send(res); +}; + +export const createCommunity = async (req: Request, res: Response, _next: NextFunction) => { + const body = req.body as Required['body']>; + + let assets: { key: string; url: string }[]; + if (req.files) { + let uploads = Array.isArray(req.files) ? req.files : Object.values(req.files).map((files) => files[0]); + uploads = uploads.map((file) => { + file.originalname = `${file.fieldname}.${file.originalname.split('.')?.[1]}`; + return file; + }); + const { ok, value } = await processUploadToIpfs({ files: uploads }); + if (ok) { + assets = value.map((ipfsImg) => ({ + key: ipfsImg.path, + url: `${process.env.IPFS_RESOLVER_OVERRIDE}/${ipfsImg.cid}`, + })); + } else { + throw new BadRequestError('Could not upload file to ipfs'); + } + } + + const image_url = body.imageUrl || assets.find((img) => img.key.toLowerCase().includes('imageurl'))?.url; + delete body.imageUrl; + + if (!image_url) throw new BadRequestError('No community logo uploaded'); + + // logger.info({ ...body, image_url }, 'payload'); + const community = await communityService.createCommunity({ ...body, image_url }); + new SuccessResponse(community).send(res); +}; + +export const listAllCommunities = async (_req: Request, res: Response, next: NextFunction) => { + const communities = await communityService.adminGetCommunities(); + logger.info({ communities }, 'List communities'); + const data = await asyncMap(communities, async (community) => { + const engagements = await communityService.getCommunityEngagementSignals(community.id); + const verifiedEngagements = await communityService.getCommunityRadarEngagementSignal(community.id); + return { + ...community, + engagements, + verifiedEngagements, + }; + }); + new SuccessResponse(data).send(res); +}; diff --git a/desci-server/src/core/ApiResponse.ts b/desci-server/src/core/ApiResponse.ts index 82a192182..238621108 100644 --- a/desci-server/src/core/ApiResponse.ts +++ b/desci-server/src/core/ApiResponse.ts @@ -1,5 +1,7 @@ import { Response } from 'express'; +import { logger } from '../logger.js'; + enum ResponseStatus { SUCCESS = 200, BAD_REQUEST = 400, @@ -24,7 +26,8 @@ export abstract class ApiResponse { protected prepare(res: Response, response: T, headers: { [key: string]: string }): Response { for (const [key, value] of Object.entries(headers)) res.append(key, value); - return res.status(this.status).json(ApiResponse.sanitize(response)); + const data = ApiResponse.sanitize(response); + return data ? res.status(this.status).json(data) : res.status(this.status).send(); } public send(res: Response, headers: Headers = {}): Response { @@ -35,8 +38,8 @@ export abstract class ApiResponse { const clone: T = {} as T; Object.assign(clone, response); delete clone.status; - for (const field in clone) if (clone[field] === 'undefined') delete clone[field]; - // if (!clone['message']) delete clone.message; + for (const field in clone) if (!clone[field]) delete clone[field]; + if (Object.keys(clone).length === 0) return undefined; return clone; } } diff --git a/desci-server/src/middleware/validator.ts b/desci-server/src/middleware/validator.ts index 2acafc15e..88b6a1f4f 100644 --- a/desci-server/src/middleware/validator.ts +++ b/desci-server/src/middleware/validator.ts @@ -1,7 +1,7 @@ import { NextFunction, Request, Response } from 'express'; import { ZodError, z } from 'zod'; -import { BadRequestError, InternalError, asyncHandler } from '../internal.js'; +import { BadRequestError, InternalError, asyncHandler, logger } from '../internal.js'; export const validate = (schema: z.ZodObject) => asyncHandler(async (req: Request, res: Response, next: NextFunction) => { @@ -9,6 +9,7 @@ export const validate = (schema: z.ZodObject) => await schema.parseAsync(req); next(); } catch (err) { + // logger.error({ body: req.body, file: req.file }, 'zod validator'); if (err instanceof ZodError) { console.log('Error', err); throw new BadRequestError( diff --git a/desci-server/src/routes/v1/admin.ts b/desci-server/src/routes/v1/admin.ts deleted file mode 100644 index 35b3c37a5..000000000 --- a/desci-server/src/routes/v1/admin.ts +++ /dev/null @@ -1,18 +0,0 @@ -import { Router } from 'express'; - -import { createCsv, getAnalytics } from '../../controllers/admin/analytics.js'; -import { debugAllNodesHandler, debugNodeHandler } from '../../controllers/admin/debug.js'; -import { listDoiRecords } from '../../internal.js'; -import { ensureAdmin } from '../../middleware/ensureAdmin.js'; -import { ensureUser } from '../../middleware/permissions.js'; - -const router = Router(); - -router.get('/analytics', [ensureUser, ensureAdmin], getAnalytics); -router.get('/analytics/csv', [ensureUser, ensureAdmin], createCsv); -router.get('/doi/list', [ensureUser, ensureAdmin], listDoiRecords); - -router.get('/debug', [ensureUser, ensureAdmin], debugAllNodesHandler); -router.get('/debug/:uuid', [ensureUser, ensureAdmin], debugNodeHandler); - -export default router; diff --git a/desci-server/src/routes/v1/admin/communities/index.ts b/desci-server/src/routes/v1/admin/communities/index.ts new file mode 100644 index 000000000..9d179c1e6 --- /dev/null +++ b/desci-server/src/routes/v1/admin/communities/index.ts @@ -0,0 +1,113 @@ +import { NextFunction, Response, Router } from 'express'; +import { Request } from 'express'; +import multer from 'multer'; +import multerS3 from 'multer-s3'; + +import { createCommunity, listAllCommunities, todoApi } from '../../../../controllers/admin/communities/index.js'; +import { asyncHandler, ensureAdmin, ensureUser, logger as parentLogger, validate } from '../../../../internal.js'; +import { isS3Configured, s3Client } from '../../../../services/s3.js'; + +import { + addAttestationSchema, + addCommunitySchema, + addEntryAttestationSchema, + addMemberSchema, + removeEntryAttestationSchema, + removeMemberSchema, +} from './schema.js'; + +const logger = parentLogger.child({ module: 'Admin/communities' }); +const router = Router(); + +const upload = isS3Configured + ? multer({ + preservePath: true, + storage: multerS3({ + s3: s3Client, + bucket: process.env.AWS_S3_BUCKET_NAME, + key: (req, file, cb) => { + // const userId = (req as any).user.id; + const { name, communitySlug } = (req as any).body; + if (!name || !name) { + cb(new Error('Missing required params to form key')); + } + const key = `${communitySlug}${name ? +'/' + name : ''}/${file.filename}`; // adjust for dir uploads, doesn't start with '/' + logger.info({ fileName: key }, 'Upload asset'); + cb(null, key); + }, + }), + }) + : multer({ preservePath: true }); + +const uploadHandler = upload.fields([{ name: 'imageUrl', maxCount: 1 }, { name: 'verifiedImageUrl' }]); + +const wrappedHandler = (req: Request, res: Response, next: NextFunction) => { + uploadHandler(req, res, (err) => { + if (err) { + if (err instanceof multer.MulterError) { + throw err; + } else { + logger.error({ err }, 'Upload Handler Error encountered'); + res.status(401).send({ msg: 'unauthorized' }); + return; + } + } + next(); + }); +}; + +const sanitizeBody = async (req: Request, _res: Response, next: NextFunction) => { + logger.info({ body: req.body }, 'sanitizeBody'); + req.body?.keywords ? (req.body.keywords = JSON.parse(req.body.keywords)) : null; + req.body?.links ? (req.body.links = JSON.parse(req.body.links)) : null; + next(); +}; + +router.get('/', [ensureUser, ensureAdmin], asyncHandler(listAllCommunities)); + +// todo: api to create desci community +router.post( + '/', + [ensureUser, ensureAdmin, /* upload.single('image'),*/ wrappedHandler, sanitizeBody, validate(addCommunitySchema)], + asyncHandler(createCommunity), +); + +// todo: api to update desci community +router.post( + ':communityId/', + [ensureUser, ensureAdmin, validate(addCommunitySchema), wrappedHandler], + asyncHandler(todoApi), +); + +// todo: api to create attestation for desci community ( with option to add it as an entryAttestation) +router.post( + ':communityId/attestations', + [ensureUser, ensureAdmin, validate(addAttestationSchema), wrappedHandler], + asyncHandler(todoApi), +); + +// todo: api to add a desci community member +router.post(':communityId/members', [ensureUser, ensureAdmin, validate(addMemberSchema)], asyncHandler(todoApi)); + +// todo: api to remove a desci community member +router.delete( + ':communityId/members/:memberId', + [ensureUser, ensureAdmin, validate(removeMemberSchema)], + asyncHandler(todoApi), +); + +// todo: api to link attestation to community (this adds it to the communityEntryAttestation) +router.post( + ':communityId/addEntryAttestation', + [ensureUser, ensureAdmin, validate(addEntryAttestationSchema)], + asyncHandler(todoApi), +); + +// todo: api to remove attestation as required in for community (remove communityEntryAttestation) +router.post( + ':communityId/removeEntryAttestation', + [ensureUser, ensureAdmin, validate(removeEntryAttestationSchema)], + asyncHandler(todoApi), +); + +export default router; diff --git a/desci-server/src/routes/v1/admin/communities/schema.ts b/desci-server/src/routes/v1/admin/communities/schema.ts new file mode 100644 index 000000000..8d9480eef --- /dev/null +++ b/desci-server/src/routes/v1/admin/communities/schema.ts @@ -0,0 +1,66 @@ +import { CommunityMembershipRole } from '@prisma/client'; +import { z } from 'zod'; + +export const addCommunitySchema = z.object({ + body: z.object({ + name: z.string(), + subtitle: z.string().min(1, 'Subtitle cannot be empty'), + description: z.string().min(1, 'Description cannot be empty'), + hidden: z.boolean().default(false), + keywords: z.array(z.string()).min(1, 'Community must have at least one keyword'), + imageUrl: z.string().url().optional(), //"https://pub.desci.com/ipfs/bafkreie7kxhzpzhsbywcrpgyv5yvy3qxcjsibuxsnsh5olaztl2uvnrzx4", + slug: z.string().min(3), + links: z.array(z.string().url()), + }), +}); + +export const addAttestationSchema = z.object({ + params: z.object({ + communityId: z.coerce.number(), + }), + body: z.object({ + name: z.string(), + communitySlug: z.string(), + description: z.string(), + imageUrl: z.string().url().optional(), //"https://pub.desci.com/ipfs/bafkreie7kxhzpzhsbywcrpgyv5yvy3qxcjsibuxsnsh5olaztl2uvnrzx4", + verifiedImageUrl: z.string().url().optional(), //"https://pub.desci.com/ipfs/bafkreie7kxhzpzhsbywcrpgyv5yvy3qxcjsibuxsnsh5olaztl2uvnrzx4", + protected: z.boolean().default(false), + }), +}); + +export const addMemberSchema = z.object({ + params: z.object({ + communityId: z.coerce.number(), + }), + body: z.object({ + userId: z.coerce.number(), + role: z.enum([CommunityMembershipRole.ADMIN, CommunityMembershipRole.MEMBER]), + }), +}); + +export const removeMemberSchema = z.object({ + params: z.object({ + communityId: z.coerce.number(), + }), + body: z.object({ + memberId: z.coerce.number(), + }), +}); + +export const addEntryAttestationSchema = z.object({ + params: z.object({ + communityId: z.coerce.number(), + }), + body: z.object({ + attestationId: z.coerce.number(), + }), +}); + +export const removeEntryAttestationSchema = z.object({ + params: z.object({ + communityId: z.coerce.number(), + }), + body: z.object({ + attestationId: z.coerce.number(), + }), +}); diff --git a/desci-server/src/routes/v1/admin/index.ts b/desci-server/src/routes/v1/admin/index.ts new file mode 100644 index 000000000..561a9e111 --- /dev/null +++ b/desci-server/src/routes/v1/admin/index.ts @@ -0,0 +1,22 @@ +import { Router } from 'express'; + +import { createCsv, getAnalytics } from '../../../controllers/admin/analytics.js'; +import { debugAllNodesHandler, debugNodeHandler } from '../../../controllers/admin/debug.js'; +import { listDoiRecords } from '../../../internal.js'; +import { ensureAdmin } from '../../../middleware/ensureAdmin.js'; +import { ensureUser } from '../../../middleware/permissions.js'; + +import communities from './communities/index.js'; + +const router = Router(); + +router.get('/analytics', [ensureUser, ensureAdmin], getAnalytics); +router.get('/analytics/csv', [ensureUser, ensureAdmin], createCsv); +router.get('/doi/list', [ensureUser, ensureAdmin], listDoiRecords); + +router.get('/debug', [ensureUser, ensureAdmin], debugAllNodesHandler); +router.get('/debug/:uuid', [ensureUser, ensureAdmin], debugNodeHandler); + +router.use('/communities', [ensureUser, ensureAdmin], communities); + +export default router; diff --git a/desci-server/src/routes/v1/index.ts b/desci-server/src/routes/v1/index.ts index a87e0ebae..616777fc6 100755 --- a/desci-server/src/routes/v1/index.ts +++ b/desci-server/src/routes/v1/index.ts @@ -10,7 +10,7 @@ import { nft } from '../../controllers/raw/nft.js'; import { asyncHandler } from '../../internal.js'; import { ensureUser } from '../../middleware/permissions.js'; -import admin from './admin.js'; +import admin from './admin/index.js'; import attestations from './attestations/index.js'; import auth from './auth.js'; import communities from './communities/index.js'; diff --git a/desci-server/src/services/Communities.ts b/desci-server/src/services/Communities.ts index 8b3114251..f9fc29ea1 100644 --- a/desci-server/src/services/Communities.ts +++ b/desci-server/src/services/Communities.ts @@ -1,5 +1,5 @@ import { Attestation, CommunityMembershipRole, NodeAttestation, NodeFeedItem, Prisma } from '@prisma/client'; -import _ from 'lodash'; +import _, { includes } from 'lodash'; import { prisma } from '../client.js'; import { DuplicateDataError, logger } from '../internal.js'; @@ -18,6 +18,22 @@ export class CommunityService { return community; } + async adminGetCommunities() { + return prisma.desciCommunity.findMany({ + orderBy: { createdAt: 'asc' }, + include: { + CommunityMember: { + select: { id: true, role: true, userId: true, user: { select: { name: true, userOrganizations: true } } }, + orderBy: { role: 'asc' }, + }, + CommunityEntryAttestation: { + select: { id: true, attestationVersion: { select: { name: true, image_url: true } } }, + orderBy: { createdAt: 'asc' }, + }, + }, + }); + } + async getAllCommunities() { return prisma.desciCommunity.findMany({ select: { diff --git a/desci-server/src/services/data/processing.ts b/desci-server/src/services/data/processing.ts index 254545b03..2b9454a69 100644 --- a/desci-server/src/services/data/processing.ts +++ b/desci-server/src/services/data/processing.ts @@ -348,7 +348,7 @@ export function extractRootDagCidFromManifest(manifest: ResearchObjectV1, manife } export async function getManifestFromNode( - node: { manifestUrl: string, cid?: string }, + node: { manifestUrl: string; cid?: string }, queryString?: string, ): Promise<{ manifest: ResearchObjectV1; manifestCid: string }> { // debugger; @@ -748,3 +748,36 @@ export async function assignTypeMapInManifest( return manifest; } } + +/** + * Proccesses regular file uploads, pins S3 files to IPFS, adds them to the end of the context DAG node, creates data references for them and updates the manifest. + */ +export async function processUploadToIpfs({ + files, +}: { + files: + | { + [fieldname: string]: Express.Multer.File[]; + } + | Express.Multer.File[]; +}): Promise> { + let pinResult: IpfsPinnedResult[] = []; + try { + const uploads = Array.isArray(files) ? files : Object.values(files).map((files) => files[0]); + // Pin new files, add draftNodeTree entries + pinResult = await pinNewFiles(uploads, false); + if (pinResult) { + logger.info({ pinResult }, 'Files uploaded to Ipfs'); + } + + return { + ok: true, + value: pinResult, + }; + // SUCCESS + } catch (error) { + logger.error({ error }, 'Error processing S3 data to IPFS'); + const controlledErr = 'type' in error ? error : createUnhandledError(error); + return { ok: false, value: controlledErr }; + } +} diff --git a/desci-server/src/types/ProcessEnv.d.ts b/desci-server/src/types/ProcessEnv.d.ts index e7fe3592b..35ac96f86 100755 --- a/desci-server/src/types/ProcessEnv.d.ts +++ b/desci-server/src/types/ProcessEnv.d.ts @@ -20,5 +20,6 @@ declare namespace NodeJS { CROSSREF_API_KEY: string; AUTOMATED_METADATA_API: string; AUTOMATED_METADATA_API_KEY: string; + IPFS_RESOLVER_OVERRIDE: string; } } From d498f8f54e7bdea0e538d2881e253cdc5a1ae6e2 Mon Sep 17 00:00:00 2001 From: m0ar Date: Mon, 23 Sep 2024 10:23:54 +0200 Subject: [PATCH 29/81] nodeslib: force sep eth chainid in CACAO unless overridden --- nodes-lib/package.json | 2 +- nodes-lib/src/util/signing.ts | 4 +++- 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/nodes-lib/package.json b/nodes-lib/package.json index 1debe7631..9964f222e 100644 --- a/nodes-lib/package.json +++ b/nodes-lib/package.json @@ -1,6 +1,6 @@ { "name": "@desci-labs/nodes-lib", - "version": "0.0.11-rc1", + "version": "0.0.11", "homepage": "https://github.com/desci-labs/nodes#readme", "description": "Stand-alone client library for interacting with desci-server", "repository": { diff --git a/nodes-lib/src/util/signing.ts b/nodes-lib/src/util/signing.ts index 333f5dd8b..c68642984 100644 --- a/nodes-lib/src/util/signing.ts +++ b/nodes-lib/src/util/signing.ts @@ -76,7 +76,9 @@ export const authorizedSessionDidFromSigner = async ( const address = await signer.getAddress(); const network = await jsonRpcProvider.getNetwork(); - const chainId = `eip155:${chainIdOverride ?? network.chainId}`; + // Force sepolia chainID in CACAO to prevent segmenting the + // user's streams over AccountIDs with different chainIDs + const chainId = `eip155:${chainIdOverride ?? "11155111" }`; const caipAccountId = new AccountId({ address, chainId }); let authMethod: AuthMethod; From ae4275306e44c1eb895aed43434ae1dbfa0def5e Mon Sep 17 00:00:00 2001 From: shadrach-tayo Date: Mon, 23 Sep 2024 04:06:16 -0500 Subject: [PATCH 30/81] clean up --- desci-server/src/controllers/admin/communities/index.ts | 1 - desci-server/src/core/ApiResponse.ts | 2 -- 2 files changed, 3 deletions(-) diff --git a/desci-server/src/controllers/admin/communities/index.ts b/desci-server/src/controllers/admin/communities/index.ts index eab4bb6bd..ae46c523a 100644 --- a/desci-server/src/controllers/admin/communities/index.ts +++ b/desci-server/src/controllers/admin/communities/index.ts @@ -44,7 +44,6 @@ export const createCommunity = async (req: Request, res: Response, _next: NextFu if (!image_url) throw new BadRequestError('No community logo uploaded'); - // logger.info({ ...body, image_url }, 'payload'); const community = await communityService.createCommunity({ ...body, image_url }); new SuccessResponse(community).send(res); }; diff --git a/desci-server/src/core/ApiResponse.ts b/desci-server/src/core/ApiResponse.ts index 238621108..bd81e30c7 100644 --- a/desci-server/src/core/ApiResponse.ts +++ b/desci-server/src/core/ApiResponse.ts @@ -1,7 +1,5 @@ import { Response } from 'express'; -import { logger } from '../logger.js'; - enum ResponseStatus { SUCCESS = 200, BAD_REQUEST = 400, From 2d6afe043ee5ea72ecfe84b1234ff57da7b80f53 Mon Sep 17 00:00:00 2001 From: shadrach-tayo Date: Mon, 23 Sep 2024 04:27:12 -0500 Subject: [PATCH 31/81] sanity check before attempting to retrieve automerge url doc --- desci-repo/src/controllers/nodes/documents.ts | 7 +------ desci-server/src/services/repoService.ts | 5 ++++- 2 files changed, 5 insertions(+), 7 deletions(-) diff --git a/desci-repo/src/controllers/nodes/documents.ts b/desci-repo/src/controllers/nodes/documents.ts index 3a70577eb..0292f664c 100644 --- a/desci-repo/src/controllers/nodes/documents.ts +++ b/desci-repo/src/controllers/nodes/documents.ts @@ -59,18 +59,13 @@ export const createNodeDocument = async function (req: Request, res: Response) { export const getLatestNodeManifest = async function (req: Request, res: Response) { logger.info({ params: req.params }, 'START [getLatestNodeManifest]'); try { - console.log('[getLatestNodeManifest]', req.params); + logger.info({ params: req.params }, '[getLatestNodeManifest]'); if (!req.params.uuid) { res.status(400).send({ ok: false, message: 'Invalid data' }); return; } const { uuid } = req.params; - - // const queryResult = await pool.query('SELECT * FROM nodes WHERE uuid = $1', [uuid]); - // console.log('user:', queryResult.rows[0]); - - logger.info('[getLatestNodeManifest]', { uuid }); const node = await findNodeByUuid(uuid); logger.trace('[getLatestNodeManifest::node]', { node }); diff --git a/desci-server/src/services/repoService.ts b/desci-server/src/services/repoService.ts index 2c9a75557..9a6cdcb7c 100644 --- a/desci-server/src/services/repoService.ts +++ b/desci-server/src/services/repoService.ts @@ -85,12 +85,15 @@ class RepoService { } async getDraftDocument(arg: { uuid: NodeUuid }) { + if (!arg.uuid) { + logger.warn({ arg }, 'Attempt to retrieve draft manifest for empty UUID'); + return null; + } logger.info({ arg }, 'Retrieve Draft Document'); try { const response = await this.#client.get>( `${this.baseUrl}/v1/nodes/documents/draft/${arg.uuid}`, ); - logger.info({ response: response.status }, 'Draft Retrieval Response'); if (response.status === 200 && response.data.ok) { return response.data.document; } else { From 4179629e1abb7cc8c57e956caad2e1dba1d32042 Mon Sep 17 00:00:00 2001 From: shadrach-tayo Date: Mon, 23 Sep 2024 07:32:12 -0500 Subject: [PATCH 32/81] implement community update api --- .../controllers/admin/communities/index.ts | 69 +++++++++++++++++-- .../src/routes/v1/admin/communities/index.ts | 33 +++++---- .../src/routes/v1/admin/communities/schema.ts | 24 ++++++- desci-server/src/services/Communities.ts | 7 ++ desci-server/src/services/data/processing.ts | 2 +- 5 files changed, 114 insertions(+), 21 deletions(-) diff --git a/desci-server/src/controllers/admin/communities/index.ts b/desci-server/src/controllers/admin/communities/index.ts index ae46c523a..72adb24f8 100644 --- a/desci-server/src/controllers/admin/communities/index.ts +++ b/desci-server/src/controllers/admin/communities/index.ts @@ -5,11 +5,13 @@ import { asyncMap, BadRequestError, communityService, + DuplicateDataError, + NotFoundError, logger as parentLogger, SuccessMessageResponse, SuccessResponse, } from '../../../internal.js'; -import { addCommunitySchema } from '../../../routes/v1/admin/communities/schema.js'; +import { addCommunitySchema, updateCommunitySchema } from '../../../routes/v1/admin/communities/schema.js'; import { processUploadToIpfs } from '../../../services/data/processing.js'; const logger = parentLogger.child({ module: 'Admin/Communities/controller' }); @@ -21,15 +23,67 @@ export const todoApi = async (_req: Request, res: Response, next: NextFunction) export const createCommunity = async (req: Request, res: Response, _next: NextFunction) => { const body = req.body as Required['body']>; + const exists = await communityService.findCommunityByNameOrSlug(body.slug); + if (exists) throw new DuplicateDataError(); + + let assets: { key: string; url: string }[]; + let uploads = Array.isArray(req.files) + ? req.files + : Object.values(req.files) + .map((files) => files[0]) + .filter(Boolean); + + if (uploads) { + uploads = uploads.map((file) => { + file.originalname = `${file.fieldname}.${file.originalname.split('.')?.[1]}`; + return file; + }); + logger.info({ uploads }, 'Uploads'); + const { ok, value } = await processUploadToIpfs({ files: uploads }); + if (ok && value) { + assets = value.map((ipfsImg) => ({ + key: ipfsImg.path, + url: `${process.env.IPFS_RESOLVER_OVERRIDE}/${ipfsImg.cid}`, + })); + } else { + throw new BadRequestError('Could not upload file to ipfs'); + } + } + + const image_url = assets.find((img) => img.key.toLowerCase().includes('imageurl'))?.url || body.imageUrl; + delete body.imageUrl; + + if (!image_url) throw new BadRequestError('No community logo uploaded'); + + const hidden = body.hidden.toString() === 'true' ? true : false; + const community = await communityService.createCommunity({ ...body, hidden, image_url }); + new SuccessResponse(community).send(res); +}; + +export const updateCommunity = async (req: Request, res: Response, _next: NextFunction) => { + const body = req.body as Required['body']>; + const { communityId } = req.params as z.infer['params']; + logger.info({ body, communityId }, 'updateCommunity'); + + let community = await communityService.findCommunityById(parseInt(communityId)); + + if (!community) throw new NotFoundError(); + let assets: { key: string; url: string }[]; - if (req.files) { - let uploads = Array.isArray(req.files) ? req.files : Object.values(req.files).map((files) => files[0]); + let uploads = Array.isArray(req.files) + ? req.files + : Object.values(req.files) + ?.map((files) => files[0]) + .filter(Boolean); + + logger.info({ uploads: !!uploads }, 'Uploads'); + if (uploads?.length) { uploads = uploads.map((file) => { file.originalname = `${file.fieldname}.${file.originalname.split('.')?.[1]}`; return file; }); const { ok, value } = await processUploadToIpfs({ files: uploads }); - if (ok) { + if (ok && value) { assets = value.map((ipfsImg) => ({ key: ipfsImg.path, url: `${process.env.IPFS_RESOLVER_OVERRIDE}/${ipfsImg.cid}`, @@ -39,12 +93,15 @@ export const createCommunity = async (req: Request, res: Response, _next: NextFu } } - const image_url = body.imageUrl || assets.find((img) => img.key.toLowerCase().includes('imageurl'))?.url; + // enforce strict non-empty check on image_url field + const image_url = + assets?.find((img) => img.key.toLowerCase().includes('imageurl'))?.url || body?.imageUrl || community.image_url; delete body.imageUrl; if (!image_url) throw new BadRequestError('No community logo uploaded'); + const hidden = body.hidden.toString() === 'true' ? true : false; - const community = await communityService.createCommunity({ ...body, image_url }); + community = await communityService.updateCommunityById(parseInt(communityId), { ...body, hidden, image_url }); new SuccessResponse(community).send(res); }; diff --git a/desci-server/src/routes/v1/admin/communities/index.ts b/desci-server/src/routes/v1/admin/communities/index.ts index 9d179c1e6..b43af850b 100644 --- a/desci-server/src/routes/v1/admin/communities/index.ts +++ b/desci-server/src/routes/v1/admin/communities/index.ts @@ -3,7 +3,12 @@ import { Request } from 'express'; import multer from 'multer'; import multerS3 from 'multer-s3'; -import { createCommunity, listAllCommunities, todoApi } from '../../../../controllers/admin/communities/index.js'; +import { + createCommunity, + listAllCommunities, + todoApi, + updateCommunity, +} from '../../../../controllers/admin/communities/index.js'; import { asyncHandler, ensureAdmin, ensureUser, logger as parentLogger, validate } from '../../../../internal.js'; import { isS3Configured, s3Client } from '../../../../services/s3.js'; @@ -14,6 +19,7 @@ import { addMemberSchema, removeEntryAttestationSchema, removeMemberSchema, + updateCommunitySchema, } from './schema.js'; const logger = parentLogger.child({ module: 'Admin/communities' }); @@ -39,7 +45,10 @@ const upload = isS3Configured }) : multer({ preservePath: true }); -const uploadHandler = upload.fields([{ name: 'imageUrl', maxCount: 1 }, { name: 'verifiedImageUrl' }]); +const uploadHandler = upload.fields([ + { name: 'imageUrl', maxCount: 1 }, + { name: 'verifiedImageUrl', maxCount: 1 }, +]); const wrappedHandler = (req: Request, res: Response, next: NextFunction) => { uploadHandler(req, res, (err) => { @@ -65,23 +74,21 @@ const sanitizeBody = async (req: Request, _res: Response, next: NextFunction) => router.get('/', [ensureUser, ensureAdmin], asyncHandler(listAllCommunities)); -// todo: api to create desci community router.post( '/', - [ensureUser, ensureAdmin, /* upload.single('image'),*/ wrappedHandler, sanitizeBody, validate(addCommunitySchema)], + [ensureUser, ensureAdmin, wrappedHandler, sanitizeBody, validate(addCommunitySchema)], asyncHandler(createCommunity), ); -// todo: api to update desci community -router.post( - ':communityId/', - [ensureUser, ensureAdmin, validate(addCommunitySchema), wrappedHandler], - asyncHandler(todoApi), +router.put( + '/:communityId', + [ensureUser, ensureAdmin, wrappedHandler, sanitizeBody, validate(updateCommunitySchema)], + asyncHandler(updateCommunity), ); // todo: api to create attestation for desci community ( with option to add it as an entryAttestation) router.post( - ':communityId/attestations', + '/:communityId/attestations', [ensureUser, ensureAdmin, validate(addAttestationSchema), wrappedHandler], asyncHandler(todoApi), ); @@ -91,21 +98,21 @@ router.post(':communityId/members', [ensureUser, ensureAdmin, validate(addMember // todo: api to remove a desci community member router.delete( - ':communityId/members/:memberId', + '/:communityId/members/:memberId', [ensureUser, ensureAdmin, validate(removeMemberSchema)], asyncHandler(todoApi), ); // todo: api to link attestation to community (this adds it to the communityEntryAttestation) router.post( - ':communityId/addEntryAttestation', + '/:communityId/addEntryAttestation', [ensureUser, ensureAdmin, validate(addEntryAttestationSchema)], asyncHandler(todoApi), ); // todo: api to remove attestation as required in for community (remove communityEntryAttestation) router.post( - ':communityId/removeEntryAttestation', + '/:communityId/removeEntryAttestation', [ensureUser, ensureAdmin, validate(removeEntryAttestationSchema)], asyncHandler(todoApi), ); diff --git a/desci-server/src/routes/v1/admin/communities/schema.ts b/desci-server/src/routes/v1/admin/communities/schema.ts index 8d9480eef..b2dc34bf0 100644 --- a/desci-server/src/routes/v1/admin/communities/schema.ts +++ b/desci-server/src/routes/v1/admin/communities/schema.ts @@ -6,7 +6,10 @@ export const addCommunitySchema = z.object({ name: z.string(), subtitle: z.string().min(1, 'Subtitle cannot be empty'), description: z.string().min(1, 'Description cannot be empty'), - hidden: z.boolean().default(false), + hidden: z.coerce + .boolean() + .transform((value) => (value.toString() === 'true' ? true : false)) + .default(false), keywords: z.array(z.string()).min(1, 'Community must have at least one keyword'), imageUrl: z.string().url().optional(), //"https://pub.desci.com/ipfs/bafkreie7kxhzpzhsbywcrpgyv5yvy3qxcjsibuxsnsh5olaztl2uvnrzx4", slug: z.string().min(3), @@ -14,6 +17,25 @@ export const addCommunitySchema = z.object({ }), }); +export const updateCommunitySchema = z.object({ + body: z.object({ + name: z.string().optional(), + subtitle: z.string().min(1, 'Subtitle cannot be empty').optional(), + description: z.string().min(1, 'Description cannot be empty').optional(), + hidden: z.coerce + .boolean() + .transform((value) => (value.toString() === 'true' ? true : false)) + .default(false), + keywords: z.array(z.string()).min(1, 'Community must have at least one keyword').optional(), + imageUrl: z.string().url().optional(), //"https://pub.desci.com/ipfs/bafkreie7kxhzpzhsbywcrpgyv5yvy3qxcjsibuxsnsh5olaztl2uvnrzx4", + slug: z.string().min(3).optional(), + links: z.array(z.string().url()).optional(), + }), + params: z.object({ + communityId: z.string(), + }), +}); + export const addAttestationSchema = z.object({ params: z.object({ communityId: z.coerce.number(), diff --git a/desci-server/src/services/Communities.ts b/desci-server/src/services/Communities.ts index f9fc29ea1..bac794c04 100644 --- a/desci-server/src/services/Communities.ts +++ b/desci-server/src/services/Communities.ts @@ -88,6 +88,13 @@ export class CommunityService { }); } + async updateCommunityById(id: number, community: Prisma.DesciCommunityUpdateInput) { + return prisma.desciCommunity.update({ + where: { id }, + data: community, + }); + } + /** * This query retrieves data from the "NodeAttestation" table along with the counts of related records from the * "Annotation", "NodeAttestationReaction", and "NodeAttestationVerification" tables. diff --git a/desci-server/src/services/data/processing.ts b/desci-server/src/services/data/processing.ts index 2b9454a69..b17c5f9bb 100644 --- a/desci-server/src/services/data/processing.ts +++ b/desci-server/src/services/data/processing.ts @@ -434,7 +434,7 @@ export async function pinNewFiles(files: any[], wrapWithDirectory = false): Prom if (structuredFilesForPinning.length) { if (structuredFilesForPinning.length) uploaded = await pinDirectory(structuredFilesForPinning, wrapWithDirectory); if (!uploaded.length) throw createIpfsUploadFailureError(); - logger.info('[UPDATE DATASET] Pinned files: ', uploaded.length); + logger.info({ uploaded }, '[UPDATE DATASET] Pinned files: '); } return uploaded; } From fe3a28eb0f8c3927f8dbbd6f4db9c9e19777cbc5 Mon Sep 17 00:00:00 2001 From: shadrach-tayo Date: Mon, 23 Sep 2024 08:55:42 -0500 Subject: [PATCH 33/81] add and update attestation api --- .../controllers/admin/communities/index.ts | 127 +++++++++++++++++- .../src/routes/v1/admin/communities/index.ts | 16 ++- .../src/routes/v1/admin/communities/schema.ts | 12 +- desci-server/src/services/Attestation.ts | 5 +- 4 files changed, 145 insertions(+), 15 deletions(-) diff --git a/desci-server/src/controllers/admin/communities/index.ts b/desci-server/src/controllers/admin/communities/index.ts index 72adb24f8..db0b2ca94 100644 --- a/desci-server/src/controllers/admin/communities/index.ts +++ b/desci-server/src/controllers/admin/communities/index.ts @@ -3,6 +3,7 @@ import { z } from 'zod'; import { asyncMap, + attestationService, BadRequestError, communityService, DuplicateDataError, @@ -11,7 +12,12 @@ import { SuccessMessageResponse, SuccessResponse, } from '../../../internal.js'; -import { addCommunitySchema, updateCommunitySchema } from '../../../routes/v1/admin/communities/schema.js'; +import { + addAttestationSchema, + addCommunitySchema, + updateAttestationSchema, + updateCommunitySchema, +} from '../../../routes/v1/admin/communities/schema.js'; import { processUploadToIpfs } from '../../../services/data/processing.js'; const logger = parentLogger.child({ module: 'Admin/Communities/controller' }); @@ -33,7 +39,7 @@ export const createCommunity = async (req: Request, res: Response, _next: NextFu .map((files) => files[0]) .filter(Boolean); - if (uploads) { + if (uploads?.length > 0) { uploads = uploads.map((file) => { file.originalname = `${file.fieldname}.${file.originalname.split('.')?.[1]}`; return file; @@ -50,7 +56,7 @@ export const createCommunity = async (req: Request, res: Response, _next: NextFu } } - const image_url = assets.find((img) => img.key.toLowerCase().includes('imageurl'))?.url || body.imageUrl; + const image_url = assets?.find((img) => img.key.toLowerCase().includes('imageurl'))?.url || body.imageUrl; delete body.imageUrl; if (!image_url) throw new BadRequestError('No community logo uploaded'); @@ -65,7 +71,7 @@ export const updateCommunity = async (req: Request, res: Response, _next: NextFu const { communityId } = req.params as z.infer['params']; logger.info({ body, communityId }, 'updateCommunity'); - let community = await communityService.findCommunityById(parseInt(communityId)); + let community = await communityService.findCommunityById(+communityId); if (!community) throw new NotFoundError(); @@ -77,7 +83,7 @@ export const updateCommunity = async (req: Request, res: Response, _next: NextFu .filter(Boolean); logger.info({ uploads: !!uploads }, 'Uploads'); - if (uploads?.length) { + if (uploads?.length > 0) { uploads = uploads.map((file) => { file.originalname = `${file.fieldname}.${file.originalname.split('.')?.[1]}`; return file; @@ -101,11 +107,11 @@ export const updateCommunity = async (req: Request, res: Response, _next: NextFu if (!image_url) throw new BadRequestError('No community logo uploaded'); const hidden = body.hidden.toString() === 'true' ? true : false; - community = await communityService.updateCommunityById(parseInt(communityId), { ...body, hidden, image_url }); + community = await communityService.updateCommunityById(+communityId, { ...body, hidden, image_url }); new SuccessResponse(community).send(res); }; -export const listAllCommunities = async (_req: Request, res: Response, next: NextFunction) => { +export const listAllCommunities = async (_req: Request, res: Response, _next: NextFunction) => { const communities = await communityService.adminGetCommunities(); logger.info({ communities }, 'List communities'); const data = await asyncMap(communities, async (community) => { @@ -119,3 +125,110 @@ export const listAllCommunities = async (_req: Request, res: Response, next: Nex }); new SuccessResponse(data).send(res); }; + +export const createAttestation = async (req: Request, res: Response, _next: NextFunction) => { + const body = req.body as Required['body']>; + const { communityId } = req.params as z.infer['params']; + logger.info({ communityId, body }, 'Payload'); + + const community = await communityService.findCommunityById(Number(communityId)); + if (!community) throw new NotFoundError(`Community ${communityId} not found`); + + let assets: { key: string; url: string }[]; + let uploads = Array.isArray(req.files) + ? req.files + : Object.values(req.files) + .map((files) => files[0]) + .filter(Boolean); + + if (uploads) { + uploads = uploads.map((file) => { + file.originalname = `${file.fieldname}.${file.originalname.split('.')?.[1]}`; + return file; + }); + + const { ok, value } = await processUploadToIpfs({ files: uploads }); + if (ok && value) { + assets = value.map((ipfsImg) => ({ + key: ipfsImg.path, + url: `${process.env.IPFS_RESOLVER_OVERRIDE}/${ipfsImg.cid}`, + })); + } else { + throw new BadRequestError('Could not upload file to ipfs'); + } + } + + const image_url = assets.find((img) => img.key.toLowerCase().includes('imageurl'))?.url || body.imageUrl; + delete body.imageUrl; + const verified_image_url = + assets.find((img) => img.key.toLowerCase().includes('verifiedimageurl'))?.url || body.verifiedImageUrl; + delete body.verifiedImageUrl; + + logger.info({ image_url, verified_image_url }, 'Assets'); + + if (!image_url) throw new BadRequestError('No community logo uploaded'); + + const isProtected = body.protected.toString() === 'true' ? true : false; + const attestation = await attestationService.create({ + ...body, + image_url, + verified_image_url, + communityId: community.id, + protected: isProtected, + }); + new SuccessResponse(attestation).send(res); +}; + +export const updateAttestation = async (req: Request, res: Response, _next: NextFunction) => { + const body = req.body as Required['body']>; + const { attestationId } = req.params as z.infer['params']; + logger.info({ attestationId, body }, 'Payload'); + + const exists = await attestationService.findAttestationById(Number(attestationId)); + if (!exists) throw new NotFoundError(`Attestation ${attestationId} not found`); + + let assets: { key: string; url: string }[] | undefined; + let uploads = Array.isArray(req.files) + ? req.files + : Object.values(req.files) + .map((files) => files[0]) + .filter(Boolean); + + logger.info({ uploads: uploads?.map((up) => up.fieldname) }, 'Uploads'); + if (uploads?.length > 0) { + uploads = uploads.map((file) => { + file.originalname = `${file.fieldname}.${file.originalname.split('.')?.[1]}`; + return file; + }); + const { ok, value } = await processUploadToIpfs({ files: uploads }); + logger.info({ ok, value }, 'Uploads REsult'); + if (ok && value) { + assets = value.map((ipfsImg) => ({ + key: ipfsImg.path, + url: `${process.env.IPFS_RESOLVER_OVERRIDE}/${ipfsImg.cid}`, + })); + } else { + throw new BadRequestError('Could not upload file to ipfs'); + } + } + + const image_url = assets?.find((img) => img.key.toLowerCase().includes('imageurl'))?.url || body.imageUrl; + const verified_image_url = + assets?.find((img) => img.key.toLowerCase().includes('verifiedimageurl'))?.url || body.verifiedImageUrl; + delete body.imageUrl; + delete body.verifiedImageUrl; + + logger.info({ image_url, verified_image_url }, 'Assets'); + + if (!image_url) throw new BadRequestError('No attestation image uploaded'); + + const isProtected = body.protected.toString() === 'true' ? true : false; + const attestation = await attestationService.updateAttestation(exists.id, { + ...body, + image_url, + verified_image_url, + communityId: exists.communityId, + protected: isProtected, + }); + new SuccessResponse(attestation).send(res); +}; diff --git a/desci-server/src/routes/v1/admin/communities/index.ts b/desci-server/src/routes/v1/admin/communities/index.ts index b43af850b..0a32bbf35 100644 --- a/desci-server/src/routes/v1/admin/communities/index.ts +++ b/desci-server/src/routes/v1/admin/communities/index.ts @@ -4,9 +4,11 @@ import multer from 'multer'; import multerS3 from 'multer-s3'; import { + createAttestation, createCommunity, listAllCommunities, todoApi, + updateAttestation, updateCommunity, } from '../../../../controllers/admin/communities/index.js'; import { asyncHandler, ensureAdmin, ensureUser, logger as parentLogger, validate } from '../../../../internal.js'; @@ -19,6 +21,7 @@ import { addMemberSchema, removeEntryAttestationSchema, removeMemberSchema, + updateAttestationSchema, updateCommunitySchema, } from './schema.js'; @@ -86,15 +89,20 @@ router.put( asyncHandler(updateCommunity), ); -// todo: api to create attestation for desci community ( with option to add it as an entryAttestation) router.post( '/:communityId/attestations', - [ensureUser, ensureAdmin, validate(addAttestationSchema), wrappedHandler], - asyncHandler(todoApi), + [ensureUser, ensureAdmin, wrappedHandler, validate(addAttestationSchema)], + asyncHandler(createAttestation), +); + +router.put( + '/:communityId/attestations/:attestationId', + [ensureUser, ensureAdmin, wrappedHandler, validate(updateAttestationSchema)], + asyncHandler(updateAttestation), ); // todo: api to add a desci community member -router.post(':communityId/members', [ensureUser, ensureAdmin, validate(addMemberSchema)], asyncHandler(todoApi)); +router.post('/:communityId/members', [ensureUser, ensureAdmin, validate(addMemberSchema)], asyncHandler(todoApi)); // todo: api to remove a desci community member router.delete( diff --git a/desci-server/src/routes/v1/admin/communities/schema.ts b/desci-server/src/routes/v1/admin/communities/schema.ts index b2dc34bf0..5ffcaff83 100644 --- a/desci-server/src/routes/v1/admin/communities/schema.ts +++ b/desci-server/src/routes/v1/admin/communities/schema.ts @@ -32,7 +32,7 @@ export const updateCommunitySchema = z.object({ links: z.array(z.string().url()).optional(), }), params: z.object({ - communityId: z.string(), + communityId: z.coerce.number(), }), }); @@ -42,14 +42,20 @@ export const addAttestationSchema = z.object({ }), body: z.object({ name: z.string(), - communitySlug: z.string(), description: z.string(), imageUrl: z.string().url().optional(), //"https://pub.desci.com/ipfs/bafkreie7kxhzpzhsbywcrpgyv5yvy3qxcjsibuxsnsh5olaztl2uvnrzx4", verifiedImageUrl: z.string().url().optional(), //"https://pub.desci.com/ipfs/bafkreie7kxhzpzhsbywcrpgyv5yvy3qxcjsibuxsnsh5olaztl2uvnrzx4", - protected: z.boolean().default(false), + protected: z.coerce + .boolean() + .transform((value) => (value.toString() === 'true' ? true : false)) + .default(false), }), }); +export const updateAttestationSchema = addAttestationSchema.extend({ + params: z.object({ attestationId: z.coerce.number(), communityId: z.coerce.number() }), +}); + export const addMemberSchema = z.object({ params: z.object({ communityId: z.coerce.number(), diff --git a/desci-server/src/services/Attestation.ts b/desci-server/src/services/Attestation.ts index 475f58be1..48a690d8a 100644 --- a/desci-server/src/services/Attestation.ts +++ b/desci-server/src/services/Attestation.ts @@ -171,7 +171,10 @@ export class AttestationService { const attestation = await this.findAttestationById(attestationId); if (!attestation) throw new AttestationNotFoundError(); - + await prisma.attestation.update({ + where: { id: attestationId }, + data: { verified_image_url: data.verified_image_url }, + }); await this.#publishVersion({ name: data.name as string, description: data.description, From eb1fc1b9114db6f4684033b956ddf5f95c196ce7 Mon Sep 17 00:00:00 2001 From: shadrach-tayo Date: Mon, 23 Sep 2024 11:33:24 -0500 Subject: [PATCH 34/81] add and remove community member apis --- .../controllers/admin/communities/index.ts | 40 +++++++++++++++++++ .../src/routes/v1/admin/communities/index.ts | 8 ++-- .../src/routes/v1/admin/communities/schema.ts | 6 +-- desci-server/src/services/Communities.ts | 8 ++++ 4 files changed, 54 insertions(+), 8 deletions(-) diff --git a/desci-server/src/controllers/admin/communities/index.ts b/desci-server/src/controllers/admin/communities/index.ts index db0b2ca94..e6ffc0221 100644 --- a/desci-server/src/controllers/admin/communities/index.ts +++ b/desci-server/src/controllers/admin/communities/index.ts @@ -1,3 +1,4 @@ +import { CommunityMembershipRole } from '@prisma/client'; import { NextFunction, Request, Response } from 'express'; import { z } from 'zod'; @@ -9,12 +10,15 @@ import { DuplicateDataError, NotFoundError, logger as parentLogger, + prisma, SuccessMessageResponse, SuccessResponse, } from '../../../internal.js'; import { addAttestationSchema, addCommunitySchema, + addMemberSchema, + removeMemberSchema, updateAttestationSchema, updateCommunitySchema, } from '../../../routes/v1/admin/communities/schema.js'; @@ -232,3 +236,39 @@ export const updateAttestation = async (req: Request, res: Response, _next: Next }); new SuccessResponse(attestation).send(res); }; + +export const addMember = async (req: Request, res: Response, _next: NextFunction) => { + const { userId, role }: Required['body']> = req.body; + const { communityId }: z.infer['params'] = req.params; + + const user = await prisma.user.findFirst({ where: { id: userId } }); + if (!user) throw new NotFoundError('Invalid user'); + + const community = await communityService.findCommunityById(Number(communityId)); + if (!community) throw new NotFoundError(`No Desci community with ID: ${Number(communityId)} found!`); + + const exists = await communityService.findMemberByUserId(Number(communityId), userId); + if (exists) throw new DuplicateDataError(); + + const member = await communityService.addCommunityMember(parseInt(communityId), { + userId, + communityId: parseInt(communityId), + role, + }); + + new SuccessResponse(member).send(res); +}; + +export const removeMember = async (req: Request, res: Response, _next: NextFunction) => { + const { communityId, memberId }: z.infer['params'] = req.params; + + const community = await communityService.findCommunityById(Number(communityId)); + if (!community) throw new NotFoundError(`No Desci community with ID: ${Number(communityId)} found!`); + + const exists = await communityService.findMemberById(Number(memberId)); + if (!exists) throw new NotFoundError(); + + await communityService.removeMemberById(Number(memberId)); + + new SuccessMessageResponse().send(res); +}; diff --git a/desci-server/src/routes/v1/admin/communities/index.ts b/desci-server/src/routes/v1/admin/communities/index.ts index 0a32bbf35..5c807d836 100644 --- a/desci-server/src/routes/v1/admin/communities/index.ts +++ b/desci-server/src/routes/v1/admin/communities/index.ts @@ -4,9 +4,11 @@ import multer from 'multer'; import multerS3 from 'multer-s3'; import { + addMember, createAttestation, createCommunity, listAllCommunities, + removeMember, todoApi, updateAttestation, updateCommunity, @@ -101,14 +103,12 @@ router.put( asyncHandler(updateAttestation), ); -// todo: api to add a desci community member -router.post('/:communityId/members', [ensureUser, ensureAdmin, validate(addMemberSchema)], asyncHandler(todoApi)); +router.post('/:communityId/members', [ensureUser, ensureAdmin, validate(addMemberSchema)], asyncHandler(addMember)); -// todo: api to remove a desci community member router.delete( '/:communityId/members/:memberId', [ensureUser, ensureAdmin, validate(removeMemberSchema)], - asyncHandler(todoApi), + asyncHandler(removeMember), ); // todo: api to link attestation to community (this adds it to the communityEntryAttestation) diff --git a/desci-server/src/routes/v1/admin/communities/schema.ts b/desci-server/src/routes/v1/admin/communities/schema.ts index 5ffcaff83..9600b2a73 100644 --- a/desci-server/src/routes/v1/admin/communities/schema.ts +++ b/desci-server/src/routes/v1/admin/communities/schema.ts @@ -58,10 +58,10 @@ export const updateAttestationSchema = addAttestationSchema.extend({ export const addMemberSchema = z.object({ params: z.object({ - communityId: z.coerce.number(), + communityId: z.string(), }), body: z.object({ - userId: z.coerce.number(), + userId: z.number(), role: z.enum([CommunityMembershipRole.ADMIN, CommunityMembershipRole.MEMBER]), }), }); @@ -69,8 +69,6 @@ export const addMemberSchema = z.object({ export const removeMemberSchema = z.object({ params: z.object({ communityId: z.coerce.number(), - }), - body: z.object({ memberId: z.coerce.number(), }), }); diff --git a/desci-server/src/services/Communities.ts b/desci-server/src/services/Communities.ts index bac794c04..6e9a467aa 100644 --- a/desci-server/src/services/Communities.ts +++ b/desci-server/src/services/Communities.ts @@ -318,9 +318,17 @@ export class CommunityService { return await prisma.communityMember.findUnique({ where: { userId_communityId: { userId, communityId } } }); } + async findMemberById(id: number) { + return await prisma.communityMember.findUnique({ where: { id } }); + } + async removeMember(communityId: number, userId: number) { return prisma.communityMember.delete({ where: { userId_communityId: { userId, communityId } } }); } + + async removeMemberById(id: number) { + return prisma.communityMember.delete({ where: { id } }); + } } export const communityService = new CommunityService(); From c40c9739f8a0744b3c120b4150aa6d70af7098af Mon Sep 17 00:00:00 2001 From: shadrach-tayo Date: Tue, 24 Sep 2024 04:49:37 -0500 Subject: [PATCH 35/81] implement apis for adding/removing community required attestations --- .../controllers/admin/communities/index.ts | 37 +++++++++++++++++++ .../src/routes/v1/admin/communities/index.ts | 16 ++++---- .../src/routes/v1/admin/communities/schema.ts | 11 ------ desci-server/src/services/Attestation.ts | 24 ++++++++++++ 4 files changed, 69 insertions(+), 19 deletions(-) diff --git a/desci-server/src/controllers/admin/communities/index.ts b/desci-server/src/controllers/admin/communities/index.ts index e6ffc0221..2daba8585 100644 --- a/desci-server/src/controllers/admin/communities/index.ts +++ b/desci-server/src/controllers/admin/communities/index.ts @@ -17,6 +17,7 @@ import { import { addAttestationSchema, addCommunitySchema, + addEntryAttestationSchema, addMemberSchema, removeMemberSchema, updateAttestationSchema, @@ -272,3 +273,39 @@ export const removeMember = async (req: Request, res: Response, _next: NextFunct new SuccessMessageResponse().send(res); }; + +export const addEntryAttestation = async (req: Request, res: Response, _next: NextFunction) => { + const { communityId, attestationId }: z.infer['params'] = req.params; + + const community = await communityService.findCommunityById(Number(communityId)); + if (!community) throw new NotFoundError(`No Desci community with ID: ${Number(communityId)} not found!`); + + const attestation = await attestationService.findAttestationById(+attestationId); + if (!attestation) throw new NotFoundError(`No attestation with ID: ${Number(attestationId)} not found!`); + + const exists = await attestationService.getCommunityEntryAttestation(Number(communityId), Number(attestationId)); + if (exists) throw new DuplicateDataError(); + + const data = await attestationService.addCommunityEntryAttestation({ + communityId: Number(communityId), + attestationId: Number(attestationId), + attestationVersion: attestation.AttestationVersion[attestation.AttestationVersion.length - 1].id, + }); + + new SuccessResponse(data).send(res); +}; + +export const removeEntryAttestation = async (req: Request, res: Response, _next: NextFunction) => { + const { communityId, attestationId }: z.infer['params'] = req.params; + + const attestation = await attestationService.findAttestationById(+attestationId); + if (!attestation) throw new NotFoundError(`No attestation with ID: ${Number(attestationId)} not found!`); + + const data = await attestationService.removeCommunityEntryAttestation({ + communityId: Number(communityId), + attestationId: Number(attestationId), + attestationVersion: attestation.AttestationVersion[attestation.AttestationVersion.length - 1].id, + }); + + new SuccessResponse(data).send(res); +}; diff --git a/desci-server/src/routes/v1/admin/communities/index.ts b/desci-server/src/routes/v1/admin/communities/index.ts index 5c807d836..f09a1b45f 100644 --- a/desci-server/src/routes/v1/admin/communities/index.ts +++ b/desci-server/src/routes/v1/admin/communities/index.ts @@ -4,12 +4,13 @@ import multer from 'multer'; import multerS3 from 'multer-s3'; import { + addEntryAttestation, addMember, createAttestation, createCommunity, listAllCommunities, + removeEntryAttestation, removeMember, - todoApi, updateAttestation, updateCommunity, } from '../../../../controllers/admin/communities/index.js'; @@ -21,7 +22,6 @@ import { addCommunitySchema, addEntryAttestationSchema, addMemberSchema, - removeEntryAttestationSchema, removeMemberSchema, updateAttestationSchema, updateCommunitySchema, @@ -113,16 +113,16 @@ router.delete( // todo: api to link attestation to community (this adds it to the communityEntryAttestation) router.post( - '/:communityId/addEntryAttestation', + '/:communityId/addEntryAttestation/:attestationId', [ensureUser, ensureAdmin, validate(addEntryAttestationSchema)], - asyncHandler(todoApi), + asyncHandler(addEntryAttestation), ); // todo: api to remove attestation as required in for community (remove communityEntryAttestation) -router.post( - '/:communityId/removeEntryAttestation', - [ensureUser, ensureAdmin, validate(removeEntryAttestationSchema)], - asyncHandler(todoApi), +router.delete( + '/:communityId/removeEntryAttestation/:attestationId', + [ensureUser, ensureAdmin, validate(addEntryAttestationSchema)], + asyncHandler(removeEntryAttestation), ); export default router; diff --git a/desci-server/src/routes/v1/admin/communities/schema.ts b/desci-server/src/routes/v1/admin/communities/schema.ts index 9600b2a73..1c3467e13 100644 --- a/desci-server/src/routes/v1/admin/communities/schema.ts +++ b/desci-server/src/routes/v1/admin/communities/schema.ts @@ -76,17 +76,6 @@ export const removeMemberSchema = z.object({ export const addEntryAttestationSchema = z.object({ params: z.object({ communityId: z.coerce.number(), - }), - body: z.object({ - attestationId: z.coerce.number(), - }), -}); - -export const removeEntryAttestationSchema = z.object({ - params: z.object({ - communityId: z.coerce.number(), - }), - body: z.object({ attestationId: z.coerce.number(), }), }); diff --git a/desci-server/src/services/Attestation.ts b/desci-server/src/services/Attestation.ts index 48a690d8a..8a7fbbb1a 100644 --- a/desci-server/src/services/Attestation.ts +++ b/desci-server/src/services/Attestation.ts @@ -17,6 +17,7 @@ import { DuplicateReactionError, DuplicateVerificationError, NoAccessError, + NotFoundError, VerificationError, VerificationNotFoundError, ensureUuidEndsWithDot, @@ -239,6 +240,23 @@ export class AttestationService { }); } + async removeCommunityEntryAttestation({ + communityId, + attestationId, + attestationVersion: version, + }: { + communityId: number; + attestationId: number; + attestationVersion: number; + }) { + const existingSelection = await prisma.communityEntryAttestation.findFirst({ + where: { desciCommunityId: communityId, attestationId, attestationVersionId: version }, + }); + if (!existingSelection) return null; + + return await prisma.communityEntryAttestation.delete({ where: { id: existingSelection.id } }); + } + async getAllNodeAttestations(uuid: string) { return prisma.nodeAttestation.findMany({ where: { nodeUuid: ensureUuidEndsWithDot(uuid), revoked: false }, @@ -300,6 +318,12 @@ export class AttestationService { }); } + async getCommunityEntryAttestation(communityId: number, attestationId: number) { + return prisma.communityEntryAttestation.findFirst({ + where: { desciCommunityId: communityId, attestationId, required: true }, + }); + } + async getCommunityEntryAttestations(communityId: number) { const community = await communityService.findCommunityById(communityId); if (!community) throw new CommunityNotFoundError(); From 42c5f7c55595f2d885477370b185e4cb7090243a Mon Sep 17 00:00:00 2001 From: Sina Iman Date: Tue, 24 Sep 2024 11:49:41 +0200 Subject: [PATCH 36/81] sanitize output for email --- desci-server/src/services/auth.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/desci-server/src/services/auth.ts b/desci-server/src/services/auth.ts index 3145f4e20..193df0ea7 100644 --- a/desci-server/src/services/auth.ts +++ b/desci-server/src/services/auth.ts @@ -124,7 +124,7 @@ const sendMagicLinkEmail = async (email: string, ip?: string) => { }); if (env.SHOULD_SEND_EMAIL) { - logger.info({ fn: 'sendMagicLinkEmail', email, token }, `Sending actual email to ${email} token: ${token}`); + logger.info({ fn: 'sendMagicLinkEmail', email }, `Sending actual email`); const url = `${env.DAPP_URL}/web/login?e=${email}&c=${token}`; const goodIp = ip?.length > 0 && ip !== '::1' && ip !== '127.0.0.1' && ip !== 'localhost'; From 8a3ffc64c421eca41b6737d38f3beb56b5620516 Mon Sep 17 00:00:00 2001 From: shadrach-tayo Date: Tue, 24 Sep 2024 05:00:09 -0500 Subject: [PATCH 37/81] clean up --- desci-server/src/routes/v1/admin/communities/index.ts | 2 -- 1 file changed, 2 deletions(-) diff --git a/desci-server/src/routes/v1/admin/communities/index.ts b/desci-server/src/routes/v1/admin/communities/index.ts index f09a1b45f..d6acaa0bb 100644 --- a/desci-server/src/routes/v1/admin/communities/index.ts +++ b/desci-server/src/routes/v1/admin/communities/index.ts @@ -111,14 +111,12 @@ router.delete( asyncHandler(removeMember), ); -// todo: api to link attestation to community (this adds it to the communityEntryAttestation) router.post( '/:communityId/addEntryAttestation/:attestationId', [ensureUser, ensureAdmin, validate(addEntryAttestationSchema)], asyncHandler(addEntryAttestation), ); -// todo: api to remove attestation as required in for community (remove communityEntryAttestation) router.delete( '/:communityId/removeEntryAttestation/:attestationId', [ensureUser, ensureAdmin, validate(addEntryAttestationSchema)], From 164b56e13da4846709a0fe4df4419e7488d8682b Mon Sep 17 00:00:00 2001 From: m0ar Date: Tue, 24 Sep 2024 12:19:50 +0200 Subject: [PATCH 38/81] ceramic: bump nodes to 6.5.0 --- ceramic-k8s/ceramic_deployment_dev.yaml | 2 +- ceramic-k8s/ceramic_deployment_prod.yaml | 2 +- docker-compose.dev.yml | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/ceramic-k8s/ceramic_deployment_dev.yaml b/ceramic-k8s/ceramic_deployment_dev.yaml index 58946e7ec..68f3fd464 100644 --- a/ceramic-k8s/ceramic_deployment_dev.yaml +++ b/ceramic-k8s/ceramic_deployment_dev.yaml @@ -41,7 +41,7 @@ spec: App: JsCeramicDev spec: containers: - - image: ceramicnetwork/js-ceramic:6.4.0 + - image: ceramicnetwork/js-ceramic:6.5.0 name: js-ceramic-dev command: ["/bin/bash", "-c"] args: diff --git a/ceramic-k8s/ceramic_deployment_prod.yaml b/ceramic-k8s/ceramic_deployment_prod.yaml index ce84fecec..7ed15bb76 100644 --- a/ceramic-k8s/ceramic_deployment_prod.yaml +++ b/ceramic-k8s/ceramic_deployment_prod.yaml @@ -62,7 +62,7 @@ spec: App: JsCeramicProd spec: containers: - - image: ceramicnetwork/js-ceramic:6.4.0 + - image: ceramicnetwork/js-ceramic:6.5.0 name: js-ceramic-prod command: ["/bin/bash", "-c"] volumeMounts: diff --git a/docker-compose.dev.yml b/docker-compose.dev.yml index 2be51c7fe..faba1ceca 100755 --- a/docker-compose.dev.yml +++ b/docker-compose.dev.yml @@ -184,7 +184,7 @@ services: - ./local-data/redis:/data ceramic: - image: ceramicnetwork/js-ceramic:6.4.0 + image: ceramicnetwork/js-ceramic:6.5.0 container_name: ceramic ports: - "7007:7007" From 82b1782a58bf3724aceb014c4a55862cd959c017 Mon Sep 17 00:00:00 2001 From: m0ar Date: Tue, 24 Sep 2024 16:09:29 +0200 Subject: [PATCH 39/81] server: include stream & dpid with other public info in checkNodeAccess --- desci-server/src/controllers/nodes/byDpid.ts | 4 ++++ .../src/controllers/nodes/checkNodeAccess.ts | 14 +++++++------- 2 files changed, 11 insertions(+), 7 deletions(-) diff --git a/desci-server/src/controllers/nodes/byDpid.ts b/desci-server/src/controllers/nodes/byDpid.ts index 10b575e24..b3a2077e0 100755 --- a/desci-server/src/controllers/nodes/byDpid.ts +++ b/desci-server/src/controllers/nodes/byDpid.ts @@ -14,6 +14,8 @@ type NodeByDpidParams = { type NodeByDpidSuccess = { uuid: string; + dpidAlias: number; + ceramicStream: string; }; type NodeByDpidError = { @@ -43,6 +45,8 @@ export const nodeByDpid = async ( node = await prisma.node.findFirstOrThrow({ select: { uuid: true, + dpidAlias: true, + ceramicStream: true, }, where: { dpidAlias: { diff --git a/desci-server/src/controllers/nodes/checkNodeAccess.ts b/desci-server/src/controllers/nodes/checkNodeAccess.ts index da59758e1..4f6c8feb6 100644 --- a/desci-server/src/controllers/nodes/checkNodeAccess.ts +++ b/desci-server/src/controllers/nodes/checkNodeAccess.ts @@ -13,8 +13,10 @@ type GetCheckNodeAccessResponse = { isOwner: boolean; isShared: boolean; hasAccess: boolean; - sharedOn?: number; isPublished: boolean; + ceramicStream?: string; + dpidAlias?: number; + sharedOn?: number; recentCid?: string; manifestUrl?: string; }; @@ -42,14 +44,10 @@ export const checkNodeAccess = async ( const node = await prisma.node.findFirst({ select: { uuid: true, - id: true, - createdAt: true, - updatedAt: true, ownerId: true, - title: true, manifestUrl: true, - cid: true, - NodeCover: true, + dpidAlias: true, + ceramicStream: true, versions: { select: { manifestUrl: true, @@ -92,6 +90,8 @@ export const checkNodeAccess = async ( isShared: !isOwner && !!privSharedNode, hasAccess, isPublished, + ceramicStream: node.ceramicStream, + dpidAlias: node.dpidAlias, sharedOn: privSharedNode?.createdAt.getTime(), recentCid: latestPublishedVersion?.manifestUrl, manifestUrl: hasAccess ? node.versions[0]?.manifestUrl : undefined, From 04ba63ee3b0cfa38b5c2e6c2cb0ab33a3bf0f00c Mon Sep 17 00:00:00 2001 From: shadrach-tayo Date: Tue, 24 Sep 2024 17:45:26 -0500 Subject: [PATCH 40/81] fix: Orcid Nodes dataset work record dpid path, clear orcid work record if no claims are found --- desci-server/src/services/orcid.ts | 36 +++++++++++++++++------------- desci-server/src/theGraph.ts | 22 +++++++++++++----- 2 files changed, 36 insertions(+), 22 deletions(-) diff --git a/desci-server/src/services/orcid.ts b/desci-server/src/services/orcid.ts index c3cc0a60a..751be20d6 100644 --- a/desci-server/src/services/orcid.ts +++ b/desci-server/src/services/orcid.ts @@ -54,7 +54,6 @@ class OrcidApiService { throw new Error('User does not have an orcid auth token'); } - // todo: refresh token if necessary try { const url = `https://${ORCID_DOMAIN}/oauth/token`; @@ -125,6 +124,9 @@ class OrcidApiService { * @returns */ async removeClaimRecord({ claimId, nodeUuid, orcid }: { claimId: number; nodeUuid: string; orcid: string }) { + const user = await prisma.user.findUnique({ where: { orcid } }); + const authToken = await this.getAccessToken(user.id); + const putCode = await prisma.orcidPutCodes.findFirst({ where: { claimId, @@ -133,18 +135,13 @@ class OrcidApiService { }, }); - if (!putCode) return; - - const user = await prisma.user.findUnique({ where: { orcid } }); - const authToken = await this.getAccessToken(user.id); - logger.info({ userId: user.id, authToken: !!authToken, nodeUuid }, '[ORCID::DELETE]:: START'); + // remove claim record on Orcid profile + if (putCode) { + logger.info({ userId: user.id, authToken: !!authToken, nodeUuid }, '[ORCID::DELETE]:: START'); - await this.removeWorkRecord({ orcid, putCode, authToken }); + await this.removeWorkRecord({ orcid, putCode, authToken }); + } - const { researchObjects } = await getIndexedResearchObjects([nodeUuid]); - const researchObject = researchObjects[0] as IndexedResearchObject; - const manifestCid = hexToCid(researchObject.recentCid); - const latestManifest = await getManifestByCid(manifestCid); let claims = await attestationService.getProtectedNodeClaims(nodeUuid); claims = claims.filter((claim) => claim.verifications > 0); logger.info({ claims: claims.length }, '[ORCID::DELETE]:: CHECK CLAIMS'); @@ -185,7 +182,7 @@ class OrcidApiService { code, orcid, }, - 'ORCID API DELETE RECORD', + 'ORCID API DELETE WORK RECORD', ); const response = await fetch(url, { method: 'DELETE', @@ -253,8 +250,14 @@ class OrcidApiService { let claims = await attestationService.getProtectedNodeClaims(nodeUuid); claims = claims.filter((claim) => claim.verifications > 0); - // TODO: if claims is empty remove orcid record - if (claims.length === 0) return; + if (claims.length === 0) { + const orcidPutCode = await prisma.orcidPutCodes.findUnique({ + where: { orcid_uuid_reference: { orcid, uuid: nodeUuid, reference: PutcodeReference.PREPRINT } }, + }); + + await orcidApiService.removeWorkRecord({ authToken, putCode: orcidPutCode, orcid: user.orcid }); + return; + } const latestVersion = researchObject.versions[researchObject.versions.length - 1]; const publicationDate = new Date(parseInt(latestVersion.time) * 1000).toLocaleDateString().replaceAll('/', '-'); @@ -270,8 +273,9 @@ class OrcidApiService { manifest: latestManifest, }); const claimRecordPromises = claims.map((claim) => { - const claimedVersionNumber = claims[claims.length - 1].nodeVersion; - const claimedVersion = researchObject.versions[claimedVersionNumber]; + const versionIndex = claims[claims.length - 1].nodeVersion; + const claimedVersionNumber = versionIndex + 1; + const claimedVersion = researchObject.versions[versionIndex]; const publicationDate = new Date(parseInt(claimedVersion.time) * 1000) .toLocaleDateString() .replaceAll('/', '-'); diff --git a/desci-server/src/theGraph.ts b/desci-server/src/theGraph.ts index 1e3cf9475..709b3b36e 100644 --- a/desci-server/src/theGraph.ts +++ b/desci-server/src/theGraph.ts @@ -77,7 +77,7 @@ export const getIndexedResearchObjects = async ( For stream resolution, build a map to allow for also returning the UUID to match the format returned by the graph lookup */ - const streamLookupMap: Record = {}; + let streamLookupMap: Record = {}; /** For legacy nodes, the graph lookup only needs the UUID */ const legacyUuids = []; @@ -100,6 +100,16 @@ export const getIndexedResearchObjects = async ( } } + /** + * fallback to _getIndexedResearchObjects() when resolving locally + * because calls to getHistoryFromStreams() never returns due to + * RESOLVER_URL not configured for local dpid resolution + */ + if (process.env.NODE_ENV === 'dev') { + legacyUuids.push(...paddedUuids); + streamLookupMap = {}; + } + let streamHistory = []; if (Object.keys(streamLookupMap).length > 0) { logger.info({ streamLookupMap }, 'Querying resolver for history'); @@ -109,7 +119,7 @@ export const getIndexedResearchObjects = async ( let legacyHistory = []; if (legacyUuids.length > 0) { - logger.info({ legacyUuids }, 'Falling back to subgraph query for history'); + logger.info({ legacyUuids, _urlSafeBase64s }, 'Falling back to subgraph query for history'); legacyHistory = (await _getIndexedResearchObjects(legacyUuids)).researchObjects; logger.info({ legacyHistory }, 'Subgraph history for nodes found'); } @@ -201,7 +211,7 @@ export const _getIndexedResearchObjects = async ( export const getTimeForTxOrCommits = async (txOrCommits: string[]): Promise> => { const isTx = (id: string) => id.startsWith('0x'); const txIds = txOrCommits.filter(isTx); - const commitIdStrs = txOrCommits.filter(id => !isTx(id)); + const commitIdStrs = txOrCommits.filter((id) => !isTx(id)); const commitTimeMap = await getCommitTimestamps(commitIdStrs); const txTimeMap = await getTxTimestamps(txIds); @@ -221,15 +231,15 @@ const getTxTimestamps = async (txIds: string[]): Promise> try { const graphTxTimestamps = await getTxTimeFromGraph(txIds); const timeMap = graphTxTimestamps.reduce( - (acc, { id, time }) => ({ ...acc, [id]: time}), + (acc, { id, time }) => ({ ...acc, [id]: time }), {} as Record, ); return timeMap; } catch (err) { logger.error({ txIds, err }, 'failed to get tx timestamps from graph, returning empty map'); return {}; - }; -} + } +}; type TransactionsWithTimestamp = { researchObjectVersions: { id: string; time: string }[]; From 85e042d4698565e43586bd25ddc12d4b474a3718 Mon Sep 17 00:00:00 2001 From: kadami <86646883+kadamidev@users.noreply.github.com> Date: Wed, 25 Sep 2024 10:44:32 +0000 Subject: [PATCH 41/81] adjust match filter to handle arrays --- .../src/services/ElasticSearchService.ts | 32 ++++++++++++++----- 1 file changed, 24 insertions(+), 8 deletions(-) diff --git a/desci-server/src/services/ElasticSearchService.ts b/desci-server/src/services/ElasticSearchService.ts index 100732aa3..9a9a84383 100644 --- a/desci-server/src/services/ElasticSearchService.ts +++ b/desci-server/src/services/ElasticSearchService.ts @@ -255,15 +255,31 @@ function buildFilter(filter: Filter) { return { match_phrase: { [filter.field]: { query: filter.value, analyzer: 'edge_ngram_analyzer' } } }; case 'match': - const matchQuery = { - match: { - [filter.field]: { - query: filter.value, - operator: filter.matchLogic || 'or', - // ...(filter.fuzziness && { fuzziness: filter.fuzziness }), + let matchQuery; + if (Array.isArray(filter.value)) { + matchQuery = { + bool: { + should: filter.value.map((value) => ({ + match: { + [filter.field]: { + query: value, + operator: filter.matchLogic || 'or', + }, + }, + })), + minimum_should_match: 1, }, - }, - }; + }; + } else { + matchQuery = { + match: { + [filter.field]: { + query: filter.value, + operator: filter.matchLogic || 'or', + }, + }, + }; + } if (filter.field.includes('.') && !filter.field.includes('institutions')) { const [nestedPath, nestedField] = filter.field.split('.'); From 14e166ebfae9abec1e44fc740659979c07d6b4c6 Mon Sep 17 00:00:00 2001 From: shadrach-tayo Date: Thu, 26 Sep 2024 13:57:34 -0500 Subject: [PATCH 42/81] series of backend updates to support comments on node without ties to specific attestations/claim --- .../migration.sql | 14 +++++ .../migration.sql | 8 +++ desci-server/prisma/schema.prisma | 16 ++++-- .../src/controllers/attestations/comments.ts | 19 +++++-- .../attestations/recommendations.ts | 3 +- .../src/controllers/nodes/comments.ts | 35 ++++++++++++ .../src/controllers/nodes/createDpid.ts | 20 ++----- desci-server/src/controllers/nodes/index.ts | 5 ++ desci-server/src/controllers/raw/versions.ts | 8 +-- .../src/routes/v1/attestations/index.ts | 2 +- .../src/routes/v1/attestations/schema.ts | 39 +++++++++++-- desci-server/src/routes/v1/nodes.ts | 21 ++++--- desci-server/src/services/Attestation.ts | 57 ++++++++++++++----- desci-server/src/theGraph.ts | 20 +++++-- 14 files changed, 203 insertions(+), 64 deletions(-) create mode 100644 desci-server/prisma/migrations/20240925135142_add_uuid_and_visible_and_make_nodeattestation_id_optional/migration.sql create mode 100644 desci-server/prisma/migrations/20240926094958_remove_nodeid_column_from_annotation/migration.sql create mode 100644 desci-server/src/controllers/nodes/comments.ts diff --git a/desci-server/prisma/migrations/20240925135142_add_uuid_and_visible_and_make_nodeattestation_id_optional/migration.sql b/desci-server/prisma/migrations/20240925135142_add_uuid_and_visible_and_make_nodeattestation_id_optional/migration.sql new file mode 100644 index 000000000..2053e708a --- /dev/null +++ b/desci-server/prisma/migrations/20240925135142_add_uuid_and_visible_and_make_nodeattestation_id_optional/migration.sql @@ -0,0 +1,14 @@ +-- DropForeignKey +ALTER TABLE "Annotation" DROP CONSTRAINT "Annotation_nodeAttestationId_fkey"; + +-- AlterTable +ALTER TABLE "Annotation" ADD COLUMN "nodeId" INTEGER, +ADD COLUMN "uuid" TEXT, +ADD COLUMN "visible" BOOLEAN NOT NULL DEFAULT true, +ALTER COLUMN "nodeAttestationId" DROP NOT NULL; + +-- AddForeignKey +ALTER TABLE "Annotation" ADD CONSTRAINT "Annotation_nodeAttestationId_fkey" FOREIGN KEY ("nodeAttestationId") REFERENCES "NodeAttestation"("id") ON DELETE SET NULL ON UPDATE CASCADE; + +-- AddForeignKey +ALTER TABLE "Annotation" ADD CONSTRAINT "Annotation_uuid_fkey" FOREIGN KEY ("uuid") REFERENCES "Node"("uuid") ON DELETE SET NULL ON UPDATE CASCADE; diff --git a/desci-server/prisma/migrations/20240926094958_remove_nodeid_column_from_annotation/migration.sql b/desci-server/prisma/migrations/20240926094958_remove_nodeid_column_from_annotation/migration.sql new file mode 100644 index 000000000..38ae5b501 --- /dev/null +++ b/desci-server/prisma/migrations/20240926094958_remove_nodeid_column_from_annotation/migration.sql @@ -0,0 +1,8 @@ +/* + Warnings: + + - You are about to drop the column `nodeId` on the `Annotation` table. All the data in the column will be lost. + +*/ +-- AlterTable +ALTER TABLE "Annotation" DROP COLUMN "nodeId"; diff --git a/desci-server/prisma/schema.prisma b/desci-server/prisma/schema.prisma index 8d18e432f..35a756c6e 100755 --- a/desci-server/prisma/schema.prisma +++ b/desci-server/prisma/schema.prisma @@ -50,6 +50,7 @@ model Node { DoiSubmissionQueue DoiSubmissionQueue[] BookmarkedNode BookmarkedNode[] DeferredEmails DeferredEmails[] + Annotation Annotation[] @@index([ownerId]) @@index([uuid]) @@ -810,16 +811,19 @@ enum EmailType { //Comments on attestations model Annotation { - id Int @id @default(autoincrement()) + id Int @id @default(autoincrement()) type AnnotationType body String - highlights Json[] @default([]) - links String[] @default([]) + highlights Json[] @default([]) + links String[] @default([]) authorId Int - author User @relation(fields: [authorId], references: [id]) - nodeAttestationId Int - attestation NodeAttestation @relation(fields: [nodeAttestationId], references: [id]) + author User @relation(fields: [authorId], references: [id]) + nodeAttestationId Int? + attestation NodeAttestation? @relation(fields: [nodeAttestationId], references: [id]) deferredEmailsId Int? + uuid String? + node Node? @relation(fields: [uuid], references: [uuid]) + visible Boolean @default(true) } //An emoji reaction to a node diff --git a/desci-server/src/controllers/attestations/comments.ts b/desci-server/src/controllers/attestations/comments.ts index aebdd6e84..d50e97369 100644 --- a/desci-server/src/controllers/attestations/comments.ts +++ b/desci-server/src/controllers/attestations/comments.ts @@ -1,5 +1,5 @@ import { HighlightBlock } from '@desci-labs/desci-models'; -import { ActionType, Annotation } from '@prisma/client'; +import { ActionType, Annotation, AnnotationType } from '@prisma/client'; import { NextFunction, Request, Response } from 'express'; import _ from 'lodash'; import zod from 'zod'; @@ -13,7 +13,9 @@ import { asyncMap, attestationService, createCommentSchema, + ensureUuidEndsWithDot, logger as parentLogger, + prisma, } from '../../internal.js'; import { saveInteraction } from '../../services/interactionLog.js'; import { client } from '../../services/ipfs.js'; @@ -78,7 +80,7 @@ export const removeComment = async (req: Request, r type AddCommentBody = zod.infer; export const addComment = async (req: Request, res: Response) => { - const { authorId, claimId, body, highlights, links } = req.body; + const { authorId, claimId, body, highlights, links, uuid, visible } = req.body; const user = (req as any).user; if (parseInt(authorId.toString()) !== user.id) throw new ForbiddenError(); @@ -89,6 +91,11 @@ export const addComment = async (req: Request, user: (req as any).user, body: req.body, }); + + if (uuid) { + const node = await prisma.node.findFirst({ where: { uuid: ensureUuidEndsWithDot(uuid) } }); + if (!node) throw new NotFoundError('Node with uuid ${uuid} not found'); + } logger.trace(`addComment`); let annotation: Annotation; @@ -102,19 +109,23 @@ export const addComment = async (req: Request, }); logger.info({ processedHighlights }, 'processedHighlights'); annotation = await attestationService.createHighlight({ - claimId: parseInt(claimId.toString()), + claimId: claimId && parseInt(claimId.toString()), authorId: user.id, comment: body, links, highlights: processedHighlights as unknown as HighlightBlock[], + visible, + uuid: ensureUuidEndsWithDot(uuid), }); await saveInteraction(req, ActionType.ADD_COMMENT, { annotationId: annotation.id, claimId, authorId }); } else { annotation = await attestationService.createComment({ - claimId: parseInt(claimId.toString()), + claimId: claimId && parseInt(claimId.toString()), authorId: user.id, comment: body, links, + visible, + uuid: ensureUuidEndsWithDot(uuid), }); } await saveInteraction(req, ActionType.ADD_COMMENT, { annotationId: annotation.id, claimId, authorId }); diff --git a/desci-server/src/controllers/attestations/recommendations.ts b/desci-server/src/controllers/attestations/recommendations.ts index f20eb18b0..cea1b0d66 100644 --- a/desci-server/src/controllers/attestations/recommendations.ts +++ b/desci-server/src/controllers/attestations/recommendations.ts @@ -60,7 +60,6 @@ export const getValidatedAttestations = async (req: Request, res: Response, _nex logger.info({ communityName }); const community = await communityService.findCommunityByNameOrSlug(communityName); if (!community) throw new NotFoundError('Community not found'); - logger.info({ community }); const attestations = await attestationService.getCommunityAttestations({ communityId: community.id, @@ -83,6 +82,6 @@ export const getValidatedRecommendations = async (req: Request, res: Response, _ communityName: attestation.community.name, AttestationVersion: attestation.AttestationVersion[0], })); - logger.info({ attestations }, 'getValidatedRecommendations'); + logger.info({ recommendations: attestations.length }, 'getValidatedRecommendations'); return new SuccessResponse(response).send(res); }; diff --git a/desci-server/src/controllers/nodes/comments.ts b/desci-server/src/controllers/nodes/comments.ts new file mode 100644 index 000000000..d9149b882 --- /dev/null +++ b/desci-server/src/controllers/nodes/comments.ts @@ -0,0 +1,35 @@ +import { Response, NextFunction } from 'express'; +import _ from 'lodash'; +import z from 'zod'; + +import { + NotFoundError, + RequestWithNode, + SuccessResponse, + attestationService, + ensureUuidEndsWithDot, + getCommentsSchema, + logger, + prisma, +} from '../../internal.js'; + +export const getGeneralComments = async (req: RequestWithNode, res: Response, _next: NextFunction) => { + const { uuid } = req.params as z.infer['params']; + const node = await prisma.node.findFirst({ where: { uuid: ensureUuidEndsWithDot(uuid) } }); + if (!node) throw new NotFoundError("Can't comment on unknown research object"); + + const restrictVisibility = node.ownerId !== req?.user?.id; + + logger.info({ restrictVisibility }, 'Query Comments'); + const comments = await attestationService.getComments({ + uuid: ensureUuidEndsWithDot(uuid), + ...(restrictVisibility && { visible: true }), + }); + + const data = comments.map((comment) => { + const author = _.pick(comment.author, ['id', 'name', 'orcid']); + return { ...comment, author, highlights: comment.highlights.map((h) => JSON.parse(h as string)) }; + }); + + return new SuccessResponse(data).send(res); +}; diff --git a/desci-server/src/controllers/nodes/createDpid.ts b/desci-server/src/controllers/nodes/createDpid.ts index 2f837387e..8bb5cbf35 100644 --- a/desci-server/src/controllers/nodes/createDpid.ts +++ b/desci-server/src/controllers/nodes/createDpid.ts @@ -7,11 +7,11 @@ import { ethers } from 'ethers'; import { Response } from 'express'; import { Logger } from 'pino'; +import { CERAMIC_API_URL } from '../../config/index.js'; import { logger as parentLogger } from '../../logger.js'; import { RequestWithNode } from '../../middleware/authorisation.js'; -import { setDpidAlias } from '../../services/nodeManager.js'; -import { CERAMIC_API_URL } from '../../config/index.js'; import { getAliasRegistry, getHotWallet, getRegistryOwnerWallet } from '../../services/chain.js'; +import { setDpidAlias } from '../../services/nodeManager.js'; type DpidResponse = DpidSuccessResponse | DpidErrorResponse; export type DpidSuccessResponse = { @@ -56,9 +56,7 @@ export const createDpid = async (req: RequestWithNode, res: Response => { +export const getOrCreateDpid = async (streamId: string): Promise => { const logger = parentLogger.child({ module: 'NODE::mintDpid', ceramicStream: streamId, @@ -97,10 +95,7 @@ export const getOrCreateDpid = async ( * Note: this method in the registry contract is only callable by contract * owner, so this is not generally available. */ -export const upgradeDpid = async ( - dpid: number, - ceramicStream: string -): Promise => { +export const upgradeDpid = async (dpid: number, ceramicStream: string): Promise => { const logger = parentLogger.child({ module: 'NODE::upgradeDpid', ceramicStream, @@ -130,12 +125,7 @@ export const upgradeDpid = async ( * This should be checked before upgrading a dPID, to make sure * the new stream accurately represents the publish history. */ -const validateHistory = async ( - dpid: number, - ceramicStream: string, - registry: DpidAliasRegistry, - logger: Logger -) => { +const validateHistory = async (dpid: number, ceramicStream: string, registry: DpidAliasRegistry, logger: Logger) => { const client = newCeramicClient(CERAMIC_API_URL); const legacyEntry = await registry.legacyLookup(dpid); diff --git a/desci-server/src/controllers/nodes/index.ts b/desci-server/src/controllers/nodes/index.ts index 08a710fbf..886f695b0 100755 --- a/desci-server/src/controllers/nodes/index.ts +++ b/desci-server/src/controllers/nodes/index.ts @@ -13,3 +13,8 @@ export * from './nodesCover.js'; export * from './manager.js'; export * from './metadata.js'; export * from './doi.js'; +export * from './comments.js'; +export * from './sharedNodes.js'; +export * from './searchNodes.js'; +export * from './versionDetails.js'; +export * from './thumbnails.js'; diff --git a/desci-server/src/controllers/raw/versions.ts b/desci-server/src/controllers/raw/versions.ts index 33ca75b87..cd63bc00b 100644 --- a/desci-server/src/controllers/raw/versions.ts +++ b/desci-server/src/controllers/raw/versions.ts @@ -5,7 +5,7 @@ import { getIndexedResearchObjects, IndexedResearchObject } from '../../theGraph import { ensureUuidEndsWithDot } from '../../utils.js'; const logger = parentLogger.child({ - module: "RAW::versionsController" + module: 'RAW::versionsController', }); /** @@ -19,12 +19,10 @@ export const versions = async (req: Request, res: Response, next: NextFunction) const { researchObjects } = await getIndexedResearchObjects([uuid]); result = researchObjects[0]; } catch (err) { - logger.error( - { result, err }, `[ERROR] graph lookup fail ${err.message}`, - ); + logger.error({ result, err }, `[ERROR] graph lookup fail ${err.message}`); } if (!result) { - logger.warn({ uuid, result }, "could not find indexed versions"); + logger.warn({ uuid, result }, 'could not find indexed versions'); res.status(404).send({ ok: false, msg: `could not locate uuid ${uuid}` }); return; } diff --git a/desci-server/src/routes/v1/attestations/index.ts b/desci-server/src/routes/v1/attestations/index.ts index aa16950bd..9c17c7e04 100644 --- a/desci-server/src/routes/v1/attestations/index.ts +++ b/desci-server/src/routes/v1/attestations/index.ts @@ -62,7 +62,7 @@ router.post('/claim', [ensureUser, validate(claimAttestationSchema)], asyncHandl router.post('/unclaim', [ensureUser, validate(removeClaimSchema)], asyncHandler(removeClaim)); router.post('/claimAll', [ensureUser, validate(claimEntryAttestationsSchema)], asyncHandler(claimEntryRequirements)); -router.post('/comment', [ensureUser, validate(createCommentSchema)], asyncHandler(addComment)); +router.post('/comments', [ensureUser, validate(createCommentSchema)], asyncHandler(addComment)); router.post('/reaction', [ensureUser, validate(addReactionSchema)], asyncHandler(addReaction)); router.post('/verification', [ensureUser, validate(addVerificationSchema)], asyncHandler(addVerification)); diff --git a/desci-server/src/routes/v1/attestations/schema.ts b/desci-server/src/routes/v1/attestations/schema.ts index 7a8ec37e5..e07f904ab 100644 --- a/desci-server/src/routes/v1/attestations/schema.ts +++ b/desci-server/src/routes/v1/attestations/schema.ts @@ -34,22 +34,47 @@ export const getAttestationCommentsSchema = z.object({ }), }); +export const getCommentsSchema = z.object({ + params: z.object({ + // quickly disqualify false uuid strings + uuid: z.string().min(10), + }), +}); + +const dpidPathRegexPlusLocalResolver = + /^https?:\/\/(?dev-beta\.dpid\.org|beta\.dpid\.org|localhost:5460)\/(?\d+)\/(?v\d+)\/(?\S+.*)?/gm; + export const dpidPathRegex = - /^https:\/\/(?dev-beta|beta)\.dpid\.org\/(?\d+)\/(?v\d+)\/(?\S+.*)?/m; -// /^https:\/\/beta\.dpid\.org\/(?\d+)\/(?v\d+)\/(?\S+.*)?/m; + process.env.NODE_ENV === 'dev' + ? dpidPathRegexPlusLocalResolver + : /^https:\/\/(?dev-beta|beta)\.dpid\.org\/(?\d+)\/(?v\d+)\/(?\S+.*)?/m; + +export const uuidPathRegex = + /^https?:\/\/(?nodes-dev.desci.com|nodes.desci.com|localhost:3000)\/node\/(?[^/^.\s]+)(?\/v\d+)?(?\/root.*)?/m; export const dpidPathSchema = z .string() .url() .refine((link) => dpidPathRegex.test(link), { message: 'Invalid dpid link' }); -// TODO: UPDATE TO A UNION OF CodeHighlightBlock and PdfHighlightBlock +export const uuidPathSchema = z + .string() + .url() + .refine((link) => uuidPathRegex.test(link), { message: 'Invalid uuid link' }); + +export const resourcePathSchema = z + .string() + .url() + .refine((link) => uuidPathRegex.test(link) || dpidPathRegex.test(link), { + message: 'Invalid Resource link', + }); + const pdfHighlightSchema = z .object({ id: z.string(), text: z.string().optional(), image: z.string().optional(), - path: dpidPathSchema, + path: resourcePathSchema, startX: z.coerce.number(), startY: z.coerce.number(), endX: z.coerce.number(), @@ -81,7 +106,7 @@ const pdfHighlightSchema = z const codeHighlightSchema = z.object({ id: z.string(), text: z.string().optional(), - path: dpidPathSchema, + path: resourcePathSchema, cid: z.string(), startLine: z.coerce.number(), endLine: z.coerce.number(), @@ -93,7 +118,7 @@ const highlightBlockSchema = z.union([pdfHighlightSchema, codeHighlightSchema]); const commentSchema = z .object({ authorId: z.coerce.number(), - claimId: z.coerce.number(), + claimId: z.coerce.number().optional(), body: z.string(), links: z .string() @@ -101,6 +126,8 @@ const commentSchema = z .refine((links) => links.every((link) => dpidPathRegex.test(link))) .optional(), highlights: z.array(highlightBlockSchema).optional(), + uuid: z.string().optional(), + visible: z.boolean().default(true), }) .refine((comment) => comment.body?.length > 0 || !!comment?.highlights?.length, { message: 'Either Comment body or highlights is required', diff --git a/desci-server/src/routes/v1/nodes.ts b/desci-server/src/routes/v1/nodes.ts index 9a0b5ddab..d6281514e 100755 --- a/desci-server/src/routes/v1/nodes.ts +++ b/desci-server/src/routes/v1/nodes.ts @@ -27,7 +27,6 @@ import { draftUpdate, list, draftAddComponent, - retrieveDoi, proxyPdf, draftCreate, consent, @@ -50,15 +49,21 @@ import { automateManuscriptDoi, attachDoiSchema, retrieveNodeDoi, + prepublish, + getGeneralComments, + listSharedNodes, + searchNodes, + versionDetails, + thumbnails, } from '../../controllers/nodes/index.js'; import { retrieveTitle } from '../../controllers/nodes/legacyManifestApi.js'; import { preparePublishPackage } from '../../controllers/nodes/preparePublishPackage.js'; -import { prepublish } from '../../controllers/nodes/prepublish.js'; -import { searchNodes } from '../../controllers/nodes/searchNodes.js'; -import { listSharedNodes } from '../../controllers/nodes/sharedNodes.js'; -import { thumbnails } from '../../controllers/nodes/thumbnails.js'; -import { versionDetails } from '../../controllers/nodes/versionDetails.js'; -import { asyncHandler, attachUser, validate, ensureUserIfPresent } from '../../internal.js'; +// import { prepublish } from '../../controllers/nodes/prepublish.js'; +// import { searchNodes } from '../../controllers/nodes/searchNodes.js'; +// import { listSharedNodes } from '../../controllers/nodes/sharedNodes.js'; +// import { thumbnails } from '../../controllers/nodes/thumbnails.js'; +// import { versionDetails } from '../../controllers/nodes/versionDetails.js'; +import { asyncHandler, attachUser, validate, ensureUserIfPresent, getCommentsSchema } from '../../internal.js'; import { ensureNodeAccess, ensureWriteNodeAccess } from '../../middleware/authorisation.js'; import { ensureUser } from '../../middleware/permissions.js'; @@ -133,6 +138,8 @@ router.post( router.delete('/:uuid', [ensureUser], deleteNode); +router.get('/:uuid/comments', [validate(getCommentsSchema), attachUser], asyncHandler(getGeneralComments)); + router.get('/feed', [], feed); router.get('/legacy/retrieveTitle', retrieveTitle); diff --git a/desci-server/src/services/Attestation.ts b/desci-server/src/services/Attestation.ts index 8a7fbbb1a..c459ca777 100644 --- a/desci-server/src/services/Attestation.ts +++ b/desci-server/src/services/Attestation.ts @@ -581,21 +581,27 @@ export class AttestationService { authorId, comment, links, + uuid, + visible = true, }: { - claimId: number; + claimId?: number; authorId: number; comment: string; links: string[]; + uuid?: string; + visible: boolean; }) { assert(authorId > 0, 'Error: authorId is zero'); - assert(claimId > 0, 'Error: claimId is zero'); + claimId && assert(claimId > 0, 'Error: claimId is zero'); - const claim = await this.findClaimById(claimId); - if (!claim) throw new ClaimNotFoundError(); + if (claimId) { + const claim = await this.findClaimById(claimId); + if (!claim) throw new ClaimNotFoundError(); - const attestation = await this.findAttestationById(claim.attestationId); - if (attestation.protected) { - await this.assertUserIsMember(authorId, attestation.communityId); + const attestation = await this.findAttestationById(claim.attestationId); + if (attestation.protected) { + await this.assertUserIsMember(authorId, attestation.communityId); + } } const data: Prisma.AnnotationUncheckedCreateInput = { @@ -604,6 +610,8 @@ export class AttestationService { nodeAttestationId: claimId, body: comment, links, + uuid, + visible, }; return this.createAnnotation(data); } @@ -614,22 +622,28 @@ export class AttestationService { comment, highlights, links, + uuid, + visible, }: { claimId: number; authorId: number; comment: string; links: string[]; highlights: HighlightBlock[]; + uuid?: string; + visible: boolean; }) { assert(authorId > 0, 'Error: authorId is zero'); - assert(claimId > 0, 'Error: claimId is zero'); + claimId && assert(claimId > 0, 'Error: claimId is zero'); - const claim = await this.findClaimById(claimId); - if (!claim) throw new ClaimNotFoundError(); + if (claimId) { + const claim = await this.findClaimById(claimId); + if (!claim) throw new ClaimNotFoundError(); - const attestation = await this.findAttestationById(claim.attestationId); - if (attestation.protected) { - await this.assertUserIsMember(authorId, attestation.communityId); + const attestation = await this.findAttestationById(claim.attestationId); + if (attestation.protected) { + await this.assertUserIsMember(authorId, attestation.communityId); + } } const data: Prisma.AnnotationUncheckedCreateInput = { @@ -639,6 +653,8 @@ export class AttestationService { body: comment, links, highlights: highlights.map((h) => JSON.stringify(h)), + uuid, + visible, }; return this.createAnnotation(data); } @@ -728,6 +744,21 @@ export class AttestationService { }); } + async getComments(filter: Prisma.AnnotationWhereInput) { + logger.info({ filter }, 'GET COMMENTS'); + return prisma.annotation.findMany({ + where: filter, + include: { + author: true, + attestation: { + include: { + attestationVersion: { select: { name: true, description: true, image_url: true, createdAt: true } }, + }, + }, + }, + }); + } + /** * List all attestations and their engagements metrics across all claimed attestations * @returns AttestationWithEngagement[] diff --git a/desci-server/src/theGraph.ts b/desci-server/src/theGraph.ts index 1e3cf9475..15e602afa 100644 --- a/desci-server/src/theGraph.ts +++ b/desci-server/src/theGraph.ts @@ -77,7 +77,7 @@ export const getIndexedResearchObjects = async ( For stream resolution, build a map to allow for also returning the UUID to match the format returned by the graph lookup */ - const streamLookupMap: Record = {}; + let streamLookupMap: Record = {}; /** For legacy nodes, the graph lookup only needs the UUID */ const legacyUuids = []; @@ -100,6 +100,16 @@ export const getIndexedResearchObjects = async ( } } + /** + * fallback to _getIndexedResearchObjects() when resolving locally + * because calls to getHistoryFromStreams() never returns due to + * RESOLVER_URL not configured for local dpid resolution + */ + if (process.env.NODE_ENV === 'dev') { + legacyUuids.push(...paddedUuids); + streamLookupMap = {}; + } + let streamHistory = []; if (Object.keys(streamLookupMap).length > 0) { logger.info({ streamLookupMap }, 'Querying resolver for history'); @@ -201,7 +211,7 @@ export const _getIndexedResearchObjects = async ( export const getTimeForTxOrCommits = async (txOrCommits: string[]): Promise> => { const isTx = (id: string) => id.startsWith('0x'); const txIds = txOrCommits.filter(isTx); - const commitIdStrs = txOrCommits.filter(id => !isTx(id)); + const commitIdStrs = txOrCommits.filter((id) => !isTx(id)); const commitTimeMap = await getCommitTimestamps(commitIdStrs); const txTimeMap = await getTxTimestamps(txIds); @@ -221,15 +231,15 @@ const getTxTimestamps = async (txIds: string[]): Promise> try { const graphTxTimestamps = await getTxTimeFromGraph(txIds); const timeMap = graphTxTimestamps.reduce( - (acc, { id, time }) => ({ ...acc, [id]: time}), + (acc, { id, time }) => ({ ...acc, [id]: time }), {} as Record, ); return timeMap; } catch (err) { logger.error({ txIds, err }, 'failed to get tx timestamps from graph, returning empty map'); return {}; - }; -} + } +}; type TransactionsWithTimestamp = { researchObjectVersions: { id: string; time: string }[]; From 56ee6069087a3d1cbc5d46c340d01a6c32b15852 Mon Sep 17 00:00:00 2001 From: m0ar Date: Fri, 27 Sep 2024 10:12:21 +0200 Subject: [PATCH 43/81] ceramic: enable metrics scraping endpoiunts, fixed dev deployment strat, bump dev to anchor healing rc --- .ceramicDev.config.json | 7 +-- ceramic-k8s/ceramic_deployment_dev.yaml | 58 +++++++++++++++--------- ceramic-k8s/ceramic_deployment_prod.yaml | 50 +++++++++++++------- docker-compose.dev.yml | 1 + 4 files changed, 74 insertions(+), 42 deletions(-) diff --git a/.ceramicDev.config.json b/.ceramicDev.config.json index 3f5d12749..d49f91f76 100644 --- a/.ceramicDev.config.json +++ b/.ceramicDev.config.json @@ -1,5 +1,5 @@ { - "anchor": { }, + "anchor": {}, "http-api": { "cors-allowed-origins": [ ".*" @@ -16,8 +16,8 @@ "log-level": 2 }, "metrics": { - "metrics-exporter-enabled": false, - "metrics-port": 9090 + "prometheus-exporter-enabled": true, + "prometheus-exporter-port": 9464 }, "network": { "name": "inmemory" @@ -33,3 +33,4 @@ "models": [] } } + diff --git a/ceramic-k8s/ceramic_deployment_dev.yaml b/ceramic-k8s/ceramic_deployment_dev.yaml index 68f3fd464..5aa80dcdf 100644 --- a/ceramic-k8s/ceramic_deployment_dev.yaml +++ b/ceramic-k8s/ceramic_deployment_dev.yaml @@ -11,10 +11,7 @@ spec: matchLabels: App: JsCeramicDev strategy: - rollingUpdate: - maxSurge: 25% - maxUnavailable: 25% - type: RollingUpdate + type: Recreate template: metadata: annotations: @@ -41,7 +38,9 @@ spec: App: JsCeramicDev spec: containers: - - image: ceramicnetwork/js-ceramic:6.5.0 + # Enables a fix allowing us to heal dropped anchors on genesis commits: + # https://github.com/ceramicnetwork/js-ceramic/pull/3280 + - image: ceramicnetwork/js-ceramic:6.6.0-rc.0 name: js-ceramic-dev command: ["/bin/bash", "-c"] args: @@ -49,6 +48,8 @@ spec: ports: - containerPort: 7007 name: http-api + - containerPort: 9464 + name: metrics resources: limits: cpu: 2 @@ -70,9 +71,38 @@ spec: port: http-api failureThreshold: 60 periodSeconds: 1 - serviceAccountName: "vault-auth" --- +apiVersion: v1 +kind: Service +metadata: + name: js-ceramic-dev-service-internal + labels: + App: JsCeramicDev +spec: + type: ClusterIP + selector: + App: JsCeramicDev + ports: + - name: metrics + port: 9464 + targetPort: metrics +--- +apiVersion: v1 +kind: Service +metadata: + name: public-js-ceramic-dev-service + labels: + App: JsCeramicDev +spec: + type: LoadBalancer + selector: + App: JsCeramicDev + ports: + - protocol: TCP + port: 80 + targetPort: http-api +--- apiVersion: networking.k8s.io/v1 kind: Ingress metadata: @@ -91,19 +121,3 @@ spec: name: public-js-ceramic-dev-service port: number: 80 ---- -apiVersion: v1 -kind: Service -metadata: - name: public-js-ceramic-dev-service - labels: - App: JsCeramicDev -spec: - type: LoadBalancer - selector: - App: JsCeramicDev - ports: - - protocol: TCP - name: http - port: 80 - targetPort: 7007 diff --git a/ceramic-k8s/ceramic_deployment_prod.yaml b/ceramic-k8s/ceramic_deployment_prod.yaml index 7ed15bb76..f2c0352e3 100644 --- a/ceramic-k8s/ceramic_deployment_prod.yaml +++ b/ceramic-k8s/ceramic_deployment_prod.yaml @@ -73,6 +73,8 @@ spec: ports: - containerPort: 7007 name: http-api + - containerPort: 9464 + name: metrics resources: limits: cpu: 2 @@ -107,9 +109,39 @@ spec: - name: ceramic-prod-persistent-storage persistentVolumeClaim: claimName: ceramic-prod-persistent-storage-pvc - serviceAccountName: "vault-auth" --- +apiVersion: v1 +kind: Service +metadata: + name: js-ceramic-prod-service-internal + labels: + App: JsCeramicProd +spec: + type: ClusterIP + selector: + App: JsCeramicProd + ports: + - name: metrics + port: 9464 + targetPort: metrics +--- +apiVersion: v1 +kind: Service +metadata: + name: public-js-ceramic-prod-service + labels: + App: JsCeramicProd +spec: + type: LoadBalancer + selector: + App: JsCeramicProd + ports: + - protocol: TCP + name: http + port: 80 + targetPort: http-api +--- apiVersion: networking.k8s.io/v1 kind: Ingress metadata: @@ -128,19 +160,3 @@ spec: name: public-js-ceramic-prod-service port: number: 80 ---- -apiVersion: v1 -kind: Service -metadata: - name: public-js-ceramic-prod-service - labels: - App: JsCeramicProd -spec: - type: LoadBalancer - selector: - App: JsCeramicProd - ports: - - protocol: TCP - name: http - port: 80 - targetPort: 7007 diff --git a/docker-compose.dev.yml b/docker-compose.dev.yml index faba1ceca..6302874a1 100755 --- a/docker-compose.dev.yml +++ b/docker-compose.dev.yml @@ -188,6 +188,7 @@ services: container_name: ceramic ports: - "7007:7007" + - "9464:9464" environment: NODE_ENV: production CERAMIC_PUBSUB_QPS_LIMIT: 500 From 30fa43a86d7a749c4cce58e1c446a79dbd10bcb1 Mon Sep 17 00:00:00 2001 From: shadrach-tayo Date: Fri, 27 Sep 2024 03:17:11 -0500 Subject: [PATCH 44/81] fix type errors in tests --- desci-server/test/integration/Attestation.test.ts | 15 +++++++++++++++ 1 file changed, 15 insertions(+) diff --git a/desci-server/test/integration/Attestation.test.ts b/desci-server/test/integration/Attestation.test.ts index a6a111899..91fb4310b 100644 --- a/desci-server/test/integration/Attestation.test.ts +++ b/desci-server/test/integration/Attestation.test.ts @@ -852,6 +852,7 @@ describe.only('Attestations Service', async () => { claimId: claim.id, authorId: users[1].id, comment: 'Love the attestation', + visible: true, }); }); @@ -1044,6 +1045,7 @@ describe.only('Attestations Service', async () => { claimId: openDataAttestationClaim.id, authorId: users[2].id, comment: 'I love this game', + visible: true, }); // verify one claims for node 2 attestations @@ -1054,6 +1056,7 @@ describe.only('Attestations Service', async () => { claimId: openDataAttestationClaim2.id, authorId: users[3].id, comment: 'I love this guy', + visible: true, }); }); @@ -1198,6 +1201,7 @@ describe.only('Attestations Service', async () => { claimId: openDataAttestationClaim.id, authorId: users[2].id, comment: 'I love this game', + visible: true, }); // verify one claims for node 2 attestations @@ -1208,6 +1212,7 @@ describe.only('Attestations Service', async () => { claimId: openDataAttestationClaim2.id, authorId: users[3].id, comment: 'I love this guy', + visible: true, }); await attestationService.createReaction({ claimId: claim2.id, @@ -1361,6 +1366,7 @@ describe.only('Attestations Service', async () => { claimId: openDataAttestationClaim.id, authorId: users[2].id, comment: 'I love this game', + visible: true, }); // verify one claims for node 2 attestations @@ -1372,12 +1378,14 @@ describe.only('Attestations Service', async () => { claimId: openDataAttestationClaim2.id, authorId: users[3].id, comment: 'I love this guy', + visible: true, }); await attestationService.createComment({ links: [], claimId: fairMetadataAttestationClaim2.id, authorId: users[3].id, comment: 'I love this guy', + visible: true, }); await attestationService.createReaction({ claimId: claim2.id, @@ -1397,6 +1405,7 @@ describe.only('Attestations Service', async () => { claimId: localClaim.id, authorId: users[3].id, comment: 'I love this guy', + visible: true, }); await attestationService.createReaction({ claimId: localClaim.id, @@ -1793,6 +1802,7 @@ describe.only('Attestations Service', async () => { claimId: openDataAttestationClaim.id, authorId: users[2].id, comment: 'I love this game', + visible: true, }); // verify one claims for node 2 attestations @@ -1804,12 +1814,14 @@ describe.only('Attestations Service', async () => { claimId: openDataAttestationClaim2.id, authorId: users[3].id, comment: 'I love this guy', + visible: true, }); await attestationService.createComment({ links: [], claimId: fairMetadataAttestationClaim2.id, authorId: users[3].id, comment: 'I love this guy', + visible: true, }); await attestationService.createReaction({ claimId: claim2.id, @@ -1829,6 +1841,7 @@ describe.only('Attestations Service', async () => { claimId: localClaim.id, authorId: users[3].id, comment: 'I love this guy', + visible: true, }); await attestationService.createReaction({ claimId: localClaim.id, @@ -2003,6 +2016,7 @@ describe.only('Attestations Service', async () => { claimId: openDataAttestationClaim.id, authorId: users[2].id, comment: 'I love this game', + visible: true, }); // verify one claims for node 2 attestations @@ -2013,6 +2027,7 @@ describe.only('Attestations Service', async () => { claimId: openDataAttestationClaim2.id, authorId: users[3].id, comment: 'I love this guy', + visible: true, }); }); From eee73da5d118a5f055ccbcf73dbb20f8e7f2a27b Mon Sep 17 00:00:00 2001 From: shadrach-tayo Date: Fri, 27 Sep 2024 05:31:43 -0500 Subject: [PATCH 45/81] fix: failing tests --- desci-server/test/integration/Attestation.test.ts | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/desci-server/test/integration/Attestation.test.ts b/desci-server/test/integration/Attestation.test.ts index 91fb4310b..1ecd8ba62 100644 --- a/desci-server/test/integration/Attestation.test.ts +++ b/desci-server/test/integration/Attestation.test.ts @@ -133,7 +133,7 @@ const clearDatabase = async () => { await prisma.$queryRaw`TRUNCATE TABLE "Node" CASCADE;`; }; -describe.only('Attestations Service', async () => { +describe('Attestations Service', async () => { let baseManifest: ResearchObjectV1; let baseManifestCid: string; let users: User[]; @@ -2259,7 +2259,7 @@ describe.only('Attestations Service', async () => { body: 'review 1', }; let res = await request(app) - .post(`/v1/attestations/comment`) + .post(`/v1/attestations/comments`) .set('authorization', memberAuthHeaderVal1) .send(body); expect(res.statusCode).to.equal(200); @@ -2269,7 +2269,7 @@ describe.only('Attestations Service', async () => { claimId: openCodeClaim.id, body: 'review 2', }; - res = await request(app).post(`/v1/attestations/comment`).set('authorization', memberAuthHeaderVal2).send(body); + res = await request(app).post(`/v1/attestations/comments`).set('authorization', memberAuthHeaderVal2).send(body); expect(res.statusCode).to.equal(200); const comments = await attestationService.getAllClaimComments({ nodeAttestationId: openCodeClaim.id }); @@ -2280,7 +2280,7 @@ describe.only('Attestations Service', async () => { it('should prevent non community members from reviewing a protected attestation(claim)', async () => { const apiResponse = await request(app) - .post(`/v1/attestations/comment`) + .post(`/v1/attestations/comments`) .set('authorization', UserAuthHeaderVal) .send({ authorId: users[1].id, From 9eff3f540cb5954fa5e2bbbd650f14403364f160 Mon Sep 17 00:00:00 2001 From: shadrach-tayo Date: Fri, 27 Sep 2024 09:56:32 -0500 Subject: [PATCH 46/81] transform private hightlights when a node is published --- .../src/controllers/attestations/comments.ts | 4 +- .../src/controllers/nodes/prepublish.ts | 1 + desci-server/src/controllers/nodes/publish.ts | 16 ++++++ .../src/routes/v1/attestations/schema.ts | 16 ++++-- desci-server/src/services/Attestation.ts | 57 ++++++++++++++++++- 5 files changed, 87 insertions(+), 7 deletions(-) diff --git a/desci-server/src/controllers/attestations/comments.ts b/desci-server/src/controllers/attestations/comments.ts index d50e97369..343bdc472 100644 --- a/desci-server/src/controllers/attestations/comments.ts +++ b/desci-server/src/controllers/attestations/comments.ts @@ -115,7 +115,7 @@ export const addComment = async (req: Request, links, highlights: processedHighlights as unknown as HighlightBlock[], visible, - uuid: ensureUuidEndsWithDot(uuid), + ...(uuid && { uuid: ensureUuidEndsWithDot(uuid) }), }); await saveInteraction(req, ActionType.ADD_COMMENT, { annotationId: annotation.id, claimId, authorId }); } else { @@ -125,7 +125,7 @@ export const addComment = async (req: Request, comment: body, links, visible, - uuid: ensureUuidEndsWithDot(uuid), + ...(uuid && { uuid: ensureUuidEndsWithDot(uuid) }), }); } await saveInteraction(req, ActionType.ADD_COMMENT, { annotationId: annotation.id, claimId, authorId }); diff --git a/desci-server/src/controllers/nodes/prepublish.ts b/desci-server/src/controllers/nodes/prepublish.ts index 85222474f..30547f81c 100644 --- a/desci-server/src/controllers/nodes/prepublish.ts +++ b/desci-server/src/controllers/nodes/prepublish.ts @@ -82,6 +82,7 @@ export const prepublish = async (req: RequestWithNode, res: Response updateAssociatedAttestations(node.uuid, dpidAlias ? dpidAlias.toString() : manifest.dpid?.id); + const root = await prisma.publicDataReference.findFirst({ + where: { nodeId: node.id, root: true, userId: owner.id }, + orderBy: { updatedAt: 'desc' }, + }); + logger.info({ root }, 'publishDraftComments::Root'); + // publish draft comments + await attestationService.publishDraftComments({ + node, + userId: owner.id, + dpidAlias: dpidAlias ?? parseInt(manifest.dpid?.id), + rootCid: root.rootCid, + // todo: get version number + version: 0, + }); + return res.send({ ok: true, dpid: dpidAlias ?? parseInt(manifest.dpid?.id), diff --git a/desci-server/src/routes/v1/attestations/schema.ts b/desci-server/src/routes/v1/attestations/schema.ts index e07f904ab..5e1721e5e 100644 --- a/desci-server/src/routes/v1/attestations/schema.ts +++ b/desci-server/src/routes/v1/attestations/schema.ts @@ -1,5 +1,7 @@ import { z } from 'zod'; +import { logger } from '../../../logger.js'; + const communityId = z.coerce.number(); const dpid = z.coerce.number(); @@ -42,7 +44,7 @@ export const getCommentsSchema = z.object({ }); const dpidPathRegexPlusLocalResolver = - /^https?:\/\/(?dev-beta\.dpid\.org|beta\.dpid\.org|localhost:5460)\/(?\d+)\/(?v\d+)\/(?\S+.*)?/gm; + /^https?:\/\/(?dev-beta\.dpid\.org|beta\.dpid\.org|localhost:5460)\/(?\d+)\/(?v\d+)\/(?\S+.*)?/m; export const dpidPathRegex = process.env.NODE_ENV === 'dev' @@ -65,9 +67,15 @@ export const uuidPathSchema = z export const resourcePathSchema = z .string() .url() - .refine((link) => uuidPathRegex.test(link) || dpidPathRegex.test(link), { - message: 'Invalid Resource link', - }); + .refine( + (link) => { + logger.info({ uuidPathRegex: uuidPathRegex.source, dpidPathRegex: dpidPathRegex.source }, 'REGEX'); + return uuidPathRegex.test(link) || dpidPathRegex.test(link); + }, + { + message: 'Invalid Resource link', + }, + ); const pdfHighlightSchema = z .object({ diff --git a/desci-server/src/services/Attestation.ts b/desci-server/src/services/Attestation.ts index c459ca777..880de3d9b 100644 --- a/desci-server/src/services/Attestation.ts +++ b/desci-server/src/services/Attestation.ts @@ -1,7 +1,7 @@ import assert from 'assert'; import { HighlightBlock } from '@desci-labs/desci-models'; -import { AnnotationType, Attestation, Prisma, User } from '@prisma/client'; +import { AnnotationType, Attestation, Node, Prisma, User } from '@prisma/client'; import sgMail from '@sendgrid/mail'; import _ from 'lodash'; @@ -20,8 +20,10 @@ import { NotFoundError, VerificationError, VerificationNotFoundError, + asyncMap, ensureUuidEndsWithDot, logger as parentLogger, + uuidPathRegex, } from '../internal.js'; import { communityService } from '../internal.js'; import { AttestationClaimedEmailHtml } from '../templates/emails/utils/emailRenderer.js'; @@ -659,6 +661,59 @@ export class AttestationService { return this.createAnnotation(data); } + /** + * Iterate on all hidden comments and check if highlights path + * have been published then update comment to become visible + */ + async publishDraftComments({ + userId, + node, + dpidAlias, + version, + rootCid, + }: { + userId: number; + node: Node; + dpidAlias: number; + version: number; + rootCid: string; + }) { + const dpidUrl = process.env.DPID_URL_OVERRIDE ?? 'https://beta.dpid.org'; + // todo: specify version here + const dpidPrefix = `${dpidUrl}/${dpidAlias}`; + + const comments = await prisma.annotation.findMany({ where: { uuid: node.uuid, visible: false } }); + const publishedComments = await asyncMap(comments, async (comment) => { + const highlights = (comment.highlights.map((h) => JSON.parse(h as string)) ?? []) as HighlightBlock[]; + + const transformed = await asyncMap(highlights, async (highlight) => { + const match = highlight.path.match(uuidPathRegex); + logger.info({ comment: comment.id, path: highlight.path, match: match?.groups }, 'publishDraftComments::Match'); + if (!match?.groups?.path) return highlight; + + const path = match.groups.path.startsWith('/root') ? match.groups.path.substring(1) : match.groups.path; + const publicPath = path.replace('root', rootCid); + const publishedPath = await prisma.publicDataReference.findFirst({ + where: { userId, nodeId: node.id, path: publicPath }, + }); + if (!publishedPath) return highlight; + + const transformedPath = `${dpidPrefix}/${path}`; + return { ...highlight, path: transformedPath }; + }); + + logger.info({ highlights }, 'publishDraftComments::Highlights'); + logger.info({ transformed }, 'publishDraftComments::Transformed'); + return { id: comment.id, highlights: transformed.map((h) => JSON.stringify(h)) }; + }); + + logger.info({ publishedComments }, 'publishDraftComments'); + + await prisma.$transaction( + publishedComments.map((comment) => prisma.annotation.update({ where: { id: comment.id }, data: comment })), + ); + } + async removeComment(commentId: number) { return prisma.annotation.delete({ where: { id: commentId }, From 90af1fe881715d87867cc9c7713365c3f7a824f2 Mon Sep 17 00:00:00 2001 From: Sina Iman Date: Fri, 27 Sep 2024 18:49:48 +0200 Subject: [PATCH 47/81] fix radar query for ceramic streams --- desci-server/src/controllers/communities/util.ts | 8 ++++---- desci-server/src/services/Attestation.ts | 2 +- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/desci-server/src/controllers/communities/util.ts b/desci-server/src/controllers/communities/util.ts index 71d135df6..e57bef7bb 100644 --- a/desci-server/src/controllers/communities/util.ts +++ b/desci-server/src/controllers/communities/util.ts @@ -32,7 +32,7 @@ export const resolveLatestNode = async (radar: Partial) => { const selectAttributes: (keyof typeof discovery)[] = ['ownerId', 'NodeCover']; const node: Partial = _.pick(discovery, selectAttributes); const publishedVersions = - (await prisma.$queryRaw`SELECT * from "NodeVersion" where "nodeId" = ${discovery.id} AND "transactionId" IS NOT NULL ORDER BY "createdAt" DESC`) as NodeVersion[]; + (await prisma.$queryRaw`SELECT * from "NodeVersion" where "nodeId" = ${discovery.id} AND ("transactionId" IS NOT NULL or "commitId" IS NOT NULL) ORDER BY "createdAt" DESC`) as NodeVersion[]; // const nodeVersions = (await getNodeVersion logger.info({ uuid: discovery.uuid, publishedVersions }, 'Resolve node'); @@ -61,13 +61,13 @@ export const resolveLatestNode = async (radar: Partial) => { }; export const getNodeVersion = async (uuid: string) => { - let indexingResults: { researchObjects: IndexedResearchObject[]}; + let indexingResults: { researchObjects: IndexedResearchObject[] }; try { indexingResults = await getIndexedResearchObjects([uuid]); const researchObject = indexingResults.researchObjects[0]; return researchObject?.versions?.length ?? 0; } catch (e) { - logger.error({ uuid, indexingResults }, "getNodeVersion failed"); + logger.error({ uuid, indexingResults }, 'getNodeVersion failed'); throw e; - }; + } }; diff --git a/desci-server/src/services/Attestation.ts b/desci-server/src/services/Attestation.ts index 8a7fbbb1a..e25bac597 100644 --- a/desci-server/src/services/Attestation.ts +++ b/desci-server/src/services/Attestation.ts @@ -75,7 +75,7 @@ export class AttestationService { const node = await prisma.node.findFirst({ where: { uuid: nodeUuid } }); const publishedNodeVersions = - (await prisma.$queryRaw`SELECT COUNT(*) from "NodeVersion" where "nodeId" = ${node.id} AND "transactionId" IS NOT NULL`) as number; + (await prisma.$queryRaw`SELECT COUNT(*) from "NodeVersion" where "nodeId" = ${node.id} AND ("transactionId" IS NOT NULL or "commitId" IS NOT NULL)`) as number; if (nodeVersion >= publishedNodeVersions) { logger.warn({ nodeVersion, publishedNodeVersions }, 'Invalid Node version'); From 7995fc2c2101c4b90b8a226b2658654eaf2b9290 Mon Sep 17 00:00:00 2001 From: Sina Iman Date: Sat, 28 Sep 2024 04:40:40 +0200 Subject: [PATCH 48/81] update sentry tracing to log db and http reqs in sentry --- desci-server/package.json | 1 + desci-server/prisma/schema.prisma | 3 +- desci-server/src/server.ts | 3 +- desci-server/yarn.lock | 157 ++++++++++++++++++++++++++++-- 4 files changed, 156 insertions(+), 8 deletions(-) diff --git a/desci-server/package.json b/desci-server/package.json index 739b8e4aa..470a8a218 100755 --- a/desci-server/package.json +++ b/desci-server/package.json @@ -71,6 +71,7 @@ "@sendgrid/mail": "^7.7.0", "@sentry/cli": "^2.35.0", "@sentry/node": "^8.29.0", + "@sentry/profiling-node": "^8.32.0", "@sentry/tracing": "^7.12.0", "@types/lodash-es": "^4.17.12", "@types/mkdirp": "^1.0.2", diff --git a/desci-server/prisma/schema.prisma b/desci-server/prisma/schema.prisma index 8d18e432f..d44babc72 100755 --- a/desci-server/prisma/schema.prisma +++ b/desci-server/prisma/schema.prisma @@ -1,5 +1,6 @@ generator client { - provider = "prisma-client-js" + provider = "prisma-client-js" + previewFeatures = ["tracing"] } datasource db { diff --git a/desci-server/src/server.ts b/desci-server/src/server.ts index a84f90f26..8b0a74191 100644 --- a/desci-server/src/server.ts +++ b/desci-server/src/server.ts @@ -7,6 +7,7 @@ import type { Server as HttpServer } from 'http'; // import path from 'path'; import * as Sentry from '@sentry/node'; +import { nodeProfilingIntegration } from '@sentry/profiling-node'; import * as Tracing from '@sentry/tracing'; import bodyParser from 'body-parser'; import cookieParser from 'cookie-parser'; @@ -224,7 +225,7 @@ class AppServer { Sentry.init({ dsn: 'https://d508a5c408f34b919ccd94aac093e076@o1330109.ingest.sentry.io/6619754', release: 'desci-nodes-server@' + process.env.npm_package_version, - integrations: [new Tracing.Integrations.Prisma({ client: prisma })], + integrations: [Sentry.prismaIntegration(), nodeProfilingIntegration()], // Set tracesSampleRate to 1.0 to capture 100% // of transactions for performance monitoring. // We recommend adjusting this value in production diff --git a/desci-server/yarn.lock b/desci-server/yarn.lock index fa90e947d..73dfed96f 100644 --- a/desci-server/yarn.lock +++ b/desci-server/yarn.lock @@ -3922,6 +3922,15 @@ "@opentelemetry/instrumentation" "^0.40.0" "@opentelemetry/semantic-conventions" "^1.0.0" +"@opentelemetry/instrumentation-amqplib@^0.42.0": + version "0.42.0" + resolved "https://registry.yarnpkg.com/@opentelemetry/instrumentation-amqplib/-/instrumentation-amqplib-0.42.0.tgz#b3cab5a7207736a30d769962eed3af3838f986c4" + integrity sha512-fiuU6OKsqHJiydHWgTRQ7MnIrJ2lEqsdgFtNIH4LbAUJl/5XmrIeoDzDnox+hfkgWK65jsleFuQDtYb5hW1koQ== + dependencies: + "@opentelemetry/core" "^1.8.0" + "@opentelemetry/instrumentation" "^0.53.0" + "@opentelemetry/semantic-conventions" "^1.27.0" + "@opentelemetry/instrumentation-aws-lambda@^0.35.3": version "0.35.3" resolved "https://registry.yarnpkg.com/@opentelemetry/instrumentation-aws-lambda/-/instrumentation-aws-lambda-0.35.3.tgz#19c42ba680f93a595a38edb06b28bac2b7da6f92" @@ -3979,6 +3988,13 @@ "@opentelemetry/semantic-conventions" "^1.0.0" "@types/connect" "3.4.35" +"@opentelemetry/instrumentation-dataloader@0.12.0": + version "0.12.0" + resolved "https://registry.yarnpkg.com/@opentelemetry/instrumentation-dataloader/-/instrumentation-dataloader-0.12.0.tgz#de03a3948dec4f15fed80aa424d6bd5d6a8d10c7" + integrity sha512-pnPxatoFE0OXIZDQhL2okF//dmbiWFzcSc8pUg9TqofCLYZySSxDCgQc69CJBo5JnI3Gz1KP+mOjS4WAeRIH4g== + dependencies: + "@opentelemetry/instrumentation" "^0.53.0" + "@opentelemetry/instrumentation-dataloader@^0.4.3": version "0.4.3" resolved "https://registry.yarnpkg.com/@opentelemetry/instrumentation-dataloader/-/instrumentation-dataloader-0.4.3.tgz#13d2041d44d8ff4b9ebfc48bcbf9cbda74b61d00" @@ -4145,6 +4161,14 @@ "@opentelemetry/semantic-conventions" "^1.0.0" "@types/ioredis4" "npm:@types/ioredis@^4.28.10" +"@opentelemetry/instrumentation-kafkajs@0.3.0": + version "0.3.0" + resolved "https://registry.yarnpkg.com/@opentelemetry/instrumentation-kafkajs/-/instrumentation-kafkajs-0.3.0.tgz#6687bce4dac8b90ef8ccbf1b662d5d1e95a34414" + integrity sha512-UnkZueYK1ise8FXQeKlpBd7YYUtC7mM8J0wzUSccEfc/G8UqHQqAzIyYCUOUPUKp8GsjLnWOOK/3hJc4owb7Jg== + dependencies: + "@opentelemetry/instrumentation" "^0.53.0" + "@opentelemetry/semantic-conventions" "^1.27.0" + "@opentelemetry/instrumentation-knex@^0.31.4": version "0.31.4" resolved "https://registry.yarnpkg.com/@opentelemetry/instrumentation-knex/-/instrumentation-knex-0.31.4.tgz#15c747acf3de94f15bbad852140ec584b79d5cd9" @@ -4374,6 +4398,14 @@ "@opentelemetry/semantic-conventions" "^1.0.0" "@types/tedious" "^4.0.6" +"@opentelemetry/instrumentation-undici@0.6.0": + version "0.6.0" + resolved "https://registry.yarnpkg.com/@opentelemetry/instrumentation-undici/-/instrumentation-undici-0.6.0.tgz#9436ee155c8dcb0b760b66947c0e0f347688a5ef" + integrity sha512-ABJBhm5OdhGmbh0S/fOTE4N69IZ00CsHC5ijMYfzbw3E5NwLgpQk5xsljaECrJ8wz1SfXbO03FiSuu5AyRAkvQ== + dependencies: + "@opentelemetry/core" "^1.8.0" + "@opentelemetry/instrumentation" "^0.53.0" + "@opentelemetry/instrumentation-winston@^0.31.4": version "0.31.4" resolved "https://registry.yarnpkg.com/@opentelemetry/instrumentation-winston/-/instrumentation-winston-0.31.4.tgz#09c160dfeb935ea6981d898176be79dea67f31c8" @@ -4646,7 +4678,7 @@ "@opentelemetry/core" "1.25.0" "@opentelemetry/semantic-conventions" "1.25.0" -"@opentelemetry/resources@1.26.0", "@opentelemetry/resources@^1.25.1": +"@opentelemetry/resources@1.26.0", "@opentelemetry/resources@^1.25.1", "@opentelemetry/resources@^1.26.0": version "1.26.0" resolved "https://registry.yarnpkg.com/@opentelemetry/resources/-/resources-1.26.0.tgz#da4c7366018bd8add1f3aa9c91c6ac59fd503cef" integrity sha512-CPNYchBE7MBecCSVy0HKpUISEeJOniWqcHaAHpmasZ3j9o6V3AyBzhRc90jdmemq0HOxDr6ylhUbDhBqqPpeNw== @@ -4786,7 +4818,7 @@ "@opentelemetry/resources" "1.8.0" "@opentelemetry/semantic-conventions" "1.8.0" -"@opentelemetry/sdk-trace-base@^1.22", "@opentelemetry/sdk-trace-base@^1.25.1": +"@opentelemetry/sdk-trace-base@^1.22", "@opentelemetry/sdk-trace-base@^1.25.1", "@opentelemetry/sdk-trace-base@^1.26.0": version "1.26.0" resolved "https://registry.yarnpkg.com/@opentelemetry/sdk-trace-base/-/sdk-trace-base-1.26.0.tgz#0c913bc6d2cfafd901de330e4540952269ae579c" integrity sha512-olWQldtvbK4v22ymrKLbIcBi9L2SpMO84sCPY54IVsJhP9fRsxJT194C/AVaAuJzLE30EdhhM1VmvVYR7az+cw== @@ -5685,6 +5717,54 @@ "@sentry/types" "8.29.0" "@sentry/utils" "8.29.0" +"@sentry/core@8.32.0": + version "8.32.0" + resolved "https://registry.yarnpkg.com/@sentry/core/-/core-8.32.0.tgz#7c4b74afa7a15bd31f5e6881aac82ccfd753e1d6" + integrity sha512-+xidTr0lZ0c755tq4k75dXPEb8PA+qvIefW3U9+dQMORLokBrYoKYMf5zZTG2k/OfSJS6OSxatUj36NFuCs3aA== + dependencies: + "@sentry/types" "8.32.0" + "@sentry/utils" "8.32.0" + +"@sentry/node@8.32.0": + version "8.32.0" + resolved "https://registry.yarnpkg.com/@sentry/node/-/node-8.32.0.tgz#68822b3246fb2ed7418f21795ed539a18058cfa8" + integrity sha512-a2PoFA9j/HmJVGF/zXJhLP6QhRHGye/2EznQdHOELsH1BkeMgBaXl7D52r2E/b7qki647lXrdbspB6jid8NycA== + dependencies: + "@opentelemetry/api" "^1.9.0" + "@opentelemetry/context-async-hooks" "^1.25.1" + "@opentelemetry/core" "^1.25.1" + "@opentelemetry/instrumentation" "^0.53.0" + "@opentelemetry/instrumentation-amqplib" "^0.42.0" + "@opentelemetry/instrumentation-connect" "0.39.0" + "@opentelemetry/instrumentation-dataloader" "0.12.0" + "@opentelemetry/instrumentation-express" "0.42.0" + "@opentelemetry/instrumentation-fastify" "0.39.0" + "@opentelemetry/instrumentation-fs" "0.15.0" + "@opentelemetry/instrumentation-generic-pool" "0.39.0" + "@opentelemetry/instrumentation-graphql" "0.43.0" + "@opentelemetry/instrumentation-hapi" "0.41.0" + "@opentelemetry/instrumentation-http" "0.53.0" + "@opentelemetry/instrumentation-ioredis" "0.43.0" + "@opentelemetry/instrumentation-kafkajs" "0.3.0" + "@opentelemetry/instrumentation-koa" "0.43.0" + "@opentelemetry/instrumentation-mongodb" "0.47.0" + "@opentelemetry/instrumentation-mongoose" "0.42.0" + "@opentelemetry/instrumentation-mysql" "0.41.0" + "@opentelemetry/instrumentation-mysql2" "0.41.0" + "@opentelemetry/instrumentation-nestjs-core" "0.40.0" + "@opentelemetry/instrumentation-pg" "0.44.0" + "@opentelemetry/instrumentation-redis-4" "0.42.0" + "@opentelemetry/instrumentation-undici" "0.6.0" + "@opentelemetry/resources" "^1.26.0" + "@opentelemetry/sdk-trace-base" "^1.26.0" + "@opentelemetry/semantic-conventions" "^1.27.0" + "@prisma/instrumentation" "5.19.1" + "@sentry/core" "8.32.0" + "@sentry/opentelemetry" "8.32.0" + "@sentry/types" "8.32.0" + "@sentry/utils" "8.32.0" + import-in-the-middle "^1.11.0" + "@sentry/node@^8.29.0": version "8.29.0" resolved "https://registry.yarnpkg.com/@sentry/node/-/node-8.29.0.tgz#6e462b8802356a630c56733dc795a4035464c4ab" @@ -5732,6 +5812,27 @@ "@sentry/types" "8.29.0" "@sentry/utils" "8.29.0" +"@sentry/opentelemetry@8.32.0": + version "8.32.0" + resolved "https://registry.yarnpkg.com/@sentry/opentelemetry/-/opentelemetry-8.32.0.tgz#4af02c17102635e4b34942d2e82d3620ddb7d95a" + integrity sha512-YCD8EnwJJ2ab3zWWtu5VrvHP/6Ss6GGQH0TYx2cfeGG3c0wTA/5zYx9JR4i3hUtOh1pifN34HlY0yyQHD4yctg== + dependencies: + "@sentry/core" "8.32.0" + "@sentry/types" "8.32.0" + "@sentry/utils" "8.32.0" + +"@sentry/profiling-node@^8.32.0": + version "8.32.0" + resolved "https://registry.yarnpkg.com/@sentry/profiling-node/-/profiling-node-8.32.0.tgz#cb4bf0512dc7a6f0a9058529f3c4dbb8963a597d" + integrity sha512-wKE2JAvDM3DjVNFKd2YLzwhXFS3SurLxDPpvA1EjMQ9Me7sR5ssO9jFn3e6et5oT3e3EzGDyTfbrJ81BNQuZhQ== + dependencies: + "@sentry/core" "8.32.0" + "@sentry/node" "8.32.0" + "@sentry/types" "8.32.0" + "@sentry/utils" "8.32.0" + detect-libc "^2.0.2" + node-abi "^3.61.0" + "@sentry/tracing@^7.12.0": version "7.106.1" resolved "https://registry.yarnpkg.com/@sentry/tracing/-/tracing-7.106.1.tgz#1142fa308f7cb90f16291b969b2d5fb14c1858ae" @@ -5749,6 +5850,11 @@ resolved "https://registry.yarnpkg.com/@sentry/types/-/types-8.29.0.tgz#c19e43524b8e7766028f4da8f02eddcc33518541" integrity sha512-j4gX3ctzgD4xVWllXAhm6M+kHFEvrFoUPFq60X/pgkjsWCocGuhtNfB0rW43ICG8hCnlz8IYl7O7b8V8qY7SPg== +"@sentry/types@8.32.0": + version "8.32.0" + resolved "https://registry.yarnpkg.com/@sentry/types/-/types-8.32.0.tgz#dfd8aa9449a5f793b9c720888819a74a11f1790d" + integrity sha512-hxckvN2MzS5SgGDgVQ0/QpZXk13Vrq4BtZLwXhPhyeTmZtUiUfWvcL5TFQqLinfKdTKPe9q2MxeAJ0D4LalhMg== + "@sentry/utils@7.106.1": version "7.106.1" resolved "https://registry.yarnpkg.com/@sentry/utils/-/utils-7.106.1.tgz#7761ed50d489286dd1e482570c498f675445ce82" @@ -5763,6 +5869,13 @@ dependencies: "@sentry/types" "8.29.0" +"@sentry/utils@8.32.0": + version "8.32.0" + resolved "https://registry.yarnpkg.com/@sentry/utils/-/utils-8.32.0.tgz#99a4298ee8fd7208ade470931c19d71c571dfce8" + integrity sha512-t1WVERhgmYURxbBj9J4/H2P2X+VKqm7B3ce9iQyrZbdf5NekhcU4jHIecPUWCPHjQkFIqkVTorqeBmDTlg/UmQ== + dependencies: + "@sentry/types" "8.32.0" + "@sideway/address@^4.1.5": version "4.1.5" resolved "https://registry.yarnpkg.com/@sideway/address/-/address-4.1.5.tgz#4bc149a0076623ced99ca8208ba780d65a99b9d5" @@ -9905,7 +10018,7 @@ detect-indent@6.1.0: resolved "https://registry.yarnpkg.com/detect-indent/-/detect-indent-6.1.0.tgz#592485ebbbf6b3b1ab2be175c8393d04ca0d57e6" integrity sha512-reYkTUJAZb9gUuZ2RvVCNhVHdg62RHnJ7WJl8ftMi4diZ6NWlciOzQN88pUhSELEwflJht4oQDv0F0BMlwaYtA== -detect-libc@^2.0.0: +detect-libc@^2.0.0, detect-libc@^2.0.2: version "2.0.3" resolved "https://registry.yarnpkg.com/detect-libc/-/detect-libc-2.0.3.tgz#f0cd503b40f9939b894697d19ad50895e30cf700" integrity sha512-bwy0MGW55bG41VqxxypOsdSdGqLwXPI/focwgTYCFMbdUiBAxLg9CFzG08sz2aqzknwiX7Hkl0bQENjg8iLByw== @@ -13929,6 +14042,13 @@ node-abi@^3.3.0: dependencies: semver "^7.3.5" +node-abi@^3.61.0: + version "3.68.0" + resolved "https://registry.yarnpkg.com/node-abi/-/node-abi-3.68.0.tgz#8f37fb02ecf4f43ebe694090dcb52e0c4cc4ba25" + integrity sha512-7vbj10trelExNjFSBm5kTvZXXa7pZyKWx9RCKIyqe6I9Ev3IzGpQoqBP3a+cOdxY+pWj6VkP28n/2wWysBHD/A== + dependencies: + semver "^7.3.5" + node-addon-api@^2.0.0: version "2.0.2" resolved "https://registry.yarnpkg.com/node-addon-api/-/node-addon-api-2.0.2.tgz#432cfa82962ce494b132e9d72a15b29f71ff5d32" @@ -16207,7 +16327,16 @@ string-template@~0.2.1: resolved "https://registry.yarnpkg.com/string-template/-/string-template-0.2.1.tgz#42932e598a352d01fc22ec3367d9d84eec6c9add" integrity sha512-Yptehjogou2xm4UJbxJ4CxgZx12HBfeystp0y3x7s4Dj32ltVVG1Gg8YhKjHZkHicuKpZX/ffilA8505VbUbpw== -"string-width-cjs@npm:string-width@^4.2.0", "string-width@^1.0.2 || 2 || 3 || 4", string-width@^4.1.0, string-width@^4.2.0, string-width@^4.2.3: +"string-width-cjs@npm:string-width@^4.2.0": + version "4.2.3" + resolved "https://registry.yarnpkg.com/string-width/-/string-width-4.2.3.tgz#269c7117d27b05ad2e536830a8ec895ef9c6d010" + integrity sha512-wKyQRQpjJ0sIp62ErSZdGsjMJWsap5oRNihHhu6G7JVO/9jIB6UyevL+tXuOqrng8j/cxKTWyWUwvSTriiZz/g== + dependencies: + emoji-regex "^8.0.0" + is-fullwidth-code-point "^3.0.0" + strip-ansi "^6.0.1" + +"string-width@^1.0.2 || 2 || 3 || 4", string-width@^4.1.0, string-width@^4.2.0, string-width@^4.2.3: version "4.2.3" resolved "https://registry.yarnpkg.com/string-width/-/string-width-4.2.3.tgz#269c7117d27b05ad2e536830a8ec895ef9c6d010" integrity sha512-wKyQRQpjJ0sIp62ErSZdGsjMJWsap5oRNihHhu6G7JVO/9jIB6UyevL+tXuOqrng8j/cxKTWyWUwvSTriiZz/g== @@ -16280,7 +16409,7 @@ stringify-object@3.3.0: is-obj "^1.0.1" is-regexp "^1.0.0" -"strip-ansi-cjs@npm:strip-ansi@^6.0.1", strip-ansi@^6.0.0, strip-ansi@^6.0.1: +"strip-ansi-cjs@npm:strip-ansi@^6.0.1": version "6.0.1" resolved "https://registry.yarnpkg.com/strip-ansi/-/strip-ansi-6.0.1.tgz#9e26c63d30f53443e9489495b2105d37b67a85d9" integrity sha512-Y38VPSHcqkFrCpFnQ9vuSXmquuv5oXOKpGeT6aGrr3o3Gc9AlVa6JBfUSOCnbxGGZF+/0ooI7KrPuUSztUdU5A== @@ -16294,6 +16423,13 @@ strip-ansi@^3.0.0: dependencies: ansi-regex "^2.0.0" +strip-ansi@^6.0.0, strip-ansi@^6.0.1: + version "6.0.1" + resolved "https://registry.yarnpkg.com/strip-ansi/-/strip-ansi-6.0.1.tgz#9e26c63d30f53443e9489495b2105d37b67a85d9" + integrity sha512-Y38VPSHcqkFrCpFnQ9vuSXmquuv5oXOKpGeT6aGrr3o3Gc9AlVa6JBfUSOCnbxGGZF+/0ooI7KrPuUSztUdU5A== + dependencies: + ansi-regex "^5.0.1" + strip-ansi@^7.0.1: version "7.1.0" resolved "https://registry.yarnpkg.com/strip-ansi/-/strip-ansi-7.1.0.tgz#d5b6568ca689d8561370b0707685d22434faff45" @@ -17329,7 +17465,7 @@ workerpool@6.2.1: resolved "https://registry.yarnpkg.com/workerpool/-/workerpool-6.2.1.tgz#46fc150c17d826b86a008e5a4508656777e9c343" integrity sha512-ILEIE97kDZvF9Wb9f6h5aXK4swSlKGUcOEGiIYb2OOu/IrDU9iwj0fD//SsA6E5ibwJxpEvhullJY4Sl4GcpAw== -"wrap-ansi-cjs@npm:wrap-ansi@^7.0.0", wrap-ansi@^7.0.0: +"wrap-ansi-cjs@npm:wrap-ansi@^7.0.0": version "7.0.0" resolved "https://registry.yarnpkg.com/wrap-ansi/-/wrap-ansi-7.0.0.tgz#67e145cff510a6a6984bdf1152911d69d2eb9e43" integrity sha512-YVGIj2kamLSTxw6NsZjoBxfSwsn0ycdesmc4p+Q21c5zPuZ1pl+NfxVdxPtdHvmNVOQ6XSYG4AUtyt/Fi7D16Q== @@ -17347,6 +17483,15 @@ wrap-ansi@^6.2.0: string-width "^4.1.0" strip-ansi "^6.0.0" +wrap-ansi@^7.0.0: + version "7.0.0" + resolved "https://registry.yarnpkg.com/wrap-ansi/-/wrap-ansi-7.0.0.tgz#67e145cff510a6a6984bdf1152911d69d2eb9e43" + integrity sha512-YVGIj2kamLSTxw6NsZjoBxfSwsn0ycdesmc4p+Q21c5zPuZ1pl+NfxVdxPtdHvmNVOQ6XSYG4AUtyt/Fi7D16Q== + dependencies: + ansi-styles "^4.0.0" + string-width "^4.1.0" + strip-ansi "^6.0.0" + wrap-ansi@^8.1.0: version "8.1.0" resolved "https://registry.yarnpkg.com/wrap-ansi/-/wrap-ansi-8.1.0.tgz#56dc22368ee570face1b49819975d9b9a5ead214" From 32044b52a2a6ed9d5700ddcb94db27a14bec6b75 Mon Sep 17 00:00:00 2001 From: Sina Iman Date: Mon, 30 Sep 2024 13:09:56 +0200 Subject: [PATCH 49/81] apply profile sample rate --- desci-server/src/server.ts | 1 + 1 file changed, 1 insertion(+) diff --git a/desci-server/src/server.ts b/desci-server/src/server.ts index 8b0a74191..172964d54 100644 --- a/desci-server/src/server.ts +++ b/desci-server/src/server.ts @@ -230,6 +230,7 @@ class AppServer { // of transactions for performance monitoring. // We recommend adjusting this value in production tracesSampleRate: 1.0, + profilesSampleRate: 1.0, }); Sentry.setupExpressErrorHandler(this.app); } else { From b4dd7f297df1ef8a698235cc4caa81c33ecd8d34 Mon Sep 17 00:00:00 2001 From: m0ar Date: Mon, 30 Sep 2024 17:45:17 +0200 Subject: [PATCH 50/81] builds: enable using fnm instead of nvm --- dockerDev.sh | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) diff --git a/dockerDev.sh b/dockerDev.sh index b4e2d0940..bf2a5f539 100755 --- a/dockerDev.sh +++ b/dockerDev.sh @@ -18,7 +18,7 @@ assert_command_available() { } init_node() { - if ! printenv NVM_DIR &> /dev/null; then + if ! printenv NVM_DIR &> /dev/null && ! command -v fnm; then echo "[dockerDev] NVM_DIR not set, please install NVM" echo "[dockerDev] curl -o- https://raw.githubusercontent.com/nvm-sh/nvm/v0.39.3/install.sh | bash" exit 1 @@ -27,13 +27,17 @@ init_node() { # Since nvm is loaded through shell config, it's not available # in scripts unless we source it manually local NVM_SCRIPT="$NVM_DIR/nvm.sh" - if [[ -s "$NVM_SCRIPT" ]]; then + if command -v fnm &>/dev/null; then + # A script doesn't inherit get aliases, so if fnm is available, "implement" nvm with that + nvm() { fnm "$@"; } + elif [[ -s "$NVM_SCRIPT" ]]; then source "$NVM_SCRIPT" else echo "[dockerDev] Could not find $NVM_SCRIPT, aborting" exit 1 fi - nvm install $(cat .nvmrc) + + nvm install "$(cat .nvmrc)" nvm use } From a61eb0bfa1183bbd894bb06ac0e6111e4c72ea0f Mon Sep 17 00:00:00 2001 From: m0ar Date: Mon, 30 Sep 2024 17:45:46 +0200 Subject: [PATCH 51/81] server: dedupe dev subgraph versions --- .env.example | 8 +++--- desci-server/src/config/index.ts | 1 + desci-server/src/services/fixDpid.ts | 2 +- desci-server/src/theGraph.ts | 42 ++++++++++++++++++---------- docker-compose.dev.yml | 2 +- 5 files changed, 34 insertions(+), 21 deletions(-) diff --git a/.env.example b/.env.example index b34c27606..a47adff3b 100755 --- a/.env.example +++ b/.env.example @@ -119,7 +119,10 @@ ETHEREUM_RPC_URL=http://host.docker.internal:8545 # Use this for Sepolia testnet # ETHEREUM_RPC_URL=https://eth-sepolia.g.alchemy.com/v2/demo -DPID_URL_OVERRIDE=https://dev-beta.dpid.org +# Use resolver in compose cluster locally +DPID_URL_OVERRIDE=http://host.docker.internal:5460 +# Use public dev resolver +# DPID_URL_OVERRIDE=https://dev-beta.dpid.org # Set to true if you want to mute the publish worker in local dev MUTE_PUBLISH_WORKER=false @@ -139,8 +142,6 @@ CROSSREF_PASSWORD= # Cross ref notification callback envs CROSSREF_NOTIFY_ENDPOINT=endpoint -# automated metadata - # Automated metadata AUTOMATED_METADATA_API=http://host.docker.internal:5005 AUTOMATED_METADATA_API_KEY= @@ -158,6 +159,5 @@ ES_DB_NAME= ES_DB_USER= ES_DB_PASSWORD= - ### open Alex Database - Postgres OPEN_ALEX_DATABASE_URL=postgresql://username:password@host/database?schema=openalex diff --git a/desci-server/src/config/index.ts b/desci-server/src/config/index.ts index 4d77a161a..22fd98a9e 100644 --- a/desci-server/src/config/index.ts +++ b/desci-server/src/config/index.ts @@ -11,6 +11,7 @@ export const PUBLIC_IPFS_PATH = export const MEDIA_SERVER_API_URL = process.env.NODES_MEDIA_SERVER_URL; export const MEDIA_SERVER_API_KEY = process.env.MEDIA_SECRET_KEY; export const SERVER_URL = process.env.SERVER_URL; +export const THEGRAPH_API_URL = process.env.THEGRAPH_API_URL; const CERAMIC_API_URLS = { local: 'http://host.docker.internal:7007', diff --git a/desci-server/src/services/fixDpid.ts b/desci-server/src/services/fixDpid.ts index 4de297940..389fec225 100644 --- a/desci-server/src/services/fixDpid.ts +++ b/desci-server/src/services/fixDpid.ts @@ -22,7 +22,7 @@ export const getTargetDpidUrl = () => { 'https://nodes-api.desci.com': 'https://beta.dpid.org', }; const targetDpidUrl = TARGET_DPID_URL_BY_SERVER_URL[process.env.SERVER_URL]; - return targetDpidUrl; + return targetDpidUrl as string; }; // usage: npx tsx scripts/fix-dpid.ts 211 diff --git a/desci-server/src/theGraph.ts b/desci-server/src/theGraph.ts index 709b3b36e..8da267532 100644 --- a/desci-server/src/theGraph.ts +++ b/desci-server/src/theGraph.ts @@ -5,6 +5,7 @@ import { logger as parentLogger } from './logger.js'; import { getCommitTimestamps } from './services/ceramic.js'; import { getTargetDpidUrl } from './services/fixDpid.js'; import { convertCidTo0xHex, decodeBase64UrlSafeToHex, ensureUuidEndsWithDot } from './utils.js'; +import { THEGRAPH_API_URL } from './config/index.js'; const logger = parentLogger.child({ module: 'GetIndexedResearchObjects', @@ -100,24 +101,14 @@ export const getIndexedResearchObjects = async ( } } - /** - * fallback to _getIndexedResearchObjects() when resolving locally - * because calls to getHistoryFromStreams() never returns due to - * RESOLVER_URL not configured for local dpid resolution - */ - if (process.env.NODE_ENV === 'dev') { - legacyUuids.push(...paddedUuids); - streamLookupMap = {}; - } - - let streamHistory = []; + let streamHistory: IndexedResearchObject[] = []; if (Object.keys(streamLookupMap).length > 0) { logger.info({ streamLookupMap }, 'Querying resolver for history'); streamHistory = await getHistoryFromStreams(streamLookupMap); logger.info({ streamHistory }, 'Resolver history for nodes found'); } - let legacyHistory = []; + let legacyHistory: IndexedResearchObject[] = []; if (legacyUuids.length > 0) { logger.info({ legacyUuids, _urlSafeBase64s }, 'Falling back to subgraph query for history'); legacyHistory = (await _getIndexedResearchObjects(legacyUuids)).researchObjects; @@ -202,9 +193,29 @@ export const _getIndexedResearchObjects = async ( } } }`; - return query(q); + + const results = await query<{ researchObjects: IndexedResearchObject[] }>(q); + if (THEGRAPH_API_URL.includes("sepolia-dev")) { + // In-place deduplication on the graph results + results.researchObjects.forEach(ro => { + ro.versions = ro.versions.reduce((deduped, next) => { + if (deduped.length === 0 || !isLegacyDupe(next, deduped.at(-1))) { + deduped.push(next); + } + return deduped; + }, [] as IndexedResearchObjectVersion[]) + }); + } + + return results; }; +/** Makes semi-certain that two entries are dupes, by requiring that +* both timestamp and cid are equal +*/ +const isLegacyDupe = (a: IndexedResearchObjectVersion, b: IndexedResearchObjectVersion) => + a.cid === b.cid && a.time === b.time; + /** * For a bunch of publish hashes, get the corresponding timestamps as strings. */ @@ -288,7 +299,7 @@ export const _getDpidForTxIds = async (txs: string[]): Promise } }`; console.log('Sending graph query:', { q }); - const url = process.env.THEGRAPH_API_URL.replace('name/nodes', 'name/dpid-registry'); + const url = THEGRAPH_API_URL.replace('name/nodes', 'name/dpid-registry'); const response = await query(q, url); return response.registers; }; @@ -297,7 +308,7 @@ export const query = async (query: string, overrideUrl?: string): Promise const payload = JSON.stringify({ query, }); - const url = overrideUrl ?? process.env.THEGRAPH_API_URL; + const url = overrideUrl ?? THEGRAPH_API_URL; const { data } = await axios.post(url, payload); if (data.errors) { logger.error({ fn: 'query', err: data.errors, query, dataRes: data }, `graph index query err ${query}`); @@ -305,3 +316,4 @@ export const query = async (query: string, overrideUrl?: string): Promise } return data.data as T; }; + diff --git a/docker-compose.dev.yml b/docker-compose.dev.yml index 6302874a1..d9c14aea0 100755 --- a/docker-compose.dev.yml +++ b/docker-compose.dev.yml @@ -232,7 +232,7 @@ services: - JAVA_OPTS=-Xmx2G -Xms2G dpid_resolver: - image: descilabs/dpid-resolver + image: descilabs/dpid-resolver:develop container_name: dpid_resolver # Uncomment and set to local repo path for tinkering # build: From 2d8146a92c3e25d540289f9566c9156b3c922058 Mon Sep 17 00:00:00 2001 From: Sina Iman Date: Mon, 30 Sep 2024 21:23:56 +0200 Subject: [PATCH 52/81] fix build --- .github/workflows/build-server.yaml | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/.github/workflows/build-server.yaml b/.github/workflows/build-server.yaml index b25936ff2..e25841008 100644 --- a/.github/workflows/build-server.yaml +++ b/.github/workflows/build-server.yaml @@ -60,7 +60,11 @@ jobs: - name: Set up Sentry CLI run: | + npm install -g @sentry/cli sentry-cli --version + sentry-cli login --auth-token $SENTRY_AUTH_TOKEN + # append to .env + echo -e "\nSENTRY_AUTH_TOKEN=$SENTRY_AUTH" >> desci-server/.env - name: Run tests run: | From 6ac88929ffa48a267ec17fa7e5791ddfd3894f75 Mon Sep 17 00:00:00 2001 From: Sina Iman Date: Mon, 30 Sep 2024 21:25:34 +0200 Subject: [PATCH 53/81] fix build2 --- .github/workflows/build-server.yaml | 3 +++ 1 file changed, 3 insertions(+) diff --git a/.github/workflows/build-server.yaml b/.github/workflows/build-server.yaml index e25841008..8d2ea2a31 100644 --- a/.github/workflows/build-server.yaml +++ b/.github/workflows/build-server.yaml @@ -124,8 +124,11 @@ jobs: - name: Set up Sentry CLI run: | + npm install -g @sentry/cli sentry-cli --version sentry-cli login --auth-token $SENTRY_AUTH_TOKEN + # append to .env + echo -e "\nSENTRY_AUTH_TOKEN=$SENTRY_AUTH" >> desci-server/.env - name: Build and tag the image (DEV) if: github.ref == 'refs/heads/develop' From e319abed8f357ae112f19a15d8e5141deda6efad Mon Sep 17 00:00:00 2001 From: Sina Iman Date: Tue, 1 Oct 2024 00:08:34 +0200 Subject: [PATCH 54/81] fix casing bug in email auth --- desci-server/src/controllers/auth/magic.ts | 13 +++++++------ 1 file changed, 7 insertions(+), 6 deletions(-) diff --git a/desci-server/src/controllers/auth/magic.ts b/desci-server/src/controllers/auth/magic.ts index 422a34914..94be7f10c 100644 --- a/desci-server/src/controllers/auth/magic.ts +++ b/desci-server/src/controllers/auth/magic.ts @@ -27,6 +27,7 @@ export const magic = async (req: Request, res: Response, next: NextFunction) => } const { email, code, dev, orcid, access_token, refresh_token, expires_in } = req.body; + const cleanEmail = email.toLowerCase().trim(); if (!code) { // we are sending the magic code @@ -34,7 +35,7 @@ export const magic = async (req: Request, res: Response, next: NextFunction) => let user = await prismaClient.user.findFirst({ where: { email: { - equals: email, + equals: cleanEmail, mode: 'insensitive', }, }, @@ -44,13 +45,13 @@ export const magic = async (req: Request, res: Response, next: NextFunction) => if (!user) { user = await prismaClient.user.upsert({ where: { - email, + email: cleanEmail, }, create: { - email, + email: cleanEmail, }, update: { - email, + email: cleanEmail, }, }); @@ -66,7 +67,7 @@ export const magic = async (req: Request, res: Response, next: NextFunction) => try { const ip = req.ip; - const ok = await sendMagicLink(email, ip); + const ok = await sendMagicLink(cleanEmail, ip); res.send({ ok }); } catch (err) { logger.error({ ...err, fn: 'magic' }); @@ -75,7 +76,7 @@ export const magic = async (req: Request, res: Response, next: NextFunction) => } else { // we are validating the magic code is correct try { - const user = await magicLinkRedeem(email, code); + const user = await magicLinkRedeem(cleanEmail, code); if (orcid && user) { logger.trace({ fn: 'magic', orcid }, `setting orcid for user`); From e99aaf29ef0efa9086b16485dca3b598db7aed72 Mon Sep 17 00:00:00 2001 From: m0ar Date: Tue, 1 Oct 2024 11:06:26 +0200 Subject: [PATCH 55/81] compose: fix redis url protocol --- docker-compose.dev.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docker-compose.dev.yml b/docker-compose.dev.yml index d9c14aea0..a00e563b2 100755 --- a/docker-compose.dev.yml +++ b/docker-compose.dev.yml @@ -242,7 +242,7 @@ services: OPTIMISM_RPC_URL: http://host.docker.internal:8545 CERAMIC_URL: http://host.docker.internal:7007 IPFS_GATEWAY: http://host.docker.internal:8089/ipfs - REDIS_HOST: http://host.docker.internal + REDIS_HOST: host.docker.internal REDIS_PORT: 6379 # How long to store anchored commit info (default 24 hours) CACHE_TTL_ANCHORED: 86400 From 845b168fa953c534bfd19975f3aad6d872c8ed13 Mon Sep 17 00:00:00 2001 From: kadami <86646883+kadamidev@users.noreply.github.com> Date: Tue, 1 Oct 2024 10:56:02 +0000 Subject: [PATCH 56/81] slight optim for phrase matches --- desci-server/src/services/ElasticSearchService.ts | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/desci-server/src/services/ElasticSearchService.ts b/desci-server/src/services/ElasticSearchService.ts index 9a9a84383..ed57ffd54 100644 --- a/desci-server/src/services/ElasticSearchService.ts +++ b/desci-server/src/services/ElasticSearchService.ts @@ -123,6 +123,11 @@ export function createFunctionScoreQuery(query: QueryDslQueryContainer, entity: type: 'article', } as QueryDslTermsQuery, }, + { + term: { + type: 'preprint', + } as QueryDslTermsQuery, + }, ], } as QueryDslBoolQuery, }; @@ -339,7 +344,9 @@ export function buildMultiMatchQuery( multi_match: { query: query, fields: fields, - type: 'best_fields', + type: 'phrase', + slop: 5, + tie_breaker: 0.7, // fuzziness: fuzzy, // Retained fuzziness }, }, From 299233a5c2cb547769d4726e99ab46546f1f9866 Mon Sep 17 00:00:00 2001 From: kadami <86646883+kadamidev@users.noreply.github.com> Date: Tue, 1 Oct 2024 20:32:45 +0000 Subject: [PATCH 57/81] rework querying, fix citation score boost drowning out 0 citation articles with strong query matches --- .../src/services/ElasticSearchService.ts | 88 +++++++++++++------ 1 file changed, 63 insertions(+), 25 deletions(-) diff --git a/desci-server/src/services/ElasticSearchService.ts b/desci-server/src/services/ElasticSearchService.ts index ed57ffd54..6059394ad 100644 --- a/desci-server/src/services/ElasticSearchService.ts +++ b/desci-server/src/services/ElasticSearchService.ts @@ -95,11 +95,11 @@ export function createFunctionScoreQuery(query: QueryDslQueryContainer, entity: // Simplified function score containers const functions: QueryDslFunctionScoreContainer[] = [ { + filter: { range: { cited_by_count: { gte: 1 } } }, field_value_factor: { field: 'cited_by_count', - factor: 1.5, + factor: 0.025, modifier: 'log1p', - missing: 0, }, }, { @@ -332,42 +332,80 @@ export function buildMultiMatchQuery( fuzzy: string | number = 0, ): QueryDslQueryContainer { const fields = getRelevantFields(entity); + const terms = query.split(/\s+/); + const termCount = terms.length; - let multiMatchQuery: QueryDslQueryContainer; + const exactMatchBoost = 1000; + const phraseMatchBoost = 100; + const termMatchBoost = 10; - if (entity.startsWith('works_') && !fields[0]?.includes('institutions')) { - const nestedField = fields[0]?.split('.')[0]; - multiMatchQuery = { - nested: { - path: nestedField, - query: { - multi_match: { - query: query, - fields: fields, - type: 'phrase', - slop: 5, - tie_breaker: 0.7, - // fuzziness: fuzzy, // Retained fuzziness - }, - }, + let shouldClauses: QueryDslQueryContainer[] = [ + // Phrase match (high priority) + { + multi_match: { + query: query, + fields: fields.map((field) => `${field}^${phraseMatchBoost}`), + type: 'phrase' as QueryDslTextQueryType, + slop: 1, + boost: phraseMatchBoost, }, - }; - } else { - multiMatchQuery = { + }, + // Phrase prefix match (medium-high priority) + { multi_match: { query: query, - fields: fields, - type: 'best_fields', - // fuzziness: fuzzy, // Retained fuzziness + fields: fields.map((field) => `${field}^${termMatchBoost * 2}`), + type: 'phrase_prefix' as QueryDslTextQueryType, + boost: termMatchBoost * 2, }, - }; + }, + // Term match with minimum should match (medium priority) + { + bool: { + should: fields.map((field) => ({ + match: { + [field]: { + query: query, + operator: 'or', + minimum_should_match: Math.min(3, Math.ceil(termCount * 0.75)), + boost: termMatchBoost, + }, + }, + })), + minimum_should_match: 1, + }, + }, + ]; + + // Special handling for 'works' and 'works_single' entities + if (entity === 'works' || entity === 'works_single') { + shouldClauses = [ + { + match_phrase: { + title: { + query: query, + boost: exactMatchBoost * 2, // Double boost for title exact match + slop: 0, + }, + }, + }, + ...shouldClauses, + ]; } + const multiMatchQuery: QueryDslQueryContainer = { + bool: { + should: shouldClauses, + minimum_should_match: 1, + }, + }; + if (entity === 'works' || entity === 'works_single') { return { function_score: createFunctionScoreQuery(multiMatchQuery, entity), }; } + return multiMatchQuery; } From 032f90ea6f51cbce7efce8fa0cf781fe681c1d8e Mon Sep 17 00:00:00 2001 From: shadrach-tayo Date: Tue, 1 Oct 2024 18:42:13 -0500 Subject: [PATCH 58/81] update visibility of private comments on publish --- desci-server/src/controllers/communities/util.ts | 6 +++--- desci-server/src/services/Attestation.ts | 10 ++++++++-- desci-server/src/theGraph.ts | 12 +----------- docker-compose.dev.yml | 6 +++--- 4 files changed, 15 insertions(+), 19 deletions(-) diff --git a/desci-server/src/controllers/communities/util.ts b/desci-server/src/controllers/communities/util.ts index 71d135df6..170ad2bc7 100644 --- a/desci-server/src/controllers/communities/util.ts +++ b/desci-server/src/controllers/communities/util.ts @@ -61,13 +61,13 @@ export const resolveLatestNode = async (radar: Partial) => { }; export const getNodeVersion = async (uuid: string) => { - let indexingResults: { researchObjects: IndexedResearchObject[]}; + let indexingResults: { researchObjects: IndexedResearchObject[] }; try { indexingResults = await getIndexedResearchObjects([uuid]); const researchObject = indexingResults.researchObjects[0]; return researchObject?.versions?.length ?? 0; } catch (e) { - logger.error({ uuid, indexingResults }, "getNodeVersion failed"); + logger.error({ uuid, indexingResults }, 'getNodeVersion failed'); throw e; - }; + } }; diff --git a/desci-server/src/services/Attestation.ts b/desci-server/src/services/Attestation.ts index 880de3d9b..f7002350f 100644 --- a/desci-server/src/services/Attestation.ts +++ b/desci-server/src/services/Attestation.ts @@ -704,13 +704,19 @@ export class AttestationService { logger.info({ highlights }, 'publishDraftComments::Highlights'); logger.info({ transformed }, 'publishDraftComments::Transformed'); - return { id: comment.id, highlights: transformed.map((h) => JSON.stringify(h)) }; + return { + id: comment.id, + highlights: transformed.map((h) => JSON.stringify(h)), + visible: true, + } as Prisma.AnnotationUncheckedUpdateManyInput; }); logger.info({ publishedComments }, 'publishDraftComments'); await prisma.$transaction( - publishedComments.map((comment) => prisma.annotation.update({ where: { id: comment.id }, data: comment })), + publishedComments.map((comment) => + prisma.annotation.update({ where: { id: comment.id as number }, data: comment }), + ), ); } diff --git a/desci-server/src/theGraph.ts b/desci-server/src/theGraph.ts index 15e602afa..6fef11a88 100644 --- a/desci-server/src/theGraph.ts +++ b/desci-server/src/theGraph.ts @@ -77,7 +77,7 @@ export const getIndexedResearchObjects = async ( For stream resolution, build a map to allow for also returning the UUID to match the format returned by the graph lookup */ - let streamLookupMap: Record = {}; + const streamLookupMap: Record = {}; /** For legacy nodes, the graph lookup only needs the UUID */ const legacyUuids = []; @@ -100,16 +100,6 @@ export const getIndexedResearchObjects = async ( } } - /** - * fallback to _getIndexedResearchObjects() when resolving locally - * because calls to getHistoryFromStreams() never returns due to - * RESOLVER_URL not configured for local dpid resolution - */ - if (process.env.NODE_ENV === 'dev') { - legacyUuids.push(...paddedUuids); - streamLookupMap = {}; - } - let streamHistory = []; if (Object.keys(streamLookupMap).length > 0) { logger.info({ streamLookupMap }, 'Querying resolver for history'); diff --git a/docker-compose.dev.yml b/docker-compose.dev.yml index faba1ceca..6c2504336 100755 --- a/docker-compose.dev.yml +++ b/docker-compose.dev.yml @@ -231,17 +231,17 @@ services: - JAVA_OPTS=-Xmx2G -Xms2G dpid_resolver: - image: descilabs/dpid-resolver + image: descilabs/dpid-resolver:develop container_name: dpid_resolver # Uncomment and set to local repo path for tinkering # build: - # context: ~/dev/desci/dpid-resolver + # context: ~/dev/desci/dpid-resolver environment: DPID_ENV: local OPTIMISM_RPC_URL: http://host.docker.internal:8545 CERAMIC_URL: http://host.docker.internal:7007 IPFS_GATEWAY: http://host.docker.internal:8089/ipfs - REDIS_HOST: http://host.docker.internal + REDIS_HOST: host.docker.internal REDIS_PORT: 6379 # How long to store anchored commit info (default 24 hours) CACHE_TTL_ANCHORED: 86400 From 28e17c18a191b99dcdf6be03063ec22f0da34f23 Mon Sep 17 00:00:00 2001 From: kadami <86646883+kadamidev@users.noreply.github.com> Date: Wed, 2 Oct 2024 11:16:26 +0000 Subject: [PATCH 59/81] change score function to sum mode, lower term match boost --- .../src/services/ElasticSearchService.ts | 63 +++++++------------ 1 file changed, 23 insertions(+), 40 deletions(-) diff --git a/desci-server/src/services/ElasticSearchService.ts b/desci-server/src/services/ElasticSearchService.ts index 6059394ad..558c1e53f 100644 --- a/desci-server/src/services/ElasticSearchService.ts +++ b/desci-server/src/services/ElasticSearchService.ts @@ -92,16 +92,18 @@ const sortConfigs: { [entity: string]: { [sortType: string]: (order: SortOrder) export function createFunctionScoreQuery(query: QueryDslQueryContainer, entity: string): QueryDslFunctionScoreQuery { const currentYear = new Date().getFullYear(); - // Simplified function score containers const functions: QueryDslFunctionScoreContainer[] = [ + // Citation count { filter: { range: { cited_by_count: { gte: 1 } } }, field_value_factor: { field: 'cited_by_count', - factor: 0.025, + factor: 0.01, modifier: 'log1p', }, + weight: 5, }, + // Publication year { linear: { publication_year: { @@ -111,54 +113,35 @@ export function createFunctionScoreQuery(query: QueryDslQueryContainer, entity: decay: 0.7, }, }, + weight: 3, }, ]; if (entity === 'works' || entity === 'works_single') { - const nonArticleFilter: QueryDslQueryContainer = { - bool: { - must_not: [ - { - term: { - type: 'article', - } as QueryDslTermsQuery, - }, - { - term: { - type: 'preprint', - } as QueryDslTermsQuery, - }, - ], - } as QueryDslBoolQuery, - }; - - const nonEnglishFilter: QueryDslQueryContainer = { - bool: { - must_not: [ - { - term: { - language: 'en', - } as QueryDslTermsQuery, - }, - ], - } as QueryDslBoolQuery, - }; - + // Boost for articles and preprints functions.push({ - weight: 0.5, - filter: nonArticleFilter, + weight: 1, + filter: { + bool: { + should: [{ term: { type: 'article' } }, { term: { type: 'preprint' } }] as QueryDslQueryContainer[], + } as QueryDslBoolQuery, + }, }); + + // Boost for English language documents functions.push({ - weight: 0.1, - filter: nonEnglishFilter, + weight: 0.5, + filter: { + term: { language: 'en' }, + }, }); } return { query, functions, - boost_mode: 'multiply' as QueryDslFunctionBoostMode, - score_mode: 'multiply' as QueryDslFunctionScoreMode, + boost_mode: 'sum' as QueryDslFunctionBoostMode, + score_mode: 'sum' as QueryDslFunctionScoreMode, }; } @@ -337,7 +320,7 @@ export function buildMultiMatchQuery( const exactMatchBoost = 1000; const phraseMatchBoost = 100; - const termMatchBoost = 10; + const termMatchBoost = 5; let shouldClauses: QueryDslQueryContainer[] = [ // Phrase match (high priority) @@ -359,7 +342,7 @@ export function buildMultiMatchQuery( boost: termMatchBoost * 2, }, }, - // Term match with minimum should match (medium priority) + // Term match with minimum should match term threshold (medium priority) { bool: { should: fields.map((field) => ({ @@ -367,7 +350,7 @@ export function buildMultiMatchQuery( [field]: { query: query, operator: 'or', - minimum_should_match: Math.min(3, Math.ceil(termCount * 0.75)), + minimum_should_match: Math.min(3, Math.ceil(termCount * 0.7)), boost: termMatchBoost, }, }, From 349aa1be368aaa416f5de0b04a1fe35ba215e33f Mon Sep 17 00:00:00 2001 From: kadami <86646883+kadamidev@users.noreply.github.com> Date: Wed, 2 Oct 2024 11:37:30 +0000 Subject: [PATCH 60/81] fix querying other indexes besides works (for single entity autocompletion) --- .../src/services/ElasticSearchService.ts | 87 +++++++++---------- 1 file changed, 43 insertions(+), 44 deletions(-) diff --git a/desci-server/src/services/ElasticSearchService.ts b/desci-server/src/services/ElasticSearchService.ts index 558c1e53f..435459d93 100644 --- a/desci-server/src/services/ElasticSearchService.ts +++ b/desci-server/src/services/ElasticSearchService.ts @@ -30,7 +30,7 @@ export const VALID_ENTITIES = [ */ export const RELEVANT_FIELDS = { works: ['title', 'abstract'], - authors: ['display_name', 'orcid', 'last_known_institution', 'authors.affiliation'], + authors: ['display_name', 'orcid', 'last_known_institution'], topics: ['display_name'], fields: ['subfield_display_name'], concepts: ['display_name'], @@ -322,58 +322,57 @@ export function buildMultiMatchQuery( const phraseMatchBoost = 100; const termMatchBoost = 5; - let shouldClauses: QueryDslQueryContainer[] = [ - // Phrase match (high priority) - { - multi_match: { - query: query, - fields: fields.map((field) => `${field}^${phraseMatchBoost}`), - type: 'phrase' as QueryDslTextQueryType, - slop: 1, - boost: phraseMatchBoost, - }, + const shouldClauses: QueryDslQueryContainer[] = []; + + // Exact match on keyword fields + shouldClauses.push({ + multi_match: { + query: query, + fields: fields.map((field) => `${field}.keyword^${exactMatchBoost}`), + type: 'best_fields' as QueryDslTextQueryType, + boost: exactMatchBoost, }, - // Phrase prefix match (medium-high priority) - { - multi_match: { - query: query, - fields: fields.map((field) => `${field}^${termMatchBoost * 2}`), - type: 'phrase_prefix' as QueryDslTextQueryType, - boost: termMatchBoost * 2, - }, + }); + + // Phrase match on text fields + shouldClauses.push({ + multi_match: { + query: query, + fields: fields.map((field) => `${field}^${phraseMatchBoost}`), + type: 'phrase' as QueryDslTextQueryType, + slop: 1, + boost: phraseMatchBoost, }, - // Term match with minimum should match term threshold (medium priority) - { - bool: { - should: fields.map((field) => ({ - match: { - [field]: { - query: query, - operator: 'or', - minimum_should_match: Math.min(3, Math.ceil(termCount * 0.7)), - boost: termMatchBoost, - }, + }); + + // Term match with minimum should match + shouldClauses.push({ + bool: { + should: fields.map((field) => ({ + match: { + [field]: { + query: query, + operator: 'or', + minimum_should_match: Math.min(3, Math.ceil(termCount * 0.7)), + boost: termMatchBoost, }, - })), - minimum_should_match: 1, - }, + }, + })), + minimum_should_match: 1, }, - ]; + }); // Special handling for 'works' and 'works_single' entities if (entity === 'works' || entity === 'works_single') { - shouldClauses = [ - { - match_phrase: { - title: { - query: query, - boost: exactMatchBoost * 2, // Double boost for title exact match - slop: 0, - }, + shouldClauses.unshift({ + match_phrase: { + title: { + query: query, + boost: exactMatchBoost * 2, // Double boost for title exact match + slop: 0, }, }, - ...shouldClauses, - ]; + }); } const multiMatchQuery: QueryDslQueryContainer = { From 021b29fbfa014f137d207415815033d1a64b3b89 Mon Sep 17 00:00:00 2001 From: shadrach-tayo Date: Wed, 2 Oct 2024 06:37:41 -0500 Subject: [PATCH 61/81] add node version to dpid prefix in comment publish --- desci-server/src/controllers/nodes/publish.ts | 11 +++++++---- desci-server/src/services/Attestation.ts | 6 ++---- desci-server/src/services/fixDpid.ts | 1 + desci-server/src/theGraph.ts | 2 +- 4 files changed, 11 insertions(+), 9 deletions(-) diff --git a/desci-server/src/controllers/nodes/publish.ts b/desci-server/src/controllers/nodes/publish.ts index a63b08815..382d38c92 100644 --- a/desci-server/src/controllers/nodes/publish.ts +++ b/desci-server/src/controllers/nodes/publish.ts @@ -16,6 +16,7 @@ import { setDpidAlias, } from '../../services/nodeManager.js'; import { publishServices } from '../../services/PublishServices.js'; +import { getIndexedResearchObjects } from '../../theGraph.js'; import { discordNotify } from '../../utils/discordUtils.js'; import { ensureUuidEndsWithDot } from '../../utils.js'; @@ -70,7 +71,6 @@ export const publish = async (req: PublishRequest, res: Response body: req.body, uuid, cid, - manifest, transactionId, ceramicStream, commitId, @@ -165,15 +165,18 @@ export const publish = async (req: PublishRequest, res: Response where: { nodeId: node.id, root: true, userId: owner.id }, orderBy: { updatedAt: 'desc' }, }); - logger.info({ root }, 'publishDraftComments::Root'); + const result = await getIndexedResearchObjects([ensureUuidEndsWithDot(uuid)]); + // if node is being published for the first time default to 1 + const version = result ? result.researchObjects?.[0]?.versions.length : 1; + logger.info({ root, result, version }, 'publishDraftComments::Root'); + // publish draft comments await attestationService.publishDraftComments({ node, userId: owner.id, dpidAlias: dpidAlias ?? parseInt(manifest.dpid?.id), rootCid: root.rootCid, - // todo: get version number - version: 0, + version, }); return res.send({ diff --git a/desci-server/src/services/Attestation.ts b/desci-server/src/services/Attestation.ts index f7002350f..15d4a48a1 100644 --- a/desci-server/src/services/Attestation.ts +++ b/desci-server/src/services/Attestation.ts @@ -679,10 +679,10 @@ export class AttestationService { rootCid: string; }) { const dpidUrl = process.env.DPID_URL_OVERRIDE ?? 'https://beta.dpid.org'; - // todo: specify version here - const dpidPrefix = `${dpidUrl}/${dpidAlias}`; + const dpidPrefix = `${dpidUrl}/${dpidAlias}/v${version}`; const comments = await prisma.annotation.findMany({ where: { uuid: node.uuid, visible: false } }); + logger.info({ dpidPrefix, comments }, 'publishDraftComments'); const publishedComments = await asyncMap(comments, async (comment) => { const highlights = (comment.highlights.map((h) => JSON.parse(h as string)) ?? []) as HighlightBlock[]; @@ -702,8 +702,6 @@ export class AttestationService { return { ...highlight, path: transformedPath }; }); - logger.info({ highlights }, 'publishDraftComments::Highlights'); - logger.info({ transformed }, 'publishDraftComments::Transformed'); return { id: comment.id, highlights: transformed.map((h) => JSON.stringify(h)), diff --git a/desci-server/src/services/fixDpid.ts b/desci-server/src/services/fixDpid.ts index 4de297940..a3ee5690f 100644 --- a/desci-server/src/services/fixDpid.ts +++ b/desci-server/src/services/fixDpid.ts @@ -20,6 +20,7 @@ export const getTargetDpidUrl = () => { const TARGET_DPID_URL_BY_SERVER_URL = { 'https://nodes-api-dev.desci.com': 'https://dev-beta.dpid.org', 'https://nodes-api.desci.com': 'https://beta.dpid.org', + 'http://localhost:5420': 'http://host.docker.internal:5460', }; const targetDpidUrl = TARGET_DPID_URL_BY_SERVER_URL[process.env.SERVER_URL]; return targetDpidUrl; diff --git a/desci-server/src/theGraph.ts b/desci-server/src/theGraph.ts index 6fef11a88..a9e7ec8e9 100644 --- a/desci-server/src/theGraph.ts +++ b/desci-server/src/theGraph.ts @@ -10,7 +10,7 @@ const logger = parentLogger.child({ module: 'GetIndexedResearchObjects', }); -const RESOLVER_URL = process.env.DPID_URL_OVERRIDE || getTargetDpidUrl(); +const RESOLVER_URL = getTargetDpidUrl(); export type IndexedResearchObject = { /** Hex: Node UUID */ From 9cff31fec67259b9f5658a5fa2620f3f953d1144 Mon Sep 17 00:00:00 2001 From: kadami <86646883+kadamidev@users.noreply.github.com> Date: Wed, 2 Oct 2024 21:17:06 +0000 Subject: [PATCH 62/81] overwrite authors index with authors_with_institutions index --- desci-server/src/controllers/search/query.ts | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/desci-server/src/controllers/search/query.ts b/desci-server/src/controllers/search/query.ts index 5bbfb05ac..e2f42a6cb 100644 --- a/desci-server/src/controllers/search/query.ts +++ b/desci-server/src/controllers/search/query.ts @@ -79,6 +79,14 @@ export const singleQuery = async ( `Entity provided is '${entity}', overwriting with '${searchEntity}' because ${entity} is accessible in that index.`, ); } + + if (entity === 'authors') { + searchEntity = 'authors_with_institutions'; // Overwrite as fields are accessible via 'subfields' index + logger.info( + { entity, searchEntity }, + `Entity provided is '${entity}', overwriting with '${searchEntity}' because its a more complete index containing institution data`, + ); + } const finalQuery = { index: searchEntity, body: { From 8996ad1fe437b8bcd77fefeee2f7107c0c685be7 Mon Sep 17 00:00:00 2001 From: kadami <86646883+kadamidev@users.noreply.github.com> Date: Wed, 2 Oct 2024 21:17:36 +0000 Subject: [PATCH 63/81] rank autocomplete results by citation/works counts --- .../src/services/ElasticSearchService.ts | 74 +++++++++++++++++++ 1 file changed, 74 insertions(+) diff --git a/desci-server/src/services/ElasticSearchService.ts b/desci-server/src/services/ElasticSearchService.ts index 435459d93..0fb2b15c6 100644 --- a/desci-server/src/services/ElasticSearchService.ts +++ b/desci-server/src/services/ElasticSearchService.ts @@ -145,6 +145,76 @@ export function createFunctionScoreQuery(query: QueryDslQueryContainer, entity: }; } +export function createAutocompleteFunctionScoreQuery(query: string): QueryDslQueryContainer { + const functions: QueryDslFunctionScoreContainer[] = [ + // Citation count + { + filter: { range: { cited_by_count: { gte: 1 } } }, + field_value_factor: { + field: 'cited_by_count', + factor: 0.01, + modifier: 'log1p', + }, + weight: 10, + }, + // Works count + { + filter: { range: { works_count: { gte: 1 } } }, + field_value_factor: { + field: 'works_count', + factor: 0.005, + modifier: 'log1p', + }, + weight: 5, + }, + ]; + + const shouldClauses: QueryDslQueryContainer[] = [ + // Exact match on keyword fields + { + multi_match: { + query: query, + fields: [ + 'title.keyword^10', + 'primary_id.keyword^10', + 'entity_type.keyword^5', + 'publisher.keyword^5', + 'issn.keyword^5', + 'id.keyword^5', + ], + type: 'best_fields', + }, + }, + // match on text fields + { + multi_match: { + query: query, + fields: [ + 'title^3', + 'description^2', + 'publisher^2', + 'subfield_display_name^2', + 'institution_data.display_name^2', + ], + }, + }, + ]; + + const boolQuery: QueryDslBoolQuery = { + should: shouldClauses, + minimum_should_match: 1, + }; + + const functionScoreQuery: QueryDslFunctionScoreQuery = { + query: { bool: boolQuery }, + functions, + boost_mode: 'multiply' as QueryDslFunctionBoostMode, + score_mode: 'sum' as QueryDslFunctionScoreMode, + }; + + return { function_score: functionScoreQuery }; +} + export function buildSimpleStringQuery(query: string, entity: string, fuzzy?: number) { return { simple_query_string: { @@ -314,6 +384,10 @@ export function buildMultiMatchQuery( entity: string, fuzzy: string | number = 0, ): QueryDslQueryContainer { + if (entity === 'autocomplete_full') { + return createAutocompleteFunctionScoreQuery(query); + } + const fields = getRelevantFields(entity); const terms = query.split(/\s+/); const termCount = terms.length; From 364e6e5646f17d16d71b24cbccbefc030ffb79fa Mon Sep 17 00:00:00 2001 From: m0ar Date: Mon, 7 Oct 2024 16:04:22 +0200 Subject: [PATCH 64/81] server: use /readyz for probes and squelch logging on that route --- desci-server/kubernetes/deployment_dev.yaml | 6 +++--- desci-server/kubernetes/deployment_prod.yaml | 6 +++--- desci-server/kubernetes/deployment_staging.yaml | 6 +++--- desci-server/src/server.ts | 13 +++++++++---- 4 files changed, 18 insertions(+), 13 deletions(-) diff --git a/desci-server/kubernetes/deployment_dev.yaml b/desci-server/kubernetes/deployment_dev.yaml index 8c5ea447c..1703430a3 100644 --- a/desci-server/kubernetes/deployment_dev.yaml +++ b/desci-server/kubernetes/deployment_dev.yaml @@ -122,21 +122,21 @@ spec: # restart pod after failureThreshold*periodSeconds total seconds livenessProbe: httpGet: - path: / + path: /readyz port: server-api failureThreshold: 80 periodSeconds: 3 # temporarily stop sending traffic to pod after failureThreshold*periodSeconds total seconds readinessProbe: httpGet: - path: / + path: /readyz port: server-api failureThreshold: 3 periodSeconds: 1 # wait for pod to start for failureThreshold*periodSeconds total seconds startupProbe: httpGet: - path: / + path: /readyz port: server-api failureThreshold: 200 periodSeconds: 1 diff --git a/desci-server/kubernetes/deployment_prod.yaml b/desci-server/kubernetes/deployment_prod.yaml index 12bb1f955..0cfe2e829 100755 --- a/desci-server/kubernetes/deployment_prod.yaml +++ b/desci-server/kubernetes/deployment_prod.yaml @@ -121,21 +121,21 @@ spec: # restart pod after failureThreshold*periodSeconds total seconds livenessProbe: httpGet: - path: / + path: /readyz port: server-api failureThreshold: 80 periodSeconds: 3 # temporarily stop sending traffic to pod after failureThreshold*periodSeconds total seconds readinessProbe: httpGet: - path: / + path: /readyz port: server-api failureThreshold: 3 periodSeconds: 1 # wait for pod to start for failureThreshold*periodSeconds total seconds startupProbe: httpGet: - path: / + path: /readyz port: server-api failureThreshold: 200 periodSeconds: 1 diff --git a/desci-server/kubernetes/deployment_staging.yaml b/desci-server/kubernetes/deployment_staging.yaml index 74bdb2aba..d94eca4fc 100644 --- a/desci-server/kubernetes/deployment_staging.yaml +++ b/desci-server/kubernetes/deployment_staging.yaml @@ -132,21 +132,21 @@ spec: # restart pod after failureThreshold*periodSeconds total seconds livenessProbe: httpGet: - path: / + path: /readyz port: server-api failureThreshold: 80 periodSeconds: 3 # temporarily stop sending traffic to pod after failureThreshold*periodSeconds total seconds readinessProbe: httpGet: - path: / + path: /readyz port: server-api failureThreshold: 3 periodSeconds: 1 # wait for pod to start for failureThreshold*periodSeconds total seconds startupProbe: httpGet: - path: / + path: /readyz port: server-api failureThreshold: 200 periodSeconds: 1 diff --git a/desci-server/src/server.ts b/desci-server/src/server.ts index 172964d54..9e9ec8f2e 100644 --- a/desci-server/src/server.ts +++ b/desci-server/src/server.ts @@ -89,7 +89,12 @@ class AppServer { next(); }); - // // attach user info to every request + // Respond to probes before we do any other work on the request + this.app.get('/readyz', (_, res) => { + res.status(200).json({ status: 'ok' }); + }); + + // attach user info to every request this.app.use(async (req: RequestWithUser, res, next) => { const token = await extractAuthToken(req); @@ -155,9 +160,6 @@ class AppServer { } #attachRouteHandlers() { - this.app.get('/readyz', (_, res) => { - res.status(200).json({ status: 'ok' }); - }); this.app.get('/version', (req, res) => { const revision = child.execSync('git rev-parse HEAD').toString().trim(); // const sha256 = child.execSync('find /app/desci-server/dist -type f -exec sha256sum \\;').toString().trim(); @@ -185,6 +187,9 @@ class AppServer { this.app.use( pinoHttp({ logger, + autoLogging: { + ignore: (req) => req.url === "/readyz" + }, customProps: (req: RequestWithUser, res) => ({ userAuth: req.userAuth, traceId: (als.getStore() as any)?.traceId, From 7c9bf4b52237652dce88ddb76252d26637d96eee Mon Sep 17 00:00:00 2001 From: shadrach-tayo Date: Mon, 7 Oct 2024 10:31:05 -0500 Subject: [PATCH 65/81] distributed trace id support on desci-repo, better log messages for debugging --- desci-repo/package.json | 4 +- desci-repo/src/controllers/nodes/documents.ts | 62 ++- desci-repo/src/logger.ts | 68 +++ desci-repo/src/middleware/ensureApiKey.ts | 2 +- desci-repo/src/middleware/guard.ts | 2 + desci-repo/src/repo.ts | 2 +- desci-repo/src/server.ts | 44 +- desci-repo/src/services/manifestRepo.ts | 7 + desci-repo/yarn.lock | 509 +++++++++++++++++- .../src/controllers/nodes/documents.ts | 8 +- .../src/controllers/nodes/draftCreate.ts | 8 +- desci-server/src/services/repoService.ts | 25 +- 12 files changed, 689 insertions(+), 52 deletions(-) diff --git a/desci-repo/package.json b/desci-repo/package.json index 6d8a9ff1c..15fd4ccd0 100644 --- a/desci-repo/package.json +++ b/desci-repo/package.json @@ -69,8 +69,10 @@ }, "dependencies": { "@desci-labs/desci-models": "0.2.11", - "@sentry/node": "^7.84.0", + "@sentry/node": "^8.29.0", + "@sentry/profiling-node": "^8.32.0", "@sentry/tracing": "^7.84.0", + "async_hooks": "^1.0.0", "axios": "^1.6.2", "cors": "^2.8.5", "deep-equal": "^2.2.3", diff --git a/desci-repo/src/controllers/nodes/documents.ts b/desci-repo/src/controllers/nodes/documents.ts index 0292f664c..3d23f3e6e 100644 --- a/desci-repo/src/controllers/nodes/documents.ts +++ b/desci-repo/src/controllers/nodes/documents.ts @@ -1,6 +1,6 @@ import { Request, Response } from 'express'; import { ResearchObjectDocument } from '../../types.js'; -import { logger } from '../../logger.js'; +import { logger as parentLogger } from '../../logger.js'; import { AutomergeUrl, DocumentId } from '@automerge/automerge-repo'; import { RequestWithNode } from '../../middleware/guard.js'; import { backendRepo } from '../../repo.js'; @@ -13,7 +13,9 @@ import { ensureUuidEndsWithDot } from './utils.js'; import { ManifestActions } from '@desci-labs/desci-models'; export const createNodeDocument = async function (req: Request, res: Response) { - logger.info('START [CreateNodeDocument]', req.body, req.params); + const logger = parentLogger.child({ module: 'createNodeDocument', body: req.body, param: req.params }); + logger.trace('createNodeDocument'); + try { if (!(req.body.uuid && req.body.manifest)) { res.status(400).send({ ok: false, message: 'Invalid data' }); @@ -21,10 +23,8 @@ export const createNodeDocument = async function (req: Request, res: Response) { } let { uuid, manifest } = req.body; - - logger.info('[Backend REPO]:', backendRepo.networkSubsystem.peerId); - uuid = ensureUuidEndsWithDot(uuid); + logger.info({ peerId: backendRepo.networkSubsystem.peerId, uuid }, '[Backend REPO]:'); const handle = backendRepo.create(); handle.change( (d) => { @@ -35,62 +35,80 @@ export const createNodeDocument = async function (req: Request, res: Response) { { message: 'Init Document', time: Date.now() }, ); + logger.info({ peerId: backendRepo.networkSubsystem.peerId, uuid }, 'Document Created'); + const document = await handle.doc(); + logger.trace({ document: !!document }, 'Document Retrieved'); + const node = await findNodeByUuid(uuid); + logger.trace({ node }, 'Node Retrieved'); // await prisma.node.update({ where: { id: node.id }, data: { manifestDocumentId: handle.documentId } }); const result = await query('UPDATE "Node" SET "manifestDocumentId" = $1 WHERE uuid = $2', [ handle.documentId, uuid, ]); - logger.info({ node, result }, '[createNodeDocument] UPDATE DOCUMENT ID'); - logger.info('[AUTOMERGE]::[HANDLE NEW CHANGED]', handle.url, handle.isReady(), document); + logger.trace( + { node, uuid, documentId: handle.documentId, url: handle.url, isReady: handle.isReady() }, + 'Node Updated', + ); + + logger.info({ result }, 'UPDATE DOCUMENT ID'); res.status(200).send({ ok: true, documentId: handle.documentId, document }); - logger.info('END [CreateNodeDocument]', { documentId: handle.documentId, document }); + + logger.info({ documentId: handle.documentId, document }, 'END'); } catch (err) { - console.error('Error [CreateNodeDocument]', err); - logger.error('END [CreateNodeDocument]', err); + logger.error({ err }, 'Error'); res.status(500).send({ ok: false, message: JSON.stringify(err) }); } }; export const getLatestNodeManifest = async function (req: Request, res: Response) { - logger.info({ params: req.params }, 'START [getLatestNodeManifest]'); + const logger = parentLogger.child({ module: 'getLatestNodeManifest', params: req.params }); + logger.trace('getLatestNodeManifest'); + try { - logger.info({ params: req.params }, '[getLatestNodeManifest]'); if (!req.params.uuid) { res.status(400).send({ ok: false, message: 'Invalid data' }); + logger.trace('No UUID FOUND'); return; } const { uuid } = req.params; - const node = await findNodeByUuid(uuid); - logger.trace('[getLatestNodeManifest::node]', { node }); + const node = await findNodeByUuid(ensureUuidEndsWithDot(uuid)); + logger.trace({ node }, 'Retrieve Node'); if (!node) { - logger.warn('[getLatestNodeManifest]', `Node with uuid ${uuid} not found!`); + logger.warn({ uuid }, `Node with uuid ${uuid} not found!`); res.status(400).send({ ok: false, message: `Node with uuid ${uuid} not found!` }); return; } + logger.info( + { manifestDocumentId: node.manifestDocumentId, url: getAutomergeUrl(node.manifestDocumentId) }, + 'Node manifestDocumentId', + ); + const automergeUrl = getAutomergeUrl(node.manifestDocumentId as DocumentId); const handle = backendRepo.find(automergeUrl as AutomergeUrl); + logger.trace({ uuid, automergeUrl }, 'Document Handle retrieved'); + logger.trace({ uuid, automergeUrl }, 'Get DOCUMENT'); const document = await handle.doc(); + logger.trace({ uuid, automergeUrl }, 'DOCUMENT Retrieved'); logger.info({ manifest: document?.manifest, automergeUrl }, '[getLatestNodeManifest::END]'); res.status(200).send({ ok: true, document }); } catch (err) { - console.error('Error [getLatestNodeManifest]', err); - logger.error(err, 'Error [getLatestNodeManifest]'); + logger.error({ err }, 'Error'); res.status(500).send({ ok: false, message: JSON.stringify(err) }); } }; export const dispatchDocumentChange = async function (req: RequestWithNode, res: Response) { - logger.info({ params: req.params }, 'START [dispatchDocumentChange]'); + const logger = parentLogger.child({ module: 'dispatchDocumentChange', body: req.body, params: req.params }); try { if (!(req.body.uuid && req.body.documentId && req.body.actions)) { res.status(400).send({ ok: false, message: 'Invalid data' }); @@ -109,8 +127,8 @@ export const dispatchDocumentChange = async function (req: RequestWithNode, res: const dispatchChange = getDocumentUpdater(documentId); + logger.info({ actions }, 'Actions'); for (const action of actions) { - logger.info({ action }, '[AUTOMERGE]::[dispatch Update]'); document = await dispatchChange(action); } @@ -119,16 +137,16 @@ export const dispatchDocumentChange = async function (req: RequestWithNode, res: return; } - logger.info('END [dispatchDocumentChange]', { document }); res.status(200).send({ ok: true, document }); + logger.trace('END'); } catch (err) { - logger.error(err, 'Error [dispatchDocumentChange]'); - + logger.error({ err }, 'Error [dispatchDocumentChange]'); res.status(500).send({ ok: false, message: JSON.stringify(err) }); } }; export const dispatchDocumentActions = async function (req: RequestWithNode, res: Response) { + const logger = parentLogger.child({ module: 'dispatchDocumentActions' }); logger.info({ body: req.body }, 'START [dispatchDocumentActions]'); try { if (!(req.body.uuid && req.body.documentId && req.body.actions)) { diff --git a/desci-repo/src/logger.ts b/desci-repo/src/logger.ts index 6767b59ab..d00ad9d6b 100644 --- a/desci-repo/src/logger.ts +++ b/desci-repo/src/logger.ts @@ -2,6 +2,9 @@ import { pino } from 'pino'; import { fileURLToPath } from 'url'; import path from 'path'; import { pool } from './db/index.js'; +import { AsyncLocalStorage } from 'async_hooks'; + +export const als = new AsyncLocalStorage(); const __filename = fileURLToPath(import.meta.url); const __dirname = path.dirname(__filename); @@ -24,11 +27,76 @@ const fileTransport = { console.log('[DIR NAME]::', __dirname, __filename, logLevel); +function logMethodHooks(inputArgs, method) { + try { + //get caller + const stack = new Error()?.stack?.split('\n') ?? []; + // find first line that is not from this file + + let callerFilePath; + try { + const intermediate = stack.filter( + (a) => a.includes('file:///') && !(a.includes('/dist/logger.') || a.includes('/src/logger.')), + )[0]; + + if (intermediate) { + callerFilePath = intermediate + .split('(')[1] + .split(')')[0] + .replace('file:///app/desci-server/src/', '') + .replace('file:///app/dist/', ''); + } + } catch (err) { + // callerFilePath = '-unknown-'; + } + + let target = typeof inputArgs[0] == 'string' ? 1 : 0; + let newInputArgs = [...inputArgs]; + + if (!newInputArgs[target]) { + newInputArgs[target] = {}; + } else if (typeof newInputArgs[target] !== 'object') { + const rawValue = {}; + rawValue['stringLogs'] = inputArgs; + + rawValue['error'] = + 'this means your pino log statement is incorrectly formatted, check the order of the arguments'; + target = 0; + newInputArgs[target] = { rawValue }; + newInputArgs = [newInputArgs[0], inputArgs[0]]; + } + + newInputArgs[target]['caller'] = callerFilePath; + + const traceId = (als.getStore() as any)?.traceId; + const callerTraceId = (als.getStore() as any)?.callerTraceId; + if (traceId) { + newInputArgs[target]['traceId'] = traceId; + newInputArgs[target]['callerTraceId'] = callerTraceId || ''; + + const timingArray = (als.getStore() as any)?.timing; + if (timingArray) { + newInputArgs[target]['traceIndex'] = timingArray.length; + newInputArgs[target]['traceDelta'] = Date.now() - timingArray[timingArray.length - 1]; + } + (als.getStore() as any)?.timing.push(Date.now()); + } + + return method.apply(this, [...newInputArgs]); + } catch (err) { + // logger.error({ err }, 'error in logMethod hook'); + return method.apply(this, inputArgs); + } +} + export const logger = pino({ level: logLevel, serializers: { files: omitBuffer, }, + hooks: { + logMethod: logMethodHooks, + }, transport: process.env.NODE_ENV === 'production' ? { targets: [] } diff --git a/desci-repo/src/middleware/ensureApiKey.ts b/desci-repo/src/middleware/ensureApiKey.ts index 042389c64..b538037bf 100644 --- a/desci-repo/src/middleware/ensureApiKey.ts +++ b/desci-repo/src/middleware/ensureApiKey.ts @@ -5,7 +5,7 @@ const REPO_SERVICE_API_KEY = process.env.REPO_SERVICE_SECRET_KEY; export const ensureApiKey = async (req: Request, res: Response, next: NextFunction) => { const apiKey = req.headers['x-api-key']; - logger.info({ module: 'EnsureApiKey', apiKeyLength: apiKey?.length }, 'VERIFY API KEY from', req.hostname); + logger.info({ module: 'EnsureApiKey', apiKeyLength: apiKey?.length, hostname: req.hostname }, 'VERIFY API KEY from'); if (!apiKey || apiKey !== REPO_SERVICE_API_KEY) { res.sendStatus(401); return; diff --git a/desci-repo/src/middleware/guard.ts b/desci-repo/src/middleware/guard.ts index b5df98e9b..b10576409 100644 --- a/desci-repo/src/middleware/guard.ts +++ b/desci-repo/src/middleware/guard.ts @@ -20,6 +20,8 @@ export type Node = { export interface RequestWithUser extends Request { user: { email: string; id: number }; + traceId?: string; + callerTraceId?: string; } export interface RequestWithNode extends RequestWithUser { diff --git a/desci-repo/src/repo.ts b/desci-repo/src/repo.ts index 9699a2d0f..ca6ea0c83 100644 --- a/desci-repo/src/repo.ts +++ b/desci-repo/src/repo.ts @@ -42,7 +42,7 @@ const config: RepoConfig = { const userId = peerId.split(':')?.[0]?.split('-')?.[1]; const isAuthorised = await verifyNodeDocumentAccess(Number(userId), documentId); - logger.info({ peerId, userId, documentId, isAuthorised }, '[SHARE POLICY CALLED]::'); + logger.trace({ peerId, userId, documentId, isAuthorised }, '[SHARE POLICY CALLED]::'); return isAuthorised; } catch (err) { logger.error({ err }, 'Error in share policy'); diff --git a/desci-repo/src/server.ts b/desci-repo/src/server.ts index 17d3c7cfb..354e960cb 100644 --- a/desci-repo/src/server.ts +++ b/desci-repo/src/server.ts @@ -17,9 +17,11 @@ import routes from './routes/index.js'; import { fileURLToPath } from 'url'; import { socket as wsSocket } from './repo.js'; -import { logger } from './logger.js'; +import { als, logger } from './logger.js'; import { extractAuthToken, extractUserFromToken } from './middleware/permissions.js'; import { pinoHttp } from 'pino-http'; +import { RequestWithUser } from './middleware/guard.js'; +import { nodeProfilingIntegration } from '@sentry/profiling-node'; const __filename = fileURLToPath(import.meta.url); const __dirname = path.dirname(__filename); @@ -47,6 +49,17 @@ const allowlist = [ 'loca.lt' /** NOT SECURE */, 'vercel.app' /** NOT SECURE */, ]; + +function getRemoteAddress(req: Request) { + let xForwardedFor = req.headers['x-forwarded-for']; + xForwardedFor = Array.isArray(xForwardedFor) ? xForwardedFor.join(',') : xForwardedFor; + if (xForwardedFor) { + return xForwardedFor.split(',')[0].trim(); + } else { + return req.socket.remoteAddress; + } +} + class AppServer { #readyResolvers: ((value: any) => void)[] = []; @@ -80,6 +93,19 @@ class AppServer { next(); }); + // attach trace id to every request + this.app.use((req: RequestWithUser, res, next) => { + req.traceId = v4(); + req.callerTraceId = req.headers['x-api-remote-traceid'] as string; + + res.header('X-Desci-Trace-Id', req.traceId); + res.header('X-Desci-Request-Trace-Id', req.headers['x-api-remote-traceid']); + + als.run({ traceId: req.traceId, callerTraceId: req.callerTraceId, timing: [new Date()] }, () => { + next(); + }); + }); + this.#initTelemetry(); this.app.use(bodyParser.json({ limit: '100mb' })); @@ -138,6 +164,12 @@ class AppServer { this.app.use( pinoHttp({ logger, + customProps: (req: RequestWithUser) => ({ + traceId: (als.getStore() as any)?.traceId, + callerTraceId: req.headers['x-api-remote-traceid'], + http: 1, + remoteAddress: getRemoteAddress(req), + }), serializers: { res: (res) => { if (IS_DEV) { @@ -172,15 +204,17 @@ class AppServer { Sentry.init({ dsn: 'https://d508a5c408f34b919ccd94aac093e076@o1330109.ingest.sentry.io/6619754', release: 'desci-nodes-repo@' + process.env.npm_package_version, - integrations: [], + integrations: [nodeProfilingIntegration()], // Set tracesSampleRate to 1.0 to capture 100% // of transactions for performance monitoring. // We recommend adjusting this value in production tracesSampleRate: 1.0, + profilesSampleRate: 1.0, }); - this.app.use(Sentry.Handlers.requestHandler()); - this.app.use(Sentry.Handlers.tracingHandler()); - this.app.use(Sentry.Handlers.errorHandler()); + // this.app.use(Sentry.Handlers.requestHandler()); + // this.app.use(Sentry.Handlers.tracingHandler()); + // this.app.use(Sentry.Handlers.errorHandler()); + Sentry.setupExpressErrorHandler(this.app); } else { logger.info('[DeSci Repo] Telemetry disabled'); } diff --git a/desci-repo/src/services/manifestRepo.ts b/desci-repo/src/services/manifestRepo.ts index 9b795d803..ee7845bc3 100644 --- a/desci-repo/src/services/manifestRepo.ts +++ b/desci-repo/src/services/manifestRepo.ts @@ -33,11 +33,15 @@ export function assertNever(value: never) { export const getDocumentUpdater = (documentId: DocumentId) => { const automergeUrl = getAutomergeUrl(documentId); + logger.trace({ automergeUrl }, 'Find handle'); const handle = backendRepo.find(automergeUrl as AutomergeUrl); + logger.trace({ automergeUrl }, 'Retrieved handle'); return async (action: ManifestActions) => { if (!handle) return; + logger.trace({ documentId, action }, 'get doc'); let latestDocument = await handle.doc(); + logger.trace({ latestDocument }, 'retrieved doc'); if (!latestDocument) { logger.error({ node: documentId }, 'Automerge document not found'); @@ -350,7 +354,10 @@ export const getDocumentUpdater = (documentId: DocumentId) => { default: assertNever(action); } + + logger.trace({ documentId }, 'get updated doc'); latestDocument = await handle.doc(); + logger.trace({ action }, 'retrieved updated doc'); if (latestDocument) { const updatedHeads = getHeads(latestDocument); diff --git a/desci-repo/yarn.lock b/desci-repo/yarn.lock index c9feb1816..f3c217550 100644 --- a/desci-repo/yarn.lock +++ b/desci-repo/yarn.lock @@ -260,6 +260,293 @@ "@nodelib/fs.scandir" "2.1.5" fastq "^1.6.0" +"@opentelemetry/api-logs@0.52.1": + version "0.52.1" + resolved "https://registry.yarnpkg.com/@opentelemetry/api-logs/-/api-logs-0.52.1.tgz#52906375da4d64c206b0c4cb8ffa209214654ecc" + integrity sha512-qnSqB2DQ9TPP96dl8cDubDvrUyWc0/sK81xHTK8eSUspzDM3bsewX903qclQFvVhgStjRWdC5bLb3kQqMkfV5A== + dependencies: + "@opentelemetry/api" "^1.0.0" + +"@opentelemetry/api-logs@0.53.0": + version "0.53.0" + resolved "https://registry.yarnpkg.com/@opentelemetry/api-logs/-/api-logs-0.53.0.tgz#c478cbd8120ec2547b64edfa03a552cfe42170be" + integrity sha512-8HArjKx+RaAI8uEIgcORbZIPklyh1YLjPSBus8hjRmvLi6DeFzgOcdZ7KwPabKj8mXF8dX0hyfAyGfycz0DbFw== + dependencies: + "@opentelemetry/api" "^1.0.0" + +"@opentelemetry/api@^1.0.0", "@opentelemetry/api@^1.8", "@opentelemetry/api@^1.9.0": + version "1.9.0" + resolved "https://registry.yarnpkg.com/@opentelemetry/api/-/api-1.9.0.tgz#d03eba68273dc0f7509e2a3d5cba21eae10379fe" + integrity sha512-3giAOQvZiH5F9bMlMiv8+GSPMeqg0dbaeo58/0SlA9sxSqZhnUtxzX9/2FzyhS9sWQf5S0GJE0AKBrFqjpeYcg== + +"@opentelemetry/context-async-hooks@^1.25.1": + version "1.26.0" + resolved "https://registry.yarnpkg.com/@opentelemetry/context-async-hooks/-/context-async-hooks-1.26.0.tgz#fa92f722cf685685334bba95f258d3ef9fce60f6" + integrity sha512-HedpXXYzzbaoutw6DFLWLDket2FwLkLpil4hGCZ1xYEIMTcivdfwEOISgdbLEWyG3HW52gTq2V9mOVJrONgiwg== + +"@opentelemetry/core@1.26.0", "@opentelemetry/core@^1.1.0", "@opentelemetry/core@^1.25.1", "@opentelemetry/core@^1.8.0": + version "1.26.0" + resolved "https://registry.yarnpkg.com/@opentelemetry/core/-/core-1.26.0.tgz#7d84265aaa850ed0ca5813f97d831155be42b328" + integrity sha512-1iKxXXE8415Cdv0yjG3G6hQnB5eVEsJce3QaawX8SjDn0mAS0ZM8fAbZZJD4ajvhC15cePvosSCut404KrIIvQ== + dependencies: + "@opentelemetry/semantic-conventions" "1.27.0" + +"@opentelemetry/instrumentation-amqplib@^0.42.0": + version "0.42.0" + resolved "https://registry.yarnpkg.com/@opentelemetry/instrumentation-amqplib/-/instrumentation-amqplib-0.42.0.tgz#b3cab5a7207736a30d769962eed3af3838f986c4" + integrity sha512-fiuU6OKsqHJiydHWgTRQ7MnIrJ2lEqsdgFtNIH4LbAUJl/5XmrIeoDzDnox+hfkgWK65jsleFuQDtYb5hW1koQ== + dependencies: + "@opentelemetry/core" "^1.8.0" + "@opentelemetry/instrumentation" "^0.53.0" + "@opentelemetry/semantic-conventions" "^1.27.0" + +"@opentelemetry/instrumentation-connect@0.39.0": + version "0.39.0" + resolved "https://registry.yarnpkg.com/@opentelemetry/instrumentation-connect/-/instrumentation-connect-0.39.0.tgz#32bdbaac464cba061c95df6c850ee81efdd86f8b" + integrity sha512-pGBiKevLq7NNglMgqzmeKczF4XQMTOUOTkK8afRHMZMnrK3fcETyTH7lVaSozwiOM3Ws+SuEmXZT7DYrrhxGlg== + dependencies: + "@opentelemetry/core" "^1.8.0" + "@opentelemetry/instrumentation" "^0.53.0" + "@opentelemetry/semantic-conventions" "^1.27.0" + "@types/connect" "3.4.36" + +"@opentelemetry/instrumentation-dataloader@0.12.0": + version "0.12.0" + resolved "https://registry.yarnpkg.com/@opentelemetry/instrumentation-dataloader/-/instrumentation-dataloader-0.12.0.tgz#de03a3948dec4f15fed80aa424d6bd5d6a8d10c7" + integrity sha512-pnPxatoFE0OXIZDQhL2okF//dmbiWFzcSc8pUg9TqofCLYZySSxDCgQc69CJBo5JnI3Gz1KP+mOjS4WAeRIH4g== + dependencies: + "@opentelemetry/instrumentation" "^0.53.0" + +"@opentelemetry/instrumentation-express@0.42.0": + version "0.42.0" + resolved "https://registry.yarnpkg.com/@opentelemetry/instrumentation-express/-/instrumentation-express-0.42.0.tgz#279f195aa66baee2b98623a16666c6229c8e7564" + integrity sha512-YNcy7ZfGnLsVEqGXQPT+S0G1AE46N21ORY7i7yUQyfhGAL4RBjnZUqefMI0NwqIl6nGbr1IpF0rZGoN8Q7x12Q== + dependencies: + "@opentelemetry/core" "^1.8.0" + "@opentelemetry/instrumentation" "^0.53.0" + "@opentelemetry/semantic-conventions" "^1.27.0" + +"@opentelemetry/instrumentation-fastify@0.39.0": + version "0.39.0" + resolved "https://registry.yarnpkg.com/@opentelemetry/instrumentation-fastify/-/instrumentation-fastify-0.39.0.tgz#96a040e4944daf77c53a8fe5a128bc3b2568e4aa" + integrity sha512-SS9uSlKcsWZabhBp2szErkeuuBDgxOUlllwkS92dVaWRnMmwysPhcEgHKB8rUe3BHg/GnZC1eo1hbTZv4YhfoA== + dependencies: + "@opentelemetry/core" "^1.8.0" + "@opentelemetry/instrumentation" "^0.53.0" + "@opentelemetry/semantic-conventions" "^1.27.0" + +"@opentelemetry/instrumentation-fs@0.15.0": + version "0.15.0" + resolved "https://registry.yarnpkg.com/@opentelemetry/instrumentation-fs/-/instrumentation-fs-0.15.0.tgz#41658507860f39fee5209bca961cea8d24ca2a83" + integrity sha512-JWVKdNLpu1skqZQA//jKOcKdJC66TWKqa2FUFq70rKohvaSq47pmXlnabNO+B/BvLfmidfiaN35XakT5RyMl2Q== + dependencies: + "@opentelemetry/core" "^1.8.0" + "@opentelemetry/instrumentation" "^0.53.0" + +"@opentelemetry/instrumentation-generic-pool@0.39.0": + version "0.39.0" + resolved "https://registry.yarnpkg.com/@opentelemetry/instrumentation-generic-pool/-/instrumentation-generic-pool-0.39.0.tgz#2b9af16ad82d5cbe67125c0125753cecd162a728" + integrity sha512-y4v8Y+tSfRB3NNBvHjbjrn7rX/7sdARG7FuK6zR8PGb28CTa0kHpEGCJqvL9L8xkTNvTXo+lM36ajFGUaK1aNw== + dependencies: + "@opentelemetry/instrumentation" "^0.53.0" + +"@opentelemetry/instrumentation-graphql@0.43.0": + version "0.43.0" + resolved "https://registry.yarnpkg.com/@opentelemetry/instrumentation-graphql/-/instrumentation-graphql-0.43.0.tgz#71bb94ea775c70dbd388c739b397ec1418f3f170" + integrity sha512-aI3YMmC2McGd8KW5du1a2gBA0iOMOGLqg4s9YjzwbjFwjlmMNFSK1P3AIg374GWg823RPUGfVTIgZ/juk9CVOA== + dependencies: + "@opentelemetry/instrumentation" "^0.53.0" + +"@opentelemetry/instrumentation-hapi@0.41.0": + version "0.41.0" + resolved "https://registry.yarnpkg.com/@opentelemetry/instrumentation-hapi/-/instrumentation-hapi-0.41.0.tgz#de8711907256d8fae1b5faf71fc825cef4a7ddbb" + integrity sha512-jKDrxPNXDByPlYcMdZjNPYCvw0SQJjN+B1A+QH+sx+sAHsKSAf9hwFiJSrI6C4XdOls43V/f/fkp9ITkHhKFbQ== + dependencies: + "@opentelemetry/core" "^1.8.0" + "@opentelemetry/instrumentation" "^0.53.0" + "@opentelemetry/semantic-conventions" "^1.27.0" + +"@opentelemetry/instrumentation-http@0.53.0": + version "0.53.0" + resolved "https://registry.yarnpkg.com/@opentelemetry/instrumentation-http/-/instrumentation-http-0.53.0.tgz#0d806adf1b3aba036bc46e16162e3c0dbb8a6b60" + integrity sha512-H74ErMeDuZfj7KgYCTOFGWF5W9AfaPnqLQQxeFq85+D29wwV2yqHbz2IKLYpkOh7EI6QwDEl7rZCIxjJLyc/CQ== + dependencies: + "@opentelemetry/core" "1.26.0" + "@opentelemetry/instrumentation" "0.53.0" + "@opentelemetry/semantic-conventions" "1.27.0" + semver "^7.5.2" + +"@opentelemetry/instrumentation-ioredis@0.43.0": + version "0.43.0" + resolved "https://registry.yarnpkg.com/@opentelemetry/instrumentation-ioredis/-/instrumentation-ioredis-0.43.0.tgz#dbadabaeefc4cb47c406f878444f1bcac774fa89" + integrity sha512-i3Dke/LdhZbiUAEImmRG3i7Dimm/BD7t8pDDzwepSvIQ6s2X6FPia7561gw+64w+nx0+G9X14D7rEfaMEmmjig== + dependencies: + "@opentelemetry/instrumentation" "^0.53.0" + "@opentelemetry/redis-common" "^0.36.2" + "@opentelemetry/semantic-conventions" "^1.27.0" + +"@opentelemetry/instrumentation-kafkajs@0.3.0": + version "0.3.0" + resolved "https://registry.yarnpkg.com/@opentelemetry/instrumentation-kafkajs/-/instrumentation-kafkajs-0.3.0.tgz#6687bce4dac8b90ef8ccbf1b662d5d1e95a34414" + integrity sha512-UnkZueYK1ise8FXQeKlpBd7YYUtC7mM8J0wzUSccEfc/G8UqHQqAzIyYCUOUPUKp8GsjLnWOOK/3hJc4owb7Jg== + dependencies: + "@opentelemetry/instrumentation" "^0.53.0" + "@opentelemetry/semantic-conventions" "^1.27.0" + +"@opentelemetry/instrumentation-koa@0.43.0": + version "0.43.0" + resolved "https://registry.yarnpkg.com/@opentelemetry/instrumentation-koa/-/instrumentation-koa-0.43.0.tgz#963fd192a1b5f6cbae5dabf4ec82e3105cbb23b1" + integrity sha512-lDAhSnmoTIN6ELKmLJBplXzT/Jqs5jGZehuG22EdSMaTwgjMpxMDI1YtlKEhiWPWkrz5LUsd0aOO0ZRc9vn3AQ== + dependencies: + "@opentelemetry/core" "^1.8.0" + "@opentelemetry/instrumentation" "^0.53.0" + "@opentelemetry/semantic-conventions" "^1.27.0" + +"@opentelemetry/instrumentation-lru-memoizer@0.40.0": + version "0.40.0" + resolved "https://registry.yarnpkg.com/@opentelemetry/instrumentation-lru-memoizer/-/instrumentation-lru-memoizer-0.40.0.tgz#dc60d7fdfd2a0c681cb23e7ed4f314d1506ccdc0" + integrity sha512-21xRwZsEdMPnROu/QsaOIODmzw59IYpGFmuC4aFWvMj6stA8+Ei1tX67nkarJttlNjoM94um0N4X26AD7ff54A== + dependencies: + "@opentelemetry/instrumentation" "^0.53.0" + +"@opentelemetry/instrumentation-mongodb@0.47.0": + version "0.47.0" + resolved "https://registry.yarnpkg.com/@opentelemetry/instrumentation-mongodb/-/instrumentation-mongodb-0.47.0.tgz#f8107d878281433905e717f223fb4c0f10356a7b" + integrity sha512-yqyXRx2SulEURjgOQyJzhCECSh5i1uM49NUaq9TqLd6fA7g26OahyJfsr9NE38HFqGRHpi4loyrnfYGdrsoVjQ== + dependencies: + "@opentelemetry/instrumentation" "^0.53.0" + "@opentelemetry/sdk-metrics" "^1.9.1" + "@opentelemetry/semantic-conventions" "^1.27.0" + +"@opentelemetry/instrumentation-mongoose@0.42.0": + version "0.42.0" + resolved "https://registry.yarnpkg.com/@opentelemetry/instrumentation-mongoose/-/instrumentation-mongoose-0.42.0.tgz#375afd21adfcd897a8f521c1ffd2d91e6a428705" + integrity sha512-AnWv+RaR86uG3qNEMwt3plKX1ueRM7AspfszJYVkvkehiicC3bHQA6vWdb6Zvy5HAE14RyFbu9+2hUUjR2NSyg== + dependencies: + "@opentelemetry/core" "^1.8.0" + "@opentelemetry/instrumentation" "^0.53.0" + "@opentelemetry/semantic-conventions" "^1.27.0" + +"@opentelemetry/instrumentation-mysql2@0.41.0": + version "0.41.0" + resolved "https://registry.yarnpkg.com/@opentelemetry/instrumentation-mysql2/-/instrumentation-mysql2-0.41.0.tgz#6377b6e2d2487fd88e1d79aa03658db6c8d51651" + integrity sha512-REQB0x+IzVTpoNgVmy5b+UnH1/mDByrneimP6sbDHkp1j8QOl1HyWOrBH/6YWR0nrbU3l825Em5PlybjT3232g== + dependencies: + "@opentelemetry/instrumentation" "^0.53.0" + "@opentelemetry/semantic-conventions" "^1.27.0" + "@opentelemetry/sql-common" "^0.40.1" + +"@opentelemetry/instrumentation-mysql@0.41.0": + version "0.41.0" + resolved "https://registry.yarnpkg.com/@opentelemetry/instrumentation-mysql/-/instrumentation-mysql-0.41.0.tgz#2d50691ead5219774bd36d66c35d5b4681485dd7" + integrity sha512-jnvrV6BsQWyHS2qb2fkfbfSb1R/lmYwqEZITwufuRl37apTopswu9izc0b1CYRp/34tUG/4k/V39PND6eyiNvw== + dependencies: + "@opentelemetry/instrumentation" "^0.53.0" + "@opentelemetry/semantic-conventions" "^1.27.0" + "@types/mysql" "2.15.26" + +"@opentelemetry/instrumentation-nestjs-core@0.40.0": + version "0.40.0" + resolved "https://registry.yarnpkg.com/@opentelemetry/instrumentation-nestjs-core/-/instrumentation-nestjs-core-0.40.0.tgz#2c0e6405b56caaec32747d55c57ff9a034668ea8" + integrity sha512-WF1hCUed07vKmf5BzEkL0wSPinqJgH7kGzOjjMAiTGacofNXjb/y4KQ8loj2sNsh5C/NN7s1zxQuCgbWbVTGKg== + dependencies: + "@opentelemetry/instrumentation" "^0.53.0" + "@opentelemetry/semantic-conventions" "^1.27.0" + +"@opentelemetry/instrumentation-pg@0.44.0": + version "0.44.0" + resolved "https://registry.yarnpkg.com/@opentelemetry/instrumentation-pg/-/instrumentation-pg-0.44.0.tgz#1e97a0aeb2dca068ee23ce75884a0a0063a7ce3f" + integrity sha512-oTWVyzKqXud1BYEGX1loo2o4k4vaU1elr3vPO8NZolrBtFvQ34nx4HgUaexUDuEog00qQt+MLR5gws/p+JXMLQ== + dependencies: + "@opentelemetry/instrumentation" "^0.53.0" + "@opentelemetry/semantic-conventions" "^1.27.0" + "@opentelemetry/sql-common" "^0.40.1" + "@types/pg" "8.6.1" + "@types/pg-pool" "2.0.6" + +"@opentelemetry/instrumentation-redis-4@0.42.0": + version "0.42.0" + resolved "https://registry.yarnpkg.com/@opentelemetry/instrumentation-redis-4/-/instrumentation-redis-4-0.42.0.tgz#fc01104cfe884c7546385eaae03c57a47edd19d1" + integrity sha512-NaD+t2JNcOzX/Qa7kMy68JbmoVIV37fT/fJYzLKu2Wwd+0NCxt+K2OOsOakA8GVg8lSpFdbx4V/suzZZ2Pvdjg== + dependencies: + "@opentelemetry/instrumentation" "^0.53.0" + "@opentelemetry/redis-common" "^0.36.2" + "@opentelemetry/semantic-conventions" "^1.27.0" + +"@opentelemetry/instrumentation-undici@0.6.0": + version "0.6.0" + resolved "https://registry.yarnpkg.com/@opentelemetry/instrumentation-undici/-/instrumentation-undici-0.6.0.tgz#9436ee155c8dcb0b760b66947c0e0f347688a5ef" + integrity sha512-ABJBhm5OdhGmbh0S/fOTE4N69IZ00CsHC5ijMYfzbw3E5NwLgpQk5xsljaECrJ8wz1SfXbO03FiSuu5AyRAkvQ== + dependencies: + "@opentelemetry/core" "^1.8.0" + "@opentelemetry/instrumentation" "^0.53.0" + +"@opentelemetry/instrumentation@0.53.0", "@opentelemetry/instrumentation@^0.53.0": + version "0.53.0" + resolved "https://registry.yarnpkg.com/@opentelemetry/instrumentation/-/instrumentation-0.53.0.tgz#e6369e4015eb5112468a4d45d38dcada7dad892d" + integrity sha512-DMwg0hy4wzf7K73JJtl95m/e0boSoWhH07rfvHvYzQtBD3Bmv0Wc1x733vyZBqmFm8OjJD0/pfiUg1W3JjFX0A== + dependencies: + "@opentelemetry/api-logs" "0.53.0" + "@types/shimmer" "^1.2.0" + import-in-the-middle "^1.8.1" + require-in-the-middle "^7.1.1" + semver "^7.5.2" + shimmer "^1.2.1" + +"@opentelemetry/instrumentation@^0.49 || ^0.50 || ^0.51 || ^0.52.0": + version "0.52.1" + resolved "https://registry.yarnpkg.com/@opentelemetry/instrumentation/-/instrumentation-0.52.1.tgz#2e7e46a38bd7afbf03cf688c862b0b43418b7f48" + integrity sha512-uXJbYU/5/MBHjMp1FqrILLRuiJCs3Ofk0MeRDk8g1S1gD47U8X3JnSwcMO1rtRo1x1a7zKaQHaoYu49p/4eSKw== + dependencies: + "@opentelemetry/api-logs" "0.52.1" + "@types/shimmer" "^1.0.2" + import-in-the-middle "^1.8.1" + require-in-the-middle "^7.1.1" + semver "^7.5.2" + shimmer "^1.2.1" + +"@opentelemetry/redis-common@^0.36.2": + version "0.36.2" + resolved "https://registry.yarnpkg.com/@opentelemetry/redis-common/-/redis-common-0.36.2.tgz#906ac8e4d804d4109f3ebd5c224ac988276fdc47" + integrity sha512-faYX1N0gpLhej/6nyp6bgRjzAKXn5GOEMYY7YhciSfCoITAktLUtQ36d24QEWNA1/WA1y6qQunCe0OhHRkVl9g== + +"@opentelemetry/resources@1.26.0", "@opentelemetry/resources@^1.26.0": + version "1.26.0" + resolved "https://registry.yarnpkg.com/@opentelemetry/resources/-/resources-1.26.0.tgz#da4c7366018bd8add1f3aa9c91c6ac59fd503cef" + integrity sha512-CPNYchBE7MBecCSVy0HKpUISEeJOniWqcHaAHpmasZ3j9o6V3AyBzhRc90jdmemq0HOxDr6ylhUbDhBqqPpeNw== + dependencies: + "@opentelemetry/core" "1.26.0" + "@opentelemetry/semantic-conventions" "1.27.0" + +"@opentelemetry/sdk-metrics@^1.9.1": + version "1.26.0" + resolved "https://registry.yarnpkg.com/@opentelemetry/sdk-metrics/-/sdk-metrics-1.26.0.tgz#37bb0afb1d4447f50aab9cdd05db6f2d8b86103e" + integrity sha512-0SvDXmou/JjzSDOjUmetAAvcKQW6ZrvosU0rkbDGpXvvZN+pQF6JbK/Kd4hNdK4q/22yeruqvukXEJyySTzyTQ== + dependencies: + "@opentelemetry/core" "1.26.0" + "@opentelemetry/resources" "1.26.0" + +"@opentelemetry/sdk-trace-base@^1.22", "@opentelemetry/sdk-trace-base@^1.26.0": + version "1.26.0" + resolved "https://registry.yarnpkg.com/@opentelemetry/sdk-trace-base/-/sdk-trace-base-1.26.0.tgz#0c913bc6d2cfafd901de330e4540952269ae579c" + integrity sha512-olWQldtvbK4v22ymrKLbIcBi9L2SpMO84sCPY54IVsJhP9fRsxJT194C/AVaAuJzLE30EdhhM1VmvVYR7az+cw== + dependencies: + "@opentelemetry/core" "1.26.0" + "@opentelemetry/resources" "1.26.0" + "@opentelemetry/semantic-conventions" "1.27.0" + +"@opentelemetry/semantic-conventions@1.27.0", "@opentelemetry/semantic-conventions@^1.27.0": + version "1.27.0" + resolved "https://registry.yarnpkg.com/@opentelemetry/semantic-conventions/-/semantic-conventions-1.27.0.tgz#1a857dcc95a5ab30122e04417148211e6f945e6c" + integrity sha512-sAay1RrB+ONOem0OZanAR1ZI/k7yDpnOQSQmTMuGImUQb2y8EbSaCJ94FQluM74xoU03vlb2d2U90hZluL6nQg== + +"@opentelemetry/sql-common@^0.40.1": + version "0.40.1" + resolved "https://registry.yarnpkg.com/@opentelemetry/sql-common/-/sql-common-0.40.1.tgz#93fbc48d8017449f5b3c3274f2268a08af2b83b6" + integrity sha512-nSDlnHSqzC3pXn/wZEZVLuAuJ1MYMXPBwtv2qAbCa3847SaHItdE7SzUq/Jtb0KZmh1zfAbNi3AAMjztTT4Ugg== + dependencies: + "@opentelemetry/core" "^1.1.0" + "@pkgjs/parseargs@^0.11.0": version "0.11.0" resolved "https://registry.npmjs.org/@pkgjs/parseargs/-/parseargs-0.11.0.tgz" @@ -270,6 +557,15 @@ resolved "https://registry.npmjs.org/@pkgr/core/-/core-0.1.1.tgz" integrity sha512-cq8o4cWH0ibXh9VGi5P20Tu9XF/0fFXl9EUinr9QfTM7a7p0oTA4iJRCQWppXR1Pg8dSM0UCItCkPwsk9qWWYA== +"@prisma/instrumentation@5.19.1": + version "5.19.1" + resolved "https://registry.yarnpkg.com/@prisma/instrumentation/-/instrumentation-5.19.1.tgz#146319cf85f22b7a43296f0f40cfeac55516e66e" + integrity sha512-VLnzMQq7CWroL5AeaW0Py2huiNKeoMfCH3SUxstdzPrlWQi6UQ9UrfcbUkNHlVFqOMacqy8X/8YtE0kuKDpD9w== + dependencies: + "@opentelemetry/api" "^1.8" + "@opentelemetry/instrumentation" "^0.49 || ^0.50 || ^0.51 || ^0.52.0" + "@opentelemetry/sdk-trace-base" "^1.22" + "@sentry-internal/tracing@7.99.0": version "7.99.0" resolved "https://registry.npmjs.org/@sentry-internal/tracing/-/tracing-7.99.0.tgz" @@ -287,15 +583,75 @@ "@sentry/types" "7.99.0" "@sentry/utils" "7.99.0" -"@sentry/node@^7.84.0": - version "7.99.0" - resolved "https://registry.npmjs.org/@sentry/node/-/node-7.99.0.tgz" - integrity sha512-34wYtLddnPcQ8qvKq62AfxowaMFw+GMUZGv7fIs9FxeBqqqn6Ckl0gFCTADudIIBQ3rSbmN7sHJIXdyiQv+pcw== - dependencies: - "@sentry-internal/tracing" "7.99.0" - "@sentry/core" "7.99.0" - "@sentry/types" "7.99.0" - "@sentry/utils" "7.99.0" +"@sentry/core@8.33.1": + version "8.33.1" + resolved "https://registry.yarnpkg.com/@sentry/core/-/core-8.33.1.tgz#dc59f73b93e6f78f15c897ac47e48008680d9c04" + integrity sha512-3SS41suXLFzxL3OQvTMZ6q92ZapELVq2l2SoWlZopcamWhog2Ru0dp2vkunq97kFHb2TzKRTlFH4+4gbT8SJug== + dependencies: + "@sentry/types" "8.33.1" + "@sentry/utils" "8.33.1" + +"@sentry/node@8.33.1", "@sentry/node@^8.29.0": + version "8.33.1" + resolved "https://registry.yarnpkg.com/@sentry/node/-/node-8.33.1.tgz#1f45d13e59b86e9572e3f7764a8c9e5fe4ece0a7" + integrity sha512-0Xmlrl5nU5Bx6YybaIfztyOIiIXW5X64vcK0u94Sg4uHcDO7YvEbhflKjp669ds2I6ZQ/czqxnaAY8gM6P2SCA== + dependencies: + "@opentelemetry/api" "^1.9.0" + "@opentelemetry/context-async-hooks" "^1.25.1" + "@opentelemetry/core" "^1.25.1" + "@opentelemetry/instrumentation" "^0.53.0" + "@opentelemetry/instrumentation-amqplib" "^0.42.0" + "@opentelemetry/instrumentation-connect" "0.39.0" + "@opentelemetry/instrumentation-dataloader" "0.12.0" + "@opentelemetry/instrumentation-express" "0.42.0" + "@opentelemetry/instrumentation-fastify" "0.39.0" + "@opentelemetry/instrumentation-fs" "0.15.0" + "@opentelemetry/instrumentation-generic-pool" "0.39.0" + "@opentelemetry/instrumentation-graphql" "0.43.0" + "@opentelemetry/instrumentation-hapi" "0.41.0" + "@opentelemetry/instrumentation-http" "0.53.0" + "@opentelemetry/instrumentation-ioredis" "0.43.0" + "@opentelemetry/instrumentation-kafkajs" "0.3.0" + "@opentelemetry/instrumentation-koa" "0.43.0" + "@opentelemetry/instrumentation-lru-memoizer" "0.40.0" + "@opentelemetry/instrumentation-mongodb" "0.47.0" + "@opentelemetry/instrumentation-mongoose" "0.42.0" + "@opentelemetry/instrumentation-mysql" "0.41.0" + "@opentelemetry/instrumentation-mysql2" "0.41.0" + "@opentelemetry/instrumentation-nestjs-core" "0.40.0" + "@opentelemetry/instrumentation-pg" "0.44.0" + "@opentelemetry/instrumentation-redis-4" "0.42.0" + "@opentelemetry/instrumentation-undici" "0.6.0" + "@opentelemetry/resources" "^1.26.0" + "@opentelemetry/sdk-trace-base" "^1.26.0" + "@opentelemetry/semantic-conventions" "^1.27.0" + "@prisma/instrumentation" "5.19.1" + "@sentry/core" "8.33.1" + "@sentry/opentelemetry" "8.33.1" + "@sentry/types" "8.33.1" + "@sentry/utils" "8.33.1" + import-in-the-middle "^1.11.0" + +"@sentry/opentelemetry@8.33.1": + version "8.33.1" + resolved "https://registry.yarnpkg.com/@sentry/opentelemetry/-/opentelemetry-8.33.1.tgz#c7419a14ca00f8326a32673f19016098eaf9ff9a" + integrity sha512-D2aE2G0DUHLLnfbOXrTjiNJKAs/RZfOBJMidI4fC2AIwqCmrp55Aex4dRq4hxd8MPLR92Kt/ikHeJxlzWB15KA== + dependencies: + "@sentry/core" "8.33.1" + "@sentry/types" "8.33.1" + "@sentry/utils" "8.33.1" + +"@sentry/profiling-node@^8.32.0": + version "8.33.1" + resolved "https://registry.yarnpkg.com/@sentry/profiling-node/-/profiling-node-8.33.1.tgz#13143360b7adf3d35d2e701191378cde0a6cb419" + integrity sha512-mpgcqT/yUyWiRKjHFJ6UMjNmMgAYK4aeaMQDL7P61y5mrVxfK9vRQbKuXdP9XiyiZe06j1PSskiBEA2S1cDVJQ== + dependencies: + "@sentry/core" "8.33.1" + "@sentry/node" "8.33.1" + "@sentry/types" "8.33.1" + "@sentry/utils" "8.33.1" + detect-libc "^2.0.2" + node-abi "^3.61.0" "@sentry/tracing@^7.84.0": version "7.99.0" @@ -309,6 +665,11 @@ resolved "https://registry.npmjs.org/@sentry/types/-/types-7.99.0.tgz" integrity sha512-94qwOw4w40sAs5mCmzcGyj8ZUu/KhnWnuMZARRq96k+SjRW/tHFAOlIdnFSrt3BLPvSOK7R3bVAskZQ0N4FTmA== +"@sentry/types@8.33.1": + version "8.33.1" + resolved "https://registry.yarnpkg.com/@sentry/types/-/types-8.33.1.tgz#3c519f974c3c3f3ea8b4e6f930b676f954c26f87" + integrity sha512-GjoAMvwtpIemoF/IiwZ7A60g4nQv3qwzR21GvJqDVUoKD0e8pv9OLX+HyXoUat4wEDGSuDUcUyUKD2G+od73QA== + "@sentry/utils@7.99.0": version "7.99.0" resolved "https://registry.npmjs.org/@sentry/utils/-/utils-7.99.0.tgz" @@ -316,6 +677,13 @@ dependencies: "@sentry/types" "7.99.0" +"@sentry/utils@8.33.1": + version "8.33.1" + resolved "https://registry.yarnpkg.com/@sentry/utils/-/utils-8.33.1.tgz#8cfc56b7dbc27135028e77aa5d553b15f4ba0466" + integrity sha512-uzuYpiiJuFY3N4WNHMBWUQX5oNv2t/TbG0OHRp3Rr7yeu+HSfD542TIp9/gMZ+G0Cxd8AmVO3wkKIFbk0TL4Qg== + dependencies: + "@sentry/types" "8.33.1" + "@tsconfig/node10@^1.0.7": version "1.0.9" resolved "https://registry.npmjs.org/@tsconfig/node10/-/node10-1.0.9.tgz" @@ -356,6 +724,13 @@ dependencies: "@types/node" "*" +"@types/connect@3.4.36": + version "3.4.36" + resolved "https://registry.yarnpkg.com/@types/connect/-/connect-3.4.36.tgz#e511558c15a39cb29bd5357eebb57bd1459cd1ab" + integrity sha512-P63Zd/JUGq+PdrM1lv0Wv5SBYeA2+CORvbrXbngriYY0jzLUWfQMQQxOhjONEz/wlHOAxOdY7CY65rgQdTjq2w== + dependencies: + "@types/node" "*" + "@types/cors@^2.8.17": version "2.8.17" resolved "https://registry.npmjs.org/@types/cors/-/cors-2.8.17.tgz" @@ -427,6 +802,13 @@ dependencies: "@types/node" "*" +"@types/mysql@2.15.26": + version "2.15.26" + resolved "https://registry.yarnpkg.com/@types/mysql/-/mysql-2.15.26.tgz#f0de1484b9e2354d587e7d2bd17a873cc8300836" + integrity sha512-DSLCOXhkvfS5WNNPbfn2KdICAmk8lLc+/PNvnPnF7gOdMZCxopXduqv0OQ13y/yA/zXTSikZZqVgybUxOEg6YQ== + dependencies: + "@types/node" "*" + "@types/node@*": version "20.11.13" resolved "https://registry.npmjs.org/@types/node/-/node-20.11.13.tgz" @@ -439,6 +821,31 @@ resolved "https://registry.npmjs.org/@types/parse-json/-/parse-json-4.0.2.tgz" integrity sha512-dISoDXWWQwUquiKsyZ4Ng+HX2KsPL7LyHKHQwgGFEA3IaKac4Obd+h2a/a6waisAoepJlBcx9paWqjA8/HVjCw== +"@types/pg-pool@2.0.6": + version "2.0.6" + resolved "https://registry.yarnpkg.com/@types/pg-pool/-/pg-pool-2.0.6.tgz#1376d9dc5aec4bb2ec67ce28d7e9858227403c77" + integrity sha512-TaAUE5rq2VQYxab5Ts7WZhKNmuN78Q6PiFonTDdpbx8a1H0M1vhy3rhiMjl+e2iHmogyMw7jZF4FrE6eJUy5HQ== + dependencies: + "@types/pg" "*" + +"@types/pg@*": + version "8.11.10" + resolved "https://registry.yarnpkg.com/@types/pg/-/pg-8.11.10.tgz#b8fb2b2b759d452fe3ec182beadd382563b63291" + integrity sha512-LczQUW4dbOQzsH2RQ5qoeJ6qJPdrcM/DcMLoqWQkMLMsq83J5lAX3LXjdkWdpscFy67JSOWDnh7Ny/sPFykmkg== + dependencies: + "@types/node" "*" + pg-protocol "*" + pg-types "^4.0.1" + +"@types/pg@8.6.1": + version "8.6.1" + resolved "https://registry.yarnpkg.com/@types/pg/-/pg-8.6.1.tgz#099450b8dc977e8197a44f5229cedef95c8747f9" + integrity sha512-1Kc4oAGzAl7uqUStZCDvaLFqZrW9qWSjXOmBfdgyBP5La7Us6Mg4GBvRlSoaZMhQF/zSj1C8CtKMBkoiT8eL8w== + dependencies: + "@types/node" "*" + pg-protocol "*" + pg-types "^2.2.0" + "@types/pg@^8.10.9": version "8.11.0" resolved "https://registry.npmjs.org/@types/pg/-/pg-8.11.0.tgz" @@ -480,6 +887,11 @@ "@types/mime" "*" "@types/node" "*" +"@types/shimmer@^1.0.2", "@types/shimmer@^1.2.0": + version "1.2.0" + resolved "https://registry.yarnpkg.com/@types/shimmer/-/shimmer-1.2.0.tgz#9b706af96fa06416828842397a70dfbbf1c14ded" + integrity sha512-UE7oxhQLLd9gub6JKIAhDq06T0F6FnztwMNRvYgjeQSBeMc1ZG/tA47EwfduvkuQS8apbkM/lpLpWsaCeYsXVg== + "@types/strip-bom@^3.0.0": version "3.0.0" resolved "https://registry.npmjs.org/@types/strip-bom/-/strip-bom-3.0.0.tgz" @@ -597,6 +1009,11 @@ accepts@~1.3.8: mime-types "~2.1.34" negotiator "0.6.3" +acorn-import-attributes@^1.9.5: + version "1.9.5" + resolved "https://registry.yarnpkg.com/acorn-import-attributes/-/acorn-import-attributes-1.9.5.tgz#7eb1557b1ba05ef18b5ed0ec67591bfab04688ef" + integrity sha512-n02Vykv5uA3eHGM/Z2dQrcD56kL8TyDb2p1+0P83PClMnC/nc+anbQRhIOWnSq4Ke/KvDPrY3C9hDtC/A3eHnQ== + acorn-jsx@^5.3.2: version "5.3.2" resolved "https://registry.npmjs.org/acorn-jsx/-/acorn-jsx-5.3.2.tgz" @@ -612,6 +1029,11 @@ acorn@^8.4.1, acorn@^8.9.0: resolved "https://registry.npmjs.org/acorn/-/acorn-8.11.3.tgz" integrity sha512-Y9rRfJG5jcKOE0CLisYbojUjIrIEE7AGMzA/Sm4BslANhbS+cDMpgBdcPT91oJ7OuJ9hYJBx59RjbhxVnrF8Xg== +acorn@^8.8.2: + version "8.12.1" + resolved "https://registry.yarnpkg.com/acorn/-/acorn-8.12.1.tgz#71616bdccbe25e27a54439e0046e89ca76df2248" + integrity sha512-tcpGyI9zbizT9JbV6oYE477V6mTlXvvi0T0G3SNIYE2apm/G5huBa1+K89VGeovbg+jycCrfhl3ADxErOuO6Jg== + aggregate-error@^3.0.0: version "3.1.0" resolved "https://registry.npmjs.org/aggregate-error/-/aggregate-error-3.1.0.tgz" @@ -777,6 +1199,11 @@ astral-regex@^2.0.0: resolved "https://registry.npmjs.org/astral-regex/-/astral-regex-2.0.0.tgz" integrity sha512-Z7tMw1ytTXt5jqMcOP+OQteU1VuNK9Y02uuJtKQ1Sv69jXQKKg5cibLwGJow8yzZP+eAc18EmLGPal0bp36rvQ== +async_hooks@^1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/async_hooks/-/async_hooks-1.0.0.tgz#815f5e861fe73f64eb29fd942c32e95c8064052f" + integrity sha512-t4BSJgx48V3e7U6Ll3/WOUNmxIRPzmPdxVfgbyzcnRItEnn4iKp4F//b0sV3L9hzbdr5qxWdNWzOF7t+rjYSfA== + asynckit@^0.4.0: version "0.4.0" resolved "https://registry.npmjs.org/asynckit/-/asynckit-0.4.0.tgz" @@ -1012,6 +1439,11 @@ chokidar@3.5.3, chokidar@^3.5.1, chokidar@^3.5.2: optionalDependencies: fsevents "~2.3.2" +cjs-module-lexer@^1.2.2: + version "1.4.1" + resolved "https://registry.yarnpkg.com/cjs-module-lexer/-/cjs-module-lexer-1.4.1.tgz#707413784dbb3a72aa11c2f2b042a0bef4004170" + integrity sha512-cuSVIHi9/9E/+821Qjdvngor+xpnlwnuwIyZOaLmHBVdXL+gP+I6QQB9VkO7RI77YIcTV+S1W9AreJ5eN63JBA== + clean-stack@^2.0.0: version "2.2.0" resolved "https://registry.npmjs.org/clean-stack/-/clean-stack-2.2.0.tgz" @@ -1184,6 +1616,13 @@ debug@^3.2.7: dependencies: ms "^2.1.1" +debug@^4.3.5: + version "4.3.7" + resolved "https://registry.yarnpkg.com/debug/-/debug-4.3.7.tgz#87945b4151a011d76d95a198d7111c865c360a52" + integrity sha512-Er2nc/H7RrMXZBFCEim6TCmMk02Z8vLC2Rbi1KEBggpo0fS6l0S1nnapwmIi3yW/+GOJap1Krg4w0Hg80oCqgQ== + dependencies: + ms "^2.1.3" + decamelize@^4.0.0: version "4.0.0" resolved "https://registry.npmjs.org/decamelize/-/decamelize-4.0.0.tgz" @@ -1263,6 +1702,11 @@ detect-libc@^2.0.1: resolved "https://registry.npmjs.org/detect-libc/-/detect-libc-2.0.2.tgz" integrity sha512-UX6sGumvvqSaXgdKGUsgZWqcUyIXZ/vZTrlRT/iobiKhGL0zL4d3osHj3uqllWJK+i+sixDS/3COVEOFbupFyw== +detect-libc@^2.0.2: + version "2.0.3" + resolved "https://registry.yarnpkg.com/detect-libc/-/detect-libc-2.0.3.tgz#f0cd503b40f9939b894697d19ad50895e30cf700" + integrity sha512-bwy0MGW55bG41VqxxypOsdSdGqLwXPI/focwgTYCFMbdUiBAxLg9CFzG08sz2aqzknwiX7Hkl0bQENjg8iLByw== + diff@5.0.0: version "5.0.0" resolved "https://registry.npmjs.org/diff/-/diff-5.0.0.tgz" @@ -2167,6 +2611,16 @@ import-fresh@^3.2.1: parent-module "^1.0.0" resolve-from "^4.0.0" +import-in-the-middle@^1.11.0, import-in-the-middle@^1.8.1: + version "1.11.2" + resolved "https://registry.yarnpkg.com/import-in-the-middle/-/import-in-the-middle-1.11.2.tgz#dd848e72b63ca6cd7c34df8b8d97fc9baee6174f" + integrity sha512-gK6Rr6EykBcc6cVWRSBR5TWf8nn6hZMYSRYqCcHa0l0d1fPK7JSYo6+Mlmck76jIX9aL/IZ71c06U2VpFwl1zA== + dependencies: + acorn "^8.8.2" + acorn-import-attributes "^1.9.5" + cjs-module-lexer "^1.2.2" + module-details-from-path "^1.0.3" + imurmurhash@^0.1.4: version "0.1.4" resolved "https://registry.npmjs.org/imurmurhash/-/imurmurhash-0.1.4.tgz" @@ -2802,6 +3256,11 @@ mocha@^10.2.0: yargs-parser "20.2.4" yargs-unparser "2.0.0" +module-details-from-path@^1.0.3: + version "1.0.3" + resolved "https://registry.yarnpkg.com/module-details-from-path/-/module-details-from-path-1.0.3.tgz#114c949673e2a8a35e9d35788527aa37b679da2b" + integrity sha512-ySViT69/76t8VhE1xXHK6Ch4NcDd26gx0MzKXLO+F7NOtnqH68d9zF94nT8ZWSxXh8ELOERsnJO/sWt1xZYw5A== + morgan@^1.10.0: version "1.10.0" resolved "https://registry.npmjs.org/morgan/-/morgan-1.10.0.tgz" @@ -2828,7 +3287,7 @@ ms@2.1.2: resolved "https://registry.npmjs.org/ms/-/ms-2.1.2.tgz" integrity sha512-sGkPx+VjMtmA6MX27oA4FBFELFCZZ4S4XqeGOXCv68tT+jb3vk/RyaKWP0PTKyWtmLSM0b+adUTEvbs1PEaH2w== -ms@2.1.3, ms@^2.1.1: +ms@2.1.3, ms@^2.1.1, ms@^2.1.3: version "2.1.3" resolved "https://registry.npmjs.org/ms/-/ms-2.1.3.tgz" integrity sha512-6FlzubTLZG3J2a/NVCAleEhjzq5oxgHyaCU9yYXvcLsvoVaHJq/s5xXI6/XXP6tz7R9xAOtHnSO/tXtF3WRTlA== @@ -2853,6 +3312,13 @@ nice-try@^1.0.4: resolved "https://registry.npmjs.org/nice-try/-/nice-try-1.0.5.tgz" integrity sha512-1nh45deeb5olNY7eX82BkPO7SSxR5SSYJiPTrTdFUVYwAl8CKMA5N9PjTYkHiRjisVcxcQ1HXdLhx2qxxJzLNQ== +node-abi@^3.61.0: + version "3.68.0" + resolved "https://registry.yarnpkg.com/node-abi/-/node-abi-3.68.0.tgz#8f37fb02ecf4f43ebe694090dcb52e0c4cc4ba25" + integrity sha512-7vbj10trelExNjFSBm5kTvZXXa7pZyKWx9RCKIyqe6I9Ev3IzGpQoqBP3a+cOdxY+pWj6VkP28n/2wWysBHD/A== + dependencies: + semver "^7.3.5" + node-domexception@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/node-domexception/-/node-domexception-1.0.0.tgz#6888db46a1f71c0b76b3f7555016b63fe64766e5" @@ -3210,7 +3676,7 @@ pg-protocol@*, pg-protocol@^1.6.0: resolved "https://registry.npmjs.org/pg-protocol/-/pg-protocol-1.6.0.tgz" integrity sha512-M+PDm637OY5WM307051+bsDia5Xej6d9IR4GwJse1qA1DIhiKlksvrneZOYQq42OM+spubpcNYEo2FcKQrDk+Q== -pg-types@^2.1.0: +pg-types@^2.1.0, pg-types@^2.2.0: version "2.2.0" resolved "https://registry.npmjs.org/pg-types/-/pg-types-2.2.0.tgz" integrity sha512-qTAAlrEsl8s4OiEQY69wDvcMIdQN6wdz5ojQiOy6YRMuynxenON0O5oCpJI6lshc6scgAY8qvJ2On/p+CXY0GA== @@ -3570,12 +4036,21 @@ require-directory@^2.1.1: resolved "https://registry.npmjs.org/require-directory/-/require-directory-2.1.1.tgz" integrity sha512-fGxEI7+wsG9xrvdjsrlmL22OMTTiHRwAMroiEeMgq8gzoLC/PQr7RsRDSTLUg/bZAZtF+TVIkHc6/4RIKrui+Q== +require-in-the-middle@^7.1.1: + version "7.4.0" + resolved "https://registry.yarnpkg.com/require-in-the-middle/-/require-in-the-middle-7.4.0.tgz#606977820d4b5f9be75e5a108ce34cfed25b3bb4" + integrity sha512-X34iHADNbNDfr6OTStIAHWSAvvKQRYgLO6duASaVf7J2VA3lvmNYboAHOuLC2huav1IwgZJtyEcJCKVzFxOSMQ== + dependencies: + debug "^4.3.5" + module-details-from-path "^1.0.3" + resolve "^1.22.8" + resolve-from@^4.0.0: version "4.0.0" resolved "https://registry.npmjs.org/resolve-from/-/resolve-from-4.0.0.tgz" integrity sha512-pb/MYmXstAkysRFx8piNI1tGFNQIFA3vkE3Gq4EuA1dF6gHp/+vgZqsCGJapvy8N3Q+4o7FwvquPJcnZ7RYy4g== -resolve@^1.0.0, resolve@^1.10.0, resolve@^1.22.4: +resolve@^1.0.0, resolve@^1.10.0, resolve@^1.22.4, resolve@^1.22.8: version "1.22.8" resolved "https://registry.npmjs.org/resolve/-/resolve-1.22.8.tgz" integrity sha512-oKWePCxqpd6FlLvGV1VU0x7bkPmmCNolxzjMf4NczoDnQcIWrAF+cPtZn5i6n+RfD2d9i0tzpKnG6Yk168yIyw== @@ -3701,6 +4176,11 @@ semver@^6.3.1: resolved "https://registry.npmjs.org/semver/-/semver-6.3.1.tgz" integrity sha512-BR7VvDCVHO+q2xBEWskxS6DJE1qRnb7DxzUrogb71CWoSficBxYsiAGd+Kl0mmq/MprG9yArRkyrQxTO6XjMzA== +semver@^7.3.5, semver@^7.5.2: + version "7.6.3" + resolved "https://registry.yarnpkg.com/semver/-/semver-7.6.3.tgz#980f7b5550bc175fb4dc09403085627f9eb33143" + integrity sha512-oVekP1cKtI+CTDvHWYFUcMtsK/00wmAEfyqKfNdARm8u1wNVhSgaX7A8d4UuIlUI5e84iEwOhs7ZPYRmzU9U6A== + semver@^7.5.3, semver@^7.5.4: version "7.5.4" resolved "https://registry.npmjs.org/semver/-/semver-7.5.4.tgz" @@ -3803,6 +4283,11 @@ shell-quote@^1.6.1: resolved "https://registry.npmjs.org/shell-quote/-/shell-quote-1.8.1.tgz" integrity sha512-6j1W9l1iAs/4xYBI1SYOVZyFcCis9b4KCLQ8fgAGG07QvzaRLVVRQvAy85yNmmZSjYjg4MWh4gNvlPujU/5LpA== +shimmer@^1.2.1: + version "1.2.1" + resolved "https://registry.yarnpkg.com/shimmer/-/shimmer-1.2.1.tgz#610859f7de327b587efebf501fb43117f9aff337" + integrity sha512-sQTKC1Re/rM6XyFM6fIAGHRPVGvyXfgzIDvzoq608vM+jeyVD0Tu1E6Np0Kc2zAIFWIj963V2800iF/9LPieQw== + side-channel@^1.0.4: version "1.0.4" resolved "https://registry.npmjs.org/side-channel/-/side-channel-1.0.4.tgz" diff --git a/desci-server/src/controllers/nodes/documents.ts b/desci-server/src/controllers/nodes/documents.ts index be54cefde..f8715a5c4 100644 --- a/desci-server/src/controllers/nodes/documents.ts +++ b/desci-server/src/controllers/nodes/documents.ts @@ -1,14 +1,16 @@ import { DocumentId } from '@automerge/automerge-repo'; +import { ManifestActions } from '@desci-labs/desci-models'; import { Response } from 'express'; -import { ManifestActions } from "@desci-labs/desci-models"; + import { prisma } from '../../client.js'; -import { logger } from '../../logger.js'; +import { logger as parentLogger } from '../../logger.js'; import { RequestWithNode } from '../../middleware/authorisation.js'; import { NodeUuid } from '../../services/manifestRepo.js'; import repoService from '../../services/repoService.js'; import { getLatestManifest } from '../data/utils.js'; export const getNodeDocument = async function (req: RequestWithNode, response: Response) { + const logger = parentLogger.child({ module: 'getNodeDocument' }); try { logger.info({ userId: req.user.id, uuid: req.node.uuid }, '[START] GetNodeDocument'); @@ -45,8 +47,8 @@ export const getNodeDocument = async function (req: RequestWithNode, response: R }; export const dispatchDocumentChange = async function (req: RequestWithNode, response: Response) { + const logger = parentLogger.child({ module: 'dispatchDocumentChange', userId: req.user.id, uuid: req.node.uuid }); try { - logger.info({ userId: req.user.id, uuid: req.node.uuid }, '[START] GetNodeDocument'); const node = req.node; const actions = req.body.actions as ManifestActions[]; diff --git a/desci-server/src/controllers/nodes/draftCreate.ts b/desci-server/src/controllers/nodes/draftCreate.ts index ec6691bcb..cc013a0a0 100755 --- a/desci-server/src/controllers/nodes/draftCreate.ts +++ b/desci-server/src/controllers/nodes/draftCreate.ts @@ -1,4 +1,4 @@ -import { DocumentId } from '@automerge/automerge-repo'; +// import { DocumentId } from '@automerge/automerge-repo'; import { ExternalLinkComponent, PdfComponent, @@ -12,7 +12,7 @@ import { Request, Response, NextFunction } from 'express'; import { prisma } from '../../client.js'; import { logger as parentLogger } from '../../logger.js'; -import { getDataUsageForUserBytes, hasAvailableDataUsageForUpload } from '../../services/dataService.js'; +import { hasAvailableDataUsageForUpload } from '../../services/dataService.js'; import { addBufferToIpfs, downloadFilesAndMakeManifest, @@ -76,7 +76,7 @@ export const draftCreate = async (req: Request, res: Response, next: NextFunctio }, }); - const dataConsumptionBytes = await getDataUsageForUserBytes(owner); + // const dataConsumptionBytes = await getDataUsageForUserBytes(owner); const uploadSizeBytes = files.map((f) => f.size).reduce((total, size) => total + size, 0); @@ -267,7 +267,7 @@ export const draftAddComponent = async (req: Request, res: Response, next: NextF subtype: componentSubtype, payload: { url: componentUrl, - path: DRIVE_NODE_ROOT_PATH + `/${name}` + path: DRIVE_NODE_ROOT_PATH + `/${name}`, }, }; manifestParsed.components.push(linkComponent); diff --git a/desci-server/src/services/repoService.ts b/desci-server/src/services/repoService.ts index 9a6cdcb7c..ea29138ca 100644 --- a/desci-server/src/services/repoService.ts +++ b/desci-server/src/services/repoService.ts @@ -2,9 +2,8 @@ import { DocumentId } from '@automerge/automerge-repo'; import { ResearchObjectV1, ManifestActions } from '@desci-labs/desci-models'; import axios, { AxiosInstance } from 'axios'; -import { logger as parentLogger } from '../logger.js'; +import { als, logger as parentLogger } from '../logger.js'; import { ResearchObjectDocument } from '../types/documents.js'; -import { ensureUuidEndsWithDot } from '../utils.js'; import { NodeUuid } from './manifestRepo.js'; @@ -38,6 +37,11 @@ class RepoService { const response = await this.#client.post<{ ok: boolean; document: ResearchObjectDocument }>( `${this.baseUrl}/v1/nodes/documents/dispatch`, arg, + { + headers: { + 'x-api-remote-traceid': (als.getStore() as any)?.traceId, + }, + }, ); logger.info({ arg, ok: response.data.ok }, 'Disatch Changes Response'); if (response.status === 200 && response.data.ok) { @@ -54,6 +58,11 @@ class RepoService { const response = await this.#client.post<{ ok: boolean; document: ResearchObjectDocument }>( `${this.baseUrl}/v1/nodes/documents/actions`, arg, + { + headers: { + 'x-api-remote-traceid': (als.getStore() as any)?.traceId, + }, + }, ); logger.info({ arg, response: response.data }, 'Disatch Actions Response'); if (response.status === 200 && response.data.ok) { @@ -71,7 +80,11 @@ class RepoService { try { const response = await this.#client.post< ApiResponse<{ documentId: DocumentId; document: ResearchObjectDocument }> - >(`${this.baseUrl}/v1/nodes/documents`, arg); + >(`${this.baseUrl}/v1/nodes/documents`, arg, { + headers: { + 'x-api-remote-traceid': (als.getStore() as any)?.traceId, + }, + }); logger.info({ response: response.data }, 'Create Draft Response'); if (response.status === 200 && response.data.ok) { return response.data; @@ -93,6 +106,11 @@ class RepoService { try { const response = await this.#client.get>( `${this.baseUrl}/v1/nodes/documents/draft/${arg.uuid}`, + { + headers: { + 'x-api-remote-traceid': (als.getStore() as any)?.traceId, + }, + }, ); if (response.status === 200 && response.data.ok) { return response.data.document; @@ -104,6 +122,7 @@ class RepoService { return null; } } + async getDraftManifest(uuid: NodeUuid) { logger.info({ uuid }, 'Retrieve Draft Document'); // try {} catch (err) {} From b30850ce783eb5e85f382c5b0270eac2bef880a7 Mon Sep 17 00:00:00 2001 From: shadrach-tayo Date: Mon, 7 Oct 2024 15:33:20 -0500 Subject: [PATCH 66/81] repo sentry config --- desci-repo/src/server.ts | 11 +++++++---- desci-server/src/server.ts | 11 ++++++++--- 2 files changed, 15 insertions(+), 7 deletions(-) diff --git a/desci-repo/src/server.ts b/desci-repo/src/server.ts index 354e960cb..5418f19ff 100644 --- a/desci-repo/src/server.ts +++ b/desci-repo/src/server.ts @@ -71,6 +71,7 @@ class AppServer { constructor() { this.app = express(); + this.#initSerialiser(); this.app.use(function (req, res, next) { @@ -106,8 +107,6 @@ class AppServer { }); }); - this.#initTelemetry(); - this.app.use(bodyParser.json({ limit: '100mb' })); this.app.use(bodyParser.urlencoded({ extended: false })); @@ -124,6 +123,9 @@ class AppServer { res.status(200).json({ id: serverUuid }); }); + // init telementry + this.#initTelemetry(); + this.port = process.env.PORT ? parseInt(process.env.PORT) : 5484; logger.info(`Server starting on port ${this.port}`); this.server = this.app.listen(this.port, () => { @@ -212,9 +214,10 @@ class AppServer { profilesSampleRate: 1.0, }); // this.app.use(Sentry.Handlers.requestHandler()); - // this.app.use(Sentry.Handlers.tracingHandler()); - // this.app.use(Sentry.Handlers.errorHandler()); + Sentry.addIntegration(Sentry.expressIntegration); Sentry.setupExpressErrorHandler(this.app); + // this.app.use(Sentry.expressIntegration); + // this.app.use(Sentry.expressErrorHandler); } else { logger.info('[DeSci Repo] Telemetry disabled'); } diff --git a/desci-server/src/server.ts b/desci-server/src/server.ts index 172964d54..1f77b29d7 100644 --- a/desci-server/src/server.ts +++ b/desci-server/src/server.ts @@ -67,6 +67,7 @@ class AppServer { constructor() { this.app = express(); + this.#initSerialiser(); this.app.use(function (req, res, next) { @@ -113,9 +114,15 @@ class AppServer { }); }); - this.#attachProxies(); + // attach all app routes + this.#attachRouteHandlers(); + + // init telementry this.#initTelemetry(); + // attach proxy routes + this.#attachProxies(); + this.app.use(helmet()); this.app.use(bodyParser.json({ limit: '100mb' })); this.app.use(bodyParser.urlencoded({ extended: false })); @@ -123,8 +130,6 @@ class AppServer { this.app.use(cookieParser()); this.app.set('trust proxy', 2); // detect AWS ELB IP + cloudflare - this.#attachRouteHandlers(); - // catch 404 errors and forward to error handler this.app.use((_req, _res, next) => next(new NotFoundError())); this.app.use(errorHandler); From 57bfe5fc056722dd20b24f880ec8ef9d657edc03 Mon Sep 17 00:00:00 2001 From: shadrach Date: Mon, 7 Oct 2024 16:37:50 -0500 Subject: [PATCH 67/81] fix: attach routes after necessary middlewares --- .../src/routes/v1/admin/communities/index.ts | 4 ++-- desci-server/src/server.ts | 14 +++++++------- docker-compose.test.yml | 1 - 3 files changed, 9 insertions(+), 10 deletions(-) diff --git a/desci-server/src/routes/v1/admin/communities/index.ts b/desci-server/src/routes/v1/admin/communities/index.ts index d6acaa0bb..e96b9d210 100644 --- a/desci-server/src/routes/v1/admin/communities/index.ts +++ b/desci-server/src/routes/v1/admin/communities/index.ts @@ -72,8 +72,8 @@ const wrappedHandler = (req: Request, res: Response, next: NextFunction) => { const sanitizeBody = async (req: Request, _res: Response, next: NextFunction) => { logger.info({ body: req.body }, 'sanitizeBody'); - req.body?.keywords ? (req.body.keywords = JSON.parse(req.body.keywords)) : null; - req.body?.links ? (req.body.links = JSON.parse(req.body.links)) : null; + typeof req.body?.keywords === 'string' ? (req.body.keywords = JSON.parse(req.body.keywords)) : null; + typeof req.body?.links === 'string' ? (req.body.links = JSON.parse(req.body.links)) : null; next(); }; diff --git a/desci-server/src/server.ts b/desci-server/src/server.ts index 1f77b29d7..276ad56ef 100644 --- a/desci-server/src/server.ts +++ b/desci-server/src/server.ts @@ -114,6 +114,13 @@ class AppServer { }); }); + this.app.use(helmet()); + this.app.use(bodyParser.json({ limit: '100mb' })); + this.app.use(bodyParser.urlencoded({ extended: false })); + + this.app.use(cookieParser()); + this.app.set('trust proxy', 2); // detect AWS ELB IP + cloudflare + // attach all app routes this.#attachRouteHandlers(); @@ -123,13 +130,6 @@ class AppServer { // attach proxy routes this.#attachProxies(); - this.app.use(helmet()); - this.app.use(bodyParser.json({ limit: '100mb' })); - this.app.use(bodyParser.urlencoded({ extended: false })); - - this.app.use(cookieParser()); - this.app.set('trust proxy', 2); // detect AWS ELB IP + cloudflare - // catch 404 errors and forward to error handler this.app.use((_req, _res, next) => next(new NotFoundError())); this.app.use(errorHandler); diff --git a/docker-compose.test.yml b/docker-compose.test.yml index accf5c451..46036157a 100755 --- a/docker-compose.test.yml +++ b/docker-compose.test.yml @@ -1,4 +1,3 @@ -version: "3" name: test services: nodes_test_db: From ac6b4e638129891b34a0102d94d822e87d0f1d2b Mon Sep 17 00:00:00 2001 From: shadrach-tayo Date: Tue, 8 Oct 2024 05:26:21 -0500 Subject: [PATCH 68/81] init sentry before import --- desci-repo/src/server.ts | 61 +++++++++++++++++++++++++--------------- package-lock.json | 6 ---- 2 files changed, 38 insertions(+), 29 deletions(-) delete mode 100644 package-lock.json diff --git a/desci-repo/src/server.ts b/desci-repo/src/server.ts index 5418f19ff..08ea4f76c 100644 --- a/desci-repo/src/server.ts +++ b/desci-repo/src/server.ts @@ -1,14 +1,36 @@ // @ts-check -import express from 'express'; -import type { Express, Request } from 'express'; -import cors from 'cors'; -import bodyParser from 'body-parser'; - import 'dotenv/config'; import 'reflect-metadata'; import path from 'path'; import * as Sentry from '@sentry/node'; +import { als, logger } from './logger.js'; + +const ENABLE_TELEMETRY = true; // process.env.NODE_ENV === 'production'; +const IS_DEV = !ENABLE_TELEMETRY; + +if (ENABLE_TELEMETRY) { + logger.info('[DeSci Repo] Telemetry enabled'); + Sentry.init({ + dsn: 'https://d508a5c408f34b919ccd94aac093e076@o1330109.ingest.sentry.io/6619754', + release: 'desci-nodes-repo@' + process.env.npm_package_version, + integrations: [nodeProfilingIntegration()], + // Set tracesSampleRate to 1.0 to capture 100% + // of transactions for performance monitoring. + // We recommend adjusting this value in production + tracesSampleRate: 1.0, + profilesSampleRate: 1.0, + }); + // Sentry.setupExpressErrorHandler(this.app); +} else { + logger.info('[DeSci Repo] Telemetry disabled'); +} + +import express from 'express'; +import type { Express, Request } from 'express'; +import cors from 'cors'; +import bodyParser from 'body-parser'; + import type { Server as HttpServer } from 'http'; import { v4 } from 'uuid'; @@ -17,7 +39,7 @@ import routes from './routes/index.js'; import { fileURLToPath } from 'url'; import { socket as wsSocket } from './repo.js'; -import { als, logger } from './logger.js'; + import { extractAuthToken, extractUserFromToken } from './middleware/permissions.js'; import { pinoHttp } from 'pino-http'; import { RequestWithUser } from './middleware/guard.js'; @@ -26,9 +48,6 @@ import { nodeProfilingIntegration } from '@sentry/profiling-node'; const __filename = fileURLToPath(import.meta.url); const __dirname = path.dirname(__filename); -const ENABLE_TELEMETRY = process.env.NODE_ENV === 'production'; -const IS_DEV = !ENABLE_TELEMETRY; - const serverUuid = v4(); const allowlist = [ @@ -203,21 +222,17 @@ class AppServer { #initTelemetry() { if (ENABLE_TELEMETRY) { logger.info('[DeSci Repo] Telemetry enabled'); - Sentry.init({ - dsn: 'https://d508a5c408f34b919ccd94aac093e076@o1330109.ingest.sentry.io/6619754', - release: 'desci-nodes-repo@' + process.env.npm_package_version, - integrations: [nodeProfilingIntegration()], - // Set tracesSampleRate to 1.0 to capture 100% - // of transactions for performance monitoring. - // We recommend adjusting this value in production - tracesSampleRate: 1.0, - profilesSampleRate: 1.0, - }); - // this.app.use(Sentry.Handlers.requestHandler()); - Sentry.addIntegration(Sentry.expressIntegration); + // Sentry.init({ + // dsn: 'https://d508a5c408f34b919ccd94aac093e076@o1330109.ingest.sentry.io/6619754', + // release: 'desci-nodes-repo@' + process.env.npm_package_version, + // integrations: [nodeProfilingIntegration()], + // // Set tracesSampleRate to 1.0 to capture 100% + // // of transactions for performance monitoring. + // // We recommend adjusting this value in production + // tracesSampleRate: 1.0, + // profilesSampleRate: 1.0, + // }); Sentry.setupExpressErrorHandler(this.app); - // this.app.use(Sentry.expressIntegration); - // this.app.use(Sentry.expressErrorHandler); } else { logger.info('[DeSci Repo] Telemetry disabled'); } diff --git a/package-lock.json b/package-lock.json deleted file mode 100644 index 29ca7076e..000000000 --- a/package-lock.json +++ /dev/null @@ -1,6 +0,0 @@ -{ - "name": "nodes", - "lockfileVersion": 3, - "requires": true, - "packages": {} -} From 1ac4c7ba33e79f739be71df2915f18bf19cb2805 Mon Sep 17 00:00:00 2001 From: shadrach Date: Tue, 8 Oct 2024 06:11:15 -0500 Subject: [PATCH 69/81] test import order --- desci-repo/src/index.ts | 1 - desci-repo/src/instrument.ts | 17 ++++++++++++++ desci-repo/src/server.ts | 43 +++++++----------------------------- desci-server/src/server.ts | 4 ++-- 4 files changed, 27 insertions(+), 38 deletions(-) create mode 100644 desci-repo/src/instrument.ts diff --git a/desci-repo/src/index.ts b/desci-repo/src/index.ts index 2db1093ea..f27c2b6d9 100644 --- a/desci-repo/src/index.ts +++ b/desci-repo/src/index.ts @@ -1,6 +1,5 @@ import { logger } from './logger.js'; import { server } from './server.js'; -// import * as db from './dbs/index.js'; server.ready().then(async (_) => { logger.info('server is ready'); diff --git a/desci-repo/src/instrument.ts b/desci-repo/src/instrument.ts new file mode 100644 index 000000000..fb4a64602 --- /dev/null +++ b/desci-repo/src/instrument.ts @@ -0,0 +1,17 @@ +import * as Sentry from '@sentry/node'; +import { nodeProfilingIntegration } from '@sentry/profiling-node'; + +const ENABLE_TELEMETRY = process.env.NODE_ENV === 'production'; + +if (ENABLE_TELEMETRY) { + Sentry.init({ + dsn: 'https://d508a5c408f34b919ccd94aac093e076@o1330109.ingest.sentry.io/6619754', + release: 'desci-nodes-repo@' + process.env.npm_package_version, + integrations: [nodeProfilingIntegration()], + // Set tracesSampleRate to 1.0 to capture 100% + // of transactions for performance monitoring. + // We recommend adjusting this value in production + tracesSampleRate: 1.0, + profilesSampleRate: 1.0, + }); +} diff --git a/desci-repo/src/server.ts b/desci-repo/src/server.ts index 08ea4f76c..9072b7f48 100644 --- a/desci-repo/src/server.ts +++ b/desci-repo/src/server.ts @@ -1,30 +1,13 @@ -// @ts-check -import 'dotenv/config'; -import 'reflect-metadata'; -import path from 'path'; - +import './instrument.js'; import * as Sentry from '@sentry/node'; -import { als, logger } from './logger.js'; -const ENABLE_TELEMETRY = true; // process.env.NODE_ENV === 'production'; +const ENABLE_TELEMETRY = process.env.NODE_ENV === 'production'; const IS_DEV = !ENABLE_TELEMETRY; -if (ENABLE_TELEMETRY) { - logger.info('[DeSci Repo] Telemetry enabled'); - Sentry.init({ - dsn: 'https://d508a5c408f34b919ccd94aac093e076@o1330109.ingest.sentry.io/6619754', - release: 'desci-nodes-repo@' + process.env.npm_package_version, - integrations: [nodeProfilingIntegration()], - // Set tracesSampleRate to 1.0 to capture 100% - // of transactions for performance monitoring. - // We recommend adjusting this value in production - tracesSampleRate: 1.0, - profilesSampleRate: 1.0, - }); - // Sentry.setupExpressErrorHandler(this.app); -} else { - logger.info('[DeSci Repo] Telemetry disabled'); -} +// @ts-check +import 'dotenv/config'; +import 'reflect-metadata'; +import path from 'path'; import express from 'express'; import type { Express, Request } from 'express'; @@ -34,6 +17,7 @@ import bodyParser from 'body-parser'; import type { Server as HttpServer } from 'http'; import { v4 } from 'uuid'; +import { als, logger } from './logger.js'; import routes from './routes/index.js'; // import SocketServer from './wsServer.js'; @@ -43,7 +27,6 @@ import { socket as wsSocket } from './repo.js'; import { extractAuthToken, extractUserFromToken } from './middleware/permissions.js'; import { pinoHttp } from 'pino-http'; import { RequestWithUser } from './middleware/guard.js'; -import { nodeProfilingIntegration } from '@sentry/profiling-node'; const __filename = fileURLToPath(import.meta.url); const __dirname = path.dirname(__filename); @@ -219,19 +202,9 @@ class AppServer { ); } - #initTelemetry() { + async #initTelemetry() { if (ENABLE_TELEMETRY) { logger.info('[DeSci Repo] Telemetry enabled'); - // Sentry.init({ - // dsn: 'https://d508a5c408f34b919ccd94aac093e076@o1330109.ingest.sentry.io/6619754', - // release: 'desci-nodes-repo@' + process.env.npm_package_version, - // integrations: [nodeProfilingIntegration()], - // // Set tracesSampleRate to 1.0 to capture 100% - // // of transactions for performance monitoring. - // // We recommend adjusting this value in production - // tracesSampleRate: 1.0, - // profilesSampleRate: 1.0, - // }); Sentry.setupExpressErrorHandler(this.app); } else { logger.info('[DeSci Repo] Telemetry disabled'); diff --git a/desci-server/src/server.ts b/desci-server/src/server.ts index 3d32484b9..5a4569ac3 100644 --- a/desci-server/src/server.ts +++ b/desci-server/src/server.ts @@ -8,7 +8,7 @@ import type { Server as HttpServer } from 'http'; import * as Sentry from '@sentry/node'; import { nodeProfilingIntegration } from '@sentry/profiling-node'; -import * as Tracing from '@sentry/tracing'; +// import * as Tracing from '@sentry/tracing'; import bodyParser from 'body-parser'; import cookieParser from 'cookie-parser'; import express from 'express'; @@ -193,7 +193,7 @@ class AppServer { pinoHttp({ logger, autoLogging: { - ignore: (req) => req.url === "/readyz" + ignore: (req) => req.url === '/readyz', }, customProps: (req: RequestWithUser, res) => ({ userAuth: req.userAuth, From e0a153414282f228abb538a931381767e808a83b Mon Sep 17 00:00:00 2001 From: shadrach Date: Tue, 8 Oct 2024 07:21:32 -0500 Subject: [PATCH 70/81] downgrade --- desci-repo/package.json | 4 +- desci-repo/src/instrument.ts | 17 - desci-repo/src/server.ts | 14 +- desci-repo/yarn.lock | 582 ++++++----------------------------- desci-server/package.json | 4 +- desci-server/yarn.lock | 64 ++-- 6 files changed, 134 insertions(+), 551 deletions(-) delete mode 100644 desci-repo/src/instrument.ts diff --git a/desci-repo/package.json b/desci-repo/package.json index 15fd4ccd0..4ee7e0a47 100644 --- a/desci-repo/package.json +++ b/desci-repo/package.json @@ -69,10 +69,8 @@ }, "dependencies": { "@desci-labs/desci-models": "0.2.11", - "@sentry/node": "^8.29.0", - "@sentry/profiling-node": "^8.32.0", + "@sentry/node": "7.84.0", "@sentry/tracing": "^7.84.0", - "async_hooks": "^1.0.0", "axios": "^1.6.2", "cors": "^2.8.5", "deep-equal": "^2.2.3", diff --git a/desci-repo/src/instrument.ts b/desci-repo/src/instrument.ts deleted file mode 100644 index fb4a64602..000000000 --- a/desci-repo/src/instrument.ts +++ /dev/null @@ -1,17 +0,0 @@ -import * as Sentry from '@sentry/node'; -import { nodeProfilingIntegration } from '@sentry/profiling-node'; - -const ENABLE_TELEMETRY = process.env.NODE_ENV === 'production'; - -if (ENABLE_TELEMETRY) { - Sentry.init({ - dsn: 'https://d508a5c408f34b919ccd94aac093e076@o1330109.ingest.sentry.io/6619754', - release: 'desci-nodes-repo@' + process.env.npm_package_version, - integrations: [nodeProfilingIntegration()], - // Set tracesSampleRate to 1.0 to capture 100% - // of transactions for performance monitoring. - // We recommend adjusting this value in production - tracesSampleRate: 1.0, - profilesSampleRate: 1.0, - }); -} diff --git a/desci-repo/src/server.ts b/desci-repo/src/server.ts index 9072b7f48..f06957745 100644 --- a/desci-repo/src/server.ts +++ b/desci-repo/src/server.ts @@ -1,4 +1,3 @@ -import './instrument.js'; import * as Sentry from '@sentry/node'; const ENABLE_TELEMETRY = process.env.NODE_ENV === 'production'; @@ -205,7 +204,18 @@ class AppServer { async #initTelemetry() { if (ENABLE_TELEMETRY) { logger.info('[DeSci Repo] Telemetry enabled'); - Sentry.setupExpressErrorHandler(this.app); + Sentry.init({ + dsn: 'https://d508a5c408f34b919ccd94aac093e076@o1330109.ingest.sentry.io/6619754', + release: 'desci-nodes-repo@' + process.env.npm_package_version, + integrations: [], + // Set tracesSampleRate to 1.0 to capture 100% + // of transactions for performance monitoring. + // We recommend adjusting this value in production + tracesSampleRate: 1.0, + }); + this.app.use(Sentry.Handlers.requestHandler()); + this.app.use(Sentry.Handlers.tracingHandler()); + this.app.use(Sentry.Handlers.errorHandler()); } else { logger.info('[DeSci Repo] Telemetry disabled'); } diff --git a/desci-repo/yarn.lock b/desci-repo/yarn.lock index f3c217550..da3a880c0 100644 --- a/desci-repo/yarn.lock +++ b/desci-repo/yarn.lock @@ -260,293 +260,6 @@ "@nodelib/fs.scandir" "2.1.5" fastq "^1.6.0" -"@opentelemetry/api-logs@0.52.1": - version "0.52.1" - resolved "https://registry.yarnpkg.com/@opentelemetry/api-logs/-/api-logs-0.52.1.tgz#52906375da4d64c206b0c4cb8ffa209214654ecc" - integrity sha512-qnSqB2DQ9TPP96dl8cDubDvrUyWc0/sK81xHTK8eSUspzDM3bsewX903qclQFvVhgStjRWdC5bLb3kQqMkfV5A== - dependencies: - "@opentelemetry/api" "^1.0.0" - -"@opentelemetry/api-logs@0.53.0": - version "0.53.0" - resolved "https://registry.yarnpkg.com/@opentelemetry/api-logs/-/api-logs-0.53.0.tgz#c478cbd8120ec2547b64edfa03a552cfe42170be" - integrity sha512-8HArjKx+RaAI8uEIgcORbZIPklyh1YLjPSBus8hjRmvLi6DeFzgOcdZ7KwPabKj8mXF8dX0hyfAyGfycz0DbFw== - dependencies: - "@opentelemetry/api" "^1.0.0" - -"@opentelemetry/api@^1.0.0", "@opentelemetry/api@^1.8", "@opentelemetry/api@^1.9.0": - version "1.9.0" - resolved "https://registry.yarnpkg.com/@opentelemetry/api/-/api-1.9.0.tgz#d03eba68273dc0f7509e2a3d5cba21eae10379fe" - integrity sha512-3giAOQvZiH5F9bMlMiv8+GSPMeqg0dbaeo58/0SlA9sxSqZhnUtxzX9/2FzyhS9sWQf5S0GJE0AKBrFqjpeYcg== - -"@opentelemetry/context-async-hooks@^1.25.1": - version "1.26.0" - resolved "https://registry.yarnpkg.com/@opentelemetry/context-async-hooks/-/context-async-hooks-1.26.0.tgz#fa92f722cf685685334bba95f258d3ef9fce60f6" - integrity sha512-HedpXXYzzbaoutw6DFLWLDket2FwLkLpil4hGCZ1xYEIMTcivdfwEOISgdbLEWyG3HW52gTq2V9mOVJrONgiwg== - -"@opentelemetry/core@1.26.0", "@opentelemetry/core@^1.1.0", "@opentelemetry/core@^1.25.1", "@opentelemetry/core@^1.8.0": - version "1.26.0" - resolved "https://registry.yarnpkg.com/@opentelemetry/core/-/core-1.26.0.tgz#7d84265aaa850ed0ca5813f97d831155be42b328" - integrity sha512-1iKxXXE8415Cdv0yjG3G6hQnB5eVEsJce3QaawX8SjDn0mAS0ZM8fAbZZJD4ajvhC15cePvosSCut404KrIIvQ== - dependencies: - "@opentelemetry/semantic-conventions" "1.27.0" - -"@opentelemetry/instrumentation-amqplib@^0.42.0": - version "0.42.0" - resolved "https://registry.yarnpkg.com/@opentelemetry/instrumentation-amqplib/-/instrumentation-amqplib-0.42.0.tgz#b3cab5a7207736a30d769962eed3af3838f986c4" - integrity sha512-fiuU6OKsqHJiydHWgTRQ7MnIrJ2lEqsdgFtNIH4LbAUJl/5XmrIeoDzDnox+hfkgWK65jsleFuQDtYb5hW1koQ== - dependencies: - "@opentelemetry/core" "^1.8.0" - "@opentelemetry/instrumentation" "^0.53.0" - "@opentelemetry/semantic-conventions" "^1.27.0" - -"@opentelemetry/instrumentation-connect@0.39.0": - version "0.39.0" - resolved "https://registry.yarnpkg.com/@opentelemetry/instrumentation-connect/-/instrumentation-connect-0.39.0.tgz#32bdbaac464cba061c95df6c850ee81efdd86f8b" - integrity sha512-pGBiKevLq7NNglMgqzmeKczF4XQMTOUOTkK8afRHMZMnrK3fcETyTH7lVaSozwiOM3Ws+SuEmXZT7DYrrhxGlg== - dependencies: - "@opentelemetry/core" "^1.8.0" - "@opentelemetry/instrumentation" "^0.53.0" - "@opentelemetry/semantic-conventions" "^1.27.0" - "@types/connect" "3.4.36" - -"@opentelemetry/instrumentation-dataloader@0.12.0": - version "0.12.0" - resolved "https://registry.yarnpkg.com/@opentelemetry/instrumentation-dataloader/-/instrumentation-dataloader-0.12.0.tgz#de03a3948dec4f15fed80aa424d6bd5d6a8d10c7" - integrity sha512-pnPxatoFE0OXIZDQhL2okF//dmbiWFzcSc8pUg9TqofCLYZySSxDCgQc69CJBo5JnI3Gz1KP+mOjS4WAeRIH4g== - dependencies: - "@opentelemetry/instrumentation" "^0.53.0" - -"@opentelemetry/instrumentation-express@0.42.0": - version "0.42.0" - resolved "https://registry.yarnpkg.com/@opentelemetry/instrumentation-express/-/instrumentation-express-0.42.0.tgz#279f195aa66baee2b98623a16666c6229c8e7564" - integrity sha512-YNcy7ZfGnLsVEqGXQPT+S0G1AE46N21ORY7i7yUQyfhGAL4RBjnZUqefMI0NwqIl6nGbr1IpF0rZGoN8Q7x12Q== - dependencies: - "@opentelemetry/core" "^1.8.0" - "@opentelemetry/instrumentation" "^0.53.0" - "@opentelemetry/semantic-conventions" "^1.27.0" - -"@opentelemetry/instrumentation-fastify@0.39.0": - version "0.39.0" - resolved "https://registry.yarnpkg.com/@opentelemetry/instrumentation-fastify/-/instrumentation-fastify-0.39.0.tgz#96a040e4944daf77c53a8fe5a128bc3b2568e4aa" - integrity sha512-SS9uSlKcsWZabhBp2szErkeuuBDgxOUlllwkS92dVaWRnMmwysPhcEgHKB8rUe3BHg/GnZC1eo1hbTZv4YhfoA== - dependencies: - "@opentelemetry/core" "^1.8.0" - "@opentelemetry/instrumentation" "^0.53.0" - "@opentelemetry/semantic-conventions" "^1.27.0" - -"@opentelemetry/instrumentation-fs@0.15.0": - version "0.15.0" - resolved "https://registry.yarnpkg.com/@opentelemetry/instrumentation-fs/-/instrumentation-fs-0.15.0.tgz#41658507860f39fee5209bca961cea8d24ca2a83" - integrity sha512-JWVKdNLpu1skqZQA//jKOcKdJC66TWKqa2FUFq70rKohvaSq47pmXlnabNO+B/BvLfmidfiaN35XakT5RyMl2Q== - dependencies: - "@opentelemetry/core" "^1.8.0" - "@opentelemetry/instrumentation" "^0.53.0" - -"@opentelemetry/instrumentation-generic-pool@0.39.0": - version "0.39.0" - resolved "https://registry.yarnpkg.com/@opentelemetry/instrumentation-generic-pool/-/instrumentation-generic-pool-0.39.0.tgz#2b9af16ad82d5cbe67125c0125753cecd162a728" - integrity sha512-y4v8Y+tSfRB3NNBvHjbjrn7rX/7sdARG7FuK6zR8PGb28CTa0kHpEGCJqvL9L8xkTNvTXo+lM36ajFGUaK1aNw== - dependencies: - "@opentelemetry/instrumentation" "^0.53.0" - -"@opentelemetry/instrumentation-graphql@0.43.0": - version "0.43.0" - resolved "https://registry.yarnpkg.com/@opentelemetry/instrumentation-graphql/-/instrumentation-graphql-0.43.0.tgz#71bb94ea775c70dbd388c739b397ec1418f3f170" - integrity sha512-aI3YMmC2McGd8KW5du1a2gBA0iOMOGLqg4s9YjzwbjFwjlmMNFSK1P3AIg374GWg823RPUGfVTIgZ/juk9CVOA== - dependencies: - "@opentelemetry/instrumentation" "^0.53.0" - -"@opentelemetry/instrumentation-hapi@0.41.0": - version "0.41.0" - resolved "https://registry.yarnpkg.com/@opentelemetry/instrumentation-hapi/-/instrumentation-hapi-0.41.0.tgz#de8711907256d8fae1b5faf71fc825cef4a7ddbb" - integrity sha512-jKDrxPNXDByPlYcMdZjNPYCvw0SQJjN+B1A+QH+sx+sAHsKSAf9hwFiJSrI6C4XdOls43V/f/fkp9ITkHhKFbQ== - dependencies: - "@opentelemetry/core" "^1.8.0" - "@opentelemetry/instrumentation" "^0.53.0" - "@opentelemetry/semantic-conventions" "^1.27.0" - -"@opentelemetry/instrumentation-http@0.53.0": - version "0.53.0" - resolved "https://registry.yarnpkg.com/@opentelemetry/instrumentation-http/-/instrumentation-http-0.53.0.tgz#0d806adf1b3aba036bc46e16162e3c0dbb8a6b60" - integrity sha512-H74ErMeDuZfj7KgYCTOFGWF5W9AfaPnqLQQxeFq85+D29wwV2yqHbz2IKLYpkOh7EI6QwDEl7rZCIxjJLyc/CQ== - dependencies: - "@opentelemetry/core" "1.26.0" - "@opentelemetry/instrumentation" "0.53.0" - "@opentelemetry/semantic-conventions" "1.27.0" - semver "^7.5.2" - -"@opentelemetry/instrumentation-ioredis@0.43.0": - version "0.43.0" - resolved "https://registry.yarnpkg.com/@opentelemetry/instrumentation-ioredis/-/instrumentation-ioredis-0.43.0.tgz#dbadabaeefc4cb47c406f878444f1bcac774fa89" - integrity sha512-i3Dke/LdhZbiUAEImmRG3i7Dimm/BD7t8pDDzwepSvIQ6s2X6FPia7561gw+64w+nx0+G9X14D7rEfaMEmmjig== - dependencies: - "@opentelemetry/instrumentation" "^0.53.0" - "@opentelemetry/redis-common" "^0.36.2" - "@opentelemetry/semantic-conventions" "^1.27.0" - -"@opentelemetry/instrumentation-kafkajs@0.3.0": - version "0.3.0" - resolved "https://registry.yarnpkg.com/@opentelemetry/instrumentation-kafkajs/-/instrumentation-kafkajs-0.3.0.tgz#6687bce4dac8b90ef8ccbf1b662d5d1e95a34414" - integrity sha512-UnkZueYK1ise8FXQeKlpBd7YYUtC7mM8J0wzUSccEfc/G8UqHQqAzIyYCUOUPUKp8GsjLnWOOK/3hJc4owb7Jg== - dependencies: - "@opentelemetry/instrumentation" "^0.53.0" - "@opentelemetry/semantic-conventions" "^1.27.0" - -"@opentelemetry/instrumentation-koa@0.43.0": - version "0.43.0" - resolved "https://registry.yarnpkg.com/@opentelemetry/instrumentation-koa/-/instrumentation-koa-0.43.0.tgz#963fd192a1b5f6cbae5dabf4ec82e3105cbb23b1" - integrity sha512-lDAhSnmoTIN6ELKmLJBplXzT/Jqs5jGZehuG22EdSMaTwgjMpxMDI1YtlKEhiWPWkrz5LUsd0aOO0ZRc9vn3AQ== - dependencies: - "@opentelemetry/core" "^1.8.0" - "@opentelemetry/instrumentation" "^0.53.0" - "@opentelemetry/semantic-conventions" "^1.27.0" - -"@opentelemetry/instrumentation-lru-memoizer@0.40.0": - version "0.40.0" - resolved "https://registry.yarnpkg.com/@opentelemetry/instrumentation-lru-memoizer/-/instrumentation-lru-memoizer-0.40.0.tgz#dc60d7fdfd2a0c681cb23e7ed4f314d1506ccdc0" - integrity sha512-21xRwZsEdMPnROu/QsaOIODmzw59IYpGFmuC4aFWvMj6stA8+Ei1tX67nkarJttlNjoM94um0N4X26AD7ff54A== - dependencies: - "@opentelemetry/instrumentation" "^0.53.0" - -"@opentelemetry/instrumentation-mongodb@0.47.0": - version "0.47.0" - resolved "https://registry.yarnpkg.com/@opentelemetry/instrumentation-mongodb/-/instrumentation-mongodb-0.47.0.tgz#f8107d878281433905e717f223fb4c0f10356a7b" - integrity sha512-yqyXRx2SulEURjgOQyJzhCECSh5i1uM49NUaq9TqLd6fA7g26OahyJfsr9NE38HFqGRHpi4loyrnfYGdrsoVjQ== - dependencies: - "@opentelemetry/instrumentation" "^0.53.0" - "@opentelemetry/sdk-metrics" "^1.9.1" - "@opentelemetry/semantic-conventions" "^1.27.0" - -"@opentelemetry/instrumentation-mongoose@0.42.0": - version "0.42.0" - resolved "https://registry.yarnpkg.com/@opentelemetry/instrumentation-mongoose/-/instrumentation-mongoose-0.42.0.tgz#375afd21adfcd897a8f521c1ffd2d91e6a428705" - integrity sha512-AnWv+RaR86uG3qNEMwt3plKX1ueRM7AspfszJYVkvkehiicC3bHQA6vWdb6Zvy5HAE14RyFbu9+2hUUjR2NSyg== - dependencies: - "@opentelemetry/core" "^1.8.0" - "@opentelemetry/instrumentation" "^0.53.0" - "@opentelemetry/semantic-conventions" "^1.27.0" - -"@opentelemetry/instrumentation-mysql2@0.41.0": - version "0.41.0" - resolved "https://registry.yarnpkg.com/@opentelemetry/instrumentation-mysql2/-/instrumentation-mysql2-0.41.0.tgz#6377b6e2d2487fd88e1d79aa03658db6c8d51651" - integrity sha512-REQB0x+IzVTpoNgVmy5b+UnH1/mDByrneimP6sbDHkp1j8QOl1HyWOrBH/6YWR0nrbU3l825Em5PlybjT3232g== - dependencies: - "@opentelemetry/instrumentation" "^0.53.0" - "@opentelemetry/semantic-conventions" "^1.27.0" - "@opentelemetry/sql-common" "^0.40.1" - -"@opentelemetry/instrumentation-mysql@0.41.0": - version "0.41.0" - resolved "https://registry.yarnpkg.com/@opentelemetry/instrumentation-mysql/-/instrumentation-mysql-0.41.0.tgz#2d50691ead5219774bd36d66c35d5b4681485dd7" - integrity sha512-jnvrV6BsQWyHS2qb2fkfbfSb1R/lmYwqEZITwufuRl37apTopswu9izc0b1CYRp/34tUG/4k/V39PND6eyiNvw== - dependencies: - "@opentelemetry/instrumentation" "^0.53.0" - "@opentelemetry/semantic-conventions" "^1.27.0" - "@types/mysql" "2.15.26" - -"@opentelemetry/instrumentation-nestjs-core@0.40.0": - version "0.40.0" - resolved "https://registry.yarnpkg.com/@opentelemetry/instrumentation-nestjs-core/-/instrumentation-nestjs-core-0.40.0.tgz#2c0e6405b56caaec32747d55c57ff9a034668ea8" - integrity sha512-WF1hCUed07vKmf5BzEkL0wSPinqJgH7kGzOjjMAiTGacofNXjb/y4KQ8loj2sNsh5C/NN7s1zxQuCgbWbVTGKg== - dependencies: - "@opentelemetry/instrumentation" "^0.53.0" - "@opentelemetry/semantic-conventions" "^1.27.0" - -"@opentelemetry/instrumentation-pg@0.44.0": - version "0.44.0" - resolved "https://registry.yarnpkg.com/@opentelemetry/instrumentation-pg/-/instrumentation-pg-0.44.0.tgz#1e97a0aeb2dca068ee23ce75884a0a0063a7ce3f" - integrity sha512-oTWVyzKqXud1BYEGX1loo2o4k4vaU1elr3vPO8NZolrBtFvQ34nx4HgUaexUDuEog00qQt+MLR5gws/p+JXMLQ== - dependencies: - "@opentelemetry/instrumentation" "^0.53.0" - "@opentelemetry/semantic-conventions" "^1.27.0" - "@opentelemetry/sql-common" "^0.40.1" - "@types/pg" "8.6.1" - "@types/pg-pool" "2.0.6" - -"@opentelemetry/instrumentation-redis-4@0.42.0": - version "0.42.0" - resolved "https://registry.yarnpkg.com/@opentelemetry/instrumentation-redis-4/-/instrumentation-redis-4-0.42.0.tgz#fc01104cfe884c7546385eaae03c57a47edd19d1" - integrity sha512-NaD+t2JNcOzX/Qa7kMy68JbmoVIV37fT/fJYzLKu2Wwd+0NCxt+K2OOsOakA8GVg8lSpFdbx4V/suzZZ2Pvdjg== - dependencies: - "@opentelemetry/instrumentation" "^0.53.0" - "@opentelemetry/redis-common" "^0.36.2" - "@opentelemetry/semantic-conventions" "^1.27.0" - -"@opentelemetry/instrumentation-undici@0.6.0": - version "0.6.0" - resolved "https://registry.yarnpkg.com/@opentelemetry/instrumentation-undici/-/instrumentation-undici-0.6.0.tgz#9436ee155c8dcb0b760b66947c0e0f347688a5ef" - integrity sha512-ABJBhm5OdhGmbh0S/fOTE4N69IZ00CsHC5ijMYfzbw3E5NwLgpQk5xsljaECrJ8wz1SfXbO03FiSuu5AyRAkvQ== - dependencies: - "@opentelemetry/core" "^1.8.0" - "@opentelemetry/instrumentation" "^0.53.0" - -"@opentelemetry/instrumentation@0.53.0", "@opentelemetry/instrumentation@^0.53.0": - version "0.53.0" - resolved "https://registry.yarnpkg.com/@opentelemetry/instrumentation/-/instrumentation-0.53.0.tgz#e6369e4015eb5112468a4d45d38dcada7dad892d" - integrity sha512-DMwg0hy4wzf7K73JJtl95m/e0boSoWhH07rfvHvYzQtBD3Bmv0Wc1x733vyZBqmFm8OjJD0/pfiUg1W3JjFX0A== - dependencies: - "@opentelemetry/api-logs" "0.53.0" - "@types/shimmer" "^1.2.0" - import-in-the-middle "^1.8.1" - require-in-the-middle "^7.1.1" - semver "^7.5.2" - shimmer "^1.2.1" - -"@opentelemetry/instrumentation@^0.49 || ^0.50 || ^0.51 || ^0.52.0": - version "0.52.1" - resolved "https://registry.yarnpkg.com/@opentelemetry/instrumentation/-/instrumentation-0.52.1.tgz#2e7e46a38bd7afbf03cf688c862b0b43418b7f48" - integrity sha512-uXJbYU/5/MBHjMp1FqrILLRuiJCs3Ofk0MeRDk8g1S1gD47U8X3JnSwcMO1rtRo1x1a7zKaQHaoYu49p/4eSKw== - dependencies: - "@opentelemetry/api-logs" "0.52.1" - "@types/shimmer" "^1.0.2" - import-in-the-middle "^1.8.1" - require-in-the-middle "^7.1.1" - semver "^7.5.2" - shimmer "^1.2.1" - -"@opentelemetry/redis-common@^0.36.2": - version "0.36.2" - resolved "https://registry.yarnpkg.com/@opentelemetry/redis-common/-/redis-common-0.36.2.tgz#906ac8e4d804d4109f3ebd5c224ac988276fdc47" - integrity sha512-faYX1N0gpLhej/6nyp6bgRjzAKXn5GOEMYY7YhciSfCoITAktLUtQ36d24QEWNA1/WA1y6qQunCe0OhHRkVl9g== - -"@opentelemetry/resources@1.26.0", "@opentelemetry/resources@^1.26.0": - version "1.26.0" - resolved "https://registry.yarnpkg.com/@opentelemetry/resources/-/resources-1.26.0.tgz#da4c7366018bd8add1f3aa9c91c6ac59fd503cef" - integrity sha512-CPNYchBE7MBecCSVy0HKpUISEeJOniWqcHaAHpmasZ3j9o6V3AyBzhRc90jdmemq0HOxDr6ylhUbDhBqqPpeNw== - dependencies: - "@opentelemetry/core" "1.26.0" - "@opentelemetry/semantic-conventions" "1.27.0" - -"@opentelemetry/sdk-metrics@^1.9.1": - version "1.26.0" - resolved "https://registry.yarnpkg.com/@opentelemetry/sdk-metrics/-/sdk-metrics-1.26.0.tgz#37bb0afb1d4447f50aab9cdd05db6f2d8b86103e" - integrity sha512-0SvDXmou/JjzSDOjUmetAAvcKQW6ZrvosU0rkbDGpXvvZN+pQF6JbK/Kd4hNdK4q/22yeruqvukXEJyySTzyTQ== - dependencies: - "@opentelemetry/core" "1.26.0" - "@opentelemetry/resources" "1.26.0" - -"@opentelemetry/sdk-trace-base@^1.22", "@opentelemetry/sdk-trace-base@^1.26.0": - version "1.26.0" - resolved "https://registry.yarnpkg.com/@opentelemetry/sdk-trace-base/-/sdk-trace-base-1.26.0.tgz#0c913bc6d2cfafd901de330e4540952269ae579c" - integrity sha512-olWQldtvbK4v22ymrKLbIcBi9L2SpMO84sCPY54IVsJhP9fRsxJT194C/AVaAuJzLE30EdhhM1VmvVYR7az+cw== - dependencies: - "@opentelemetry/core" "1.26.0" - "@opentelemetry/resources" "1.26.0" - "@opentelemetry/semantic-conventions" "1.27.0" - -"@opentelemetry/semantic-conventions@1.27.0", "@opentelemetry/semantic-conventions@^1.27.0": - version "1.27.0" - resolved "https://registry.yarnpkg.com/@opentelemetry/semantic-conventions/-/semantic-conventions-1.27.0.tgz#1a857dcc95a5ab30122e04417148211e6f945e6c" - integrity sha512-sAay1RrB+ONOem0OZanAR1ZI/k7yDpnOQSQmTMuGImUQb2y8EbSaCJ94FQluM74xoU03vlb2d2U90hZluL6nQg== - -"@opentelemetry/sql-common@^0.40.1": - version "0.40.1" - resolved "https://registry.yarnpkg.com/@opentelemetry/sql-common/-/sql-common-0.40.1.tgz#93fbc48d8017449f5b3c3274f2268a08af2b83b6" - integrity sha512-nSDlnHSqzC3pXn/wZEZVLuAuJ1MYMXPBwtv2qAbCa3847SaHItdE7SzUq/Jtb0KZmh1zfAbNi3AAMjztTT4Ugg== - dependencies: - "@opentelemetry/core" "^1.1.0" - "@pkgjs/parseargs@^0.11.0": version "0.11.0" resolved "https://registry.npmjs.org/@pkgjs/parseargs/-/parseargs-0.11.0.tgz" @@ -557,14 +270,14 @@ resolved "https://registry.npmjs.org/@pkgr/core/-/core-0.1.1.tgz" integrity sha512-cq8o4cWH0ibXh9VGi5P20Tu9XF/0fFXl9EUinr9QfTM7a7p0oTA4iJRCQWppXR1Pg8dSM0UCItCkPwsk9qWWYA== -"@prisma/instrumentation@5.19.1": - version "5.19.1" - resolved "https://registry.yarnpkg.com/@prisma/instrumentation/-/instrumentation-5.19.1.tgz#146319cf85f22b7a43296f0f40cfeac55516e66e" - integrity sha512-VLnzMQq7CWroL5AeaW0Py2huiNKeoMfCH3SUxstdzPrlWQi6UQ9UrfcbUkNHlVFqOMacqy8X/8YtE0kuKDpD9w== +"@sentry-internal/tracing@7.84.0": + version "7.84.0" + resolved "https://registry.yarnpkg.com/@sentry-internal/tracing/-/tracing-7.84.0.tgz#430da253ee5b075be4ef57f20ea842c0208bc6b0" + integrity sha512-y9bGYA0OM6PEREfd+nk4UURZy29tpIw+7vQwpxWfEVs2fqq0/5TBFX/tKFb8AKUI9lVM8v0bcF0bNSCnuPQZHQ== dependencies: - "@opentelemetry/api" "^1.8" - "@opentelemetry/instrumentation" "^0.49 || ^0.50 || ^0.51 || ^0.52.0" - "@opentelemetry/sdk-trace-base" "^1.22" + "@sentry/core" "7.84.0" + "@sentry/types" "7.84.0" + "@sentry/utils" "7.84.0" "@sentry-internal/tracing@7.99.0": version "7.99.0" @@ -575,6 +288,14 @@ "@sentry/types" "7.99.0" "@sentry/utils" "7.99.0" +"@sentry/core@7.84.0": + version "7.84.0" + resolved "https://registry.yarnpkg.com/@sentry/core/-/core-7.84.0.tgz#01d33fc452044ffd8ea57b20f60304b9cfa2b9e1" + integrity sha512-tbuwunbBx2kSex15IHCqHDnrMfIlqPc6w/76fwkGqokz3oh9GSEGlLICwmBWL8AypWimUg13IDtFpD0TJTriWA== + dependencies: + "@sentry/types" "7.84.0" + "@sentry/utils" "7.84.0" + "@sentry/core@7.99.0": version "7.99.0" resolved "https://registry.npmjs.org/@sentry/core/-/core-7.99.0.tgz" @@ -583,75 +304,16 @@ "@sentry/types" "7.99.0" "@sentry/utils" "7.99.0" -"@sentry/core@8.33.1": - version "8.33.1" - resolved "https://registry.yarnpkg.com/@sentry/core/-/core-8.33.1.tgz#dc59f73b93e6f78f15c897ac47e48008680d9c04" - integrity sha512-3SS41suXLFzxL3OQvTMZ6q92ZapELVq2l2SoWlZopcamWhog2Ru0dp2vkunq97kFHb2TzKRTlFH4+4gbT8SJug== - dependencies: - "@sentry/types" "8.33.1" - "@sentry/utils" "8.33.1" - -"@sentry/node@8.33.1", "@sentry/node@^8.29.0": - version "8.33.1" - resolved "https://registry.yarnpkg.com/@sentry/node/-/node-8.33.1.tgz#1f45d13e59b86e9572e3f7764a8c9e5fe4ece0a7" - integrity sha512-0Xmlrl5nU5Bx6YybaIfztyOIiIXW5X64vcK0u94Sg4uHcDO7YvEbhflKjp669ds2I6ZQ/czqxnaAY8gM6P2SCA== - dependencies: - "@opentelemetry/api" "^1.9.0" - "@opentelemetry/context-async-hooks" "^1.25.1" - "@opentelemetry/core" "^1.25.1" - "@opentelemetry/instrumentation" "^0.53.0" - "@opentelemetry/instrumentation-amqplib" "^0.42.0" - "@opentelemetry/instrumentation-connect" "0.39.0" - "@opentelemetry/instrumentation-dataloader" "0.12.0" - "@opentelemetry/instrumentation-express" "0.42.0" - "@opentelemetry/instrumentation-fastify" "0.39.0" - "@opentelemetry/instrumentation-fs" "0.15.0" - "@opentelemetry/instrumentation-generic-pool" "0.39.0" - "@opentelemetry/instrumentation-graphql" "0.43.0" - "@opentelemetry/instrumentation-hapi" "0.41.0" - "@opentelemetry/instrumentation-http" "0.53.0" - "@opentelemetry/instrumentation-ioredis" "0.43.0" - "@opentelemetry/instrumentation-kafkajs" "0.3.0" - "@opentelemetry/instrumentation-koa" "0.43.0" - "@opentelemetry/instrumentation-lru-memoizer" "0.40.0" - "@opentelemetry/instrumentation-mongodb" "0.47.0" - "@opentelemetry/instrumentation-mongoose" "0.42.0" - "@opentelemetry/instrumentation-mysql" "0.41.0" - "@opentelemetry/instrumentation-mysql2" "0.41.0" - "@opentelemetry/instrumentation-nestjs-core" "0.40.0" - "@opentelemetry/instrumentation-pg" "0.44.0" - "@opentelemetry/instrumentation-redis-4" "0.42.0" - "@opentelemetry/instrumentation-undici" "0.6.0" - "@opentelemetry/resources" "^1.26.0" - "@opentelemetry/sdk-trace-base" "^1.26.0" - "@opentelemetry/semantic-conventions" "^1.27.0" - "@prisma/instrumentation" "5.19.1" - "@sentry/core" "8.33.1" - "@sentry/opentelemetry" "8.33.1" - "@sentry/types" "8.33.1" - "@sentry/utils" "8.33.1" - import-in-the-middle "^1.11.0" - -"@sentry/opentelemetry@8.33.1": - version "8.33.1" - resolved "https://registry.yarnpkg.com/@sentry/opentelemetry/-/opentelemetry-8.33.1.tgz#c7419a14ca00f8326a32673f19016098eaf9ff9a" - integrity sha512-D2aE2G0DUHLLnfbOXrTjiNJKAs/RZfOBJMidI4fC2AIwqCmrp55Aex4dRq4hxd8MPLR92Kt/ikHeJxlzWB15KA== - dependencies: - "@sentry/core" "8.33.1" - "@sentry/types" "8.33.1" - "@sentry/utils" "8.33.1" - -"@sentry/profiling-node@^8.32.0": - version "8.33.1" - resolved "https://registry.yarnpkg.com/@sentry/profiling-node/-/profiling-node-8.33.1.tgz#13143360b7adf3d35d2e701191378cde0a6cb419" - integrity sha512-mpgcqT/yUyWiRKjHFJ6UMjNmMgAYK4aeaMQDL7P61y5mrVxfK9vRQbKuXdP9XiyiZe06j1PSskiBEA2S1cDVJQ== - dependencies: - "@sentry/core" "8.33.1" - "@sentry/node" "8.33.1" - "@sentry/types" "8.33.1" - "@sentry/utils" "8.33.1" - detect-libc "^2.0.2" - node-abi "^3.61.0" +"@sentry/node@7.84.0": + version "7.84.0" + resolved "https://registry.yarnpkg.com/@sentry/node/-/node-7.84.0.tgz#c06167106796b2b83c0a9b52fa56f8ca820034ca" + integrity sha512-Xm3fIXT3TZOQi+6uQBavI8iOehD3PkY7v0y3hog0d4lQTH88vQK9BBsI+jZEq81Em+RG/u7vZNiFo6YMTnWF7Q== + dependencies: + "@sentry-internal/tracing" "7.84.0" + "@sentry/core" "7.84.0" + "@sentry/types" "7.84.0" + "@sentry/utils" "7.84.0" + https-proxy-agent "^5.0.0" "@sentry/tracing@^7.84.0": version "7.99.0" @@ -660,15 +322,22 @@ dependencies: "@sentry-internal/tracing" "7.99.0" +"@sentry/types@7.84.0": + version "7.84.0" + resolved "https://registry.yarnpkg.com/@sentry/types/-/types-7.84.0.tgz#e8db86c36c61659c3b2558f0aa8b6a073a756117" + integrity sha512-VqGLIF3JOUrk7yIXjLXJvAORkZL1e3dDX0Q1okRehwyt/5CRE+mdUTeJZkBo9P9mBwgMyvtwklzOGGrzjb4eMA== + "@sentry/types@7.99.0": version "7.99.0" resolved "https://registry.npmjs.org/@sentry/types/-/types-7.99.0.tgz" integrity sha512-94qwOw4w40sAs5mCmzcGyj8ZUu/KhnWnuMZARRq96k+SjRW/tHFAOlIdnFSrt3BLPvSOK7R3bVAskZQ0N4FTmA== -"@sentry/types@8.33.1": - version "8.33.1" - resolved "https://registry.yarnpkg.com/@sentry/types/-/types-8.33.1.tgz#3c519f974c3c3f3ea8b4e6f930b676f954c26f87" - integrity sha512-GjoAMvwtpIemoF/IiwZ7A60g4nQv3qwzR21GvJqDVUoKD0e8pv9OLX+HyXoUat4wEDGSuDUcUyUKD2G+od73QA== +"@sentry/utils@7.84.0": + version "7.84.0" + resolved "https://registry.yarnpkg.com/@sentry/utils/-/utils-7.84.0.tgz#32861d922fa31e86dd2863a1d9dfc5a369e98952" + integrity sha512-qdUVuxnRBvaf05AU+28R+xYtZmi/Ymf8os3Njq9g4XuA+QEkZLbzmIpRK5W9Ja7vUtjOeg29Xgg43A8znde9LQ== + dependencies: + "@sentry/types" "7.84.0" "@sentry/utils@7.99.0": version "7.99.0" @@ -677,13 +346,6 @@ dependencies: "@sentry/types" "7.99.0" -"@sentry/utils@8.33.1": - version "8.33.1" - resolved "https://registry.yarnpkg.com/@sentry/utils/-/utils-8.33.1.tgz#8cfc56b7dbc27135028e77aa5d553b15f4ba0466" - integrity sha512-uzuYpiiJuFY3N4WNHMBWUQX5oNv2t/TbG0OHRp3Rr7yeu+HSfD542TIp9/gMZ+G0Cxd8AmVO3wkKIFbk0TL4Qg== - dependencies: - "@sentry/types" "8.33.1" - "@tsconfig/node10@^1.0.7": version "1.0.9" resolved "https://registry.npmjs.org/@tsconfig/node10/-/node10-1.0.9.tgz" @@ -724,13 +386,6 @@ dependencies: "@types/node" "*" -"@types/connect@3.4.36": - version "3.4.36" - resolved "https://registry.yarnpkg.com/@types/connect/-/connect-3.4.36.tgz#e511558c15a39cb29bd5357eebb57bd1459cd1ab" - integrity sha512-P63Zd/JUGq+PdrM1lv0Wv5SBYeA2+CORvbrXbngriYY0jzLUWfQMQQxOhjONEz/wlHOAxOdY7CY65rgQdTjq2w== - dependencies: - "@types/node" "*" - "@types/cors@^2.8.17": version "2.8.17" resolved "https://registry.npmjs.org/@types/cors/-/cors-2.8.17.tgz" @@ -802,13 +457,6 @@ dependencies: "@types/node" "*" -"@types/mysql@2.15.26": - version "2.15.26" - resolved "https://registry.yarnpkg.com/@types/mysql/-/mysql-2.15.26.tgz#f0de1484b9e2354d587e7d2bd17a873cc8300836" - integrity sha512-DSLCOXhkvfS5WNNPbfn2KdICAmk8lLc+/PNvnPnF7gOdMZCxopXduqv0OQ13y/yA/zXTSikZZqVgybUxOEg6YQ== - dependencies: - "@types/node" "*" - "@types/node@*": version "20.11.13" resolved "https://registry.npmjs.org/@types/node/-/node-20.11.13.tgz" @@ -821,31 +469,6 @@ resolved "https://registry.npmjs.org/@types/parse-json/-/parse-json-4.0.2.tgz" integrity sha512-dISoDXWWQwUquiKsyZ4Ng+HX2KsPL7LyHKHQwgGFEA3IaKac4Obd+h2a/a6waisAoepJlBcx9paWqjA8/HVjCw== -"@types/pg-pool@2.0.6": - version "2.0.6" - resolved "https://registry.yarnpkg.com/@types/pg-pool/-/pg-pool-2.0.6.tgz#1376d9dc5aec4bb2ec67ce28d7e9858227403c77" - integrity sha512-TaAUE5rq2VQYxab5Ts7WZhKNmuN78Q6PiFonTDdpbx8a1H0M1vhy3rhiMjl+e2iHmogyMw7jZF4FrE6eJUy5HQ== - dependencies: - "@types/pg" "*" - -"@types/pg@*": - version "8.11.10" - resolved "https://registry.yarnpkg.com/@types/pg/-/pg-8.11.10.tgz#b8fb2b2b759d452fe3ec182beadd382563b63291" - integrity sha512-LczQUW4dbOQzsH2RQ5qoeJ6qJPdrcM/DcMLoqWQkMLMsq83J5lAX3LXjdkWdpscFy67JSOWDnh7Ny/sPFykmkg== - dependencies: - "@types/node" "*" - pg-protocol "*" - pg-types "^4.0.1" - -"@types/pg@8.6.1": - version "8.6.1" - resolved "https://registry.yarnpkg.com/@types/pg/-/pg-8.6.1.tgz#099450b8dc977e8197a44f5229cedef95c8747f9" - integrity sha512-1Kc4oAGzAl7uqUStZCDvaLFqZrW9qWSjXOmBfdgyBP5La7Us6Mg4GBvRlSoaZMhQF/zSj1C8CtKMBkoiT8eL8w== - dependencies: - "@types/node" "*" - pg-protocol "*" - pg-types "^2.2.0" - "@types/pg@^8.10.9": version "8.11.0" resolved "https://registry.npmjs.org/@types/pg/-/pg-8.11.0.tgz" @@ -887,11 +510,6 @@ "@types/mime" "*" "@types/node" "*" -"@types/shimmer@^1.0.2", "@types/shimmer@^1.2.0": - version "1.2.0" - resolved "https://registry.yarnpkg.com/@types/shimmer/-/shimmer-1.2.0.tgz#9b706af96fa06416828842397a70dfbbf1c14ded" - integrity sha512-UE7oxhQLLd9gub6JKIAhDq06T0F6FnztwMNRvYgjeQSBeMc1ZG/tA47EwfduvkuQS8apbkM/lpLpWsaCeYsXVg== - "@types/strip-bom@^3.0.0": version "3.0.0" resolved "https://registry.npmjs.org/@types/strip-bom/-/strip-bom-3.0.0.tgz" @@ -1009,11 +627,6 @@ accepts@~1.3.8: mime-types "~2.1.34" negotiator "0.6.3" -acorn-import-attributes@^1.9.5: - version "1.9.5" - resolved "https://registry.yarnpkg.com/acorn-import-attributes/-/acorn-import-attributes-1.9.5.tgz#7eb1557b1ba05ef18b5ed0ec67591bfab04688ef" - integrity sha512-n02Vykv5uA3eHGM/Z2dQrcD56kL8TyDb2p1+0P83PClMnC/nc+anbQRhIOWnSq4Ke/KvDPrY3C9hDtC/A3eHnQ== - acorn-jsx@^5.3.2: version "5.3.2" resolved "https://registry.npmjs.org/acorn-jsx/-/acorn-jsx-5.3.2.tgz" @@ -1029,10 +642,12 @@ acorn@^8.4.1, acorn@^8.9.0: resolved "https://registry.npmjs.org/acorn/-/acorn-8.11.3.tgz" integrity sha512-Y9rRfJG5jcKOE0CLisYbojUjIrIEE7AGMzA/Sm4BslANhbS+cDMpgBdcPT91oJ7OuJ9hYJBx59RjbhxVnrF8Xg== -acorn@^8.8.2: - version "8.12.1" - resolved "https://registry.yarnpkg.com/acorn/-/acorn-8.12.1.tgz#71616bdccbe25e27a54439e0046e89ca76df2248" - integrity sha512-tcpGyI9zbizT9JbV6oYE477V6mTlXvvi0T0G3SNIYE2apm/G5huBa1+K89VGeovbg+jycCrfhl3ADxErOuO6Jg== +agent-base@6: + version "6.0.2" + resolved "https://registry.yarnpkg.com/agent-base/-/agent-base-6.0.2.tgz#49fff58577cfee3f37176feab4c22e00f86d7f77" + integrity sha512-RZNwNclF7+MS/8bDg70amg32dyeZGZxiDuQmZxKLAlQjr3jGyLx+4Kkk58UO7D2QdgFIQCovuSuZESne6RG6XQ== + dependencies: + debug "4" aggregate-error@^3.0.0: version "3.1.0" @@ -1199,11 +814,6 @@ astral-regex@^2.0.0: resolved "https://registry.npmjs.org/astral-regex/-/astral-regex-2.0.0.tgz" integrity sha512-Z7tMw1ytTXt5jqMcOP+OQteU1VuNK9Y02uuJtKQ1Sv69jXQKKg5cibLwGJow8yzZP+eAc18EmLGPal0bp36rvQ== -async_hooks@^1.0.0: - version "1.0.0" - resolved "https://registry.yarnpkg.com/async_hooks/-/async_hooks-1.0.0.tgz#815f5e861fe73f64eb29fd942c32e95c8064052f" - integrity sha512-t4BSJgx48V3e7U6Ll3/WOUNmxIRPzmPdxVfgbyzcnRItEnn4iKp4F//b0sV3L9hzbdr5qxWdNWzOF7t+rjYSfA== - asynckit@^0.4.0: version "0.4.0" resolved "https://registry.npmjs.org/asynckit/-/asynckit-0.4.0.tgz" @@ -1439,11 +1049,6 @@ chokidar@3.5.3, chokidar@^3.5.1, chokidar@^3.5.2: optionalDependencies: fsevents "~2.3.2" -cjs-module-lexer@^1.2.2: - version "1.4.1" - resolved "https://registry.yarnpkg.com/cjs-module-lexer/-/cjs-module-lexer-1.4.1.tgz#707413784dbb3a72aa11c2f2b042a0bef4004170" - integrity sha512-cuSVIHi9/9E/+821Qjdvngor+xpnlwnuwIyZOaLmHBVdXL+gP+I6QQB9VkO7RI77YIcTV+S1W9AreJ5eN63JBA== - clean-stack@^2.0.0: version "2.2.0" resolved "https://registry.npmjs.org/clean-stack/-/clean-stack-2.2.0.tgz" @@ -1602,6 +1207,13 @@ debug@2.6.9: dependencies: ms "2.0.0" +debug@4: + version "4.3.7" + resolved "https://registry.yarnpkg.com/debug/-/debug-4.3.7.tgz#87945b4151a011d76d95a198d7111c865c360a52" + integrity sha512-Er2nc/H7RrMXZBFCEim6TCmMk02Z8vLC2Rbi1KEBggpo0fS6l0S1nnapwmIi3yW/+GOJap1Krg4w0Hg80oCqgQ== + dependencies: + ms "^2.1.3" + debug@4.3.4, debug@^4, debug@^4.3.1, debug@^4.3.2, debug@^4.3.4: version "4.3.4" resolved "https://registry.npmjs.org/debug/-/debug-4.3.4.tgz" @@ -1616,13 +1228,6 @@ debug@^3.2.7: dependencies: ms "^2.1.1" -debug@^4.3.5: - version "4.3.7" - resolved "https://registry.yarnpkg.com/debug/-/debug-4.3.7.tgz#87945b4151a011d76d95a198d7111c865c360a52" - integrity sha512-Er2nc/H7RrMXZBFCEim6TCmMk02Z8vLC2Rbi1KEBggpo0fS6l0S1nnapwmIi3yW/+GOJap1Krg4w0Hg80oCqgQ== - dependencies: - ms "^2.1.3" - decamelize@^4.0.0: version "4.0.0" resolved "https://registry.npmjs.org/decamelize/-/decamelize-4.0.0.tgz" @@ -1702,11 +1307,6 @@ detect-libc@^2.0.1: resolved "https://registry.npmjs.org/detect-libc/-/detect-libc-2.0.2.tgz" integrity sha512-UX6sGumvvqSaXgdKGUsgZWqcUyIXZ/vZTrlRT/iobiKhGL0zL4d3osHj3uqllWJK+i+sixDS/3COVEOFbupFyw== -detect-libc@^2.0.2: - version "2.0.3" - resolved "https://registry.yarnpkg.com/detect-libc/-/detect-libc-2.0.3.tgz#f0cd503b40f9939b894697d19ad50895e30cf700" - integrity sha512-bwy0MGW55bG41VqxxypOsdSdGqLwXPI/focwgTYCFMbdUiBAxLg9CFzG08sz2aqzknwiX7Hkl0bQENjg8iLByw== - diff@5.0.0: version "5.0.0" resolved "https://registry.npmjs.org/diff/-/diff-5.0.0.tgz" @@ -2571,6 +2171,14 @@ http-errors@2.0.0: statuses "2.0.1" toidentifier "1.0.1" +https-proxy-agent@^5.0.0: + version "5.0.1" + resolved "https://registry.yarnpkg.com/https-proxy-agent/-/https-proxy-agent-5.0.1.tgz#c59ef224a04fe8b754f3db0063a25ea30d0005d6" + integrity sha512-dFcAjpTQFgoLMzC2VwU+C/CbS7uRL0lWmxDITmqm7C+7F0Odmj6s9l6alZc6AELXhrnggM2CeWSXHGOdX2YtwA== + dependencies: + agent-base "6" + debug "4" + human-signals@^1.1.1: version "1.1.1" resolved "https://registry.npmjs.org/human-signals/-/human-signals-1.1.1.tgz" @@ -2611,16 +2219,6 @@ import-fresh@^3.2.1: parent-module "^1.0.0" resolve-from "^4.0.0" -import-in-the-middle@^1.11.0, import-in-the-middle@^1.8.1: - version "1.11.2" - resolved "https://registry.yarnpkg.com/import-in-the-middle/-/import-in-the-middle-1.11.2.tgz#dd848e72b63ca6cd7c34df8b8d97fc9baee6174f" - integrity sha512-gK6Rr6EykBcc6cVWRSBR5TWf8nn6hZMYSRYqCcHa0l0d1fPK7JSYo6+Mlmck76jIX9aL/IZ71c06U2VpFwl1zA== - dependencies: - acorn "^8.8.2" - acorn-import-attributes "^1.9.5" - cjs-module-lexer "^1.2.2" - module-details-from-path "^1.0.3" - imurmurhash@^0.1.4: version "0.1.4" resolved "https://registry.npmjs.org/imurmurhash/-/imurmurhash-0.1.4.tgz" @@ -3256,11 +2854,6 @@ mocha@^10.2.0: yargs-parser "20.2.4" yargs-unparser "2.0.0" -module-details-from-path@^1.0.3: - version "1.0.3" - resolved "https://registry.yarnpkg.com/module-details-from-path/-/module-details-from-path-1.0.3.tgz#114c949673e2a8a35e9d35788527aa37b679da2b" - integrity sha512-ySViT69/76t8VhE1xXHK6Ch4NcDd26gx0MzKXLO+F7NOtnqH68d9zF94nT8ZWSxXh8ELOERsnJO/sWt1xZYw5A== - morgan@^1.10.0: version "1.10.0" resolved "https://registry.npmjs.org/morgan/-/morgan-1.10.0.tgz" @@ -3312,13 +2905,6 @@ nice-try@^1.0.4: resolved "https://registry.npmjs.org/nice-try/-/nice-try-1.0.5.tgz" integrity sha512-1nh45deeb5olNY7eX82BkPO7SSxR5SSYJiPTrTdFUVYwAl8CKMA5N9PjTYkHiRjisVcxcQ1HXdLhx2qxxJzLNQ== -node-abi@^3.61.0: - version "3.68.0" - resolved "https://registry.yarnpkg.com/node-abi/-/node-abi-3.68.0.tgz#8f37fb02ecf4f43ebe694090dcb52e0c4cc4ba25" - integrity sha512-7vbj10trelExNjFSBm5kTvZXXa7pZyKWx9RCKIyqe6I9Ev3IzGpQoqBP3a+cOdxY+pWj6VkP28n/2wWysBHD/A== - dependencies: - semver "^7.3.5" - node-domexception@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/node-domexception/-/node-domexception-1.0.0.tgz#6888db46a1f71c0b76b3f7555016b63fe64766e5" @@ -3676,7 +3262,7 @@ pg-protocol@*, pg-protocol@^1.6.0: resolved "https://registry.npmjs.org/pg-protocol/-/pg-protocol-1.6.0.tgz" integrity sha512-M+PDm637OY5WM307051+bsDia5Xej6d9IR4GwJse1qA1DIhiKlksvrneZOYQq42OM+spubpcNYEo2FcKQrDk+Q== -pg-types@^2.1.0, pg-types@^2.2.0: +pg-types@^2.1.0: version "2.2.0" resolved "https://registry.npmjs.org/pg-types/-/pg-types-2.2.0.tgz" integrity sha512-qTAAlrEsl8s4OiEQY69wDvcMIdQN6wdz5ojQiOy6YRMuynxenON0O5oCpJI6lshc6scgAY8qvJ2On/p+CXY0GA== @@ -4036,21 +3622,12 @@ require-directory@^2.1.1: resolved "https://registry.npmjs.org/require-directory/-/require-directory-2.1.1.tgz" integrity sha512-fGxEI7+wsG9xrvdjsrlmL22OMTTiHRwAMroiEeMgq8gzoLC/PQr7RsRDSTLUg/bZAZtF+TVIkHc6/4RIKrui+Q== -require-in-the-middle@^7.1.1: - version "7.4.0" - resolved "https://registry.yarnpkg.com/require-in-the-middle/-/require-in-the-middle-7.4.0.tgz#606977820d4b5f9be75e5a108ce34cfed25b3bb4" - integrity sha512-X34iHADNbNDfr6OTStIAHWSAvvKQRYgLO6duASaVf7J2VA3lvmNYboAHOuLC2huav1IwgZJtyEcJCKVzFxOSMQ== - dependencies: - debug "^4.3.5" - module-details-from-path "^1.0.3" - resolve "^1.22.8" - resolve-from@^4.0.0: version "4.0.0" resolved "https://registry.npmjs.org/resolve-from/-/resolve-from-4.0.0.tgz" integrity sha512-pb/MYmXstAkysRFx8piNI1tGFNQIFA3vkE3Gq4EuA1dF6gHp/+vgZqsCGJapvy8N3Q+4o7FwvquPJcnZ7RYy4g== -resolve@^1.0.0, resolve@^1.10.0, resolve@^1.22.4, resolve@^1.22.8: +resolve@^1.0.0, resolve@^1.10.0, resolve@^1.22.4: version "1.22.8" resolved "https://registry.npmjs.org/resolve/-/resolve-1.22.8.tgz" integrity sha512-oKWePCxqpd6FlLvGV1VU0x7bkPmmCNolxzjMf4NczoDnQcIWrAF+cPtZn5i6n+RfD2d9i0tzpKnG6Yk168yIyw== @@ -4176,11 +3753,6 @@ semver@^6.3.1: resolved "https://registry.npmjs.org/semver/-/semver-6.3.1.tgz" integrity sha512-BR7VvDCVHO+q2xBEWskxS6DJE1qRnb7DxzUrogb71CWoSficBxYsiAGd+Kl0mmq/MprG9yArRkyrQxTO6XjMzA== -semver@^7.3.5, semver@^7.5.2: - version "7.6.3" - resolved "https://registry.yarnpkg.com/semver/-/semver-7.6.3.tgz#980f7b5550bc175fb4dc09403085627f9eb33143" - integrity sha512-oVekP1cKtI+CTDvHWYFUcMtsK/00wmAEfyqKfNdARm8u1wNVhSgaX7A8d4UuIlUI5e84iEwOhs7ZPYRmzU9U6A== - semver@^7.5.3, semver@^7.5.4: version "7.5.4" resolved "https://registry.npmjs.org/semver/-/semver-7.5.4.tgz" @@ -4283,11 +3855,6 @@ shell-quote@^1.6.1: resolved "https://registry.npmjs.org/shell-quote/-/shell-quote-1.8.1.tgz" integrity sha512-6j1W9l1iAs/4xYBI1SYOVZyFcCis9b4KCLQ8fgAGG07QvzaRLVVRQvAy85yNmmZSjYjg4MWh4gNvlPujU/5LpA== -shimmer@^1.2.1: - version "1.2.1" - resolved "https://registry.yarnpkg.com/shimmer/-/shimmer-1.2.1.tgz#610859f7de327b587efebf501fb43117f9aff337" - integrity sha512-sQTKC1Re/rM6XyFM6fIAGHRPVGvyXfgzIDvzoq608vM+jeyVD0Tu1E6Np0Kc2zAIFWIj963V2800iF/9LPieQw== - side-channel@^1.0.4: version "1.0.4" resolved "https://registry.npmjs.org/side-channel/-/side-channel-1.0.4.tgz" @@ -4405,7 +3972,16 @@ string-argv@0.3.1: resolved "https://registry.npmjs.org/string-argv/-/string-argv-0.3.1.tgz" integrity sha512-a1uQGz7IyVy9YwhqjZIZu1c8JO8dNIe20xBmSS6qu9kv++k3JGzCVmprbNN5Kn+BgzD5E7YYwg1CcjuJMRNsvg== -"string-width-cjs@npm:string-width@^4.2.0", string-width@^4.1.0, string-width@^4.2.0: +"string-width-cjs@npm:string-width@^4.2.0": + version "4.2.3" + resolved "https://registry.npmjs.org/string-width/-/string-width-4.2.3.tgz" + integrity sha512-wKyQRQpjJ0sIp62ErSZdGsjMJWsap5oRNihHhu6G7JVO/9jIB6UyevL+tXuOqrng8j/cxKTWyWUwvSTriiZz/g== + dependencies: + emoji-regex "^8.0.0" + is-fullwidth-code-point "^3.0.0" + strip-ansi "^6.0.1" + +string-width@^4.1.0, string-width@^4.2.0: version "4.2.3" resolved "https://registry.npmjs.org/string-width/-/string-width-4.2.3.tgz" integrity sha512-wKyQRQpjJ0sIp62ErSZdGsjMJWsap5oRNihHhu6G7JVO/9jIB6UyevL+tXuOqrng8j/cxKTWyWUwvSTriiZz/g== @@ -4475,7 +4051,14 @@ stringify-object@^3.3.0: is-obj "^1.0.1" is-regexp "^1.0.0" -"strip-ansi-cjs@npm:strip-ansi@^6.0.1", strip-ansi@^6.0.0, strip-ansi@^6.0.1: +"strip-ansi-cjs@npm:strip-ansi@^6.0.1": + version "6.0.1" + resolved "https://registry.npmjs.org/strip-ansi/-/strip-ansi-6.0.1.tgz" + integrity sha512-Y38VPSHcqkFrCpFnQ9vuSXmquuv5oXOKpGeT6aGrr3o3Gc9AlVa6JBfUSOCnbxGGZF+/0ooI7KrPuUSztUdU5A== + dependencies: + ansi-regex "^5.0.1" + +strip-ansi@^6.0.0, strip-ansi@^6.0.1: version "6.0.1" resolved "https://registry.npmjs.org/strip-ansi/-/strip-ansi-6.0.1.tgz" integrity sha512-Y38VPSHcqkFrCpFnQ9vuSXmquuv5oXOKpGeT6aGrr3o3Gc9AlVa6JBfUSOCnbxGGZF+/0ooI7KrPuUSztUdU5A== @@ -4870,7 +4453,7 @@ workerpool@6.2.1: resolved "https://registry.npmjs.org/workerpool/-/workerpool-6.2.1.tgz" integrity sha512-ILEIE97kDZvF9Wb9f6h5aXK4swSlKGUcOEGiIYb2OOu/IrDU9iwj0fD//SsA6E5ibwJxpEvhullJY4Sl4GcpAw== -"wrap-ansi-cjs@npm:wrap-ansi@^7.0.0", wrap-ansi@^7.0.0: +"wrap-ansi-cjs@npm:wrap-ansi@^7.0.0": version "7.0.0" resolved "https://registry.npmjs.org/wrap-ansi/-/wrap-ansi-7.0.0.tgz" integrity sha512-YVGIj2kamLSTxw6NsZjoBxfSwsn0ycdesmc4p+Q21c5zPuZ1pl+NfxVdxPtdHvmNVOQ6XSYG4AUtyt/Fi7D16Q== @@ -4888,6 +4471,15 @@ wrap-ansi@^6.2.0: string-width "^4.1.0" strip-ansi "^6.0.0" +wrap-ansi@^7.0.0: + version "7.0.0" + resolved "https://registry.npmjs.org/wrap-ansi/-/wrap-ansi-7.0.0.tgz" + integrity sha512-YVGIj2kamLSTxw6NsZjoBxfSwsn0ycdesmc4p+Q21c5zPuZ1pl+NfxVdxPtdHvmNVOQ6XSYG4AUtyt/Fi7D16Q== + dependencies: + ansi-styles "^4.0.0" + string-width "^4.1.0" + strip-ansi "^6.0.0" + wrap-ansi@^8.1.0: version "8.1.0" resolved "https://registry.npmjs.org/wrap-ansi/-/wrap-ansi-8.1.0.tgz" diff --git a/desci-server/package.json b/desci-server/package.json index 470a8a218..ec8c73380 100755 --- a/desci-server/package.json +++ b/desci-server/package.json @@ -70,8 +70,8 @@ "@react-email/components": "0.0.15", "@sendgrid/mail": "^7.7.0", "@sentry/cli": "^2.35.0", - "@sentry/node": "^8.29.0", - "@sentry/profiling-node": "^8.32.0", + "@sentry/node": "8.29.0", + "@sentry/profiling-node": "8.32.0", "@sentry/tracing": "^7.12.0", "@types/lodash-es": "^4.17.12", "@types/mkdirp": "^1.0.2", diff --git a/desci-server/yarn.lock b/desci-server/yarn.lock index 73dfed96f..c45cfcd68 100644 --- a/desci-server/yarn.lock +++ b/desci-server/yarn.lock @@ -5725,18 +5725,16 @@ "@sentry/types" "8.32.0" "@sentry/utils" "8.32.0" -"@sentry/node@8.32.0": - version "8.32.0" - resolved "https://registry.yarnpkg.com/@sentry/node/-/node-8.32.0.tgz#68822b3246fb2ed7418f21795ed539a18058cfa8" - integrity sha512-a2PoFA9j/HmJVGF/zXJhLP6QhRHGye/2EznQdHOELsH1BkeMgBaXl7D52r2E/b7qki647lXrdbspB6jid8NycA== +"@sentry/node@8.29.0": + version "8.29.0" + resolved "https://registry.yarnpkg.com/@sentry/node/-/node-8.29.0.tgz#6e462b8802356a630c56733dc795a4035464c4ab" + integrity sha512-RCKpWR6DUWmlxtms10MRXwJZRrFt1a2P38FjwEEahcdcK1R6wB8GPf0GO4JnJAiw6oeM0MERSqLIcSLT8+FxtA== dependencies: "@opentelemetry/api" "^1.9.0" "@opentelemetry/context-async-hooks" "^1.25.1" "@opentelemetry/core" "^1.25.1" "@opentelemetry/instrumentation" "^0.53.0" - "@opentelemetry/instrumentation-amqplib" "^0.42.0" "@opentelemetry/instrumentation-connect" "0.39.0" - "@opentelemetry/instrumentation-dataloader" "0.12.0" "@opentelemetry/instrumentation-express" "0.42.0" "@opentelemetry/instrumentation-fastify" "0.39.0" "@opentelemetry/instrumentation-fs" "0.15.0" @@ -5745,7 +5743,6 @@ "@opentelemetry/instrumentation-hapi" "0.41.0" "@opentelemetry/instrumentation-http" "0.53.0" "@opentelemetry/instrumentation-ioredis" "0.43.0" - "@opentelemetry/instrumentation-kafkajs" "0.3.0" "@opentelemetry/instrumentation-koa" "0.43.0" "@opentelemetry/instrumentation-mongodb" "0.47.0" "@opentelemetry/instrumentation-mongoose" "0.42.0" @@ -5754,27 +5751,30 @@ "@opentelemetry/instrumentation-nestjs-core" "0.40.0" "@opentelemetry/instrumentation-pg" "0.44.0" "@opentelemetry/instrumentation-redis-4" "0.42.0" - "@opentelemetry/instrumentation-undici" "0.6.0" - "@opentelemetry/resources" "^1.26.0" - "@opentelemetry/sdk-trace-base" "^1.26.0" - "@opentelemetry/semantic-conventions" "^1.27.0" + "@opentelemetry/resources" "^1.25.1" + "@opentelemetry/sdk-trace-base" "^1.25.1" + "@opentelemetry/semantic-conventions" "^1.25.1" "@prisma/instrumentation" "5.19.1" - "@sentry/core" "8.32.0" - "@sentry/opentelemetry" "8.32.0" - "@sentry/types" "8.32.0" - "@sentry/utils" "8.32.0" + "@sentry/core" "8.29.0" + "@sentry/opentelemetry" "8.29.0" + "@sentry/types" "8.29.0" + "@sentry/utils" "8.29.0" import-in-the-middle "^1.11.0" + optionalDependencies: + opentelemetry-instrumentation-fetch-node "1.2.3" -"@sentry/node@^8.29.0": - version "8.29.0" - resolved "https://registry.yarnpkg.com/@sentry/node/-/node-8.29.0.tgz#6e462b8802356a630c56733dc795a4035464c4ab" - integrity sha512-RCKpWR6DUWmlxtms10MRXwJZRrFt1a2P38FjwEEahcdcK1R6wB8GPf0GO4JnJAiw6oeM0MERSqLIcSLT8+FxtA== +"@sentry/node@8.32.0": + version "8.32.0" + resolved "https://registry.yarnpkg.com/@sentry/node/-/node-8.32.0.tgz#68822b3246fb2ed7418f21795ed539a18058cfa8" + integrity sha512-a2PoFA9j/HmJVGF/zXJhLP6QhRHGye/2EznQdHOELsH1BkeMgBaXl7D52r2E/b7qki647lXrdbspB6jid8NycA== dependencies: "@opentelemetry/api" "^1.9.0" "@opentelemetry/context-async-hooks" "^1.25.1" "@opentelemetry/core" "^1.25.1" "@opentelemetry/instrumentation" "^0.53.0" + "@opentelemetry/instrumentation-amqplib" "^0.42.0" "@opentelemetry/instrumentation-connect" "0.39.0" + "@opentelemetry/instrumentation-dataloader" "0.12.0" "@opentelemetry/instrumentation-express" "0.42.0" "@opentelemetry/instrumentation-fastify" "0.39.0" "@opentelemetry/instrumentation-fs" "0.15.0" @@ -5783,6 +5783,7 @@ "@opentelemetry/instrumentation-hapi" "0.41.0" "@opentelemetry/instrumentation-http" "0.53.0" "@opentelemetry/instrumentation-ioredis" "0.43.0" + "@opentelemetry/instrumentation-kafkajs" "0.3.0" "@opentelemetry/instrumentation-koa" "0.43.0" "@opentelemetry/instrumentation-mongodb" "0.47.0" "@opentelemetry/instrumentation-mongoose" "0.42.0" @@ -5791,17 +5792,16 @@ "@opentelemetry/instrumentation-nestjs-core" "0.40.0" "@opentelemetry/instrumentation-pg" "0.44.0" "@opentelemetry/instrumentation-redis-4" "0.42.0" - "@opentelemetry/resources" "^1.25.1" - "@opentelemetry/sdk-trace-base" "^1.25.1" - "@opentelemetry/semantic-conventions" "^1.25.1" + "@opentelemetry/instrumentation-undici" "0.6.0" + "@opentelemetry/resources" "^1.26.0" + "@opentelemetry/sdk-trace-base" "^1.26.0" + "@opentelemetry/semantic-conventions" "^1.27.0" "@prisma/instrumentation" "5.19.1" - "@sentry/core" "8.29.0" - "@sentry/opentelemetry" "8.29.0" - "@sentry/types" "8.29.0" - "@sentry/utils" "8.29.0" + "@sentry/core" "8.32.0" + "@sentry/opentelemetry" "8.32.0" + "@sentry/types" "8.32.0" + "@sentry/utils" "8.32.0" import-in-the-middle "^1.11.0" - optionalDependencies: - opentelemetry-instrumentation-fetch-node "1.2.3" "@sentry/opentelemetry@8.29.0": version "8.29.0" @@ -5821,7 +5821,7 @@ "@sentry/types" "8.32.0" "@sentry/utils" "8.32.0" -"@sentry/profiling-node@^8.32.0": +"@sentry/profiling-node@8.32.0": version "8.32.0" resolved "https://registry.yarnpkg.com/@sentry/profiling-node/-/profiling-node-8.32.0.tgz#cb4bf0512dc7a6f0a9058529f3c4dbb8963a597d" integrity sha512-wKE2JAvDM3DjVNFKd2YLzwhXFS3SurLxDPpvA1EjMQ9Me7sR5ssO9jFn3e6et5oT3e3EzGDyTfbrJ81BNQuZhQ== @@ -12071,9 +12071,9 @@ import-in-the-middle@1.7.1: module-details-from-path "^1.0.3" import-in-the-middle@^1.11.0, import-in-the-middle@^1.8.1: - version "1.11.0" - resolved "https://registry.yarnpkg.com/import-in-the-middle/-/import-in-the-middle-1.11.0.tgz#a94c4925b8da18256cde3b3b7b38253e6ca5e708" - integrity sha512-5DimNQGoe0pLUHbR9qK84iWaWjjbsxiqXnw6Qz64+azRgleqv9k2kTt5fw7QsOpmaGYtuxxursnPPsnTKEx10Q== + version "1.11.2" + resolved "https://registry.yarnpkg.com/import-in-the-middle/-/import-in-the-middle-1.11.2.tgz#dd848e72b63ca6cd7c34df8b8d97fc9baee6174f" + integrity sha512-gK6Rr6EykBcc6cVWRSBR5TWf8nn6hZMYSRYqCcHa0l0d1fPK7JSYo6+Mlmck76jIX9aL/IZ71c06U2VpFwl1zA== dependencies: acorn "^8.8.2" acorn-import-attributes "^1.9.5" From 39594d0eb3323c46dfe2f8aaa441e61317ee8419 Mon Sep 17 00:00:00 2001 From: shadrach Date: Tue, 8 Oct 2024 08:46:22 -0500 Subject: [PATCH 71/81] test sentrrry --- desci-repo/src/instrument.ts | 4 ++-- desci-repo/src/server.ts | 26 +++++++++++++++++++------- 2 files changed, 21 insertions(+), 9 deletions(-) diff --git a/desci-repo/src/instrument.ts b/desci-repo/src/instrument.ts index fb4a64602..45c4ce46d 100644 --- a/desci-repo/src/instrument.ts +++ b/desci-repo/src/instrument.ts @@ -1,13 +1,13 @@ import * as Sentry from '@sentry/node'; import { nodeProfilingIntegration } from '@sentry/profiling-node'; -const ENABLE_TELEMETRY = process.env.NODE_ENV === 'production'; +const ENABLE_TELEMETRY = true; // process.env.NODE_ENV === 'production'; if (ENABLE_TELEMETRY) { Sentry.init({ dsn: 'https://d508a5c408f34b919ccd94aac093e076@o1330109.ingest.sentry.io/6619754', release: 'desci-nodes-repo@' + process.env.npm_package_version, - integrations: [nodeProfilingIntegration()], + integrations: [], // Set tracesSampleRate to 1.0 to capture 100% // of transactions for performance monitoring. // We recommend adjusting this value in production diff --git a/desci-repo/src/server.ts b/desci-repo/src/server.ts index 9072b7f48..9ab9fd0f6 100644 --- a/desci-repo/src/server.ts +++ b/desci-repo/src/server.ts @@ -1,7 +1,8 @@ -import './instrument.js'; +// import './instrument.js'; import * as Sentry from '@sentry/node'; +import { nodeProfilingIntegration } from '@sentry/profiling-node'; -const ENABLE_TELEMETRY = process.env.NODE_ENV === 'production'; +const ENABLE_TELEMETRY = true; //process.env.NODE_ENV === 'production'; const IS_DEV = !ENABLE_TELEMETRY; // @ts-check @@ -109,6 +110,9 @@ class AppServer { }); }); + // init telementry + this.#initTelemetry(); + this.app.use(bodyParser.json({ limit: '100mb' })); this.app.use(bodyParser.urlencoded({ extended: false })); @@ -125,9 +129,6 @@ class AppServer { res.status(200).json({ id: serverUuid }); }); - // init telementry - this.#initTelemetry(); - this.port = process.env.PORT ? parseInt(process.env.PORT) : 5484; logger.info(`Server starting on port ${this.port}`); this.server = this.app.listen(this.port, () => { @@ -202,10 +203,21 @@ class AppServer { ); } - async #initTelemetry() { + #initTelemetry() { if (ENABLE_TELEMETRY) { logger.info('[DeSci Repo] Telemetry enabled'); - Sentry.setupExpressErrorHandler(this.app); + Sentry.init({ + dsn: 'https://d508a5c408f34b919ccd94aac093e076@o1330109.ingest.sentry.io/6619754', + release: 'desci-nodes-repo@' + process.env.npm_package_version, + integrations: [nodeProfilingIntegration()], + // Set tracesSampleRate to 1.0 to capture 100% + // of transactions for performance monitoring. + // We recommend adjusting this value in production + tracesSampleRate: 1.0, + profilesSampleRate: 1.0, + }); + // Sentry.setupExpressErrorHandler(this.app); + this.app.use(Sentry.expressErrorHandler()); } else { logger.info('[DeSci Repo] Telemetry disabled'); } From 0925f38537e98f15efb5450af8ab5b38d52d24db Mon Sep 17 00:00:00 2001 From: shadrach Date: Tue, 8 Oct 2024 08:47:12 -0500 Subject: [PATCH 72/81] remove trash --- desci-repo/src/instrument.ts | 17 ----------------- desci-repo/src/server.ts | 1 - 2 files changed, 18 deletions(-) delete mode 100644 desci-repo/src/instrument.ts diff --git a/desci-repo/src/instrument.ts b/desci-repo/src/instrument.ts deleted file mode 100644 index 45c4ce46d..000000000 --- a/desci-repo/src/instrument.ts +++ /dev/null @@ -1,17 +0,0 @@ -import * as Sentry from '@sentry/node'; -import { nodeProfilingIntegration } from '@sentry/profiling-node'; - -const ENABLE_TELEMETRY = true; // process.env.NODE_ENV === 'production'; - -if (ENABLE_TELEMETRY) { - Sentry.init({ - dsn: 'https://d508a5c408f34b919ccd94aac093e076@o1330109.ingest.sentry.io/6619754', - release: 'desci-nodes-repo@' + process.env.npm_package_version, - integrations: [], - // Set tracesSampleRate to 1.0 to capture 100% - // of transactions for performance monitoring. - // We recommend adjusting this value in production - tracesSampleRate: 1.0, - profilesSampleRate: 1.0, - }); -} diff --git a/desci-repo/src/server.ts b/desci-repo/src/server.ts index 9ab9fd0f6..1035756a1 100644 --- a/desci-repo/src/server.ts +++ b/desci-repo/src/server.ts @@ -1,4 +1,3 @@ -// import './instrument.js'; import * as Sentry from '@sentry/node'; import { nodeProfilingIntegration } from '@sentry/profiling-node'; From e3a53baba5400181f1d641b65e1cb4ec97e0d8c4 Mon Sep 17 00:00:00 2001 From: shadrach Date: Tue, 8 Oct 2024 08:50:14 -0500 Subject: [PATCH 73/81] remove static flag --- desci-repo/src/server.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/desci-repo/src/server.ts b/desci-repo/src/server.ts index 1035756a1..f8b95d724 100644 --- a/desci-repo/src/server.ts +++ b/desci-repo/src/server.ts @@ -1,7 +1,7 @@ import * as Sentry from '@sentry/node'; import { nodeProfilingIntegration } from '@sentry/profiling-node'; -const ENABLE_TELEMETRY = true; //process.env.NODE_ENV === 'production'; +const ENABLE_TELEMETRY = process.env.NODE_ENV === 'production'; const IS_DEV = !ENABLE_TELEMETRY; // @ts-check From cc05ff20210a288a429917c446efcdf528e79ff1 Mon Sep 17 00:00:00 2001 From: shadrach Date: Tue, 8 Oct 2024 08:55:48 -0500 Subject: [PATCH 74/81] fix deps --- desci-repo/package.json | 3 +- desci-repo/yarn.lock | 643 ++++++++++++++++++++++++++++++++++++---- 2 files changed, 584 insertions(+), 62 deletions(-) diff --git a/desci-repo/package.json b/desci-repo/package.json index 4ee7e0a47..740c5882e 100644 --- a/desci-repo/package.json +++ b/desci-repo/package.json @@ -69,7 +69,8 @@ }, "dependencies": { "@desci-labs/desci-models": "0.2.11", - "@sentry/node": "7.84.0", + "@sentry/node": "8.29.0", + "@sentry/profiling-node": "8.32.0", "@sentry/tracing": "^7.84.0", "axios": "^1.6.2", "cors": "^2.8.5", diff --git a/desci-repo/yarn.lock b/desci-repo/yarn.lock index da3a880c0..e6744e445 100644 --- a/desci-repo/yarn.lock +++ b/desci-repo/yarn.lock @@ -260,6 +260,297 @@ "@nodelib/fs.scandir" "2.1.5" fastq "^1.6.0" +"@opentelemetry/api-logs@0.52.1": + version "0.52.1" + resolved "https://registry.yarnpkg.com/@opentelemetry/api-logs/-/api-logs-0.52.1.tgz#52906375da4d64c206b0c4cb8ffa209214654ecc" + integrity sha512-qnSqB2DQ9TPP96dl8cDubDvrUyWc0/sK81xHTK8eSUspzDM3bsewX903qclQFvVhgStjRWdC5bLb3kQqMkfV5A== + dependencies: + "@opentelemetry/api" "^1.0.0" + +"@opentelemetry/api-logs@0.53.0": + version "0.53.0" + resolved "https://registry.yarnpkg.com/@opentelemetry/api-logs/-/api-logs-0.53.0.tgz#c478cbd8120ec2547b64edfa03a552cfe42170be" + integrity sha512-8HArjKx+RaAI8uEIgcORbZIPklyh1YLjPSBus8hjRmvLi6DeFzgOcdZ7KwPabKj8mXF8dX0hyfAyGfycz0DbFw== + dependencies: + "@opentelemetry/api" "^1.0.0" + +"@opentelemetry/api@^1.0.0", "@opentelemetry/api@^1.8", "@opentelemetry/api@^1.9.0": + version "1.9.0" + resolved "https://registry.yarnpkg.com/@opentelemetry/api/-/api-1.9.0.tgz#d03eba68273dc0f7509e2a3d5cba21eae10379fe" + integrity sha512-3giAOQvZiH5F9bMlMiv8+GSPMeqg0dbaeo58/0SlA9sxSqZhnUtxzX9/2FzyhS9sWQf5S0GJE0AKBrFqjpeYcg== + +"@opentelemetry/context-async-hooks@^1.25.1": + version "1.26.0" + resolved "https://registry.yarnpkg.com/@opentelemetry/context-async-hooks/-/context-async-hooks-1.26.0.tgz#fa92f722cf685685334bba95f258d3ef9fce60f6" + integrity sha512-HedpXXYzzbaoutw6DFLWLDket2FwLkLpil4hGCZ1xYEIMTcivdfwEOISgdbLEWyG3HW52gTq2V9mOVJrONgiwg== + +"@opentelemetry/core@1.26.0", "@opentelemetry/core@^1.1.0", "@opentelemetry/core@^1.25.1", "@opentelemetry/core@^1.8.0": + version "1.26.0" + resolved "https://registry.yarnpkg.com/@opentelemetry/core/-/core-1.26.0.tgz#7d84265aaa850ed0ca5813f97d831155be42b328" + integrity sha512-1iKxXXE8415Cdv0yjG3G6hQnB5eVEsJce3QaawX8SjDn0mAS0ZM8fAbZZJD4ajvhC15cePvosSCut404KrIIvQ== + dependencies: + "@opentelemetry/semantic-conventions" "1.27.0" + +"@opentelemetry/instrumentation-amqplib@^0.42.0": + version "0.42.0" + resolved "https://registry.yarnpkg.com/@opentelemetry/instrumentation-amqplib/-/instrumentation-amqplib-0.42.0.tgz#b3cab5a7207736a30d769962eed3af3838f986c4" + integrity sha512-fiuU6OKsqHJiydHWgTRQ7MnIrJ2lEqsdgFtNIH4LbAUJl/5XmrIeoDzDnox+hfkgWK65jsleFuQDtYb5hW1koQ== + dependencies: + "@opentelemetry/core" "^1.8.0" + "@opentelemetry/instrumentation" "^0.53.0" + "@opentelemetry/semantic-conventions" "^1.27.0" + +"@opentelemetry/instrumentation-connect@0.39.0": + version "0.39.0" + resolved "https://registry.yarnpkg.com/@opentelemetry/instrumentation-connect/-/instrumentation-connect-0.39.0.tgz#32bdbaac464cba061c95df6c850ee81efdd86f8b" + integrity sha512-pGBiKevLq7NNglMgqzmeKczF4XQMTOUOTkK8afRHMZMnrK3fcETyTH7lVaSozwiOM3Ws+SuEmXZT7DYrrhxGlg== + dependencies: + "@opentelemetry/core" "^1.8.0" + "@opentelemetry/instrumentation" "^0.53.0" + "@opentelemetry/semantic-conventions" "^1.27.0" + "@types/connect" "3.4.36" + +"@opentelemetry/instrumentation-dataloader@0.12.0": + version "0.12.0" + resolved "https://registry.yarnpkg.com/@opentelemetry/instrumentation-dataloader/-/instrumentation-dataloader-0.12.0.tgz#de03a3948dec4f15fed80aa424d6bd5d6a8d10c7" + integrity sha512-pnPxatoFE0OXIZDQhL2okF//dmbiWFzcSc8pUg9TqofCLYZySSxDCgQc69CJBo5JnI3Gz1KP+mOjS4WAeRIH4g== + dependencies: + "@opentelemetry/instrumentation" "^0.53.0" + +"@opentelemetry/instrumentation-express@0.42.0": + version "0.42.0" + resolved "https://registry.yarnpkg.com/@opentelemetry/instrumentation-express/-/instrumentation-express-0.42.0.tgz#279f195aa66baee2b98623a16666c6229c8e7564" + integrity sha512-YNcy7ZfGnLsVEqGXQPT+S0G1AE46N21ORY7i7yUQyfhGAL4RBjnZUqefMI0NwqIl6nGbr1IpF0rZGoN8Q7x12Q== + dependencies: + "@opentelemetry/core" "^1.8.0" + "@opentelemetry/instrumentation" "^0.53.0" + "@opentelemetry/semantic-conventions" "^1.27.0" + +"@opentelemetry/instrumentation-fastify@0.39.0": + version "0.39.0" + resolved "https://registry.yarnpkg.com/@opentelemetry/instrumentation-fastify/-/instrumentation-fastify-0.39.0.tgz#96a040e4944daf77c53a8fe5a128bc3b2568e4aa" + integrity sha512-SS9uSlKcsWZabhBp2szErkeuuBDgxOUlllwkS92dVaWRnMmwysPhcEgHKB8rUe3BHg/GnZC1eo1hbTZv4YhfoA== + dependencies: + "@opentelemetry/core" "^1.8.0" + "@opentelemetry/instrumentation" "^0.53.0" + "@opentelemetry/semantic-conventions" "^1.27.0" + +"@opentelemetry/instrumentation-fs@0.15.0": + version "0.15.0" + resolved "https://registry.yarnpkg.com/@opentelemetry/instrumentation-fs/-/instrumentation-fs-0.15.0.tgz#41658507860f39fee5209bca961cea8d24ca2a83" + integrity sha512-JWVKdNLpu1skqZQA//jKOcKdJC66TWKqa2FUFq70rKohvaSq47pmXlnabNO+B/BvLfmidfiaN35XakT5RyMl2Q== + dependencies: + "@opentelemetry/core" "^1.8.0" + "@opentelemetry/instrumentation" "^0.53.0" + +"@opentelemetry/instrumentation-generic-pool@0.39.0": + version "0.39.0" + resolved "https://registry.yarnpkg.com/@opentelemetry/instrumentation-generic-pool/-/instrumentation-generic-pool-0.39.0.tgz#2b9af16ad82d5cbe67125c0125753cecd162a728" + integrity sha512-y4v8Y+tSfRB3NNBvHjbjrn7rX/7sdARG7FuK6zR8PGb28CTa0kHpEGCJqvL9L8xkTNvTXo+lM36ajFGUaK1aNw== + dependencies: + "@opentelemetry/instrumentation" "^0.53.0" + +"@opentelemetry/instrumentation-graphql@0.43.0": + version "0.43.0" + resolved "https://registry.yarnpkg.com/@opentelemetry/instrumentation-graphql/-/instrumentation-graphql-0.43.0.tgz#71bb94ea775c70dbd388c739b397ec1418f3f170" + integrity sha512-aI3YMmC2McGd8KW5du1a2gBA0iOMOGLqg4s9YjzwbjFwjlmMNFSK1P3AIg374GWg823RPUGfVTIgZ/juk9CVOA== + dependencies: + "@opentelemetry/instrumentation" "^0.53.0" + +"@opentelemetry/instrumentation-hapi@0.41.0": + version "0.41.0" + resolved "https://registry.yarnpkg.com/@opentelemetry/instrumentation-hapi/-/instrumentation-hapi-0.41.0.tgz#de8711907256d8fae1b5faf71fc825cef4a7ddbb" + integrity sha512-jKDrxPNXDByPlYcMdZjNPYCvw0SQJjN+B1A+QH+sx+sAHsKSAf9hwFiJSrI6C4XdOls43V/f/fkp9ITkHhKFbQ== + dependencies: + "@opentelemetry/core" "^1.8.0" + "@opentelemetry/instrumentation" "^0.53.0" + "@opentelemetry/semantic-conventions" "^1.27.0" + +"@opentelemetry/instrumentation-http@0.53.0": + version "0.53.0" + resolved "https://registry.yarnpkg.com/@opentelemetry/instrumentation-http/-/instrumentation-http-0.53.0.tgz#0d806adf1b3aba036bc46e16162e3c0dbb8a6b60" + integrity sha512-H74ErMeDuZfj7KgYCTOFGWF5W9AfaPnqLQQxeFq85+D29wwV2yqHbz2IKLYpkOh7EI6QwDEl7rZCIxjJLyc/CQ== + dependencies: + "@opentelemetry/core" "1.26.0" + "@opentelemetry/instrumentation" "0.53.0" + "@opentelemetry/semantic-conventions" "1.27.0" + semver "^7.5.2" + +"@opentelemetry/instrumentation-ioredis@0.43.0": + version "0.43.0" + resolved "https://registry.yarnpkg.com/@opentelemetry/instrumentation-ioredis/-/instrumentation-ioredis-0.43.0.tgz#dbadabaeefc4cb47c406f878444f1bcac774fa89" + integrity sha512-i3Dke/LdhZbiUAEImmRG3i7Dimm/BD7t8pDDzwepSvIQ6s2X6FPia7561gw+64w+nx0+G9X14D7rEfaMEmmjig== + dependencies: + "@opentelemetry/instrumentation" "^0.53.0" + "@opentelemetry/redis-common" "^0.36.2" + "@opentelemetry/semantic-conventions" "^1.27.0" + +"@opentelemetry/instrumentation-kafkajs@0.3.0": + version "0.3.0" + resolved "https://registry.yarnpkg.com/@opentelemetry/instrumentation-kafkajs/-/instrumentation-kafkajs-0.3.0.tgz#6687bce4dac8b90ef8ccbf1b662d5d1e95a34414" + integrity sha512-UnkZueYK1ise8FXQeKlpBd7YYUtC7mM8J0wzUSccEfc/G8UqHQqAzIyYCUOUPUKp8GsjLnWOOK/3hJc4owb7Jg== + dependencies: + "@opentelemetry/instrumentation" "^0.53.0" + "@opentelemetry/semantic-conventions" "^1.27.0" + +"@opentelemetry/instrumentation-koa@0.43.0": + version "0.43.0" + resolved "https://registry.yarnpkg.com/@opentelemetry/instrumentation-koa/-/instrumentation-koa-0.43.0.tgz#963fd192a1b5f6cbae5dabf4ec82e3105cbb23b1" + integrity sha512-lDAhSnmoTIN6ELKmLJBplXzT/Jqs5jGZehuG22EdSMaTwgjMpxMDI1YtlKEhiWPWkrz5LUsd0aOO0ZRc9vn3AQ== + dependencies: + "@opentelemetry/core" "^1.8.0" + "@opentelemetry/instrumentation" "^0.53.0" + "@opentelemetry/semantic-conventions" "^1.27.0" + +"@opentelemetry/instrumentation-mongodb@0.47.0": + version "0.47.0" + resolved "https://registry.yarnpkg.com/@opentelemetry/instrumentation-mongodb/-/instrumentation-mongodb-0.47.0.tgz#f8107d878281433905e717f223fb4c0f10356a7b" + integrity sha512-yqyXRx2SulEURjgOQyJzhCECSh5i1uM49NUaq9TqLd6fA7g26OahyJfsr9NE38HFqGRHpi4loyrnfYGdrsoVjQ== + dependencies: + "@opentelemetry/instrumentation" "^0.53.0" + "@opentelemetry/sdk-metrics" "^1.9.1" + "@opentelemetry/semantic-conventions" "^1.27.0" + +"@opentelemetry/instrumentation-mongoose@0.42.0": + version "0.42.0" + resolved "https://registry.yarnpkg.com/@opentelemetry/instrumentation-mongoose/-/instrumentation-mongoose-0.42.0.tgz#375afd21adfcd897a8f521c1ffd2d91e6a428705" + integrity sha512-AnWv+RaR86uG3qNEMwt3plKX1ueRM7AspfszJYVkvkehiicC3bHQA6vWdb6Zvy5HAE14RyFbu9+2hUUjR2NSyg== + dependencies: + "@opentelemetry/core" "^1.8.0" + "@opentelemetry/instrumentation" "^0.53.0" + "@opentelemetry/semantic-conventions" "^1.27.0" + +"@opentelemetry/instrumentation-mysql2@0.41.0": + version "0.41.0" + resolved "https://registry.yarnpkg.com/@opentelemetry/instrumentation-mysql2/-/instrumentation-mysql2-0.41.0.tgz#6377b6e2d2487fd88e1d79aa03658db6c8d51651" + integrity sha512-REQB0x+IzVTpoNgVmy5b+UnH1/mDByrneimP6sbDHkp1j8QOl1HyWOrBH/6YWR0nrbU3l825Em5PlybjT3232g== + dependencies: + "@opentelemetry/instrumentation" "^0.53.0" + "@opentelemetry/semantic-conventions" "^1.27.0" + "@opentelemetry/sql-common" "^0.40.1" + +"@opentelemetry/instrumentation-mysql@0.41.0": + version "0.41.0" + resolved "https://registry.yarnpkg.com/@opentelemetry/instrumentation-mysql/-/instrumentation-mysql-0.41.0.tgz#2d50691ead5219774bd36d66c35d5b4681485dd7" + integrity sha512-jnvrV6BsQWyHS2qb2fkfbfSb1R/lmYwqEZITwufuRl37apTopswu9izc0b1CYRp/34tUG/4k/V39PND6eyiNvw== + dependencies: + "@opentelemetry/instrumentation" "^0.53.0" + "@opentelemetry/semantic-conventions" "^1.27.0" + "@types/mysql" "2.15.26" + +"@opentelemetry/instrumentation-nestjs-core@0.40.0": + version "0.40.0" + resolved "https://registry.yarnpkg.com/@opentelemetry/instrumentation-nestjs-core/-/instrumentation-nestjs-core-0.40.0.tgz#2c0e6405b56caaec32747d55c57ff9a034668ea8" + integrity sha512-WF1hCUed07vKmf5BzEkL0wSPinqJgH7kGzOjjMAiTGacofNXjb/y4KQ8loj2sNsh5C/NN7s1zxQuCgbWbVTGKg== + dependencies: + "@opentelemetry/instrumentation" "^0.53.0" + "@opentelemetry/semantic-conventions" "^1.27.0" + +"@opentelemetry/instrumentation-pg@0.44.0": + version "0.44.0" + resolved "https://registry.yarnpkg.com/@opentelemetry/instrumentation-pg/-/instrumentation-pg-0.44.0.tgz#1e97a0aeb2dca068ee23ce75884a0a0063a7ce3f" + integrity sha512-oTWVyzKqXud1BYEGX1loo2o4k4vaU1elr3vPO8NZolrBtFvQ34nx4HgUaexUDuEog00qQt+MLR5gws/p+JXMLQ== + dependencies: + "@opentelemetry/instrumentation" "^0.53.0" + "@opentelemetry/semantic-conventions" "^1.27.0" + "@opentelemetry/sql-common" "^0.40.1" + "@types/pg" "8.6.1" + "@types/pg-pool" "2.0.6" + +"@opentelemetry/instrumentation-redis-4@0.42.0": + version "0.42.0" + resolved "https://registry.yarnpkg.com/@opentelemetry/instrumentation-redis-4/-/instrumentation-redis-4-0.42.0.tgz#fc01104cfe884c7546385eaae03c57a47edd19d1" + integrity sha512-NaD+t2JNcOzX/Qa7kMy68JbmoVIV37fT/fJYzLKu2Wwd+0NCxt+K2OOsOakA8GVg8lSpFdbx4V/suzZZ2Pvdjg== + dependencies: + "@opentelemetry/instrumentation" "^0.53.0" + "@opentelemetry/redis-common" "^0.36.2" + "@opentelemetry/semantic-conventions" "^1.27.0" + +"@opentelemetry/instrumentation-undici@0.6.0": + version "0.6.0" + resolved "https://registry.yarnpkg.com/@opentelemetry/instrumentation-undici/-/instrumentation-undici-0.6.0.tgz#9436ee155c8dcb0b760b66947c0e0f347688a5ef" + integrity sha512-ABJBhm5OdhGmbh0S/fOTE4N69IZ00CsHC5ijMYfzbw3E5NwLgpQk5xsljaECrJ8wz1SfXbO03FiSuu5AyRAkvQ== + dependencies: + "@opentelemetry/core" "^1.8.0" + "@opentelemetry/instrumentation" "^0.53.0" + +"@opentelemetry/instrumentation@0.53.0", "@opentelemetry/instrumentation@^0.53.0": + version "0.53.0" + resolved "https://registry.yarnpkg.com/@opentelemetry/instrumentation/-/instrumentation-0.53.0.tgz#e6369e4015eb5112468a4d45d38dcada7dad892d" + integrity sha512-DMwg0hy4wzf7K73JJtl95m/e0boSoWhH07rfvHvYzQtBD3Bmv0Wc1x733vyZBqmFm8OjJD0/pfiUg1W3JjFX0A== + dependencies: + "@opentelemetry/api-logs" "0.53.0" + "@types/shimmer" "^1.2.0" + import-in-the-middle "^1.8.1" + require-in-the-middle "^7.1.1" + semver "^7.5.2" + shimmer "^1.2.1" + +"@opentelemetry/instrumentation@^0.46.0": + version "0.46.0" + resolved "https://registry.yarnpkg.com/@opentelemetry/instrumentation/-/instrumentation-0.46.0.tgz#a8a252306f82e2eace489312798592a14eb9830e" + integrity sha512-a9TijXZZbk0vI5TGLZl+0kxyFfrXHhX6Svtz7Pp2/VBlCSKrazuULEyoJQrOknJyFWNMEmbbJgOciHCCpQcisw== + dependencies: + "@types/shimmer" "^1.0.2" + import-in-the-middle "1.7.1" + require-in-the-middle "^7.1.1" + semver "^7.5.2" + shimmer "^1.2.1" + +"@opentelemetry/instrumentation@^0.49 || ^0.50 || ^0.51 || ^0.52.0": + version "0.52.1" + resolved "https://registry.yarnpkg.com/@opentelemetry/instrumentation/-/instrumentation-0.52.1.tgz#2e7e46a38bd7afbf03cf688c862b0b43418b7f48" + integrity sha512-uXJbYU/5/MBHjMp1FqrILLRuiJCs3Ofk0MeRDk8g1S1gD47U8X3JnSwcMO1rtRo1x1a7zKaQHaoYu49p/4eSKw== + dependencies: + "@opentelemetry/api-logs" "0.52.1" + "@types/shimmer" "^1.0.2" + import-in-the-middle "^1.8.1" + require-in-the-middle "^7.1.1" + semver "^7.5.2" + shimmer "^1.2.1" + +"@opentelemetry/redis-common@^0.36.2": + version "0.36.2" + resolved "https://registry.yarnpkg.com/@opentelemetry/redis-common/-/redis-common-0.36.2.tgz#906ac8e4d804d4109f3ebd5c224ac988276fdc47" + integrity sha512-faYX1N0gpLhej/6nyp6bgRjzAKXn5GOEMYY7YhciSfCoITAktLUtQ36d24QEWNA1/WA1y6qQunCe0OhHRkVl9g== + +"@opentelemetry/resources@1.26.0", "@opentelemetry/resources@^1.25.1", "@opentelemetry/resources@^1.26.0": + version "1.26.0" + resolved "https://registry.yarnpkg.com/@opentelemetry/resources/-/resources-1.26.0.tgz#da4c7366018bd8add1f3aa9c91c6ac59fd503cef" + integrity sha512-CPNYchBE7MBecCSVy0HKpUISEeJOniWqcHaAHpmasZ3j9o6V3AyBzhRc90jdmemq0HOxDr6ylhUbDhBqqPpeNw== + dependencies: + "@opentelemetry/core" "1.26.0" + "@opentelemetry/semantic-conventions" "1.27.0" + +"@opentelemetry/sdk-metrics@^1.9.1": + version "1.26.0" + resolved "https://registry.yarnpkg.com/@opentelemetry/sdk-metrics/-/sdk-metrics-1.26.0.tgz#37bb0afb1d4447f50aab9cdd05db6f2d8b86103e" + integrity sha512-0SvDXmou/JjzSDOjUmetAAvcKQW6ZrvosU0rkbDGpXvvZN+pQF6JbK/Kd4hNdK4q/22yeruqvukXEJyySTzyTQ== + dependencies: + "@opentelemetry/core" "1.26.0" + "@opentelemetry/resources" "1.26.0" + +"@opentelemetry/sdk-trace-base@^1.22", "@opentelemetry/sdk-trace-base@^1.25.1", "@opentelemetry/sdk-trace-base@^1.26.0": + version "1.26.0" + resolved "https://registry.yarnpkg.com/@opentelemetry/sdk-trace-base/-/sdk-trace-base-1.26.0.tgz#0c913bc6d2cfafd901de330e4540952269ae579c" + integrity sha512-olWQldtvbK4v22ymrKLbIcBi9L2SpMO84sCPY54IVsJhP9fRsxJT194C/AVaAuJzLE30EdhhM1VmvVYR7az+cw== + dependencies: + "@opentelemetry/core" "1.26.0" + "@opentelemetry/resources" "1.26.0" + "@opentelemetry/semantic-conventions" "1.27.0" + +"@opentelemetry/semantic-conventions@1.27.0", "@opentelemetry/semantic-conventions@^1.17.0", "@opentelemetry/semantic-conventions@^1.25.1", "@opentelemetry/semantic-conventions@^1.27.0": + version "1.27.0" + resolved "https://registry.yarnpkg.com/@opentelemetry/semantic-conventions/-/semantic-conventions-1.27.0.tgz#1a857dcc95a5ab30122e04417148211e6f945e6c" + integrity sha512-sAay1RrB+ONOem0OZanAR1ZI/k7yDpnOQSQmTMuGImUQb2y8EbSaCJ94FQluM74xoU03vlb2d2U90hZluL6nQg== + +"@opentelemetry/sql-common@^0.40.1": + version "0.40.1" + resolved "https://registry.yarnpkg.com/@opentelemetry/sql-common/-/sql-common-0.40.1.tgz#93fbc48d8017449f5b3c3274f2268a08af2b83b6" + integrity sha512-nSDlnHSqzC3pXn/wZEZVLuAuJ1MYMXPBwtv2qAbCa3847SaHItdE7SzUq/Jtb0KZmh1zfAbNi3AAMjztTT4Ugg== + dependencies: + "@opentelemetry/core" "^1.1.0" + "@pkgjs/parseargs@^0.11.0": version "0.11.0" resolved "https://registry.npmjs.org/@pkgjs/parseargs/-/parseargs-0.11.0.tgz" @@ -270,14 +561,14 @@ resolved "https://registry.npmjs.org/@pkgr/core/-/core-0.1.1.tgz" integrity sha512-cq8o4cWH0ibXh9VGi5P20Tu9XF/0fFXl9EUinr9QfTM7a7p0oTA4iJRCQWppXR1Pg8dSM0UCItCkPwsk9qWWYA== -"@sentry-internal/tracing@7.84.0": - version "7.84.0" - resolved "https://registry.yarnpkg.com/@sentry-internal/tracing/-/tracing-7.84.0.tgz#430da253ee5b075be4ef57f20ea842c0208bc6b0" - integrity sha512-y9bGYA0OM6PEREfd+nk4UURZy29tpIw+7vQwpxWfEVs2fqq0/5TBFX/tKFb8AKUI9lVM8v0bcF0bNSCnuPQZHQ== +"@prisma/instrumentation@5.19.1": + version "5.19.1" + resolved "https://registry.yarnpkg.com/@prisma/instrumentation/-/instrumentation-5.19.1.tgz#146319cf85f22b7a43296f0f40cfeac55516e66e" + integrity sha512-VLnzMQq7CWroL5AeaW0Py2huiNKeoMfCH3SUxstdzPrlWQi6UQ9UrfcbUkNHlVFqOMacqy8X/8YtE0kuKDpD9w== dependencies: - "@sentry/core" "7.84.0" - "@sentry/types" "7.84.0" - "@sentry/utils" "7.84.0" + "@opentelemetry/api" "^1.8" + "@opentelemetry/instrumentation" "^0.49 || ^0.50 || ^0.51 || ^0.52.0" + "@opentelemetry/sdk-trace-base" "^1.22" "@sentry-internal/tracing@7.99.0": version "7.99.0" @@ -288,14 +579,6 @@ "@sentry/types" "7.99.0" "@sentry/utils" "7.99.0" -"@sentry/core@7.84.0": - version "7.84.0" - resolved "https://registry.yarnpkg.com/@sentry/core/-/core-7.84.0.tgz#01d33fc452044ffd8ea57b20f60304b9cfa2b9e1" - integrity sha512-tbuwunbBx2kSex15IHCqHDnrMfIlqPc6w/76fwkGqokz3oh9GSEGlLICwmBWL8AypWimUg13IDtFpD0TJTriWA== - dependencies: - "@sentry/types" "7.84.0" - "@sentry/utils" "7.84.0" - "@sentry/core@7.99.0": version "7.99.0" resolved "https://registry.npmjs.org/@sentry/core/-/core-7.99.0.tgz" @@ -304,16 +587,129 @@ "@sentry/types" "7.99.0" "@sentry/utils" "7.99.0" -"@sentry/node@7.84.0": - version "7.84.0" - resolved "https://registry.yarnpkg.com/@sentry/node/-/node-7.84.0.tgz#c06167106796b2b83c0a9b52fa56f8ca820034ca" - integrity sha512-Xm3fIXT3TZOQi+6uQBavI8iOehD3PkY7v0y3hog0d4lQTH88vQK9BBsI+jZEq81Em+RG/u7vZNiFo6YMTnWF7Q== - dependencies: - "@sentry-internal/tracing" "7.84.0" - "@sentry/core" "7.84.0" - "@sentry/types" "7.84.0" - "@sentry/utils" "7.84.0" - https-proxy-agent "^5.0.0" +"@sentry/core@8.29.0": + version "8.29.0" + resolved "https://registry.yarnpkg.com/@sentry/core/-/core-8.29.0.tgz#52032ece2d7b60f3775f10189c27e26b1cebdbca" + integrity sha512-scMbZaJ0Ov8NPgWn86EdjhyTLrhvRVbTxjg0imJAvhIvRbblH3xyqye/17Qnk2fOp8TNDOl7TBZHi0NCFQ5HUw== + dependencies: + "@sentry/types" "8.29.0" + "@sentry/utils" "8.29.0" + +"@sentry/core@8.32.0": + version "8.32.0" + resolved "https://registry.yarnpkg.com/@sentry/core/-/core-8.32.0.tgz#7c4b74afa7a15bd31f5e6881aac82ccfd753e1d6" + integrity sha512-+xidTr0lZ0c755tq4k75dXPEb8PA+qvIefW3U9+dQMORLokBrYoKYMf5zZTG2k/OfSJS6OSxatUj36NFuCs3aA== + dependencies: + "@sentry/types" "8.32.0" + "@sentry/utils" "8.32.0" + +"@sentry/node@8.29.0": + version "8.29.0" + resolved "https://registry.yarnpkg.com/@sentry/node/-/node-8.29.0.tgz#6e462b8802356a630c56733dc795a4035464c4ab" + integrity sha512-RCKpWR6DUWmlxtms10MRXwJZRrFt1a2P38FjwEEahcdcK1R6wB8GPf0GO4JnJAiw6oeM0MERSqLIcSLT8+FxtA== + dependencies: + "@opentelemetry/api" "^1.9.0" + "@opentelemetry/context-async-hooks" "^1.25.1" + "@opentelemetry/core" "^1.25.1" + "@opentelemetry/instrumentation" "^0.53.0" + "@opentelemetry/instrumentation-connect" "0.39.0" + "@opentelemetry/instrumentation-express" "0.42.0" + "@opentelemetry/instrumentation-fastify" "0.39.0" + "@opentelemetry/instrumentation-fs" "0.15.0" + "@opentelemetry/instrumentation-generic-pool" "0.39.0" + "@opentelemetry/instrumentation-graphql" "0.43.0" + "@opentelemetry/instrumentation-hapi" "0.41.0" + "@opentelemetry/instrumentation-http" "0.53.0" + "@opentelemetry/instrumentation-ioredis" "0.43.0" + "@opentelemetry/instrumentation-koa" "0.43.0" + "@opentelemetry/instrumentation-mongodb" "0.47.0" + "@opentelemetry/instrumentation-mongoose" "0.42.0" + "@opentelemetry/instrumentation-mysql" "0.41.0" + "@opentelemetry/instrumentation-mysql2" "0.41.0" + "@opentelemetry/instrumentation-nestjs-core" "0.40.0" + "@opentelemetry/instrumentation-pg" "0.44.0" + "@opentelemetry/instrumentation-redis-4" "0.42.0" + "@opentelemetry/resources" "^1.25.1" + "@opentelemetry/sdk-trace-base" "^1.25.1" + "@opentelemetry/semantic-conventions" "^1.25.1" + "@prisma/instrumentation" "5.19.1" + "@sentry/core" "8.29.0" + "@sentry/opentelemetry" "8.29.0" + "@sentry/types" "8.29.0" + "@sentry/utils" "8.29.0" + import-in-the-middle "^1.11.0" + optionalDependencies: + opentelemetry-instrumentation-fetch-node "1.2.3" + +"@sentry/node@8.32.0": + version "8.32.0" + resolved "https://registry.yarnpkg.com/@sentry/node/-/node-8.32.0.tgz#68822b3246fb2ed7418f21795ed539a18058cfa8" + integrity sha512-a2PoFA9j/HmJVGF/zXJhLP6QhRHGye/2EznQdHOELsH1BkeMgBaXl7D52r2E/b7qki647lXrdbspB6jid8NycA== + dependencies: + "@opentelemetry/api" "^1.9.0" + "@opentelemetry/context-async-hooks" "^1.25.1" + "@opentelemetry/core" "^1.25.1" + "@opentelemetry/instrumentation" "^0.53.0" + "@opentelemetry/instrumentation-amqplib" "^0.42.0" + "@opentelemetry/instrumentation-connect" "0.39.0" + "@opentelemetry/instrumentation-dataloader" "0.12.0" + "@opentelemetry/instrumentation-express" "0.42.0" + "@opentelemetry/instrumentation-fastify" "0.39.0" + "@opentelemetry/instrumentation-fs" "0.15.0" + "@opentelemetry/instrumentation-generic-pool" "0.39.0" + "@opentelemetry/instrumentation-graphql" "0.43.0" + "@opentelemetry/instrumentation-hapi" "0.41.0" + "@opentelemetry/instrumentation-http" "0.53.0" + "@opentelemetry/instrumentation-ioredis" "0.43.0" + "@opentelemetry/instrumentation-kafkajs" "0.3.0" + "@opentelemetry/instrumentation-koa" "0.43.0" + "@opentelemetry/instrumentation-mongodb" "0.47.0" + "@opentelemetry/instrumentation-mongoose" "0.42.0" + "@opentelemetry/instrumentation-mysql" "0.41.0" + "@opentelemetry/instrumentation-mysql2" "0.41.0" + "@opentelemetry/instrumentation-nestjs-core" "0.40.0" + "@opentelemetry/instrumentation-pg" "0.44.0" + "@opentelemetry/instrumentation-redis-4" "0.42.0" + "@opentelemetry/instrumentation-undici" "0.6.0" + "@opentelemetry/resources" "^1.26.0" + "@opentelemetry/sdk-trace-base" "^1.26.0" + "@opentelemetry/semantic-conventions" "^1.27.0" + "@prisma/instrumentation" "5.19.1" + "@sentry/core" "8.32.0" + "@sentry/opentelemetry" "8.32.0" + "@sentry/types" "8.32.0" + "@sentry/utils" "8.32.0" + import-in-the-middle "^1.11.0" + +"@sentry/opentelemetry@8.29.0": + version "8.29.0" + resolved "https://registry.yarnpkg.com/@sentry/opentelemetry/-/opentelemetry-8.29.0.tgz#6ae54c640155925fc42ac86f37d125f9bb983794" + integrity sha512-MtfjDMUuKFYlyw9hZohp9xnphz+6QosyHb2zCV3e/fANoA53FDxmg/Co7haMohUCiOwwJPytUmSQQaP0nyL2Uw== + dependencies: + "@sentry/core" "8.29.0" + "@sentry/types" "8.29.0" + "@sentry/utils" "8.29.0" + +"@sentry/opentelemetry@8.32.0": + version "8.32.0" + resolved "https://registry.yarnpkg.com/@sentry/opentelemetry/-/opentelemetry-8.32.0.tgz#4af02c17102635e4b34942d2e82d3620ddb7d95a" + integrity sha512-YCD8EnwJJ2ab3zWWtu5VrvHP/6Ss6GGQH0TYx2cfeGG3c0wTA/5zYx9JR4i3hUtOh1pifN34HlY0yyQHD4yctg== + dependencies: + "@sentry/core" "8.32.0" + "@sentry/types" "8.32.0" + "@sentry/utils" "8.32.0" + +"@sentry/profiling-node@8.32.0": + version "8.32.0" + resolved "https://registry.yarnpkg.com/@sentry/profiling-node/-/profiling-node-8.32.0.tgz#cb4bf0512dc7a6f0a9058529f3c4dbb8963a597d" + integrity sha512-wKE2JAvDM3DjVNFKd2YLzwhXFS3SurLxDPpvA1EjMQ9Me7sR5ssO9jFn3e6et5oT3e3EzGDyTfbrJ81BNQuZhQ== + dependencies: + "@sentry/core" "8.32.0" + "@sentry/node" "8.32.0" + "@sentry/types" "8.32.0" + "@sentry/utils" "8.32.0" + detect-libc "^2.0.2" + node-abi "^3.61.0" "@sentry/tracing@^7.84.0": version "7.99.0" @@ -322,22 +718,20 @@ dependencies: "@sentry-internal/tracing" "7.99.0" -"@sentry/types@7.84.0": - version "7.84.0" - resolved "https://registry.yarnpkg.com/@sentry/types/-/types-7.84.0.tgz#e8db86c36c61659c3b2558f0aa8b6a073a756117" - integrity sha512-VqGLIF3JOUrk7yIXjLXJvAORkZL1e3dDX0Q1okRehwyt/5CRE+mdUTeJZkBo9P9mBwgMyvtwklzOGGrzjb4eMA== - "@sentry/types@7.99.0": version "7.99.0" resolved "https://registry.npmjs.org/@sentry/types/-/types-7.99.0.tgz" integrity sha512-94qwOw4w40sAs5mCmzcGyj8ZUu/KhnWnuMZARRq96k+SjRW/tHFAOlIdnFSrt3BLPvSOK7R3bVAskZQ0N4FTmA== -"@sentry/utils@7.84.0": - version "7.84.0" - resolved "https://registry.yarnpkg.com/@sentry/utils/-/utils-7.84.0.tgz#32861d922fa31e86dd2863a1d9dfc5a369e98952" - integrity sha512-qdUVuxnRBvaf05AU+28R+xYtZmi/Ymf8os3Njq9g4XuA+QEkZLbzmIpRK5W9Ja7vUtjOeg29Xgg43A8znde9LQ== - dependencies: - "@sentry/types" "7.84.0" +"@sentry/types@8.29.0": + version "8.29.0" + resolved "https://registry.yarnpkg.com/@sentry/types/-/types-8.29.0.tgz#c19e43524b8e7766028f4da8f02eddcc33518541" + integrity sha512-j4gX3ctzgD4xVWllXAhm6M+kHFEvrFoUPFq60X/pgkjsWCocGuhtNfB0rW43ICG8hCnlz8IYl7O7b8V8qY7SPg== + +"@sentry/types@8.32.0": + version "8.32.0" + resolved "https://registry.yarnpkg.com/@sentry/types/-/types-8.32.0.tgz#dfd8aa9449a5f793b9c720888819a74a11f1790d" + integrity sha512-hxckvN2MzS5SgGDgVQ0/QpZXk13Vrq4BtZLwXhPhyeTmZtUiUfWvcL5TFQqLinfKdTKPe9q2MxeAJ0D4LalhMg== "@sentry/utils@7.99.0": version "7.99.0" @@ -346,6 +740,20 @@ dependencies: "@sentry/types" "7.99.0" +"@sentry/utils@8.29.0": + version "8.29.0" + resolved "https://registry.yarnpkg.com/@sentry/utils/-/utils-8.29.0.tgz#d4a36643369e30ba62ef8f40f149420a100f64bb" + integrity sha512-nb93/m3SjQChQJFqJj3oNW3Rz/12yrT7jypTCire3c2hpYWG2uR5n8VY9UUMTA6HLNvdom6tckK7p3bXGXlF0w== + dependencies: + "@sentry/types" "8.29.0" + +"@sentry/utils@8.32.0": + version "8.32.0" + resolved "https://registry.yarnpkg.com/@sentry/utils/-/utils-8.32.0.tgz#99a4298ee8fd7208ade470931c19d71c571dfce8" + integrity sha512-t1WVERhgmYURxbBj9J4/H2P2X+VKqm7B3ce9iQyrZbdf5NekhcU4jHIecPUWCPHjQkFIqkVTorqeBmDTlg/UmQ== + dependencies: + "@sentry/types" "8.32.0" + "@tsconfig/node10@^1.0.7": version "1.0.9" resolved "https://registry.npmjs.org/@tsconfig/node10/-/node10-1.0.9.tgz" @@ -386,6 +794,13 @@ dependencies: "@types/node" "*" +"@types/connect@3.4.36": + version "3.4.36" + resolved "https://registry.yarnpkg.com/@types/connect/-/connect-3.4.36.tgz#e511558c15a39cb29bd5357eebb57bd1459cd1ab" + integrity sha512-P63Zd/JUGq+PdrM1lv0Wv5SBYeA2+CORvbrXbngriYY0jzLUWfQMQQxOhjONEz/wlHOAxOdY7CY65rgQdTjq2w== + dependencies: + "@types/node" "*" + "@types/cors@^2.8.17": version "2.8.17" resolved "https://registry.npmjs.org/@types/cors/-/cors-2.8.17.tgz" @@ -457,6 +872,13 @@ dependencies: "@types/node" "*" +"@types/mysql@2.15.26": + version "2.15.26" + resolved "https://registry.yarnpkg.com/@types/mysql/-/mysql-2.15.26.tgz#f0de1484b9e2354d587e7d2bd17a873cc8300836" + integrity sha512-DSLCOXhkvfS5WNNPbfn2KdICAmk8lLc+/PNvnPnF7gOdMZCxopXduqv0OQ13y/yA/zXTSikZZqVgybUxOEg6YQ== + dependencies: + "@types/node" "*" + "@types/node@*": version "20.11.13" resolved "https://registry.npmjs.org/@types/node/-/node-20.11.13.tgz" @@ -469,6 +891,31 @@ resolved "https://registry.npmjs.org/@types/parse-json/-/parse-json-4.0.2.tgz" integrity sha512-dISoDXWWQwUquiKsyZ4Ng+HX2KsPL7LyHKHQwgGFEA3IaKac4Obd+h2a/a6waisAoepJlBcx9paWqjA8/HVjCw== +"@types/pg-pool@2.0.6": + version "2.0.6" + resolved "https://registry.yarnpkg.com/@types/pg-pool/-/pg-pool-2.0.6.tgz#1376d9dc5aec4bb2ec67ce28d7e9858227403c77" + integrity sha512-TaAUE5rq2VQYxab5Ts7WZhKNmuN78Q6PiFonTDdpbx8a1H0M1vhy3rhiMjl+e2iHmogyMw7jZF4FrE6eJUy5HQ== + dependencies: + "@types/pg" "*" + +"@types/pg@*": + version "8.11.10" + resolved "https://registry.yarnpkg.com/@types/pg/-/pg-8.11.10.tgz#b8fb2b2b759d452fe3ec182beadd382563b63291" + integrity sha512-LczQUW4dbOQzsH2RQ5qoeJ6qJPdrcM/DcMLoqWQkMLMsq83J5lAX3LXjdkWdpscFy67JSOWDnh7Ny/sPFykmkg== + dependencies: + "@types/node" "*" + pg-protocol "*" + pg-types "^4.0.1" + +"@types/pg@8.6.1": + version "8.6.1" + resolved "https://registry.yarnpkg.com/@types/pg/-/pg-8.6.1.tgz#099450b8dc977e8197a44f5229cedef95c8747f9" + integrity sha512-1Kc4oAGzAl7uqUStZCDvaLFqZrW9qWSjXOmBfdgyBP5La7Us6Mg4GBvRlSoaZMhQF/zSj1C8CtKMBkoiT8eL8w== + dependencies: + "@types/node" "*" + pg-protocol "*" + pg-types "^2.2.0" + "@types/pg@^8.10.9": version "8.11.0" resolved "https://registry.npmjs.org/@types/pg/-/pg-8.11.0.tgz" @@ -510,6 +957,11 @@ "@types/mime" "*" "@types/node" "*" +"@types/shimmer@^1.0.2", "@types/shimmer@^1.2.0": + version "1.2.0" + resolved "https://registry.yarnpkg.com/@types/shimmer/-/shimmer-1.2.0.tgz#9b706af96fa06416828842397a70dfbbf1c14ded" + integrity sha512-UE7oxhQLLd9gub6JKIAhDq06T0F6FnztwMNRvYgjeQSBeMc1ZG/tA47EwfduvkuQS8apbkM/lpLpWsaCeYsXVg== + "@types/strip-bom@^3.0.0": version "3.0.0" resolved "https://registry.npmjs.org/@types/strip-bom/-/strip-bom-3.0.0.tgz" @@ -627,6 +1079,16 @@ accepts@~1.3.8: mime-types "~2.1.34" negotiator "0.6.3" +acorn-import-assertions@^1.9.0: + version "1.9.0" + resolved "https://registry.yarnpkg.com/acorn-import-assertions/-/acorn-import-assertions-1.9.0.tgz#507276249d684797c84e0734ef84860334cfb1ac" + integrity sha512-cmMwop9x+8KFhxvKrKfPYmN6/pKTYYHBqLa0DfvVZcKMJWNyWLnaqND7dx/qn66R7ewM1UX5XMaDVP5wlVTaVA== + +acorn-import-attributes@^1.9.5: + version "1.9.5" + resolved "https://registry.yarnpkg.com/acorn-import-attributes/-/acorn-import-attributes-1.9.5.tgz#7eb1557b1ba05ef18b5ed0ec67591bfab04688ef" + integrity sha512-n02Vykv5uA3eHGM/Z2dQrcD56kL8TyDb2p1+0P83PClMnC/nc+anbQRhIOWnSq4Ke/KvDPrY3C9hDtC/A3eHnQ== + acorn-jsx@^5.3.2: version "5.3.2" resolved "https://registry.npmjs.org/acorn-jsx/-/acorn-jsx-5.3.2.tgz" @@ -642,12 +1104,10 @@ acorn@^8.4.1, acorn@^8.9.0: resolved "https://registry.npmjs.org/acorn/-/acorn-8.11.3.tgz" integrity sha512-Y9rRfJG5jcKOE0CLisYbojUjIrIEE7AGMzA/Sm4BslANhbS+cDMpgBdcPT91oJ7OuJ9hYJBx59RjbhxVnrF8Xg== -agent-base@6: - version "6.0.2" - resolved "https://registry.yarnpkg.com/agent-base/-/agent-base-6.0.2.tgz#49fff58577cfee3f37176feab4c22e00f86d7f77" - integrity sha512-RZNwNclF7+MS/8bDg70amg32dyeZGZxiDuQmZxKLAlQjr3jGyLx+4Kkk58UO7D2QdgFIQCovuSuZESne6RG6XQ== - dependencies: - debug "4" +acorn@^8.8.2: + version "8.12.1" + resolved "https://registry.yarnpkg.com/acorn/-/acorn-8.12.1.tgz#71616bdccbe25e27a54439e0046e89ca76df2248" + integrity sha512-tcpGyI9zbizT9JbV6oYE477V6mTlXvvi0T0G3SNIYE2apm/G5huBa1+K89VGeovbg+jycCrfhl3ADxErOuO6Jg== aggregate-error@^3.0.0: version "3.1.0" @@ -1049,6 +1509,11 @@ chokidar@3.5.3, chokidar@^3.5.1, chokidar@^3.5.2: optionalDependencies: fsevents "~2.3.2" +cjs-module-lexer@^1.2.2: + version "1.4.1" + resolved "https://registry.yarnpkg.com/cjs-module-lexer/-/cjs-module-lexer-1.4.1.tgz#707413784dbb3a72aa11c2f2b042a0bef4004170" + integrity sha512-cuSVIHi9/9E/+821Qjdvngor+xpnlwnuwIyZOaLmHBVdXL+gP+I6QQB9VkO7RI77YIcTV+S1W9AreJ5eN63JBA== + clean-stack@^2.0.0: version "2.2.0" resolved "https://registry.npmjs.org/clean-stack/-/clean-stack-2.2.0.tgz" @@ -1207,13 +1672,6 @@ debug@2.6.9: dependencies: ms "2.0.0" -debug@4: - version "4.3.7" - resolved "https://registry.yarnpkg.com/debug/-/debug-4.3.7.tgz#87945b4151a011d76d95a198d7111c865c360a52" - integrity sha512-Er2nc/H7RrMXZBFCEim6TCmMk02Z8vLC2Rbi1KEBggpo0fS6l0S1nnapwmIi3yW/+GOJap1Krg4w0Hg80oCqgQ== - dependencies: - ms "^2.1.3" - debug@4.3.4, debug@^4, debug@^4.3.1, debug@^4.3.2, debug@^4.3.4: version "4.3.4" resolved "https://registry.npmjs.org/debug/-/debug-4.3.4.tgz" @@ -1228,6 +1686,13 @@ debug@^3.2.7: dependencies: ms "^2.1.1" +debug@^4.3.5: + version "4.3.7" + resolved "https://registry.yarnpkg.com/debug/-/debug-4.3.7.tgz#87945b4151a011d76d95a198d7111c865c360a52" + integrity sha512-Er2nc/H7RrMXZBFCEim6TCmMk02Z8vLC2Rbi1KEBggpo0fS6l0S1nnapwmIi3yW/+GOJap1Krg4w0Hg80oCqgQ== + dependencies: + ms "^2.1.3" + decamelize@^4.0.0: version "4.0.0" resolved "https://registry.npmjs.org/decamelize/-/decamelize-4.0.0.tgz" @@ -1307,6 +1772,11 @@ detect-libc@^2.0.1: resolved "https://registry.npmjs.org/detect-libc/-/detect-libc-2.0.2.tgz" integrity sha512-UX6sGumvvqSaXgdKGUsgZWqcUyIXZ/vZTrlRT/iobiKhGL0zL4d3osHj3uqllWJK+i+sixDS/3COVEOFbupFyw== +detect-libc@^2.0.2: + version "2.0.3" + resolved "https://registry.yarnpkg.com/detect-libc/-/detect-libc-2.0.3.tgz#f0cd503b40f9939b894697d19ad50895e30cf700" + integrity sha512-bwy0MGW55bG41VqxxypOsdSdGqLwXPI/focwgTYCFMbdUiBAxLg9CFzG08sz2aqzknwiX7Hkl0bQENjg8iLByw== + diff@5.0.0: version "5.0.0" resolved "https://registry.npmjs.org/diff/-/diff-5.0.0.tgz" @@ -2171,14 +2641,6 @@ http-errors@2.0.0: statuses "2.0.1" toidentifier "1.0.1" -https-proxy-agent@^5.0.0: - version "5.0.1" - resolved "https://registry.yarnpkg.com/https-proxy-agent/-/https-proxy-agent-5.0.1.tgz#c59ef224a04fe8b754f3db0063a25ea30d0005d6" - integrity sha512-dFcAjpTQFgoLMzC2VwU+C/CbS7uRL0lWmxDITmqm7C+7F0Odmj6s9l6alZc6AELXhrnggM2CeWSXHGOdX2YtwA== - dependencies: - agent-base "6" - debug "4" - human-signals@^1.1.1: version "1.1.1" resolved "https://registry.npmjs.org/human-signals/-/human-signals-1.1.1.tgz" @@ -2219,6 +2681,26 @@ import-fresh@^3.2.1: parent-module "^1.0.0" resolve-from "^4.0.0" +import-in-the-middle@1.7.1: + version "1.7.1" + resolved "https://registry.yarnpkg.com/import-in-the-middle/-/import-in-the-middle-1.7.1.tgz#3e111ff79c639d0bde459bd7ba29dd9fdf357364" + integrity sha512-1LrZPDtW+atAxH42S6288qyDFNQ2YCty+2mxEPRtfazH6Z5QwkaBSTS2ods7hnVJioF6rkRfNoA6A/MstpFXLg== + dependencies: + acorn "^8.8.2" + acorn-import-assertions "^1.9.0" + cjs-module-lexer "^1.2.2" + module-details-from-path "^1.0.3" + +import-in-the-middle@^1.11.0, import-in-the-middle@^1.8.1: + version "1.11.2" + resolved "https://registry.yarnpkg.com/import-in-the-middle/-/import-in-the-middle-1.11.2.tgz#dd848e72b63ca6cd7c34df8b8d97fc9baee6174f" + integrity sha512-gK6Rr6EykBcc6cVWRSBR5TWf8nn6hZMYSRYqCcHa0l0d1fPK7JSYo6+Mlmck76jIX9aL/IZ71c06U2VpFwl1zA== + dependencies: + acorn "^8.8.2" + acorn-import-attributes "^1.9.5" + cjs-module-lexer "^1.2.2" + module-details-from-path "^1.0.3" + imurmurhash@^0.1.4: version "0.1.4" resolved "https://registry.npmjs.org/imurmurhash/-/imurmurhash-0.1.4.tgz" @@ -2854,6 +3336,11 @@ mocha@^10.2.0: yargs-parser "20.2.4" yargs-unparser "2.0.0" +module-details-from-path@^1.0.3: + version "1.0.3" + resolved "https://registry.yarnpkg.com/module-details-from-path/-/module-details-from-path-1.0.3.tgz#114c949673e2a8a35e9d35788527aa37b679da2b" + integrity sha512-ySViT69/76t8VhE1xXHK6Ch4NcDd26gx0MzKXLO+F7NOtnqH68d9zF94nT8ZWSxXh8ELOERsnJO/sWt1xZYw5A== + morgan@^1.10.0: version "1.10.0" resolved "https://registry.npmjs.org/morgan/-/morgan-1.10.0.tgz" @@ -2905,6 +3392,13 @@ nice-try@^1.0.4: resolved "https://registry.npmjs.org/nice-try/-/nice-try-1.0.5.tgz" integrity sha512-1nh45deeb5olNY7eX82BkPO7SSxR5SSYJiPTrTdFUVYwAl8CKMA5N9PjTYkHiRjisVcxcQ1HXdLhx2qxxJzLNQ== +node-abi@^3.61.0: + version "3.68.0" + resolved "https://registry.yarnpkg.com/node-abi/-/node-abi-3.68.0.tgz#8f37fb02ecf4f43ebe694090dcb52e0c4cc4ba25" + integrity sha512-7vbj10trelExNjFSBm5kTvZXXa7pZyKWx9RCKIyqe6I9Ev3IzGpQoqBP3a+cOdxY+pWj6VkP28n/2wWysBHD/A== + dependencies: + semver "^7.3.5" + node-domexception@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/node-domexception/-/node-domexception-1.0.0.tgz#6888db46a1f71c0b76b3f7555016b63fe64766e5" @@ -3090,6 +3584,14 @@ onetime@^5.1.0, onetime@^5.1.2: dependencies: mimic-fn "^2.1.0" +opentelemetry-instrumentation-fetch-node@1.2.3: + version "1.2.3" + resolved "https://registry.yarnpkg.com/opentelemetry-instrumentation-fetch-node/-/opentelemetry-instrumentation-fetch-node-1.2.3.tgz#beb24048bdccb1943ba2a5bbadca68020e448ea7" + integrity sha512-Qb11T7KvoCevMaSeuamcLsAD+pZnavkhDnlVL0kRozfhl42dKG5Q3anUklAFKJZjY3twLR+BnRa6DlwwkIE/+A== + dependencies: + "@opentelemetry/instrumentation" "^0.46.0" + "@opentelemetry/semantic-conventions" "^1.17.0" + optionator@^0.9.3: version "0.9.3" resolved "https://registry.npmjs.org/optionator/-/optionator-0.9.3.tgz" @@ -3262,9 +3764,9 @@ pg-protocol@*, pg-protocol@^1.6.0: resolved "https://registry.npmjs.org/pg-protocol/-/pg-protocol-1.6.0.tgz" integrity sha512-M+PDm637OY5WM307051+bsDia5Xej6d9IR4GwJse1qA1DIhiKlksvrneZOYQq42OM+spubpcNYEo2FcKQrDk+Q== -pg-types@^2.1.0: +pg-types@^2.1.0, pg-types@^2.2.0: version "2.2.0" - resolved "https://registry.npmjs.org/pg-types/-/pg-types-2.2.0.tgz" + resolved "https://registry.yarnpkg.com/pg-types/-/pg-types-2.2.0.tgz#2d0250d636454f7cfa3b6ae0382fdfa8063254a3" integrity sha512-qTAAlrEsl8s4OiEQY69wDvcMIdQN6wdz5ojQiOy6YRMuynxenON0O5oCpJI6lshc6scgAY8qvJ2On/p+CXY0GA== dependencies: pg-int8 "1.0.1" @@ -3622,14 +4124,23 @@ require-directory@^2.1.1: resolved "https://registry.npmjs.org/require-directory/-/require-directory-2.1.1.tgz" integrity sha512-fGxEI7+wsG9xrvdjsrlmL22OMTTiHRwAMroiEeMgq8gzoLC/PQr7RsRDSTLUg/bZAZtF+TVIkHc6/4RIKrui+Q== +require-in-the-middle@^7.1.1: + version "7.4.0" + resolved "https://registry.yarnpkg.com/require-in-the-middle/-/require-in-the-middle-7.4.0.tgz#606977820d4b5f9be75e5a108ce34cfed25b3bb4" + integrity sha512-X34iHADNbNDfr6OTStIAHWSAvvKQRYgLO6duASaVf7J2VA3lvmNYboAHOuLC2huav1IwgZJtyEcJCKVzFxOSMQ== + dependencies: + debug "^4.3.5" + module-details-from-path "^1.0.3" + resolve "^1.22.8" + resolve-from@^4.0.0: version "4.0.0" resolved "https://registry.npmjs.org/resolve-from/-/resolve-from-4.0.0.tgz" integrity sha512-pb/MYmXstAkysRFx8piNI1tGFNQIFA3vkE3Gq4EuA1dF6gHp/+vgZqsCGJapvy8N3Q+4o7FwvquPJcnZ7RYy4g== -resolve@^1.0.0, resolve@^1.10.0, resolve@^1.22.4: +resolve@^1.0.0, resolve@^1.10.0, resolve@^1.22.4, resolve@^1.22.8: version "1.22.8" - resolved "https://registry.npmjs.org/resolve/-/resolve-1.22.8.tgz" + resolved "https://registry.yarnpkg.com/resolve/-/resolve-1.22.8.tgz#b6c87a9f2aa06dfab52e3d70ac8cde321fa5a48d" integrity sha512-oKWePCxqpd6FlLvGV1VU0x7bkPmmCNolxzjMf4NczoDnQcIWrAF+cPtZn5i6n+RfD2d9i0tzpKnG6Yk168yIyw== dependencies: is-core-module "^2.13.0" @@ -3753,6 +4264,11 @@ semver@^6.3.1: resolved "https://registry.npmjs.org/semver/-/semver-6.3.1.tgz" integrity sha512-BR7VvDCVHO+q2xBEWskxS6DJE1qRnb7DxzUrogb71CWoSficBxYsiAGd+Kl0mmq/MprG9yArRkyrQxTO6XjMzA== +semver@^7.3.5, semver@^7.5.2: + version "7.6.3" + resolved "https://registry.yarnpkg.com/semver/-/semver-7.6.3.tgz#980f7b5550bc175fb4dc09403085627f9eb33143" + integrity sha512-oVekP1cKtI+CTDvHWYFUcMtsK/00wmAEfyqKfNdARm8u1wNVhSgaX7A8d4UuIlUI5e84iEwOhs7ZPYRmzU9U6A== + semver@^7.5.3, semver@^7.5.4: version "7.5.4" resolved "https://registry.npmjs.org/semver/-/semver-7.5.4.tgz" @@ -3855,6 +4371,11 @@ shell-quote@^1.6.1: resolved "https://registry.npmjs.org/shell-quote/-/shell-quote-1.8.1.tgz" integrity sha512-6j1W9l1iAs/4xYBI1SYOVZyFcCis9b4KCLQ8fgAGG07QvzaRLVVRQvAy85yNmmZSjYjg4MWh4gNvlPujU/5LpA== +shimmer@^1.2.1: + version "1.2.1" + resolved "https://registry.yarnpkg.com/shimmer/-/shimmer-1.2.1.tgz#610859f7de327b587efebf501fb43117f9aff337" + integrity sha512-sQTKC1Re/rM6XyFM6fIAGHRPVGvyXfgzIDvzoq608vM+jeyVD0Tu1E6Np0Kc2zAIFWIj963V2800iF/9LPieQw== + side-channel@^1.0.4: version "1.0.4" resolved "https://registry.npmjs.org/side-channel/-/side-channel-1.0.4.tgz" From 8558d1037c361ef9dbe4619c768c07dc6981e1c3 Mon Sep 17 00:00:00 2001 From: shadrach Date: Tue, 8 Oct 2024 09:30:44 -0500 Subject: [PATCH 75/81] fix logger transport --- desci-repo/src/logger.ts | 32 +++++++++++++------------------- 1 file changed, 13 insertions(+), 19 deletions(-) diff --git a/desci-repo/src/logger.ts b/desci-repo/src/logger.ts index d00ad9d6b..2589555a6 100644 --- a/desci-repo/src/logger.ts +++ b/desci-repo/src/logger.ts @@ -43,7 +43,7 @@ function logMethodHooks(inputArgs, method) { callerFilePath = intermediate .split('(')[1] .split(')')[0] - .replace('file:///app/desci-server/src/', '') + .replace('file:///app/desci-repo/src/', '') .replace('file:///app/dist/', ''); } } catch (err) { @@ -89,6 +89,8 @@ function logMethodHooks(inputArgs, method) { } } +const IS_PROD = process.env.NODE_ENV === 'production'; + export const logger = pino({ level: logLevel, serializers: { @@ -97,12 +99,13 @@ export const logger = pino({ hooks: { logMethod: logMethodHooks, }, - transport: - process.env.NODE_ENV === 'production' - ? { targets: [] } - : { + ...(!IS_PROD + ? { + transport: { targets: [devTransport, fileTransport], }, + } + : {}), redact: { paths: [ 'req.headers.cookie', @@ -137,25 +140,16 @@ function omitBuffer(array) { } type RejectionPayload = { - reason: unknown, - promise: Promise, + reason: unknown; + promise: Promise; }; -const shutdownNicely = async ( - err: Error | RejectionPayload, - kind: string -): Promise => { +const shutdownNicely = async (err: Error | RejectionPayload, kind: string): Promise => { await pool.end(); logger.fatal(err, kind); process.exit(1); }; -process.on( - 'uncaughtException', - e => shutdownNicely(e, 'uncaughtException') -); +process.on('uncaughtException', (e) => shutdownNicely(e, 'uncaughtException')); -process.on( - 'unhandledRejection', - (reason, promise) => shutdownNicely({ reason, promise }, 'unhandledRejection') -); +process.on('unhandledRejection', (reason, promise) => shutdownNicely({ reason, promise }, 'unhandledRejection')); From 434005e7d27cde348240536b05311df8d38ff1ae Mon Sep 17 00:00:00 2001 From: shadrach-tayo Date: Tue, 8 Oct 2024 11:28:48 -0500 Subject: [PATCH 76/81] remove call to find and update node in repo service --- desci-repo/src/controllers/nodes/documents.ts | 30 +++++++++---------- .../src/controllers/nodes/draftCreate.ts | 1 + 2 files changed, 16 insertions(+), 15 deletions(-) diff --git a/desci-repo/src/controllers/nodes/documents.ts b/desci-repo/src/controllers/nodes/documents.ts index 3d23f3e6e..dc72aeb44 100644 --- a/desci-repo/src/controllers/nodes/documents.ts +++ b/desci-repo/src/controllers/nodes/documents.ts @@ -35,26 +35,26 @@ export const createNodeDocument = async function (req: Request, res: Response) { { message: 'Init Document', time: Date.now() }, ); - logger.info({ peerId: backendRepo.networkSubsystem.peerId, uuid }, 'Document Created'); + logger.trace({ peerId: backendRepo.networkSubsystem.peerId, uuid }, 'Document Created'); - const document = await handle.doc(); + // const document = await handle.doc(); - logger.trace({ document: !!document }, 'Document Retrieved'); + logger.trace({ handleReady: handle.isReady() }, 'Document Retrieved'); - const node = await findNodeByUuid(uuid); - logger.trace({ node }, 'Node Retrieved'); + // const node = await findNodeByUuid(uuid); + // logger.trace({ node }, 'Node Retrieved'); // await prisma.node.update({ where: { id: node.id }, data: { manifestDocumentId: handle.documentId } }); - const result = await query('UPDATE "Node" SET "manifestDocumentId" = $1 WHERE uuid = $2', [ - handle.documentId, - uuid, - ]); - - logger.trace( - { node, uuid, documentId: handle.documentId, url: handle.url, isReady: handle.isReady() }, - 'Node Updated', - ); + // const result = await query('UPDATE "Node" SET "manifestDocumentId" = $1 WHERE uuid = $2', [ + // handle.documentId, + // uuid, + // ]); + + // logger.trace( + // { node, uuid, documentId: handle.documentId, url: handle.url, isReady: handle.isReady() }, + // 'Node Updated', + // ); - logger.info({ result }, 'UPDATE DOCUMENT ID'); + // logger.info({ result }, 'UPDATE DOCUMENT ID'); res.status(200).send({ ok: true, documentId: handle.documentId, document }); diff --git a/desci-server/src/controllers/nodes/draftCreate.ts b/desci-server/src/controllers/nodes/draftCreate.ts index cc013a0a0..16d3585ab 100755 --- a/desci-server/src/controllers/nodes/draftCreate.ts +++ b/desci-server/src/controllers/nodes/draftCreate.ts @@ -129,6 +129,7 @@ export const draftCreate = async (req: Request, res: Response, next: NextFunctio const documentId = result.documentId; const document = result.document; + // attach automerge documentId to node await prisma.node.update({ where: { id: node.id }, data: { manifestDocumentId: documentId } }); logger.info({ uuid: node.uuid, documentId }, 'Automerge document created'); From 9b7b179aacb964e3003ed6e8b31372bf6520c7a2 Mon Sep 17 00:00:00 2001 From: shadrach-tayo Date: Wed, 9 Oct 2024 04:18:06 -0500 Subject: [PATCH 77/81] identify potential bottlenecks to optimize --- desci-server/src/controllers/nodes/show.ts | 12 ++++++++++-- 1 file changed, 10 insertions(+), 2 deletions(-) diff --git a/desci-server/src/controllers/nodes/show.ts b/desci-server/src/controllers/nodes/show.ts index 7e3488043..3263ff27d 100755 --- a/desci-server/src/controllers/nodes/show.ts +++ b/desci-server/src/controllers/nodes/show.ts @@ -87,12 +87,20 @@ export const show = async (req: RequestWithNode, res: Response, next: NextFuncti try { gatewayUrl = cleanupManifestUrl(gatewayUrl, req.query?.g as string); logger.trace({ gatewayUrl, uuid }, 'transforming manifest'); - (discovery as any).manifestData = transformManifestWithHistory((await axios.get(gatewayUrl)).data, discovery); + + // this can take >30s before it resolves or + // even fail after a much longer time there by causing the slow loading of nodes + // and a lot of failing `*.loggedIn` test in + (discovery as any).manifestData = transformManifestWithHistory( + (await axios.get(gatewayUrl, { timeout: 2000 })).data, + discovery, + ); // Add draft manifest document const nodeUuid = ensureUuidEndsWithDot(uuid) as NodeUuid; + // for draft nodes we can do this asynchronously on the frontend const manifest = await repoService.getDraftManifest(nodeUuid); - logger.info({ manifest }, '[SHOW API GET DRAFT MANIFEST]'); + logger.info({ manifest: !!manifest }, '[SHOW API GET DRAFT MANIFEST]'); if (manifest) (discovery as any).manifestData = transformManifestWithHistory(manifest, discovery); delete (discovery as any).restBody; From 791f76e98606bf9bc3a9174662d7f56b79a1eacb Mon Sep 17 00:00:00 2001 From: shadrach Date: Wed, 9 Oct 2024 06:33:25 -0500 Subject: [PATCH 78/81] optimize createDraft and show draft nodes api --- desci-repo/src/controllers/nodes/documents.ts | 7 +- desci-repo/src/logger.ts | 17 ++--- desci-server/src/controllers/data/retrieve.ts | 3 +- .../src/controllers/nodes/draftCreate.ts | 5 ++ desci-server/src/controllers/nodes/show.ts | 49 ++++++------- desci-server/src/services/nodeManager.ts | 71 ++++++++++++++++++- desci-server/src/services/repoService.ts | 19 +++-- 7 files changed, 127 insertions(+), 44 deletions(-) diff --git a/desci-repo/src/controllers/nodes/documents.ts b/desci-repo/src/controllers/nodes/documents.ts index dc72aeb44..89df8be4a 100644 --- a/desci-repo/src/controllers/nodes/documents.ts +++ b/desci-repo/src/controllers/nodes/documents.ts @@ -37,7 +37,7 @@ export const createNodeDocument = async function (req: Request, res: Response) { logger.trace({ peerId: backendRepo.networkSubsystem.peerId, uuid }, 'Document Created'); - // const document = await handle.doc(); + const document = await handle.doc(); logger.trace({ handleReady: handle.isReady() }, 'Document Retrieved'); @@ -68,15 +68,16 @@ export const createNodeDocument = async function (req: Request, res: Response) { export const getLatestNodeManifest = async function (req: Request, res: Response) { const logger = parentLogger.child({ module: 'getLatestNodeManifest', params: req.params }); logger.trace('getLatestNodeManifest'); + const { uuid, documentId } = req.params; + // todo: add support for documentId params and skip querying node try { - if (!req.params.uuid) { + if (!uuid) { res.status(400).send({ ok: false, message: 'Invalid data' }); logger.trace('No UUID FOUND'); return; } - const { uuid } = req.params; const node = await findNodeByUuid(ensureUuidEndsWithDot(uuid)); logger.trace({ node }, 'Retrieve Node'); diff --git a/desci-repo/src/logger.ts b/desci-repo/src/logger.ts index 2589555a6..22ede5be2 100644 --- a/desci-repo/src/logger.ts +++ b/desci-repo/src/logger.ts @@ -90,8 +90,16 @@ function logMethodHooks(inputArgs, method) { } const IS_PROD = process.env.NODE_ENV === 'production'; - +const transport = { + ...(!IS_PROD && { + transport: { + targets: [devTransport, fileTransport], + }, + }), +}; +console.log('[transport]', transport); export const logger = pino({ + ...transport, level: logLevel, serializers: { files: omitBuffer, @@ -99,13 +107,6 @@ export const logger = pino({ hooks: { logMethod: logMethodHooks, }, - ...(!IS_PROD - ? { - transport: { - targets: [devTransport, fileTransport], - }, - } - : {}), redact: { paths: [ 'req.headers.cookie', diff --git a/desci-server/src/controllers/data/retrieve.ts b/desci-server/src/controllers/data/retrieve.ts index 372157ab6..245fb6816 100644 --- a/desci-server/src/controllers/data/retrieve.ts +++ b/desci-server/src/controllers/data/retrieve.ts @@ -14,6 +14,7 @@ import redisClient, { getOrCache } from '../../redisClient.js'; import { getLatestDriveTime } from '../../services/draftTrees.js'; import { getDatasetTar } from '../../services/ipfs.js'; import { NodeUuid, getLatestManifestFromNode } from '../../services/manifestRepo.js'; +import { showNodeDraftManifest } from '../../services/nodeManager.js'; import { getTreeAndFill, getTreeAndFillDeprecated } from '../../utils/driveUtils.js'; import { cleanupManifestUrl } from '../../utils/manifest.js'; import { ensureUuidEndsWithDot } from '../../utils.js'; @@ -94,7 +95,7 @@ export const retrieveTree = async (req: Request, res: Response30s before it resolves or - // even fail after a much longer time there by causing the slow loading of nodes - // and a lot of failing `*.loggedIn` test in - (discovery as any).manifestData = transformManifestWithHistory( - (await axios.get(gatewayUrl, { timeout: 2000 })).data, - discovery, - ); - // Add draft manifest document - const nodeUuid = ensureUuidEndsWithDot(uuid) as NodeUuid; - // for draft nodes we can do this asynchronously on the frontend - const manifest = await repoService.getDraftManifest(nodeUuid); + // // this can take >30s before it resolves or + // // even fail after a much longer time there by causing the slow loading of nodes + // // and a lot of failing `*.loggedIn` test in + // (discovery as any).manifestData = transformManifestWithHistory( + // (await axios.get(gatewayUrl, { timeout: 2000 })).data, + // discovery, + // ); + // // Add draft manifest document + // const nodeUuid = ensureUuidEndsWithDot(uuid) as NodeUuid; + // // for draft nodes we can do this asynchronously on the frontend + // const manifest = await repoService.getDraftManifest(nodeUuid); - logger.info({ manifest: !!manifest }, '[SHOW API GET DRAFT MANIFEST]'); + // logger.info({ manifest: !!manifest }, '[SHOW API GET DRAFT MANIFEST]'); - if (manifest) (discovery as any).manifestData = transformManifestWithHistory(manifest, discovery); - delete (discovery as any).restBody; - logger.info({}, 'Retrive DraftManifest For /SHOW'); + // if (manifest) (discovery as any).manifestData = transformManifestWithHistory(manifest, discovery); + // delete (discovery as any).restBody; + // logger.info({}, 'Retrive DraftManifest For /SHOW'); + logger.trace('[showNodeDraftManifest]::START'); + (discovery as any).manifestData = await showNodeDraftManifest(discovery, req.query?.g as string); + logger.trace('[showNodeDraftManifest]::END'); } catch (err) { - logger.error( - { err, manifestUrl: discovery.manifestUrl, gatewayUrl }, - 'nodes/show.ts: failed to preload manifest', - ); + logger.error({ err }, 'nodes/show.ts: failed to preload manifest'); } res.send({ ...discovery }); diff --git a/desci-server/src/services/nodeManager.ts b/desci-server/src/services/nodeManager.ts index e932fa29d..129ea3e85 100644 --- a/desci-server/src/services/nodeManager.ts +++ b/desci-server/src/services/nodeManager.ts @@ -1,16 +1,21 @@ +import { DocumentId } from '@automerge/automerge-repo'; import { PdfComponent, ResearchObjectComponentType, ResearchObjectV1 } from '@desci-labs/desci-models'; -import { DataType, Prisma, PublicDataReference, User } from '@prisma/client'; +import { DataType, Node, Prisma, PublicDataReference, User } from '@prisma/client'; import axios from 'axios'; import { prisma } from '../client.js'; import { MEDIA_SERVER_API_KEY, MEDIA_SERVER_API_URL, PUBLIC_IPFS_PATH } from '../config/index.js'; +import { ForbiddenError, NodeUuid, NotFoundError } from '../internal.js'; import { logger as parentLogger } from '../logger.js'; +import { getFromCache } from '../redisClient.js'; import { getIndexedResearchObjects } from '../theGraph.js'; +import { ResearchObjectDocument } from '../types/documents.js'; import { generateDataReferences } from '../utils/dataRefTools.js'; -import { cleanupManifestUrl } from '../utils/manifest.js'; +import { cleanupManifestUrl, transformManifestWithHistory } from '../utils/manifest.js'; import { hexToCid, randomUUID64, asyncMap, ensureUuidEndsWithDot } from '../utils.js'; import { addBufferToIpfs, downloadFilesAndMakeManifest, getSizeForCid, resolveIpfsData } from './ipfs.js'; +import repoService from './repoService.js'; const ESTUARY_MIRROR_ID = 1; @@ -443,3 +448,65 @@ export const cacheNodeMetadata = async (uuid: string, manifestCid: string, versi return false; } }; + +export const showNodeDraftManifest = async (node: Node, ipfsFallbackUrl?: string) => { + logger.trace('[getNodeManifest] ==> start'); + const timeDifferenceInSeconds = getTimeDiffInSec(node.createdAt.toString()); + logger.trace( + { timeDifferenceInSeconds, uuid: node.uuid, now: Date.now(), created: node.createdAt }, + '[getNodeManifest] ==> timeDifferenceInSeconds', + ); + + const cachedDraftMetadata = (await getFromCache(`node-draft-${node.uuid}`)) as { + documentId: DocumentId; + document: ResearchObjectDocument; + }; + + logger.trace( + { timeDifferenceInSeconds, uuid: node.uuid, cachedDraftMetadata: !!cachedDraftMetadata }, + '[getNodeManifest] ==> cachedDraftMetadata', + ); + + if (timeDifferenceInSeconds <= 30 && cachedDraftMetadata) { + logger.trace( + { timeDifferenceInSeconds, uuid: node.uuid, driveClock: cachedDraftMetadata.document.driveClock }, + '[getNodeManifest] ==> Found cachedDraftetadata', + ); + return cachedDraftMetadata.document.manifest; + } + + logger.trace( + { timeDifferenceInSeconds, uuid: node.uuid, cachedDraftMetadata: !!cachedDraftMetadata }, + '[getNodeManifest] ==> Fallback to repoService.getDraftManifest', + ); + // Add draft manifest document + const nodeUuid = ensureUuidEndsWithDot(node.uuid) as NodeUuid; + // for draft nodes we can do this asynchronously on the frontend + const manifest = await repoService.getDraftManifest(nodeUuid); + + logger.trace({ nodeUuid, manifestFound: !!manifest }, '[getNodeManifest] ==> repoService.getDraftManifest'); + + if (manifest) return manifest; + + logger.trace( + { uuid: node.uuid, cid: node.manifestUrl, ipfsFallbackUrl, timeout: 5000 }, + '[getNodeManifest] ==> Fallback to IPFS Call', + ); + const gatewayUrl = cleanupManifestUrl(node.manifestUrl, ipfsFallbackUrl); + const data = transformManifestWithHistory((await axios.get(gatewayUrl, { timeout: 5000 })).data, node); + + logger.trace( + { uuid: node.uuid, cid: node.manifestUrl, ipfsFallbackUrl, manifest: !!data }, + '[getNodeManifest] ==> Found manifest on IPFS', + ); + + logger.trace('[getNodeManifest] ==> end'); + return data; +}; + +const getTimeDiffInSec = (date: string) => { + const now = Date.now(); + const start = new Date(date).getTime(); + + return (now - start) / 1000; +}; diff --git a/desci-server/src/services/repoService.ts b/desci-server/src/services/repoService.ts index ea29138ca..0bce51e55 100644 --- a/desci-server/src/services/repoService.ts +++ b/desci-server/src/services/repoService.ts @@ -1,6 +1,6 @@ import { DocumentId } from '@automerge/automerge-repo'; import { ResearchObjectV1, ManifestActions } from '@desci-labs/desci-models'; -import axios, { AxiosInstance } from 'axios'; +import axios, { AxiosError, AxiosInstance } from 'axios'; import { als, logger as parentLogger } from '../logger.js'; import { ResearchObjectDocument } from '../types/documents.js'; @@ -17,6 +17,9 @@ class RepoService { baseUrl: string; + defaultTimeoutInMilliseconds: 5000; + timeoutErrorMessage = 'Timeout: Call to Repo service timed out'; + constructor() { if (!process.env.REPO_SERVICE_SECRET_KEY || !process.env.REPO_SERVER_URL) throw new Error('[REPO SERVICE]: env.REPO_SERVER_URL or env.REPO_SERVICE_SECRET_KEY missing'); @@ -97,7 +100,7 @@ class RepoService { } } - async getDraftDocument(arg: { uuid: NodeUuid }) { + async getDraftDocument(arg: { uuid: NodeUuid; timeout?: number }) { if (!arg.uuid) { logger.warn({ arg }, 'Attempt to retrieve draft manifest for empty UUID'); return null; @@ -110,6 +113,8 @@ class RepoService { headers: { 'x-api-remote-traceid': (als.getStore() as any)?.traceId, }, + timeout: arg.timeout ?? this.defaultTimeoutInMilliseconds, + timeoutErrorMessage: this.timeoutErrorMessage, }, ); if (response.status === 200 && response.data.ok) { @@ -118,17 +123,19 @@ class RepoService { return null; } } catch (err) { + const error = err as AxiosError; + if (error?.code === 'ECONNABORTED' || error?.message?.toLowerCase().includes('timeout')) { + logger.error({ error }, 'REPO_SERVICE_CALL_TIMEOUT'); + } logger.error({ err }, 'GET Draft Document Error'); return null; } } - async getDraftManifest(uuid: NodeUuid) { + async getDraftManifest(uuid: NodeUuid, timeout?: number) { logger.info({ uuid }, 'Retrieve Draft Document'); - // try {} catch (err) {} - // uuid = ensureUuidEndsWithDot(uuid) as NodeUuid; try { - const response = await this.getDraftDocument({ uuid }); + const response = await this.getDraftDocument({ uuid, timeout }); return response ? response.manifest : null; } catch (err) { logger.error({ err }, 'GET Draft manifest Error'); From 60739180a2581038fc2fba6ea696c5028f4891f7 Mon Sep 17 00:00:00 2001 From: shadrach Date: Wed, 9 Oct 2024 07:28:06 -0500 Subject: [PATCH 79/81] optimize all calls and apis to getDraftManifest, fast track repo latest node manifest api using documentId query param --- desci-repo/src/controllers/nodes/documents.ts | 50 +++++++++++++++---- .../src/controllers/communities/util.ts | 5 +- desci-server/src/controllers/data/rename.ts | 10 +++- .../src/controllers/nodes/bookmarks/index.ts | 14 ++---- .../src/controllers/nodes/draftUpdate.ts | 5 +- .../src/controllers/nodes/prepublish.ts | 5 +- .../src/controllers/nodes/sharedNodes.ts | 39 +++++++-------- .../services/data/externalUrlProcessing.ts | 4 +- desci-server/src/services/data/processing.ts | 5 +- desci-server/src/services/manifestRepo.ts | 13 +++-- desci-server/src/services/nodeManager.ts | 5 +- desci-server/src/services/repoService.ts | 18 +++++-- .../test/integration/Attestation.test.ts | 2 +- 13 files changed, 117 insertions(+), 58 deletions(-) diff --git a/desci-repo/src/controllers/nodes/documents.ts b/desci-repo/src/controllers/nodes/documents.ts index 89df8be4a..3188a8cce 100644 --- a/desci-repo/src/controllers/nodes/documents.ts +++ b/desci-repo/src/controllers/nodes/documents.ts @@ -68,10 +68,33 @@ export const createNodeDocument = async function (req: Request, res: Response) { export const getLatestNodeManifest = async function (req: Request, res: Response) { const logger = parentLogger.child({ module: 'getLatestNodeManifest', params: req.params }); logger.trace('getLatestNodeManifest'); - const { uuid, documentId } = req.params; + const { uuid } = req.params; + const { documentId } = req.query; + + const getDocument = async (documentId: DocumentId) => { + const automergeUrl = getAutomergeUrl(documentId); + const handle = backendRepo.find(automergeUrl as AutomergeUrl); + logger.trace({ uuid, automergeUrl }, 'Document Handle retrieved'); + + logger.trace({ uuid, automergeUrl }, 'Get DOCUMENT'); + const document = await handle.doc(); + logger.trace({ uuid, automergeUrl }, 'DOCUMENT Retrieved'); + return document; + }; - // todo: add support for documentId params and skip querying node try { + // todo: add support for documentId params and skip querying node + // fast track call if documentId is available + if (documentId) { + logger.trace({ documentId }, 'Fast track using documentId'); + const document = await getDocument(documentId as DocumentId); + if (document) res.status(200).send({ ok: true, document }); + logger.trace({ document: !!document }, 'Fast tracked call using documentId'); + return; + } + + // calls might never reach this place again now that documentId is + // used to fast track calls and skip database calls if (!uuid) { res.status(400).send({ ok: false, message: 'Invalid data' }); logger.trace('No UUID FOUND'); @@ -83,7 +106,7 @@ export const getLatestNodeManifest = async function (req: Request, res: Response if (!node) { logger.warn({ uuid }, `Node with uuid ${uuid} not found!`); - res.status(400).send({ ok: false, message: `Node with uuid ${uuid} not found!` }); + res.status(404).send({ ok: false, message: `Node with uuid ${uuid} not found!` }); return; } @@ -92,15 +115,22 @@ export const getLatestNodeManifest = async function (req: Request, res: Response 'Node manifestDocumentId', ); - const automergeUrl = getAutomergeUrl(node.manifestDocumentId as DocumentId); - const handle = backendRepo.find(automergeUrl as AutomergeUrl); - logger.trace({ uuid, automergeUrl }, 'Document Handle retrieved'); + // const automergeUrl = getAutomergeUrl(node.manifestDocumentId as DocumentId); + // const handle = backendRepo.find(automergeUrl as AutomergeUrl); + // logger.trace({ uuid, automergeUrl }, 'Document Handle retrieved'); - logger.trace({ uuid, automergeUrl }, 'Get DOCUMENT'); - const document = await handle.doc(); - logger.trace({ uuid, automergeUrl }, 'DOCUMENT Retrieved'); + // logger.trace({ uuid, automergeUrl }, 'Get DOCUMENT'); + // const document = await handle.doc(); + // logger.trace({ uuid, automergeUrl }, 'DOCUMENT Retrieved'); + + if (!node.manifestDocumentId) { + res.status(404).send({ ok: false, message: `node: ${uuid} has no documentId: ${node.manifestDocumentId}` }); + return; + } + + const document = await getDocument(node.manifestDocumentId as DocumentId); - logger.info({ manifest: document?.manifest, automergeUrl }, '[getLatestNodeManifest::END]'); + logger.info({ manifest: document?.manifest }, '[getLatestNodeManifest::END]'); res.status(200).send({ ok: true, document }); } catch (err) { logger.error({ err }, 'Error'); diff --git a/desci-server/src/controllers/communities/util.ts b/desci-server/src/controllers/communities/util.ts index e57bef7bb..469be6ba7 100644 --- a/desci-server/src/controllers/communities/util.ts +++ b/desci-server/src/controllers/communities/util.ts @@ -51,7 +51,10 @@ export const resolveLatestNode = async (radar: Partial) => { logger.info({ manifest }, '[SHOW API GET LAST PUBLISHED MANIFEST]'); } catch (err) { - const manifest = await repoService.getDraftManifest(uuid as NodeUuid); + const manifest = await repoService.getDraftManifest({ + uuid: node.uuid as NodeUuid, + documentId: node.manifestDocumentId, + }); radar.manifest = manifest; logger.error({ err, manifestUrl: discovery.manifestUrl, gatewayUrl }, 'nodes/show.ts: failed to preload manifest'); } diff --git a/desci-server/src/controllers/data/rename.ts b/desci-server/src/controllers/data/rename.ts index 1737a1774..86543edb7 100644 --- a/desci-server/src/controllers/data/rename.ts +++ b/desci-server/src/controllers/data/rename.ts @@ -78,7 +78,10 @@ export const renameData = async (req: Request, res: Response { + bookmarkedNodes.map(async ({ shareId, node }) => { const latestManifest = await getLatestManifestFromNode(node); - const manifestDpid = latestManifest.dpid - ? parseInt(latestManifest.dpid.id) - : undefined; + const manifestDpid = latestManifest.dpid ? parseInt(latestManifest.dpid.id) : undefined; const published = node.versions.length > 0; return { diff --git a/desci-server/src/controllers/nodes/draftUpdate.ts b/desci-server/src/controllers/nodes/draftUpdate.ts index 859e8bda9..723c8b70f 100644 --- a/desci-server/src/controllers/nodes/draftUpdate.ts +++ b/desci-server/src/controllers/nodes/draftUpdate.ts @@ -52,7 +52,10 @@ export const draftUpdate = async (req: Request, res: Response, next: NextFunctio let manifestParsed: ResearchObjectV1; try { - manifestParsed = await repoService.getDraftManifest(node.uuid as NodeUuid); //await getDraftManifestFromUuid(node.uuid as NodeUuid); + manifestParsed = await repoService.getDraftManifest({ + uuid: node.uuid as NodeUuid, + documentId: node.manifestDocumentId, + }); //await getDraftManifestFromUuid(node.uuid as NodeUuid); } catch (e) { manifestParsed = req.body.manifest as ResearchObjectV1; } diff --git a/desci-server/src/controllers/nodes/prepublish.ts b/desci-server/src/controllers/nodes/prepublish.ts index 85222474f..f1ebeb78e 100644 --- a/desci-server/src/controllers/nodes/prepublish.ts +++ b/desci-server/src/controllers/nodes/prepublish.ts @@ -57,7 +57,10 @@ export const prepublish = async (req: RequestWithNode, res: Response & { @@ -58,13 +58,11 @@ export const listSharedNodes = async (req: ListSharedNodesRequest, res: Response uuid: true, manifestUrl: true, dpidAlias: true, + manifestDocumentId: true, // Get published versions, if any versions: { where: { - OR: [ - { transactionId: { not: null }}, - { commitId: { not: null }}, - ], + OR: [{ transactionId: { not: null } }, { commitId: { not: null } }], }, }, }, @@ -76,7 +74,7 @@ export const listSharedNodes = async (req: ListSharedNodesRequest, res: Response if (privSharedNodes?.length === 0) { return res.status(200).json({ ok: true, sharedNodes: [] }); - }; + } const nodeUuids = privSharedNodes.map((priv) => priv.node.uuid); @@ -96,21 +94,22 @@ export const listSharedNodes = async (req: ListSharedNodesRequest, res: Response verified: true, denied: true, contributorId: true, - node: { select: { uuid: true }} + node: { select: { uuid: true } }, }, }); - const contributionEntryMap = contributionEntries.reduce((acc, entry) => { - acc[entry.node.uuid] = entry; - return acc; - }, {} as Record); + const contributionEntryMap = contributionEntries.reduce( + (acc, entry) => { + acc[entry.node.uuid] = entry; + return acc; + }, + {} as Record, + ); const filledSharedNodes = await Promise.all( privSharedNodes.map(async ({ shareId, node }) => { const latestManifest = await getLatestManifestFromNode(node); - const manifestDpid = latestManifest.dpid - ? parseInt(latestManifest.dpid.id) - : undefined; + const manifestDpid = latestManifest.dpid ? parseInt(latestManifest.dpid.id) : undefined; const published = node.versions.length > 0; const contributionEntry = contributionEntryMap[node.uuid]; diff --git a/desci-server/src/services/data/externalUrlProcessing.ts b/desci-server/src/services/data/externalUrlProcessing.ts index a02b4c09f..fcc5008cd 100644 --- a/desci-server/src/services/data/externalUrlProcessing.ts +++ b/desci-server/src/services/data/externalUrlProcessing.ts @@ -274,7 +274,9 @@ export async function processExternalUrlDataToIpfs({ } } - updatedManifest = updatedManifest ?? (await repoService.getDraftManifest(ltsNode.uuid as NodeUuid)); + updatedManifest = + updatedManifest ?? + (await repoService.getDraftManifest({ uuid: ltsNode.uuid as NodeUuid, documentId: ltsNode.manifestDocumentId })); // Update existing data references, add new data references. const upserts = await updateDataReferences({ node, user, updatedManifest }); diff --git a/desci-server/src/services/data/processing.ts b/desci-server/src/services/data/processing.ts index b17c5f9bb..868b69e19 100644 --- a/desci-server/src/services/data/processing.ts +++ b/desci-server/src/services/data/processing.ts @@ -137,7 +137,10 @@ export async function processS3DataToIpfs({ }); // const ltsManifest = await getLatestManifestFromNode(ltsNode); - let updatedManifest = await repoService.getDraftManifest(ltsNode.uuid as NodeUuid); + let updatedManifest = await repoService.getDraftManifest({ + uuid: ltsNode.uuid as NodeUuid, + documentId: ltsNode.manifestDocumentId, + }); const { filteredFiles } = filterFirstNestings(pinResult.slice(0, -1)); diff --git a/desci-server/src/services/manifestRepo.ts b/desci-server/src/services/manifestRepo.ts index 1386fe8b4..31b7f368e 100644 --- a/desci-server/src/services/manifestRepo.ts +++ b/desci-server/src/services/manifestRepo.ts @@ -1,6 +1,8 @@ import { AutomergeUrl, DocumentId } from '@automerge/automerge-repo'; import { Node } from '@prisma/client'; + import { logger } from '../logger.js'; + import { getManifestFromNode } from './data/processing.js'; import repoService from './repoService.js'; @@ -10,11 +12,12 @@ export const getAutomergeUrl = (documentId: DocumentId): AutomergeUrl => { return `automerge:${documentId}` as AutomergeUrl; }; -export const getLatestManifestFromNode = async ( - node: Pick -) => { +export const getLatestManifestFromNode = async (node: Pick) => { logger.info({ uuid: node.uuid }, 'START [getLatestManifestFromNode]'); - let manifest = await repoService.getDraftManifest(node.uuid as NodeUuid); + let manifest = await repoService.getDraftManifest({ + uuid: node.uuid as NodeUuid, + documentId: node.manifestDocumentId, + }); if (!manifest) { const publishedManifest = await getManifestFromNode(node); manifest = publishedManifest.manifest; @@ -25,4 +28,4 @@ export const getLatestManifestFromNode = async ( export function assertNever(value: never) { console.error('Unknown value', value); throw Error('Not Possible'); -}; +} diff --git a/desci-server/src/services/nodeManager.ts b/desci-server/src/services/nodeManager.ts index 129ea3e85..1436da574 100644 --- a/desci-server/src/services/nodeManager.ts +++ b/desci-server/src/services/nodeManager.ts @@ -482,7 +482,10 @@ export const showNodeDraftManifest = async (node: Node, ipfsFallbackUrl?: string // Add draft manifest document const nodeUuid = ensureUuidEndsWithDot(node.uuid) as NodeUuid; // for draft nodes we can do this asynchronously on the frontend - const manifest = await repoService.getDraftManifest(nodeUuid); + const manifest = await repoService.getDraftManifest({ + uuid: nodeUuid, + documentId: node.manifestDocumentId as DocumentId, + }); logger.trace({ nodeUuid, manifestFound: !!manifest }, '[getNodeManifest] ==> repoService.getDraftManifest'); diff --git a/desci-server/src/services/repoService.ts b/desci-server/src/services/repoService.ts index 0bce51e55..35b9bf030 100644 --- a/desci-server/src/services/repoService.ts +++ b/desci-server/src/services/repoService.ts @@ -100,15 +100,15 @@ class RepoService { } } - async getDraftDocument(arg: { uuid: NodeUuid; timeout?: number }) { - if (!arg.uuid) { + async getDraftDocument(arg: { uuid: NodeUuid; documentId?: string | DocumentId; timeout?: number }) { + if (!arg.uuid && !arg.documentId) { logger.warn({ arg }, 'Attempt to retrieve draft manifest for empty UUID'); return null; } logger.info({ arg }, 'Retrieve Draft Document'); try { const response = await this.#client.get>( - `${this.baseUrl}/v1/nodes/documents/draft/${arg.uuid}`, + `${this.baseUrl}/v1/nodes/documents/draft/${arg.uuid}?documentId=${arg.documentId}`, { headers: { 'x-api-remote-traceid': (als.getStore() as any)?.traceId, @@ -132,10 +132,18 @@ class RepoService { } } - async getDraftManifest(uuid: NodeUuid, timeout?: number) { + async getDraftManifest({ + uuid, + timeout, + documentId, + }: { + uuid: NodeUuid; + documentId?: string | DocumentId; + timeout?: number; + }) { logger.info({ uuid }, 'Retrieve Draft Document'); try { - const response = await this.getDraftDocument({ uuid, timeout }); + const response = await this.getDraftDocument({ uuid, timeout, documentId }); return response ? response.manifest : null; } catch (err) { logger.error({ err }, 'GET Draft manifest Error'); diff --git a/desci-server/test/integration/Attestation.test.ts b/desci-server/test/integration/Attestation.test.ts index a6a111899..1d7bd25e0 100644 --- a/desci-server/test/integration/Attestation.test.ts +++ b/desci-server/test/integration/Attestation.test.ts @@ -133,7 +133,7 @@ const clearDatabase = async () => { await prisma.$queryRaw`TRUNCATE TABLE "Node" CASCADE;`; }; -describe.only('Attestations Service', async () => { +describe('Attestations Service', async () => { let baseManifest: ResearchObjectV1; let baseManifestCid: string; let users: User[]; From 51e78caa5e0c135d5b213929fe8d8445c7fa63f4 Mon Sep 17 00:00:00 2001 From: shadrach-tayo Date: Thu, 10 Oct 2024 08:49:43 -0500 Subject: [PATCH 80/81] deprecate old publish flow --- desci-server/src/controllers/nodes/publish.ts | 41 +++++++++---------- desci-server/src/server.ts | 4 +- 2 files changed, 21 insertions(+), 24 deletions(-) diff --git a/desci-server/src/controllers/nodes/publish.ts b/desci-server/src/controllers/nodes/publish.ts index 382d38c92..b39326144 100644 --- a/desci-server/src/controllers/nodes/publish.ts +++ b/desci-server/src/controllers/nodes/publish.ts @@ -123,25 +123,24 @@ export const publish = async (req: PublishRequest, res: Response if (task) return res.status(400).json({ error: 'Node publishing in progress' }); - let publishTask: PublishTaskQueue | undefined; - let dpidAlias: number; - if (useNewPublish) { - logger.info({ ceramicStream, commitId, uuid, owner: owner.id }, 'Triggering new publish flow'); - dpidAlias = await syncPublish(ceramicStream, commitId, node, owner, cid, uuid, manifest); - } else { - publishTask = await prisma.publishTaskQueue.create({ - data: { - cid, - dpid: manifest.dpid?.id, - userId: owner.id, - transactionId, - ceramicStream, - commitId, - uuid: ensureUuidEndsWithDot(uuid), - status: PublishTaskQueueStatus.WAITING, - }, - }); - } + // let publishTask: PublishTaskQueue | undefined; + logger.info({ ceramicStream, commitId, uuid, owner: owner.id }, 'Triggering new publish flow'); + const dpidAlias = await syncPublish(ceramicStream, commitId, node, owner, cid, uuid, manifest); + // if (useNewPublish) { + // } else { + // publishTask = await prisma.publishTaskQueue.create({ + // data: { + // cid, + // dpid: manifest.dpid?.id, + // userId: owner.id, + // transactionId, + // ceramicStream, + // commitId, + // uuid: ensureUuidEndsWithDot(uuid), + // status: PublishTaskQueueStatus.WAITING, + // }, + // }); + // } saveInteraction( req, @@ -154,7 +153,7 @@ export const publish = async (req: PublishRequest, res: Response ceramicStream, commitId, uuid: ensureUuidEndsWithDot(uuid), - status: PublishTaskQueueStatus.WAITING, + // status: PublishTaskQueueStatus.WAITING, }, owner.id, ); @@ -182,7 +181,7 @@ export const publish = async (req: PublishRequest, res: Response return res.send({ ok: true, dpid: dpidAlias ?? parseInt(manifest.dpid?.id), - taskId: publishTask?.id, + // taskId: publishTask?.id, }); } catch (err) { logger.error({ err }, '[publish::publish] node-publish-err'); diff --git a/desci-server/src/server.ts b/desci-server/src/server.ts index 5a4569ac3..03606067d 100644 --- a/desci-server/src/server.ts +++ b/desci-server/src/server.ts @@ -147,7 +147,7 @@ class AppServer { }); // init publish worker - this.#initWorker(); + // this.#initWorker(); } get httpServer() { @@ -249,8 +249,6 @@ class AppServer { } async #initWorker() { - // TODO: remove after testing - // await Promise.all([runWorkerUntilStopped(), runWorkerUntilStopped()]); await runWorkerUntilStopped(); } } From aed8e26eff222e8b9f661a3d1914df8a8f86a889 Mon Sep 17 00:00:00 2001 From: shadrach-tayo Date: Thu, 10 Oct 2024 13:55:29 -0500 Subject: [PATCH 81/81] feat: Doi submission queue cron job --- desci-server/.gitignore | 2 + desci-server/package.json | 1 + desci-server/src/controllers/doi/mint.ts | 15 +----- desci-server/src/redisClient.ts | 2 + desci-server/src/server.ts | 12 ++--- desci-server/src/services/Doi.ts | 26 +++++++++- desci-server/src/services/crossRef/client.ts | 5 -- .../src/workers/doiSubmissionQueue.ts | 50 +++++++++++++++++++ desci-server/yarn.lock | 46 +++++++---------- 9 files changed, 103 insertions(+), 56 deletions(-) create mode 100644 desci-server/src/workers/doiSubmissionQueue.ts diff --git a/desci-server/.gitignore b/desci-server/.gitignore index 358616150..36e98c535 100755 --- a/desci-server/.gitignore +++ b/desci-server/.gitignore @@ -19,3 +19,5 @@ queries.sql # Sentry Config File .sentryclirc + +seed-doi-queue.ts \ No newline at end of file diff --git a/desci-server/package.json b/desci-server/package.json index ec8c73380..f2a664a6a 100755 --- a/desci-server/package.json +++ b/desci-server/package.json @@ -85,6 +85,7 @@ "body-parser": "^1.20.2", "concurrently": "^8.2.0", "cookie-parser": "^1.4.5", + "cron": "^3.1.7", "crypto": "^1.0.1", "ethers": "^5.6.9", "express": "^4.17.1", diff --git a/desci-server/src/controllers/doi/mint.ts b/desci-server/src/controllers/doi/mint.ts index 879b849ef..1072035f9 100644 --- a/desci-server/src/controllers/doi/mint.ts +++ b/desci-server/src/controllers/doi/mint.ts @@ -88,20 +88,7 @@ export const handleCrossrefNotificationCallback = async ( if (response.success) { logger.info({ response, submission }, 'CREATE DOI '); - const doiRecord = await prisma.doiRecord.create({ - data: { - uuid: submission.uuid, - dpid: submission.dpid, - doi: submission.uniqueDoi, - }, - }); - await doiService.updateSubmission( - { id: submission.id }, - { - status: DoiStatus.SUCCESS, - doiRecordId: doiRecord.id, - }, - ); + await doiService.onRegistrationSuccessful(submission); // send discord notification discordNotify({ diff --git a/desci-server/src/redisClient.ts b/desci-server/src/redisClient.ts index 856bd1cda..0852cd0b9 100644 --- a/desci-server/src/redisClient.ts +++ b/desci-server/src/redisClient.ts @@ -3,6 +3,7 @@ import os from 'os'; import { createClient } from 'redis'; import { logger as parentLogger } from './logger.js'; +import { SubmissionQueueJob } from './workers/doiSubmissionQueue.js'; const hostname = os.hostname(); const logger = parentLogger.child({ @@ -151,6 +152,7 @@ process.on('exit', () => { logger.info('Process caught exit'); lockService.freeLocks(); redisClient.quit(); + SubmissionQueueJob.stop(); }); // catches ctrl+c event diff --git a/desci-server/src/server.ts b/desci-server/src/server.ts index 5a4569ac3..5b16b2d6e 100644 --- a/desci-server/src/server.ts +++ b/desci-server/src/server.ts @@ -28,6 +28,7 @@ import { NotFoundError, RequestWithUser, extractAuthToken, extractUserFromToken import { als, logger } from './logger.js'; import { ensureUserIfPresent } from './middleware/ensureUserIfPresent.js'; import { errorHandler } from './middleware/errorHandler.js'; +import { SubmissionQueueJob } from './workers/doiSubmissionQueue.js'; import { runWorkerUntilStopped } from './workers/publish.js'; // const __dirname = path.dirname(__filename); @@ -146,8 +147,8 @@ class AppServer { console.log(`Server running on port ${this.port}`); }); - // init publish worker - this.#initWorker(); + // start jobs + this.startJobs(); } get httpServer() { @@ -248,10 +249,9 @@ class AppServer { } } - async #initWorker() { - // TODO: remove after testing - // await Promise.all([runWorkerUntilStopped(), runWorkerUntilStopped()]); - await runWorkerUntilStopped(); + async startJobs() { + // start doi submission cron job + SubmissionQueueJob.start(); } } function getRemoteAddress(req) { diff --git a/desci-server/src/services/Doi.ts b/desci-server/src/services/Doi.ts index c160c06fd..cf4994d51 100644 --- a/desci-server/src/services/Doi.ts +++ b/desci-server/src/services/Doi.ts @@ -1,5 +1,5 @@ import { PdfComponent, ResearchObjectComponentType, ResearchObjectV1 } from '@desci-labs/desci-models'; -import { DoiStatus, Prisma, PrismaClient } from '@prisma/client'; +import { DoiStatus, DoiSubmissionQueue, Prisma, PrismaClient } from '@prisma/client'; import { v4 } from 'uuid'; import { @@ -164,7 +164,6 @@ export class DoiService { // only create doi if submission status is success const submission = await crossRefClient.addSubmissiontoQueue({ - // doi: doiRecord.id, dpid, uuid: ensureUuidEndsWithDot(uuid), uniqueDoi: doi, @@ -208,10 +207,33 @@ export class DoiService { }); } + async getPendingSubmissions() { + return await this.dbClient.doiSubmissionQueue.findMany({ + where: { status: DoiStatus.PENDING }, + }); + } + async updateSubmission( filter: Prisma.DoiSubmissionQueueWhereInput, data: Prisma.DoiSubmissionQueueUncheckedUpdateManyInput, ) { return await this.dbClient.doiSubmissionQueue.updateMany({ where: filter, data }); } + + async onRegistrationSuccessful(submission: DoiSubmissionQueue) { + const doiRecord = await this.dbClient.doiRecord.create({ + data: { + uuid: submission.uuid, + dpid: submission.dpid, + doi: submission.uniqueDoi, + }, + }); + await this.updateSubmission( + { id: submission.id }, + { + status: DoiStatus.SUCCESS, + doiRecordId: doiRecord.id, + }, + ); + } } diff --git a/desci-server/src/services/crossRef/client.ts b/desci-server/src/services/crossRef/client.ts index 9829a5dd8..4c2a78d87 100644 --- a/desci-server/src/services/crossRef/client.ts +++ b/desci-server/src/services/crossRef/client.ts @@ -174,11 +174,6 @@ class CrossRefClient { } } - // check if there's a pending submission for a dpid - async getPendingSubmission(dpid: string) { - // todo: retrieve doi whose submission log is pending - } - async registerDoi(query: { manifest: ResearchObjectV1; doi: string; diff --git a/desci-server/src/workers/doiSubmissionQueue.ts b/desci-server/src/workers/doiSubmissionQueue.ts new file mode 100644 index 000000000..dbbd8ba25 --- /dev/null +++ b/desci-server/src/workers/doiSubmissionQueue.ts @@ -0,0 +1,50 @@ +import { CronJob } from 'cron'; + +import { asyncMap, doiService, logger as parentLogger } from '../internal.js'; +import { DiscordChannel, discordNotify, DiscordNotifyType } from '../utils/discordUtils.js'; + +const logger = parentLogger.child({ module: 'DoiSubmissionJob' }); + +const pingDoi = async (doi: string) => { + const response = await fetch(`https://doi.org/${doi}`, { method: 'HEAD' }); + logger.trace({ ping: response.ok, doi, headers: response.headers }, 'PING DOI'); + if (response.ok) return true; + return false; +}; + +/** + * Submission queue cron callback + * Concurrently process submission queue by pinging their respective + * DOIs, if they resolve mark doi registration as successful and send a discord notification + * to this effect + * @returns void + */ +export const onTick = async () => { + const pendingSubmissions = await doiService.getPendingSubmissions(); + logger.info({ pendingSubmissions }, 'pending submission'); + if (pendingSubmissions.length === 0) return; + const processed = await asyncMap(pendingSubmissions, async (job) => { + const isResolved = await pingDoi(job.uniqueDoi); + if (isResolved) { + await doiService.onRegistrationSuccessful(job); + discordNotify({ + channel: DiscordChannel.DoiMinting, + title: 'DOI Registration ✅', + type: DiscordNotifyType.SUCCESS, + message: `DOI: https://doi.org/${job.uniqueDoi} + DPID: ${job.dpid}`, + }); + } + return { doi: job.uniqueDoi, jobId: job.id, isResolved }; + }); + logger.trace({ processed }, 'Exiting Job with results'); +}; + +export const SubmissionQueueJob = new CronJob( + // schedule cron to run every hour + // '*/10 * * * * *', // 10 seconds (for local test) + '0 * * * * *', // 1 hour + onTick, // onTick + null, // onComplete + false, // start +); diff --git a/desci-server/yarn.lock b/desci-server/yarn.lock index c45cfcd68..7ed941906 100644 --- a/desci-server/yarn.lock +++ b/desci-server/yarn.lock @@ -7448,6 +7448,11 @@ resolved "https://registry.yarnpkg.com/@types/lodash/-/lodash-4.17.0.tgz#d774355e41f372d5350a4d0714abb48194a489c3" integrity sha512-t7dhREVv6dbNj0q17X12j7yDG4bD/DHYX7o5/DbDxobP0HnGPgpRz2Ej77aL7TZT3DSw13fqUTj8J4mMnqa7WA== +"@types/luxon@~3.4.0": + version "3.4.2" + resolved "https://registry.yarnpkg.com/@types/luxon/-/luxon-3.4.2.tgz#e4fc7214a420173cea47739c33cdf10874694db7" + integrity sha512-TifLZlFudklWlMBfhubvgqTXRzLDI5pCbGa4P8a3wPyUQSW+1xQ5eDsreP9DWHX3tjq1ke96uYG/nwundroWcA== + "@types/memcached@^2.2.6": version "2.2.10" resolved "https://registry.yarnpkg.com/@types/memcached/-/memcached-2.2.10.tgz#113f9e3a451d6b5e0a3822e06d9feb52e63e954a" @@ -9734,6 +9739,14 @@ cron-parser@^4.0.0: dependencies: luxon "^3.2.1" +cron@^3.1.7: + version "3.1.7" + resolved "https://registry.yarnpkg.com/cron/-/cron-3.1.7.tgz#3423d618ba625e78458fff8cb67001672d49ba0d" + integrity sha512-tlBg7ARsAMQLzgwqVxy8AZl/qlTc5nibqYwtNGoCrd+cV+ugI+tvZC1oT/8dFH8W455YrywGykx/KMmAqOr7Jw== + dependencies: + "@types/luxon" "~3.4.0" + luxon "~3.4.0" + cross-fetch@^3.1.5: version "3.1.8" resolved "https://registry.yarnpkg.com/cross-fetch/-/cross-fetch-3.1.8.tgz#0327eba65fd68a7d119f8fb2bf9334a1a7956f82" @@ -13454,7 +13467,7 @@ lru-cache@^6.0.0: resolved "https://registry.yarnpkg.com/lru-cache/-/lru-cache-10.2.0.tgz#0bd445ca57363465900f4d1f9bd8db343a4d95c3" integrity sha512-2bIM8x+VAf6JT4bKAljS1qUWgMsqZRPGJS6FSahIMPVvctcNhyVp7AJu7quxOW9jwkryBReKZY5tY5JYv2n/7Q== -luxon@^3.2.1: +luxon@^3.2.1, luxon@~3.4.0: version "3.4.4" resolved "https://registry.yarnpkg.com/luxon/-/luxon-3.4.4.tgz#cf20dc27dc532ba41a169c43fdcc0063601577af" integrity sha512-zobTr7akeGHnv7eBOXcRgMeCP6+uyYsczwmeRCauvpvaAltgNyTbLH/+VaEAPUeWBT+1GuNmz4wC/6jtQzbbVA== @@ -16327,16 +16340,7 @@ string-template@~0.2.1: resolved "https://registry.yarnpkg.com/string-template/-/string-template-0.2.1.tgz#42932e598a352d01fc22ec3367d9d84eec6c9add" integrity sha512-Yptehjogou2xm4UJbxJ4CxgZx12HBfeystp0y3x7s4Dj32ltVVG1Gg8YhKjHZkHicuKpZX/ffilA8505VbUbpw== -"string-width-cjs@npm:string-width@^4.2.0": - version "4.2.3" - resolved "https://registry.yarnpkg.com/string-width/-/string-width-4.2.3.tgz#269c7117d27b05ad2e536830a8ec895ef9c6d010" - integrity sha512-wKyQRQpjJ0sIp62ErSZdGsjMJWsap5oRNihHhu6G7JVO/9jIB6UyevL+tXuOqrng8j/cxKTWyWUwvSTriiZz/g== - dependencies: - emoji-regex "^8.0.0" - is-fullwidth-code-point "^3.0.0" - strip-ansi "^6.0.1" - -"string-width@^1.0.2 || 2 || 3 || 4", string-width@^4.1.0, string-width@^4.2.0, string-width@^4.2.3: +"string-width-cjs@npm:string-width@^4.2.0", "string-width@^1.0.2 || 2 || 3 || 4", string-width@^4.1.0, string-width@^4.2.0, string-width@^4.2.3: version "4.2.3" resolved "https://registry.yarnpkg.com/string-width/-/string-width-4.2.3.tgz#269c7117d27b05ad2e536830a8ec895ef9c6d010" integrity sha512-wKyQRQpjJ0sIp62ErSZdGsjMJWsap5oRNihHhu6G7JVO/9jIB6UyevL+tXuOqrng8j/cxKTWyWUwvSTriiZz/g== @@ -16409,7 +16413,7 @@ stringify-object@3.3.0: is-obj "^1.0.1" is-regexp "^1.0.0" -"strip-ansi-cjs@npm:strip-ansi@^6.0.1": +"strip-ansi-cjs@npm:strip-ansi@^6.0.1", strip-ansi@^6.0.0, strip-ansi@^6.0.1: version "6.0.1" resolved "https://registry.yarnpkg.com/strip-ansi/-/strip-ansi-6.0.1.tgz#9e26c63d30f53443e9489495b2105d37b67a85d9" integrity sha512-Y38VPSHcqkFrCpFnQ9vuSXmquuv5oXOKpGeT6aGrr3o3Gc9AlVa6JBfUSOCnbxGGZF+/0ooI7KrPuUSztUdU5A== @@ -16423,13 +16427,6 @@ strip-ansi@^3.0.0: dependencies: ansi-regex "^2.0.0" -strip-ansi@^6.0.0, strip-ansi@^6.0.1: - version "6.0.1" - resolved "https://registry.yarnpkg.com/strip-ansi/-/strip-ansi-6.0.1.tgz#9e26c63d30f53443e9489495b2105d37b67a85d9" - integrity sha512-Y38VPSHcqkFrCpFnQ9vuSXmquuv5oXOKpGeT6aGrr3o3Gc9AlVa6JBfUSOCnbxGGZF+/0ooI7KrPuUSztUdU5A== - dependencies: - ansi-regex "^5.0.1" - strip-ansi@^7.0.1: version "7.1.0" resolved "https://registry.yarnpkg.com/strip-ansi/-/strip-ansi-7.1.0.tgz#d5b6568ca689d8561370b0707685d22434faff45" @@ -17465,7 +17462,7 @@ workerpool@6.2.1: resolved "https://registry.yarnpkg.com/workerpool/-/workerpool-6.2.1.tgz#46fc150c17d826b86a008e5a4508656777e9c343" integrity sha512-ILEIE97kDZvF9Wb9f6h5aXK4swSlKGUcOEGiIYb2OOu/IrDU9iwj0fD//SsA6E5ibwJxpEvhullJY4Sl4GcpAw== -"wrap-ansi-cjs@npm:wrap-ansi@^7.0.0": +"wrap-ansi-cjs@npm:wrap-ansi@^7.0.0", wrap-ansi@^7.0.0: version "7.0.0" resolved "https://registry.yarnpkg.com/wrap-ansi/-/wrap-ansi-7.0.0.tgz#67e145cff510a6a6984bdf1152911d69d2eb9e43" integrity sha512-YVGIj2kamLSTxw6NsZjoBxfSwsn0ycdesmc4p+Q21c5zPuZ1pl+NfxVdxPtdHvmNVOQ6XSYG4AUtyt/Fi7D16Q== @@ -17483,15 +17480,6 @@ wrap-ansi@^6.2.0: string-width "^4.1.0" strip-ansi "^6.0.0" -wrap-ansi@^7.0.0: - version "7.0.0" - resolved "https://registry.yarnpkg.com/wrap-ansi/-/wrap-ansi-7.0.0.tgz#67e145cff510a6a6984bdf1152911d69d2eb9e43" - integrity sha512-YVGIj2kamLSTxw6NsZjoBxfSwsn0ycdesmc4p+Q21c5zPuZ1pl+NfxVdxPtdHvmNVOQ6XSYG4AUtyt/Fi7D16Q== - dependencies: - ansi-styles "^4.0.0" - string-width "^4.1.0" - strip-ansi "^6.0.0" - wrap-ansi@^8.1.0: version "8.1.0" resolved "https://registry.yarnpkg.com/wrap-ansi/-/wrap-ansi-8.1.0.tgz#56dc22368ee570face1b49819975d9b9a5ead214"