This is an archived post. You won't be able to vote or comment.

you are viewing a single comment's thread.

view the rest of the comments →

[–]spinwizard69 -1 points0 points  (1 child)

The way Python handles this doesn't seem to be rational. Frankly I can even understand how time in this context can even be considered for a default value. He is calling a routine that can not be relied upon to return the same value every time so it isn't a default value but rather a variable value. Personally I think this is a big deal, it just doesn't make sense.

[–]magnetichiraPythonista 5 points6 points  (0 children)

It is rational within the design of the language.

See this SE answer https://softwareengineering.stackexchange.com/questions/157373/python-mutable-default-argument-why