Skip to content

Is it safe to override __init__ for a PClass? #305

@travis-leith

Description

@travis-leith

Currently, PClass exposed constructors of the form MyClass(**kwargs: Any).
If I want to support static type checking, I need a factory method. But if I want to prevent people from using the standard constructor, I need to overrde __init__. Is this a safe thing to do or might it break something?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions