Skip to content
This repository has been archived by the owner on Oct 12, 2023. It is now read-only.

Commit

Permalink
Merge pull request #182 from senrabc/feature/venv_to_gitingnore
Browse files Browse the repository at this point in the history
Feature/venv to gitingnore
  • Loading branch information
nrejac committed Mar 11, 2016
2 parents 7be9f55 + 94d6655 commit 3546115
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 2 deletions.
2 changes: 2 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
*.eggs
venv/
*.pyc
*.pyo
*.egg-info/
Expand Down
5 changes: 3 additions & 2 deletions redi/utils/redcapClient.py
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,7 @@
from requests import RequestException
from requests.packages.urllib3.exceptions import MaxRetryError
from requests.packages.urllib3.exceptions import NewConnectionError
from requests.exceptions import ConnectionError

# Configure module's logger
logger = logging.getLogger(__name__)
Expand Down Expand Up @@ -116,9 +117,9 @@ def send_data_to_redcap(self, data, max_retry_count, overwrite=False,
response = self.project.import_records(data,
overwrite=overwrite_value)
return response
except (MaxRetryError, NewConnectionError) as e:
except (MaxRetryError, NewConnectionError, ConnectionError) as e:
logger.error("Exception encountered: ", exc_info = True)
logger.debug(e.message + ", Attempt no.: " + str(retry_count))
logger.debug(str(e.message) + ", Attempt no.: " + str(retry_count))
if (retry_count == max_retry_count):
message = "Exiting since network connection timed out after"\
" reaching the maximum retry limit for resending data."
Expand Down

0 comments on commit 3546115

Please sign in to comment.