Last active
March 2, 2021 08:21
-
-
Save cstrap/dbc39c79fbe28edea141aacad4fcd100 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
attrs = {'some_property': 'some_value'} | |
Obj = type('ObjectClassName', (object,), attrs) | |
obj = Obj() | |
print(obj.some_property) | |
# >>> some_value |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment