from enum import StrEnum, auto
class Foo(StrEnum):
A = auto()
B = auto()
C = auto()
# ValueError why? and why it looks like im making an instance and giving arguments but it gives back an instance of existing values only
Foo('A')
# This works
Foo('a')
# I figured out that auto when using StrEnum it uses alphabetical charecters
# Key error, i figured out that doing like that its accesing the members dictionary, so it makes sense to me
Foo['a']
# This works and ill be using that
Foo['A']
You might ask why im doing like that cuz Enums ussually are used Foo.A but im loading things from a file so i have a string value