title: Uploading text file dictionary to python dictionary is not working
body: <p>I created a dictionary with data in this format in python. This is what my product.txt file contains</p>
  <blockquote>
  <p>{&quot;6TII7N11RJ0J&quot;: {&quot;productName&quot;: &quot;Hisense 58&quot; Class 4K UHD LED Roku Smart TV HDR 58R6E3&quot;, &quot;productDescription&quot;: &quot;58 Hisense 4k Roku Tv W/ Hdr&quot;, &quot;productLocation_section&quot;: &quot;N/A&quot;, &quot;productLocation_zone&quot;: &quot;N/A&quot;, &quot;productLocation_aisle&quot;: &quot;N/A&quot;, &quot;productImg&quot;: &quot;http://i5.walmartimages.com/asr/e00046a4-2eb3-48dc-b9ab-f0b750c384a7_1.fbb6003cb707252842bc913860c28568.jpeg?odnHeight=180&amp;odnWidth=180&amp;odnBg=ffffff&quot;, &quot;productImg1&quot;: &quot;/ip/Hisense-58-Class-4K-UHD-LED-Roku-Smart-TV-HDR-58R6E3/587182688&quot;, &quot;productPrice&quot;: 278, &quot;product_stock_status&quot;: &quot;In Stock&quot;, &quot;productBrand&quot;: &quot;Hisense&quot;, &quot;productRating&quot;: 4.5, &quot;productDept&quot;: &quot;Electronics&quot;, &quot;store_available&quot;: &quot;walmart&quot;, &quot;_partitionKey&quot;: &quot;store=name&quot;, &quot;storeProductId&quot;: &quot;6TII7N11RJ0J&quot;}, &quot;3MI7DUPI5M39&quot;: {&quot;productName&quot;: &quot;Hisense 40&quot; Class FHD (1080P) Roku Smart LED TV (40H4030F1)&quot;, &quot;productDescription&quot;: &quot;Hisense 40&quot; Class 1080P FHD LED Roku Smart TV 40H4030F1&quot;, &quot;productLocation_section&quot;: 6, &quot;productLocation_zone&quot;: &quot;J&quot;, &quot;productLocation_aisle&quot;: 23, &quot;productImg&quot;: &quot;http://i5.walmartimages.com/asr/104b5bcf-e7da-497b-87f6-0a5a56249d27_1.5c18e44aae7893f3044b2aeeed360603.jpeg?odnHeight=180&amp;odnWidth=180&amp;odnBg=ffffff&quot;, &quot;productImg1&quot;: &quot;/ip/Hisense-40-Class-FHD-1080P-Roku-Smart-LED-TV-40H4030F1/470905078&quot;, &quot;productPrice&quot;: 178, &quot;product_stock_status&quot;: &quot;Out of Stock&quot;, &quot;productBrand&quot;: &quot;Hisense&quot;, &quot;productRating&quot;: 4.5, &quot;productDept&quot;: &quot;Electronics&quot;, &quot;store_available&quot;: &quot;walmart&quot;, &quot;_partitionKey&quot;: &quot;store=walmart&quot;, &quot;storeProductId&quot;: &quot;3MI7DUPI5M39&quot;}</p>
  </blockquote>
  <p>product.txt file's content were created through this code</p>
  <pre><code>  try:
          # WRITE THE PRODUCT TO FILE
          productFile = &quot;storeData/store/productDir.txt&quot;
          with open(productFile, &quot;w&quot;) as pfile:
              pfile.write(json.dumps(NewProductDict))
      except Exception as e:
          print(e)  
  </code></pre>
  <p>now I need to open product.txt file and read the content back into a dictionary in python. This is one of many codes i tried.</p>
  <pre><code>def uploadProductDir():
      productFile1 = &quot;storeData/store/productDir.txt&quot;
      with open(productFile1, &quot;r&quot;) as pfile:
            developer = json.load(pfile)
      for key, value in developer.items():
          print(key, &quot;:&quot;, value, &quot;\n&quot;)
  </code></pre>
  <p>but i am getting this error</p>
  <blockquote>
  <p>Expecting value&quot;, s, err.value) from None
  json.decoder.JSONDecodeError: Expecting value: line 1 column 1 (char 0)</p>
  </blockquote>
  <p>how could I upload a text file containing dictionary data format above in python so that i can iterate through the dictionary. This was a python json dictionary that i mistakenly saved to a .txt instead of .json file. Now I want to import from the .txt file back in python so that i can work with the data.</p>