argilla icon indicating copy to clipboard operation
argilla copied to clipboard

[REFACTOR] Align `@abstractmethod` definition within `argilla`

Open alvarobartt opened this issue 1 year ago • 2 comments

Is your feature request related to a problem? Please describe.

As of the Python documentation the usage of @abstractproperty is discouraged and deprecated since Python 3.3, so we should stop using those in the first place, replacing them with @property + @abstractmethod.

Then regarding the body of those @abstractmethods we should define an standard way of defining those.

Describe the solution you'd like

  • Adding a one-line docstring

    from abc import abstractmethod
    
    class A:
       ...
    
       @abstractmethod
       def implement_me(self) -> None:
          """This is a docstring"""
    
  • Adding pass

    from abc import abstractmethod
    
    class A:
       ...
    
       @abstractmethod
       def implement_me(self) -> None:
          pass
    
  • Adding ...

    from abc import abstractmethod
    
    class A:
       ...
    
       @abstractmethod
       def implement_me(self) -> None:
          ...
    

alvarobartt avatar Oct 13 '23 09:10 alvarobartt

@frascuchon @jfcalvo @gabrielmbmb

davidberenstein1957 avatar Oct 31 '23 09:10 davidberenstein1957

This issue is stale because it has been open for 90 days with no activity.

github-actions[bot] avatar Jan 30 '24 01:01 github-actions[bot]

This issue was closed because it has been inactive for 30 days since being marked as stale.

github-actions[bot] avatar May 04 '24 01:05 github-actions[bot]