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

chore: scene on chain validations #149

Merged
merged 1 commit into from
Dec 23, 2022
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 7 additions & 2 deletions etc/content-validator.api.md
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,11 @@ export type BlockInformation = {
// @public (undocumented)
export const calculateDeploymentSize: (deployment: DeploymentToValidate, externalCalls: ExternalCalls) => Promise<number | string>;

// @public (undocumented)
export type Checker = {
checkLAND(address: string, x: number, y: number, block: number): Promise<boolean>;
};

// @public (undocumented)
export type ConditionalValidation = {
predicate: (components: ContentValidatorComponents, deployment: DeploymentToValidate) => ValidationResponse | Promise<ValidationResponse>;
Expand Down Expand Up @@ -92,7 +97,7 @@ export const statelessValidations: readonly [Validation, Validation, Validation]
// @public
export type SubGraphs = {
L1: {
landManager: ISubgraphComponent;
checker: Checker;
collections: ISubgraphComponent;
ensOwner: ISubgraphComponent;
};
Expand Down Expand Up @@ -144,7 +149,7 @@ export type Warnings = string[];

// Warnings were encountered during analysis:
//
// src/types.ts:147:3 - (ae-forgotten-export) The symbol "PermissionResult" needs to be exported by the entry point index.d.ts
// src/types.ts:154:3 - (ae-forgotten-export) The symbol "PermissionResult" needs to be exported by the entry point index.d.ts

// (No @packageDocumentation comment for this package)

Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,7 @@
"typescript": "^4.7.3"
},
"dependencies": {
"@dcl/block-indexer": "1.0.0-20221219151053.commit-69f0ed7",
"@dcl/block-indexer": "^1.0.0-20221223191317.commit-2d753e7",
"@dcl/content-hash-tree": "^1.1.3",
"@dcl/hashing": "1.1.2",
"@dcl/schemas": "^5.4.2",
Expand Down
9 changes: 8 additions & 1 deletion src/types.ts
Original file line number Diff line number Diff line change
Expand Up @@ -122,13 +122,20 @@ export const fromErrors = (...errors: Errors): ValidationResponse => ({
errors: errors.length > 0 ? errors : undefined
})

/**
* @public
*/
export type Checker = {
checkLAND(address: string, x: number, y: number, block: number): Promise<boolean>
}

/**
* A list with all sub-graphs used for validations.
* @public
*/
export type SubGraphs = {
L1: {
landManager: ISubgraphComponent
checker: Checker
collections: ISubgraphComponent
ensOwner: ISubgraphComponent
}
Expand Down
Loading