Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Schema validation #462

Draft
wants to merge 21 commits into
base: v2
Choose a base branch
from
Draft

Schema validation #462

wants to merge 21 commits into from

Conversation

JIOjosBG
Copy link
Member

@JIOjosBG JIOjosBG commented Nov 24, 2023

This PR:

  • Break ambire-app, ambire-app requires this PR https://github.com/AmbireTech/ambire-app/pull/1440 for schema validation
  • Introduces basic schema malidation by:
    a. Compiling ts interfaces via compile:tsSchemas script
    b. Validates them via the exported schemas object
  • Adds typescript-json-schema and ajv packages
  • Moves some interfaces from libs/module/interfaces.ts to interfaces/module.ts

@JIOjosBG JIOjosBG marked this pull request as ready for review November 30, 2023 16:12
@borislav-itskov
Copy link
Member

@JIOjosBG Before merging this, I suggest opening the extension and testing sign and broadcast on polygon. After we merge the eip-1559 branch, we should test everything on the avalanche chain as well as to be sure it's all working

@JIOjosBG JIOjosBG marked this pull request as ready for review December 6, 2023 15:17
@JIOjosBG
Copy link
Member Author

JIOjosBG commented Dec 6, 2023

@JIOjosBG Before merging this, I suggest opening the extension and testing sign and broadcast on polygon. After we merge the eip-1559 branch, we should test everything on the avalanche chain as well as to be sure it's all working

There was a problem with ajv's lazy compiling that resultet in the extension not loading. I updated the library and now it seems to work properly. Tested with sign hash for web wallet txn and broadcasting a swap on polygon via extension itself.

@JIOjosBG JIOjosBG marked this pull request as draft December 6, 2023 15:25
@JIOjosBG JIOjosBG marked this pull request as ready for review December 6, 2023 15:52
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
2 participants