[1.7.x] Edited setup.py in reuseable apps tutorial to use a context manager for open().

Backport of b8d255071e from master