mirror of
https://git.mirrors.martin98.com/https://github.com/Ultimaker/Cura
synced 2025-08-11 11:28:58 +08:00
Make the sentry_env a bit smarter
This commit is contained in:
parent
bd18a539e2
commit
c97ce6fafb
@ -29,9 +29,13 @@ parser.add_argument("--debug",
|
||||
known_args = vars(parser.parse_known_args()[0])
|
||||
|
||||
if with_sentry_sdk:
|
||||
sentry_env = "production"
|
||||
if ApplicationMetadata.CuraVersion == "master":
|
||||
sentry_env = "unknown" # Start off with a "IDK"
|
||||
if hasattr(sys, "frozen"):
|
||||
sentry_env = "production" # A frozen build is a "real" distribution.
|
||||
elif ApplicationMetadata.CuraVersion == "master":
|
||||
sentry_env = "development"
|
||||
elif "beta" in ApplicationMetadata.CuraVersion or "BETA" in ApplicationMetadata.CuraVersion:
|
||||
sentry_env = "beta"
|
||||
try:
|
||||
if ApplicationMetadata.CuraVersion.split(".")[2] == "99":
|
||||
sentry_env = "nightly"
|
||||
|
Loading…
x
Reference in New Issue
Block a user