mirror of
				https://github.com/paperless-ngx/paperless-ngx.git
				synced 2025-10-30 03:56:23 -05:00 
			
		
		
		
	don't run post-consume script inside transaction #259
This commit is contained in:
		| @@ -252,8 +252,6 @@ class Consumer(LoggingMixin): | |||||||
|                 self.log("debug", "Deleting file {}".format(self.path)) |                 self.log("debug", "Deleting file {}".format(self.path)) | ||||||
|                 os.unlink(self.path) |                 os.unlink(self.path) | ||||||
|  |  | ||||||
|                 self.run_post_consume_script(document) |  | ||||||
|  |  | ||||||
|         except Exception as e: |         except Exception as e: | ||||||
|             self.log( |             self.log( | ||||||
|                 "error", |                 "error", | ||||||
| @@ -264,6 +262,8 @@ class Consumer(LoggingMixin): | |||||||
|         finally: |         finally: | ||||||
|             document_parser.cleanup() |             document_parser.cleanup() | ||||||
|  |  | ||||||
|  |         self.run_post_consume_script(document) | ||||||
|  |  | ||||||
|         self.log( |         self.log( | ||||||
|             "info", |             "info", | ||||||
|             "Document {} consumption finished".format(document) |             "Document {} consumption finished".format(document) | ||||||
|   | |||||||
		Reference in New Issue
	
	Block a user
	 jonaswinkler
					jonaswinkler