Level 1 : What is the purpose of the __init_subclass__ method in Python?

Author: IndraD | Tags: __init_subclass__ | 1859+ Python FAQs | Share
syntax-error | creating-custom-modules | identity-operator | bitwise-operator | append | __all__-attribute | async | classes | command-line-parsing | arithmetic-expression | arithmetic-operation | indentation | list-comprehension | expand-tab | test-discovery | inheritance | function-and-scope | virtual-environment | comment | working-with-temporary-files-using-tempfile | threading | string-formatting | higher-order-function | inherit | goto-function | variable | mathematics | basic | sys | parameter | format | string | escape-operator | regex | access-modifier | sorting | memory | tuples | floats | using-os-and-pathlib-modules | integers | operator | booleans | implementation | list | __future__ | list-methods-and-slicing | operator-and | set-operation | introduction-to-threads | thread | identity-operator | working-with-binary-files-(rb,-wb) | advanced-file-operations | touples | string-slicing | array | range | invalid-list | assignment-operator | built-in-function | built-in-modules | assignment-operators | choice | precedence-and-associativity | boolean | encoding | string-concatenation | logical-operator | version-check | boolean-masking | version | pseudocode | raise | rollback | binary-operation | aggregating-data-with-functools.reduce() | using-lists-as-stacks | strings | operand | package-management | method-overloading | expression | literal-characters-and-special-characters | comparison | directory-operations | math-copysign | lists | string-methods | pickling--unpickling | frozenset | multiple-inheritance | collections | working-with-dates-and-times | asyncio-module | binary | multiple-inheritance | multiple-except-blocks | class-and-instance-variable | functions | list-method | collection | matplotlib | using-join()-and-is_alive()-methods | class | raise-statement | counter-function | map-function | destructor | file_handling | loop | int | while-else-loop | reading-and-writing-large-files-efficiently | conversion | objects | recursion | __init_subclass__ | lambda-functions | shallow-copy | syntax-error | overflow | application | typeerror | object-attribute | syntaxerror | comprehension | string-slicing | math | class-decorators | input | python-repl | anchors-(^,-$) | iterator | loop-control-statements | zip | introduction-to-multiprocessing | indexing:-loc-vs-iloc | numeric | datetime | working-with-file-paths | list-join | slice | zfill-function | filter | match | control-flow | key-value-pairs | class-and-inheritance | return-statement | name-mangling | call | list-vs-tuple | static-method | membership-operators-(in,-not-in) | arbitrary-arguments-(*args,-**kwargs) | mysql | difference-between-threads-and-processes | regular-expression | head-and-tail | slicing | numpy | unit-testing | quantifiers-(*,-+,-?,-{}) | random | methods | bitwise | immutability | set | built-in-function | creating-and-starting-threads | thread-synchronization | type-conversion-and-casting | interpreter | type-conversion | lambda | assert | zip-function | class-and-object | while-and-for-loop | list-operation | filtering-and-indexing | deep-copy | tuple | attribute | list-slicing | data-type-conversions | time-series-with-pandas | descriptors | loop-control | intering | identity-operators-(is,-is-not) | counter | reading:-read(),-readline(),-readlines() | introduction-to-python | file-handling | encapsulation | filter-function | center | why-use-multiprocessing-over-threading?-(gil) | defining-functions | decimal | bitwise-operator | gil | while-loop | statement | logical-operator | sum-function | library | indexing | method | global-variable | benefit | compute | module | matrix | input-function | error-handling | exception-handling | id-function | built-in | boolean-and-non-boolean | control-statement | tuple-unpacking | asyncio | magic-method | sys-module | string-iteration | def | matrix-list-comprehension | multiprocessing | loops | list-comprehensions | type_conversion | global | list-comprehension | constructor | lambdas | list-indexing | python-module | python-operators | for | python | round-function | dictionaries | debugging | python-syntax-and-structure | conditional-statement | datetime.date,-datetime.time,-datetime.datetime | nested-loop | pass | global-keyword | formal-and-actual-parameter | default-mutable-argument | data-types | iterators | sets | lambda-function | virtual-environment | functional-programming | copy | data-structure | python-history | tuple-methods | using-the-threading-module | floating-point-precision | context-manager | global-variable | using-map()-for-transformations | control-flow | random-function | while-loops | data-structures | namespace | data-type | split | using-assertions-(assertequal,-assertraises) | recurssion | turtle | yield | odd-number | oop | import-method | heap-memory | sorted | sorting-and-ranking | string-formatting | overriding-methods | data-structures-in-python | python_version | postfix | using-yield-in-functions | default-arguments | polymorphism | thread-safe-data-structures-(queue.queue) | swapping | walking-through-directories-using-os.walk() | data-structure | oops | joining-and-merging-dataframes | data-type | type-conversion | formatting-with-strftime | condition | identifier | print | operators | handling-missing-values-(fillna,-dropna) | generators | print-statement | feature | dicts | reading-and-writing-files | opening-files-(open()) | using-else-and-finally | datatype | join | writing:-write(),-writelines() | design-principle | dictionary-comprehensions | pandas | exception | operations | with-statement | update | logical-operation | syntax | python-django | conditional-statement | mapping-function | integer | conditional-statements | immutable-data-type | dictionary-methods | data_structure | docstring | round | file | max-min | stack | factorial-function | complex | operator-or | dictionary | generator | exponentiation | operator-overloading | error-handling | keyword | decorator | input-function | software-design | dataframe-and-series-objects | string-method | generators-in-python | regular-expressions | complex-number | parsing-with-strptime | string-method | memory-management | file-handling | logical-operators | function | exception-handling | else | min-max-function | iterable | function-argument | mathematical-function | precedence | min-function | managing-directories-with-os-and-shutil | error | namedtuple | scientific-notation | sum() | list,-set,-and-dictionary-comprehensions | single-inheritance | else-statement | functional-programming | list-mutation | mutable | staticmethod | init | string-manipulation | multithreading | fabs-function | enumerate() | pep | installation ...