Welcome to our new forum
All users of the legacy CODESYS Forums, please create a new account at account.codesys.com. But make sure to use the same E-Mail address as in the old Forum. Then your posts will be matched.
Close
Hello,
an invalid repository URL given to
svn.checkout
function leads to an exception.
How can this be handeled?
Is there a possibility to check the validity of the URL before call the interface function?
Thanks in advance.
Kind regards
D. Baur
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
we use the commandline option from TortoiseSVN with the subprocess module to check the path:
defsvn_check_path(URL):
  command='CD C:\Program Files\TortoiseSVN\bin' # theshellcommand
  process=subprocess.Popen(command, stdout=subprocess.PIPE, stderr=None, shell=True)
  process.communicate()
 Â
  command="svn ls "+URL
  process=subprocess.Popen(command, stdout=subprocess.PIPE, stderr=subprocess.PIPE, shell=True)
  #Launchtheshellcommand:
  output=process.communicate()
  log=output[1].decode("cp1252");
  #Splitthelogs
  infos=log.splitlines();
  path_missing=False;
  forlogsininfos:
    if'warning'inlogsor'E200009'inlogs:
      path_missing=True
  return(path_missing)
Hello,
an invalid repository URL given to
svn.checkout
function leads to an exception.
How can this be handeled?
Is there a possibility to check the validity of the URL before call the interface function?
Thanks in advance.
Kind regards
D. Baur
Hi,
we use the commandline option from TortoiseSVN with the subprocess module to check the path:
Related
Talk.ru: 1