<commit_before>Class {
	#name : #BlTktLoggingCommand,
	#superclass : #BlTktDecoratedCommand,
	#instVars : [
		'callingMethod'
	],
	#category : #'Bloc-TaskIt-Commands'
}

{ #category : #'instance-creation' }
BlTktLoggingCommand class >> valuable: aValuable [

	^self new 
		command: aValuable asBlTktCommand;
		callingMethod: thisContext sender sender method asRingDefinition;
		yourself
]

{ #category : #converting }
BlTktLoggingCommand >> asBlTktLoggingCommand [
	^ self
]

{ #category : #accessing }
BlTktLoggingCommand >> callingMethod [
	^ callingMethod
]

{ #category : #accessing }
BlTktLoggingCommand >> callingMethod: anObject [
	callingMethod := anObject
]

{ #category : #executing }
BlTktLoggingCommand >> execute [
	| aResult |
	BlTaskItSignal emitValuable: self command message: #startExecution callingMethod: callingMethod.
	aResult := self command execute.
	BlTaskItSignal emitValuable: self command message: #doneExecution callingMethod: callingMethod.
	^ aResult
]<commit_msg>log an exception [feenkcom/gtoolkit#380]<commit_after>Class {
	#name : #BlTktLoggingCommand,
	#superclass : #BlTktDecoratedCommand,
	#instVars : [
		'callingMethod'
	],
	#category : #'Bloc-TaskIt-Commands'
}

{ #category : #'instance-creation' }
BlTktLoggingCommand class >> valuable: aValuable [

	^self new 
		command: aValuable asBlTktCommand;
		callingMethod: thisContext sender sender method asRingDefinition;
		yourself
]

{ #category : #converting }
BlTktLoggingCommand >> asBlTktLoggingCommand [
	^ self
]

{ #category : #accessing }
BlTktLoggingCommand >> callingMethod [
	^ callingMethod
]

{ #category : #accessing }
BlTktLoggingCommand >> callingMethod: anObject [
	callingMethod := anObject
]

{ #category : #executing }
BlTktLoggingCommand >> execute [
	| aResult |
	BlTaskItSignal emitValuable: self command message: #startExecution callingMethod: callingMethod.
	[ 
		aResult := self command execute.
		BlTaskItSignal emitValuable: self command message: #doneExecution callingMethod: callingMethod.
	] on: Error do: [ :anException |
		BlTaskItSignal emitValuable: self command message: #exceptionExecution callingMethod: callingMethod.
		anException emit.
		anException pass
	].
	^ aResult
]
{'fraction_non_alphanumeric': 0.10131758291685597, 'fraction_numerical': 0.0013630168105406633, 'mean_word_length': 5.495575221238938, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 23, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '815166', 'n_tokens_mistral': 734, 'n_tokens_neox': 711, 'n_words': 159}