1,129 matching pages, found in 222 ms

Ask StyxWritten on your GPU machine; takes a few seconds the first time.

  1. discuss.python.orghttps://discuss.python.org › t › class-variables › 18214
    More about discuss.python.org
    Class variables - Python Help - Discussions on Python.org

    ForumAug 14, 2022. … it goes on to the class, and the superclasses. So looking up instance.attr will also return ‘from the class’. But when we assign to the instance attribute: instance.attr = 'from the instance' now …

    0 points
  2. discuss.python.orghttps://discuss.python.org › t › accessing-attributes-of-a-class › 13873
    More about discuss.python.org
    Accessing attributes of a class - Python Help - Discussions on Python.org

    ForumFeb 22, 2022. … if dir() on a class reported the methods and properties that its metaclass defines for the class object in addition to the methods and properties that the class defines for its instances …

    0 points
  3. discuss.python.orghttps://discuss.python.org › t › docstrings-threated-differentl… › 7988
    More about discuss.python.org
    Docstrings threated differently for static method and class method - Python Help - Discussions on Python.org

    ForumMar 30, 2021. … help(Foo) I get the docstring of the Callable class for the class method but not the static method? Help on class Foo in module foo: class Foo(builtins.object) | Class methods defined …

    0 points
  4. discuss.python.orghttps://discuss.python.org › t › class-composition-between-two-… › 37531
    More about discuss.python.org
    Class Composition Between Two Classes - Python Help - Discussions on Python.org

    ForumOct 31, 2023. … Issue 1 I referenced the tk.Tk class as the ‘master’ class because the code snippet is based on this module. Additionally, in my test snippet: Login - Base class (inheriting from the tk.Tk …

    0 points
  5. discuss.python.orghttps://discuss.python.org › t › add-syntax-for-annotating-a-fu… › 105799
    More about discuss.python.org
    Add syntax for annotating a function/class - Ideas - Discussions on Python.org

    ForumJan 19, 2026. … you're skipping, start from the paragraph above me from typing import Sealed class Node :: Sealed[Leaf, Branch]: ... class Leaf(Node): ... class Branch(Node): ... It’s an actual annotation on the class, not a …

    0 points
  6. discuss.python.orghttps://discuss.python.org › t › doing-something-evil-deleting-… › 19184
    More about discuss.python.org
    Doing something evil: deleting a class (not instance) from memory - Python Help - Discussions on Python.org

    ForumSep 16, 2022. … Namely, if one of the classes is renamed, or one of the classes is removed, it will still be in memory in the interpreter, and when the parent class cycles through all …

    0 points
  7. discuss.python.orghttps://discuss.python.org › t › def-and-class-words-like-an-op… › 41446
    More about discuss.python.org
    Def and class words like an option - Ideas - Discussions on Python.org

    ForumDec 19, 2023. … is accepting arguments and classes inherenting from parent classes add(a,b): #function add(parent1, parent2): #class How would the parser tell the difference between the two? Unless you wanna enforce case …

    0 points
  8. discuss.python.orghttps://discuss.python.org › t › dataclass-transform-inheriting… › 55734
    More about discuss.python.org
    Dataclass_transform - Inheriting class doesn't recognize kw_only=True from parent class - Typing - Discussions on Python.org

    ForumJun 14, 2024. Dataclass_transform - Inheriting class doesn't recognize kw_only=True from parent class Typing Avishayy (Avishay Matayev) June 14, 2024, 5:13am 1 Following the post on the mypy issue tracker – PEP-681 …

    0 points
  9. discuss.python.orghttps://discuss.python.org › t › class-coding-and-usage › 25616
    More about discuss.python.org
    Class coding and usage - Python Help - Discussions on Python.org

    ForumApr 9, 2023. … As suggested your Movie class could know how to play() the movie, access IMDB to return a list of actors, etc. Without the methods the class is missing that behaviour. What is …

    0 points
  10. discuss.python.orghttps://discuss.python.org › t › basic-atm-machine-calling-a-cl… › 14166
    More about discuss.python.org
    Basic ATM machine - calling a class within another class - Python Help - Discussions on Python.org

    ForumMar 10, 2022. … am trying to create the confirmation number using an f-string. The problem is with the way I am calling the TimeZone class embedded within the Account class within the deposit() method …

    0 points

Search for “The Class site:discuss.python.org” on Google, or add !ddg, !w and other shortcuts to any search.