CODESYS - the IEC 61131-3 automation software

Welcome to the official CODESYS Forum
Deutsche Version English version russian version 
It is currently Mon Mar 19, 2018 7:13 pm

All times are UTC+01:00

Post new topic  Reply to topic  [ 2 posts ] 
Author Message
PostPosted: Thu Jan 18, 2018 11:36 am 

Joined: Mon Oct 20, 2014 7:05 am
Posts: 9
an invalid repository URL given to
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

PostPosted: Thu Mar 08, 2018 4:46 pm 

Joined: Thu Aug 11, 2016 7:15 am
Posts: 1

we use the commandline option from TortoiseSVN with the subprocess module to check the path:

def svn_check_path(URL):
   command = 'CD C:\Program Files\TortoiseSVN\bin' # the shell command
   process = subprocess.Popen(command, stdout=subprocess.PIPE, stderr=None, shell=True)
   command = "svn ls " + URL
   process = subprocess.Popen(command, stdout=subprocess.PIPE, stderr=subprocess.PIPE, shell=True)

   #Launch the shell command:
   output = process.communicate()
   log = output[1].decode("cp1252");
   #Split the logs
   infos = log.splitlines();
   path_missing = False;
   for logs in infos:
      if 'warning' in logs or 'E200009' in logs:
         path_missing = True

Display posts from previous:  Sort by  
Post new topic  Reply to topic  [ 2 posts ] 

All times are UTC+01:00

Who is online

Users browsing this forum: No registered users and 1 guest

You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to:  
Powered by phpBB® Forum Software © phpBB Limited