pdoc3 / pdoc

:snake: :arrow_right: :scroll: Auto-generate API documentation for Python projects
https://pdoc3.github.io/pdoc/
GNU Affero General Public License v3.0
1.14k stars 146 forks source link

Dataclass arguments should not be interpreted as static members #378

Open amin-nejad opened 2 years ago

amin-nejad commented 2 years ago

Expected Behavior

Dataclass arguments/attributes should display as instance variables

Actual Behavior

Instead they appear as static variables

Steps to Reproduce

  1. Create a simple dataclass. e.g.
from dataclasses import dataclass

@dataclass
class Foo:
    bar: int
  1. Run pdoc
  2. Observe that the bar variable shows up as static

Additional info