In other words, please change this
{{{
# Create a Python file object using open() and the with statement
>>> with open('/tmp/hello.world', 'w') as f:
>>> myfile = File(f)
...
}}}
to this
{{{
# Create a Python file object using open() and the with statement
>>> with open('/tmp/hello.world') as f:
>>> myfile = File(f)
...
}}}
--
Ticket URL: <https://code.djangoproject.com/ticket/20604>
Django <https://code.djangoproject.com/>
The Web framework for perfectionists with deadlines.
* status: new => closed
* resolution: => fixed
Comment:
In [changeset:"a1122e14a6d2ace8907923507e7d31c44a6f7c68"]:
{{{
#!CommitTicketReference repository=""
revision="a1122e14a6d2ace8907923507e7d31c44a6f7c68"
Fixed #20604 - Fixed file example in docs.
Thanks Chris Lasher for the report.
}}}
--
Ticket URL: <https://code.djangoproject.com/ticket/20604#comment:1>
Comment (by Tim Graham <timograham@…>):
In [changeset:"e411e9931272cd22247095fc2af8d26d58eeddd6"]:
{{{
#!CommitTicketReference repository=""
revision="e411e9931272cd22247095fc2af8d26d58eeddd6"
[1.5.x] Fixed #20604 - Fixed file example in docs.
Thanks Chris Lasher for the report.
Backport of a1122e14a6 from master
}}}
--
Ticket URL: <https://code.djangoproject.com/ticket/20604#comment:2>