code: def get_version():
      
      try:
          version_file = open(os.path.join(ROOT_DIR, 'mollie', 'api', 'version.py'), encoding='utf=8')
      except TypeError:
          # support python 2
          version_file = open(os.path.join(ROOT_DIR, 'mollie', 'api', 'version.py'))
      contents = version_file.read()
      match = re.search(r'VERSION = [\'"]([^\'"]+)', contents)
      if match:
          return match.group(1)
      else:
          raise RuntimeError("Can't determine package version")
docs: Read the version from a file (mollie/api/version.py) in the repository.
  
      We can't import here since we might import from an installed version.