Skip to content

Fixes #1302 : Updated validation for API name with special characters#1303

Merged
afsalthaj merged 11 commits intogolemcloud:mainfrom
0xvasanth:fix/1302
Feb 12, 2025
Merged

Fixes #1302 : Updated validation for API name with special characters#1303
afsalthaj merged 11 commits intogolemcloud:mainfrom
0xvasanth:fix/1302

Conversation

@0xvasanth
Copy link
Contributor

@0xvasanth 0xvasanth commented Feb 9, 2025

Resolves #1302

What have been fixed

Validation Logic Update:

• Updated the input validation for API names to accept only alphanumerical characters, hyphens, and underscores.

• Extended similar validation to Worker names to prevent future issues when users set custom names.

User Feedback Improvement:

Enhanced error messaging in the Cloud Console to inform users of the acceptable character set when an invalid name is entered.

Resource Accessibility:

Prevented the creation of APIs (and Workers) with invalid names, ensuring that all created resources remain accessible for subsequent editing and deletion.

Testings

Manual Testing:

Valid Name Creation:

       Created APIs with valid names (e.g., "test_api", "test-api", "Test123") to confirm that resources are created successfully and remain accessible.

Invalid Name Rejection:

       Attempted to create APIs using names with special characters (e.g., "test;;", "test:api", "test/api"), verifying that the console correctly blocks these names and displays an appropriate error message.

@0xvasanth 0xvasanth changed the title Fixes #1302 Fixes #1302 : Updated validation for API name with special characters Feb 9, 2025
@afsalthaj
Copy link
Contributor

Could you please make the build green?

@vigoo
Copy link
Contributor

vigoo commented Feb 12, 2025

Hi! As the feedback loop is a bit slow because you are a first contributor and I have to click on an approve button here for each attempt :) I just wanted to mention make sure you:

  • merge with latest main (we are merging in several changes per dy)
  • run cargo make build to make sure everything compiles
  • run cargo make fix to make sure all clippy rules are passing and formatting
  • make sure you run the tests of whatever area you touched (in this case the worker service tests)

there are some flaky worker executor tests that may randomly fail, I'll restart your CI run when that happens.

@0xvasanth
Copy link
Contributor Author

Hi! As the feedback loop is a bit slow because you are a first contributor and I have to click on an approve button here for each attempt :) I just wanted to mention make sure you:

  • merge with latest main (we are merging in several changes per dy)
  • run cargo make build to make sure everything compiles
  • run cargo make fix to make sure all clippy rules are passing and formatting
  • make sure you run the tests of whatever area you touched (in this case the worker service tests)

there are some flaky worker executor tests that may randomly fail, I'll restart your CI run when that happens.

Hi @vigoo , Thanks for helping me out, I have executed all the command which you have mention, but will do it one more time in same order in which you have specified and will get back to you

@0xvasanth
Copy link
Contributor Author

0xvasanth commented Feb 12, 2025

@vigoo you have missed two more command which run the test case

cargo make test
cargo make integration-tests

since I am facing error in integration testing GitHub-action
will debug this today and update here

@0xvasanth
Copy link
Contributor Author

@vigoo I have tested it locally can you approve that it now

@afsalthaj afsalthaj merged commit 6607d03 into golemcloud:main Feb 12, 2025
18 checks passed
@0xvasanth 0xvasanth deleted the fix/1302 branch February 27, 2025 16:32
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

API name with special characters causes it to be inaccessibe in Golem Cloud Console

3 participants