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

spacetime server add - Remove trailing /s from server URIs #1552

Merged
merged 3 commits into from
Jul 26, 2024

Conversation

bfops
Copy link
Collaborator

@bfops bfops commented Jul 26, 2024

Description of Changes

Fixes part of #1551. See the issue for more background details.

API and ABI breaking changes

No. Un-breaks some cases.

Expected complexity level and risk

1

Testing

Before:

$ spacetime server add https://testnet.spacetimedb.com/ testnet-test
Error: Unable to retrieve fingerprint for server: https://testnet.spacetimedb.com/
Is the server running?
Add a server without retrieving its fingerprint with:
	spacetime server add https://testnet.spacetimedb.com/ --no-fingerprint

Caused by:
    HTTP status client error (404 Not Found) for url (https://testnet.spacetimedb.com//identity/public-key)

On this branch:

$ cargo run -- server add https://testnet.spacetimedb.com/ testnet-test
    Finished `dev` profile [unoptimized + debuginfo] target(s) in 0.22s
     Running `target/debug/spacetime server add 'https://testnet.spacetimedb.com/' testnet-test`
For server https://testnet.spacetimedb.com, got fingerprint:
-----BEGIN PUBLIC KEY-----
MFkwEwYHKoZIzj0CAQYIKoZIzj0DAQcDQgAEmF4e1ygt1sgluqRmi1Lwz8jK+GVz
kUnUtZJsDu5ACsJqwSDiMMDnBrNW41Bx0Qrg8FJNsK7mC767nvVmSYzyDg==
-----END PUBLIC KEY-----

Error: Server already configured for host: testnet.spacetimedb.com

@bfops bfops requested a review from jdetter July 26, 2024 15:57
@bfops bfops added release-any To be landed in any release window CLI only This change only affects the CLI behavior labels Jul 26, 2024
@bfops bfops changed the title spacetime server add - Remove trailing /s spacetime server add - Remove trailing /s from server URIs Jul 26, 2024
Copy link
Collaborator

@jdetter jdetter left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good to me, I haven't tested it but I agree with the change.

Thanks Zeke! 👍

@bfops bfops enabled auto-merge July 26, 2024 16:01
@bfops bfops added this pull request to the merge queue Jul 26, 2024
Merged via the queue into master with commit cd5e50a Jul 26, 2024
7 checks passed
@bfops bfops deleted the bfops/server-trailing-slash branch September 5, 2024 17:49
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
CLI only This change only affects the CLI behavior release-any To be landed in any release window
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants