-
Notifications
You must be signed in to change notification settings - Fork 16
Fix/fix deploy command #422
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
Closed
Closed
Changes from 7 commits
Commits
Show all changes
26 commits
Select commit
Hold shift + click to select a range
74b2d2b
Upgraded lerna
rpanic e8c94d5
.nx gitignore
rpanic 5a94507
Removed --no-verify-access
rpanic fb121dd
versions
rpanic a8fa945
bump git head
rpanic bde3149
Merge branch 'develop' into release/canary-pre-devnet
rpanic 5d967a3
package-lock
rpanic 99e0289
Merge branch 'develop' into release/canary-pre-devnet
rpanic af934eb
package-lock 2
rpanic 4ebe9ab
fix: add BridgingModule to appchain and fix network urls
4ytuncs 5654998
chore(debug): add debug logs for method id registration
4ytuncs 9143ce5
style: run lint fix
4ytuncs 73a393f
Fixed linting in cli
rpanic 9614cf4
Fixed and skipped test
rpanic e103b2d
refactor: separate TestBalances as utils
4ytuncs 97a70cc
fix: add bridging module for deposit and redeem
4ytuncs 0737f85
style: run lint fix
4ytuncs 66817b9
Merge branch 'fix/fix-deploy-command' into release/canary-pre-devnet
rpanic b799f6a
refactor: move BridgingModule to settlementScript
4ytuncs 3005eae
style: run lint fix
4ytuncs ca4b2bb
refactor: remove debug logs
4ytuncs 8af4bf7
Fixed configurations
rpanic 50abed0
Merge branch 'fix/fix-deploy-command' into release/canary-pre-devnet
rpanic 138737b
style: run lint fix
4ytuncs 1329ecb
refactor: move TestBalances to a helpers folder in src
4ytuncs b08726a
rebase to canary release
4ytuncs File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,47 @@ | ||
| import { PublicKey } from "o1js"; | ||
| import { runtimeMethod, runtimeModule } from "@proto-kit/module"; | ||
| import { State, state } from "@proto-kit/protocol"; | ||
| import { | ||
| Balance, | ||
| Balances, | ||
| BalancesKey, | ||
| TokenId, | ||
| UInt64, | ||
| } from "@proto-kit/library"; | ||
|
|
||
| @runtimeModule() | ||
| export class TestBalances extends Balances { | ||
| /** | ||
| * We use `satisfies` here in order to be able to access | ||
| * presets by key in a type safe way. | ||
| */ | ||
| // public static presets = {} satisfies Presets<object>; | ||
|
|
||
| @state() public totalSupply = State.from<UInt64>(UInt64); | ||
|
|
||
| @runtimeMethod() | ||
| public async getBalanceForUser( | ||
| tokenId: TokenId, | ||
| address: PublicKey | ||
| ): Promise<Balance> { | ||
| return await super.getBalance(tokenId, address); | ||
| } | ||
|
|
||
| @runtimeMethod() | ||
| public async addBalance( | ||
| tokenId: TokenId, | ||
| address: PublicKey, | ||
| balance: UInt64 | ||
| ) { | ||
| const totalSupply = await this.totalSupply.get(); | ||
| await this.totalSupply.set(totalSupply.orElse(UInt64.zero).add(balance)); | ||
|
|
||
| const previous = await this.balances.get( | ||
| new BalancesKey({ tokenId, address }) | ||
| ); | ||
| await this.balances.set( | ||
| new BalancesKey({ tokenId, address }), | ||
| previous.orElse(UInt64.zero).add(balance) | ||
| ); | ||
| } | ||
| } |
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Remove these logs pls