-
Notifications
You must be signed in to change notification settings - Fork 38
Description
Description:
The Token Deployer on the Helios Portal (https://portal.helioschain.network/token-deployer) requires users to manually enter a unique, lowercase denomination (smallest unit) that does not conflict with any previously deployed denominations. If a "missing or invalid parameters" error occurs due to an invalid or conflicting denomination, users must manually try different values, which is inefficient and error-prone.
Problem:
Manual denomination entry is prone to errors, especially in a multi-user environment where conflicts are common. This creates friction, delays token deployments, and frustrates users, particularly those unaware of the lowercase or uniqueness requirements.
Proposed Solution:
Implement an automated denomination management system for the Token Deployer to:
- Auto-generate a unique, lowercase denomination for each deployment.
- Validate the denomination against a centralized registry of all previously deployed denominations on the Helios network.
- Provide real-time feedback in the UI, suggesting alternative denominations if a user-provided value is invalid or already in use.
Setup Instructions for Proposed Solution:
To implement the automated denomination system, the development team can follow these steps:
- Backend Registry:
- Create a centralized database (e.g., on-chain or off-chain) to store all deployed denomination values.
- Expose an API endpoint (e.g.,
/api/denominations/check
) to validate uniqueness during deployment.
- Auto-Generation Logic:
- Develop a function to generate random, lowercase denomination strings (e.g., using a UUID-based or timestamp-based suffix like
token-abc123
). - Ensure generated denominations comply with lowercase and character requirements.
- Develop a function to generate random, lowercase denomination strings (e.g., using a UUID-based or timestamp-based suffix like
- Frontend Integration:
- Update the Token Deployer UI to auto-populate the denomination field with a generated value.
- Add real-time validation using the API to check user inputs or generated values against the registry.
- Display user-friendly error messages (e.g., "Denomination already in use, try: [suggested value]") with a "Generate New" button for alternatives.
- Testing:
- Test the system with edge cases (e.g., uppercase inputs, existing denominations, invalid characters).
- Simulate multi-user deployments to ensure no conflicts occur.
Steps to Reproduce the Issue:
- Navigate to https://portal.helioschain.network/token-deployer.
- Enter a denomination that is uppercase (e.g.,
TOKEN
), contains invalid characters, or matches an existing deployed value. - Receive a "missing or invalid parameters" error.
- Manually test alternative denominations until deployment succeeds.
Expected Behavior:
The Token Deployer should auto-generate a valid, unique, lowercase denomination or validate user input in real-time against a registry, ensuring error-free deployments. The UI should provide clear feedback and suggested denominations to resolve conflicts instantly.
Additional Context:
- Automating denomination handling will streamline token deployment, improving user experience on the Helios Portal, especially for cross-chain use cases.
- This feature aligns with the Helios Portal’s goal of being a developer-friendly platform for token deployment.