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

get_public_info assumes PUBLIC_STATS_PORT is an int #652

Open
timraay opened this issue Aug 29, 2024 · 0 comments
Open

get_public_info assumes PUBLIC_STATS_PORT is an int #652

timraay opened this issue Aug 29, 2024 · 0 comments
Labels
bug Something isn't working

Comments

@timraay
Copy link
Collaborator

timraay commented Aug 29, 2024

The default.env file says that you can prefix PUBLIC_STATS_PORT with 127.0.0.1: to disable access. While the stats can also be disabled through Settings > CRCON Settings > lock_stats_api, this is still useful if you want to disable the HTTP port while leaving the HTTPS port accessible.

The implementation of get_public_info does not account for the case where the variable is prefixed and will error when trying to convert it to an int. If the value cannot be converted to an int it should instead return None.

There might be other instances where this same issue can occur.

@timraay timraay added the bug Something isn't working label Aug 29, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

1 participant