
class FileResolver(object):

    def read(self, path):
        with open(path, 'r') as file:
            return file.read()


class FileResolver(object):

    def read(self, path):
        try:
            with open(path, 'r') as f:
                return f.read()
        except IOError as e:
            raise CfnSphereException("Cannot read file " + path, e) 

Throw CfnSphereException on IOErrors. Fix landmark issue.
Throw  CfnSphereException on IOErrors. Fix landmark issue.

  
  class FileResolver(object):
  
      def read(self, path):
+         try:
-         with open(path, 'r') as file:
+             with open(path, 'r') as f:
-             return file.read()
+                 return f.read()
+         except IOError as e:
+             raise CfnSphereException("Cannot read file " + path, e) 
  
Throw CfnSphereException on IOErrors. Fix landmark issue.
## Code Before:

class FileResolver(object):

    def read(self, path):
        with open(path, 'r') as file:
            return file.read()

## Instruction:
Throw CfnSphereException on IOErrors. Fix landmark issue.
## Code After:

class FileResolver(object):

    def read(self, path):
        try:
            with open(path, 'r') as f:
                return f.read()
        except IOError as e:
            raise CfnSphereException("Cannot read file " + path, e) 
