-
-
Notifications
You must be signed in to change notification settings - Fork 32.4k
Closed as not planned
Labels
interpreter-core(Objects, Python, Grammar, and Parser dirs)(Objects, Python, Grammar, and Parser dirs)pendingThe issue will be closed if no feedback is providedThe issue will be closed if no feedback is providedtype-featureA feature request or enhancementA feature request or enhancement
Description
Bug report
Bug description:
dict("")
# {}
dict(" ")
ValueError: dictionary update sequence element #0 has length 1; 2 is required
I can see how an empty string might be intended to return an empty dict
but since " "
is raising an error about the 0th element needing a longer length it seems it isn't looking at the type of the input and an empty string works simply because its length is 0.
CPython versions tested on:
3.11
Operating systems tested on:
Linux
Metadata
Metadata
Assignees
Labels
interpreter-core(Objects, Python, Grammar, and Parser dirs)(Objects, Python, Grammar, and Parser dirs)pendingThe issue will be closed if no feedback is providedThe issue will be closed if no feedback is providedtype-featureA feature request or enhancementA feature request or enhancement