Pass exception to log.exception as it is not called from within an except: clause. Add Python 3.8 test support, drop Python 3.4 test support.
This commit is contained in:
		
							parent
							
								
									f9e188812f
								
							
						
					
					
						commit
						5630520771
					
				| @ -2,9 +2,9 @@ language: python | ||||
| 
 | ||||
| python: | ||||
|   - 2.7 | ||||
|   - 3.4 | ||||
|   - 3.5 | ||||
|   - 3.6 | ||||
|   - 3.8 | ||||
|    | ||||
| install: pip install tox-travis codecov | ||||
| 
 | ||||
|  | ||||
| @ -95,7 +95,7 @@ class DSMRProtocol(asyncio.Protocol): | ||||
|     def connection_lost(self, exc): | ||||
|         """Stop when connection is lost.""" | ||||
|         if exc: | ||||
|             self.log.exception('disconnected due to exception') | ||||
|             self.log.exception('disconnected due to exception', exc_info=exc) | ||||
|         else: | ||||
|             self.log.info('disconnected because of close/abort.') | ||||
|         self._closed.set() | ||||
|  | ||||
		Loading…
	
		Reference in New Issue
	
	Block a user