mirror of
				https://github.com/paperless-ngx/paperless-ngx.git
				synced 2025-10-30 03:56:23 -05:00 
			
		
		
		
	logging before executing pre and post consume scripts
This commit is contained in:
		| @@ -115,6 +115,9 @@ class Consumer(LoggingMixin): | |||||||
|                 f"Configured pre-consume script " |                 f"Configured pre-consume script " | ||||||
|                 f"{settings.PRE_CONSUME_SCRIPT} does not exist.") |                 f"{settings.PRE_CONSUME_SCRIPT} does not exist.") | ||||||
|  |  | ||||||
|  |         self.log("info", | ||||||
|  |                  f"Executing pre-consume script {settings.PRE_CONSUME_SCRIPT}") | ||||||
|  |  | ||||||
|         try: |         try: | ||||||
|             Popen((settings.PRE_CONSUME_SCRIPT, self.path)).wait() |             Popen((settings.PRE_CONSUME_SCRIPT, self.path)).wait() | ||||||
|         except Exception as e: |         except Exception as e: | ||||||
| @@ -135,6 +138,11 @@ class Consumer(LoggingMixin): | |||||||
|                 f"{settings.POST_CONSUME_SCRIPT} does not exist." |                 f"{settings.POST_CONSUME_SCRIPT} does not exist." | ||||||
|             ) |             ) | ||||||
|  |  | ||||||
|  |         self.log( | ||||||
|  |             "info", | ||||||
|  |             f"Executing post-consume script {settings.POST_CONSUME_SCRIPT}" | ||||||
|  |         ) | ||||||
|  |  | ||||||
|         try: |         try: | ||||||
|             Popen(( |             Popen(( | ||||||
|                 settings.POST_CONSUME_SCRIPT, |                 settings.POST_CONSUME_SCRIPT, | ||||||
|   | |||||||
		Reference in New Issue
	
	Block a user
	 jonaswinkler
					jonaswinkler