Opened 7 years ago
Last modified 7 years ago
#28623 closed Cleanup/optimization
Docs: handle_uploaded_file(f) .. what is "f"? — at Initial Version
Reported by: | Thomas Güttler | Owned by: | nobody |
---|---|---|---|
Component: | Documentation | Version: | 1.11 |
Severity: | Normal | Keywords: | |
Cc: | Triage Stage: | Unreviewed | |
Has patch: | no | Needs documentation: | no |
Needs tests: | no | Patch needs improvement: | no |
Easy pickings: | no | UI/UX: | no |
Description
https://docs.djangoproject.com/en/1.11/topics/http/file-uploads/
def handle_uploaded_file(f): with open('some/file/name.txt', 'wb+') as destination: for chunk in f.chunks(): destination.write(chunk)
I talked with an other developer about this above code.
I started to stutter.
Why?
Because: What is "f"?
A more verbose name would be great.
Note:
See TracTickets
for help on using tickets.