You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Describe the bug
With usePublications react hook, if profile post a publications encrypted with invalid currency object/address condition, we can't retrieve any publications and I can't retrieve publications at all
To Reproduce
Encrypted publication with invalid erc20OwnershipCondition(or erc721 maybe) condition with lensClient.gated
Post publication on arweave
Execute usePublications with publisher profile id on where.from for argument
Expected behaviuor
Perhaps a modifier would be needed to verify the validity of the conditions before encryption
If using the React bindings, what is the essence of your React app?
React Web App
React Native
Version of the packages you are using "@lens-protocol/client": "2.0.0-alpha.37", "@lens-protocol/metadata": "^1.1.6", "@lens-protocol/react-web": "latest", "@lens-protocol/wagmi": "latest",`
Additional context
In all applications, the profile page returns UnspecifiedError: { "name": "ApolloError", "graphQLErrors": [ { "message": "Currency not found for contract 0xD13c7342e1ef687C5ad21b27c2b65D772cAb5C8c:137", "locations": [ { "line": 1782, "column": 3 } ], "path": [ "result", "items", 2, "metadata" ], "extensions": { "code": "GRAPHQL_VALIDATION_FAILED", "stacktrace": [ "GraphQLError: Currency not found for contract 0xD13c7342e1ef687C5ad21b27c2b65D772cAb5C8c:137", " at new ValidationError (/usr/src/app/packages/apollo-server-errors/lib/index.js:40:9)", " at getModuleCurrency (/usr/src/app/packages/api-lens/lib/currency/operations/get-module-currency.js:14:15)", " at process.processTicksAndRejections (node:internal/process/task_queues:95:5)", " at async Amount.fromValueAndCurrency (/usr/src/app/packages/api-lens/lib/shared/types/amount.js:35:23)", " at async Erc20OwnershipCondition.fromMetadataErc20OwnershipCondition (/usr/src/app/packages/api-lens/lib/shared/types/gated.js:86:25)", " at async Promise.all (index 1)", " at async OrCondition.fromMetadataSimpleConditionList (/usr/src/app/packages/api-lens/lib/shared/types/gated.js:286:27)", " at async Promise.all (index 1)", " at async RootCondition.fromMetadataRootConditionCriteria (/usr/src/app/packages/api-lens/lib/shared/types/gated.js:263:27)", " at async PublicationMetadataLitEncryption.fromPublicationMetadata (/usr/src/app/packages/api-lens/lib/publication/types/metadata.js:73:34)", " at async TextOnlyMetadataV3.resolveModernPublicationMetadata (/usr/src/app/packages/api-lens/lib/publication/types/metadata.js:159:32)", " at async TextOnlyMetadataV3.fromTextOnlyMetadata (/usr/src/app/packages/api-lens/lib/publication/types/metadata.js:877:24)" ] } } ], "message": "Currency not found for contract 0xD13c7342e1ef687C5ad21b27c2b65D772cAb5C8c:137" }
The text was updated successfully, but these errors were encountered:
Describe the bug
With usePublications react hook, if profile post a publications encrypted with invalid currency object/address condition, we can't retrieve any publications and I can't retrieve publications at all
To Reproduce
lensClient.gated
where.from
for argumentExpected behaviuor
Perhaps a modifier would be needed to verify the validity of the conditions before encryption
If using the React bindings, what is the essence of your React app?
Version of the packages you are using
"@lens-protocol/client": "2.0.0-alpha.37", "@lens-protocol/metadata": "^1.1.6", "@lens-protocol/react-web": "latest", "@lens-protocol/wagmi":
"latest",`Additional context
In all applications, the profile page returns UnspecifiedError:
{ "name": "ApolloError", "graphQLErrors": [ { "message": "Currency not found for contract 0xD13c7342e1ef687C5ad21b27c2b65D772cAb5C8c:137", "locations": [ { "line": 1782, "column": 3 } ], "path": [ "result", "items", 2, "metadata" ], "extensions": { "code": "GRAPHQL_VALIDATION_FAILED", "stacktrace": [ "GraphQLError: Currency not found for contract 0xD13c7342e1ef687C5ad21b27c2b65D772cAb5C8c:137", " at new ValidationError (/usr/src/app/packages/apollo-server-errors/lib/index.js:40:9)", " at getModuleCurrency (/usr/src/app/packages/api-lens/lib/currency/operations/get-module-currency.js:14:15)", " at process.processTicksAndRejections (node:internal/process/task_queues:95:5)", " at async Amount.fromValueAndCurrency (/usr/src/app/packages/api-lens/lib/shared/types/amount.js:35:23)", " at async Erc20OwnershipCondition.fromMetadataErc20OwnershipCondition (/usr/src/app/packages/api-lens/lib/shared/types/gated.js:86:25)", " at async Promise.all (index 1)", " at async OrCondition.fromMetadataSimpleConditionList (/usr/src/app/packages/api-lens/lib/shared/types/gated.js:286:27)", " at async Promise.all (index 1)", " at async RootCondition.fromMetadataRootConditionCriteria (/usr/src/app/packages/api-lens/lib/shared/types/gated.js:263:27)", " at async PublicationMetadataLitEncryption.fromPublicationMetadata (/usr/src/app/packages/api-lens/lib/publication/types/metadata.js:73:34)", " at async TextOnlyMetadataV3.resolveModernPublicationMetadata (/usr/src/app/packages/api-lens/lib/publication/types/metadata.js:159:32)", " at async TextOnlyMetadataV3.fromTextOnlyMetadata (/usr/src/app/packages/api-lens/lib/publication/types/metadata.js:877:24)" ] } } ], "message": "Currency not found for contract 0xD13c7342e1ef687C5ad21b27c2b65D772cAb5C8c:137" }
The text was updated successfully, but these errors were encountered: