From c72f5902a8e84ea0f611448c3103b814c66d9b13 Mon Sep 17 00:00:00 2001 From: Abhishek Soni Date: Sun, 15 Jul 2018 19:38:44 +0530 Subject: [PATCH] close the file after reading --- emotions.ipynb | 1 + utilities.py | 1 + 2 files changed, 2 insertions(+) diff --git a/emotions.ipynb b/emotions.ipynb index fc0a403..20f3a57 100644 --- a/emotions.ipynb +++ b/emotions.ipynb @@ -45,6 +45,7 @@ "def cleanText(filename): \n", " chat = open(filename)\n", " chatText = chat.read()\n", + " chat.close()\n", "\n", " # 01/09/17, 11:34 PM - Amfa:\n", "\n", diff --git a/utilities.py b/utilities.py index ca968e6..b7adf9b 100644 --- a/utilities.py +++ b/utilities.py @@ -13,6 +13,7 @@ def cleanText(filename): chat = open(filename) chatText = chat.read() + chat.close() # 01/09/17, 11:34 PM - Amfa: