title: How can I set an attribute on a functools.partialmethod?
body: <p>I have ported the following code from Django 2.2 to Django 3.1, and replaced <code>django.utils.functional.curry</code> with <code>functools.partialmethod</code>:</p>
  <pre><code>class CurrencyField(models.DecimalField):
      description = 'Currency amount'
  
      def __init__(self, *args, **kwargs):
          kwargs.setdefault('max_digits', 9)
          kwargs.setdefault('decimal_places', 2)
          super().__init__(*args, **kwargs)
  
      def contribute_to_class(self, cls, name):
          super().contribute_to_class(cls, name)
          if hasattr(cls, '_get_value_as_currency'):
              curried = partialmethod(cls._get_value_as_currency, field=self)
              curried.admin_order_field = self.name
              curried.short_description = self.verbose_name
              setattr(cls, f'get_{self.name}_as_currency', curried)
  </code></pre>
  <p>The method works correctly, however the <code>admin_order_field</code> and <code>short_description</code> attributes don't &quot;stick&quot; to the method like they did when I used <code>curry</code>.</p>
  <pre><code>getattr(cls, f'get_{self.name}_as_currency').short_description
  *** AttributeError: 'function' object has no attribute 'short_description'
  </code></pre>
  <p>Is it possible to set attributes on a <code>partialmethod</code>, or will I need to replace this with some other mechanism?</p>