Add runTaskUnhandled to Extracted

This commit is contained in:
Billy Autrey 2025-09-15 11:17:19 -05:00
parent 8193d6befb
commit f8903ab37a
No known key found for this signature in database
GPG Key ID: F86AD21E31257794
1 changed files with 9 additions and 0 deletions

View File

@ -66,6 +66,15 @@ final case class Extracted(
(newS, EvaluateTask.processResult2(result))
}
/**
* Runs the task specified by `key` and returns the unhandled direct result of EvaluateTask.
*
* This method differs from `runTask` in that it does not unwrap the option, or process results.
*/
def runTaskUnhandled[T](key: TaskKey[T], state: State): Option[(State, Result[T])] =
val config = extractedTaskConfig(this, structure, state)
EvaluateTask(structure, key.scopedKey, state, currentRef, config)
/**
* Runs the input task specified by `key`, using the `input` as the input to it, and returns the transformed State
* and the resulting value of the input task.