src/eric7/QScintilla/Editor.py

branch
server
changeset 10708
a6094987c1be
parent 10704
27d21e5163b8
child 10718
c9252721680b
equal deleted inserted replaced
10707:3df56b1c9570 10708:a6094987c1be
450 raise OSError() 450 raise OSError()
451 451
452 if FileSystemUtilities.isRemoteFileName(self.fileName): 452 if FileSystemUtilities.isRemoteFileName(self.fileName):
453 fileIsRemote = True 453 fileIsRemote = True
454 fileExists = self.__remotefsInterface.exists(self.fileName) 454 fileExists = self.__remotefsInterface.exists(self.fileName)
455 fileSizeKB = self.__remotefsInterface.stat( 455 fileSizeKB = (
456 self.fileName, ["st_size"] 456 self.__remotefsInterface.stat(self.fileName, ["st_size"])[
457 )["st_size"] // 1024 457 "st_size"
458 ]
459 // 1024
460 )
458 else: 461 else:
459 fileIsRemote = False 462 fileIsRemote = False
460 fileExists = pathlib.Path(self.fileName).exists() 463 fileExists = pathlib.Path(self.fileName).exists()
461 fileSizeKB = pathlib.Path(self.fileName).stat().st_size // 1024 464 fileSizeKB = pathlib.Path(self.fileName).stat().st_size // 1024
462 if fileExists: 465 if fileExists:

eric ide

mercurial