Skip to content

Commit

Permalink
Fix amusifier Python 3.13 compatibility
Browse files Browse the repository at this point in the history
  • Loading branch information
LourensVeen committed Oct 23, 2024
1 parent 2f788f3 commit d8c5ec9
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion src/amuse/datamodel/attributes.py
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ class DomainMetaclass(type):
def __new__(metaclass, name, bases, dict):
replacement_dictionary = {}
for key, value in dict.items():
if isinstance(value, tuple):
if not key.startswith('__') and isinstance(value, tuple):
default_value, description = value
replacement_dictionary[key] = AttributeDefinition(
key, description, default_value.unit, default_value
Expand Down
2 changes: 1 addition & 1 deletion src/amuse/datamodel/base.py
Original file line number Diff line number Diff line change
Expand Up @@ -528,7 +528,7 @@ def __call__(self, *list_arguments, **keyword_arguments):

def new_particle_function_attribute_with_doc(function):
class BoundParticleFunctionAttribute(object):
if function.__doc__:
if function is not None and function.__doc__:
__doc__ = (
"\n Documentation on '{0}' particle function attribute:"
"\n\n".format(function.__name__) + function.__doc__
Expand Down

0 comments on commit d8c5ec9

Please sign in to comment.