Skip to content

Latest commit

 

History

History

Folders and files

NameName
Last commit message
Last commit date

parent directory

..
 
 
 
 
 
 

readme.md

TypeError: missing 1 required positional argument

Occurs when a function is called without required arguments.

reproduce.py

def greet(name):
    print("Hello", name)

greet()

Error Message

TypeError: greet() missing 1 required positional argument: 'name'

Fix

def greet(name):
    print("Hello", name)

greet("Python")

Reflection

Called the function without the required argument.