feat(assessment): add the review band of attempt signals and the disclosed collector
This commit is contained in:
1 parent
68286af8b7
commit
b3c6dc870b
124 files changed
+13522
-633
No files matched your search
@@ -0,0 +1,28 @@
|
||||
// Command assessment-review prints the stored manual-review band of one
|
||||
// assessment attempt for an operator and records the read in an audit table.
|
||||
// It changes nothing else.
|
||||
package main
|
||||
|
||||
import (
|
||||
"context"
|
||||
"fmt"
|
||||
"os"
|
||||
"os/signal"
|
||||
"syscall"
|
||||
|
||||
"lincodex/backend/internal/adapter/primary/cli/assessmentreview"
|
||||
)
|
||||
|
||||
func main() {
|
||||
os.Exit(run())
|
||||
}
|
||||
|
||||
func run() int {
|
||||
ctx, stop := signal.NotifyContext(context.Background(), os.Interrupt, syscall.SIGTERM)
|
||||
defer stop()
|
||||
if err := assessmentreview.Run(ctx, os.Args[1:], os.LookupEnv, os.Stdout); err != nil {
|
||||
_, _ = fmt.Fprintf(os.Stderr, "assessment-review: %v\n", err)
|
||||
return 2
|
||||
}
|
||||
return 0
|
||||
}
|
||||
@@ -314,8 +314,9 @@ func backendQuestionnaireBankOccupied(ctx context.Context, pool *pgxpool.Pool) (
|
||||
return occupied, err
|
||||
}
|
||||
|
||||
// The isolated browser fixture opts into the extended demo policy explicitly.
|
||||
// Normal startup still seeds V1, and an operator's policy must never be replaced.
|
||||
// The isolated browser fixture opts into the extended demo policy explicitly,
|
||||
// including the manual-review band thresholds. Normal startup still seeds V1,
|
||||
// and an operator's policy must never be replaced.
|
||||
func publishFixturePolicy(ctx context.Context, transactor outbound.Transactor) (domain.PolicyVersion, error) {
|
||||
initial, err := domain.NewPolicyVersionDraft(domain.NewPolicyVersionDraftInput{
|
||||
Key: domain.ProductPolicyKey, Kind: domain.PolicyKindDemo,
|
||||
@@ -344,7 +345,7 @@ func publishFixturePolicy(ctx context.Context, transactor outbound.Transactor) (
|
||||
}
|
||||
version, err = policy.NewPublisher(unit.Policies(), func() time.Time { return databaseTime }).Publish(ctx, policy.PublishInput{
|
||||
Key: domain.ProductPolicyKey, Kind: domain.PolicyKindDemo,
|
||||
Author: domain.PolicyAuthor(fixtureAuthor), Policy: domain.DemoProductPolicyV2(),
|
||||
Author: domain.PolicyAuthor(fixtureAuthor), Policy: domain.DemoProductPolicyV3(),
|
||||
})
|
||||
return err
|
||||
})
|
||||
|
||||
Reference in new issue
Block a user