Python Forum
Fatal Python error: initfsencoding: unable to load the file system codec
Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Fatal Python error: initfsencoding: unable to load the file system codec
#1
Good Day Everyone

I am very new to Python programming and created program to compare two csv files and produce a result in Excel. The program worked fine so i created a exe by using pyinstaller. Pyinstaller created the exe with some warning. However, when i am trying to run the exe( from dist folder), i am getting below error:

Fatal Python error: initfsencoding: unable to load the file system codec
zipimport.ZipImportError: can't find module 'encodings'

Below is my current Python Version:
Python 3.6.6 (v3.6.6:4cf1f54eb7, Jun 27 2018, 03:37:03) [MSC v.1900 64 bit (AMD64)] on win32

When i setup PYTHONHOME and PYTHONPATH in the environment variable then i am getting same when i am even trying to open python 3.6 command prompt( before setting up the path, i was able to open the python 3.6 command prompt)

PYTHONHOME
C:\Users\gaurbhardwaj\AppData\Local\Programs\Python\Python37-32

PYTHONPATH
C:\Users\gaurbhardwaj\AppData\Local\Programs\Python\Python37-32\Lib\site-packages

Any help pointer/help would be highly appreciated!

Thanks
Gaurav
Reply


Messages In This Thread
Fatal Python error: initfsencoding: unable to load the file system codec - by gauravbhardwajee - Nov-28-2018, 08:18 PM

Possibly Related Threads…
Thread Author Replies Views Last Post
  (unicode error) 'unicodeescape' codec can't decode bytes in position 2-3: truncated \ Jack_Sparrow 8 128,349 Jul-17-2021, 10:01 AM
Last Post: Afy555
  Error : (FileNotFoundError(2, 'The system cannot find the file specified', None, 2, Shipika 3 3,545 Nov-25-2019, 02:39 PM
Last Post: buran
  Fatal Python error: Aborted rohitlal125555 0 3,514 Nov-12-2019, 05:43 AM
Last Post: rohitlal125555
  Unable to identify Tuple index error appmkl 4 4,703 Jun-28-2019, 10:12 AM
Last Post: appmkl
  Is there any way to properly load fixed width file into a dataframe using Pandas? vicky53 1 3,068 Mar-29-2019, 06:04 PM
Last Post: Larz60+
  Load .abf file and for analysis with Pandas finalcode 0 3,004 Nov-10-2018, 09:51 AM
Last Post: finalcode
  save 2d array to file and load back ian 3 18,298 May-18-2018, 05:00 AM
Last Post: scidam
  Newbie, can't load csv file. david_ford 2 6,576 Apr-15-2018, 01:51 PM
Last Post: snippsat
  Unable to create vtu file from python tady57 2 4,627 Dec-01-2017, 09:58 PM
Last Post: Larz60+
  Unable to understand reason for error IndexError: tuple index out of range rajat2504 4 54,135 Dec-09-2016, 11:04 AM
Last Post: Kebap

Forum Jump:

User Panel Messages

Announcements
Announcement #1 8/1/2020
Announcement #2 8/2/2020
Announcement #3 8/6/2020