-
Notifications
You must be signed in to change notification settings - Fork 4
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
Feat/add lightnet #98
Closed
Closed
Conversation
This file contains 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 commit introduces a new contract.ts file in the zkapp directory. This file contains the logic for a HelloWorld smart contract, including state variables, methods, and events. feat(zkapp): add tsconfig.test.json for TypeScript configuration This commit also adds a new tsconfig.test.json file in the zkapp directory. This file contains the TypeScript configuration for the test environment.
…t files using its specific tsconfig.test.json file
…ting of zkapp directory
… to ensure compatibility with testing frameworks
This script includes the following functionalities: - Network configuration - Fee payer setup - zkApp compilation and deployment - zkApp state update - zkApp event emissions - zkApp action emissions and reductions - Tear down This script is essential for testing and running the zkApp smart contract operations.
…nhance security fix(contract.ts): replace account.delegate.set with actionState.set to correct state initialization refactor(contract.ts): remove admin parameter from update method to simplify function signature refactor(contract.ts): refactor reduceStructAction method for better readability and maintainability
Add utility functions for zkApp including network configuration, account fetching, contract deployment, state updating, event emitting, action emitting and reducing, and transaction sending. This is to provide a set of reusable functions for zkApp operations.
…tions The code in run.ts was simplified by extracting the logic into utility functions. This was done to improve readability and maintainability of the code. The utility functions are now responsible for setting network configuration, fetching account info, deploying and updating contract state, emitting events and actions, and reducing actions.
…e lightnet lifecycle feat(utils.ts): add execShellCommand function to execute shell commands from Node.js These changes allow the application to start and stop the lightnet as needed, and to execute shell commands directly from the application.
…Lightnet lifecycle This change allows the application to start and stop the Lightnet service as needed, improving resource management.
…new features and bug fixes
… startLightnet and stopLightnet functions for more reliable status checking refactor(utils.ts): modify execShellCommand to return exit code instead of stdout for more precise command execution result handling
…ators fix: add file extensions to all imports for compatibility with new TypeScript configuration style: add missing semicolons and adjust line breaks for better code readability feat: update 'target' and 'moduleResolution' in tsconfig.json to use ES2021 and Node's native ESM support
fix: remove outdated tsconfig.test.json from zkapp directory This change was made to update the TypeScript configuration for tests and remove the outdated configuration from the zkapp directory.
…pose sensitive information
…nction to ensure Lightnet starts successfully within 1 minute, improving reliability and error handling
… compatibility with different environments
…bility with different environments This change is necessary because some environments or tools might require explicit file extensions in import statements.
feat(run.ts): add comment to ensure running a local archive node for better user guidance
Imported modules from 'o1js' and '../zkapp/utils.js' to provide more comprehensive testing capabilities. Also updated import paths for 'resolvers' and 'context' to include '.js' extension for better compatibility.
… for better compatibility feat(resolvers.test.ts): add more comprehensive tests for events and actions fix(resolvers.test.ts): update PG_CONN string for better database connection refactor(resolvers.test.ts): replace beforeAll with before and after for better test setup and teardown feat(resolvers.test.ts): add keypair and contract setup for more realistic testing
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
No description provided.