Skip to content

Conversation

@howieleung
Copy link
Collaborator

No description provided.

@howieleung howieleung changed the title Restore Foundry URL on the UI Restore Foundry URL on the UI and remove unused clode Dec 2, 2025
base64_str = base64.b64encode(binary_str).decode('utf-8')

# Convert to base64url format (replace +/= with -_)
return base64_str.replace('+', '-').replace('/', '_').rstrip('=')
Copy link
Collaborator

Choose a reason for hiding this comment

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

We can simplify:

import urllib.parse
<...>
return urllib.parse.quote_plus(base64_str)

hex_str = guid.replace('-', '')

# Convert hex string to bytes
binary_str = bytes.fromhex(hex_str)
Copy link
Collaborator

Choose a reason for hiding this comment

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

[Suggestion] We can just serialize string:

 base64_str = base64.b64encode(guid.encode).decode('utf-8')

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.

3 participants