Summary

When dialers are not initialized, the template loader now returns nil and logs an error instead of panicking. This allows callers to handle the situation gracefully.

Changes

  • Replace panic(...) with store.logger.Error().Msgf(...) and return nil
  • Follows the broader codebase pattern of returning errors instead of panicking

Before

dialers := protocolstate.GetDialersWithId(typesOpts.ExecutionId)
if dialers == nil {
panic("dialers with executionId " + typesOpts.ExecutionId + " not found")
}

After

dialers := protocolstate.GetDialersWithId(typesOpts.ExecutionId)
if dialers == nil {
store.logger.Error().Msgf("dialers with executionId %s not found, skipping template loading", typesOpts.ExecutionId)
return nil
}

Fixes #6674

/claim #6674

Summary by CodeRabbit

  • Bug Fixes

    • Loading now surfaces errors instead of causing a runtime crash; failures to load templates or missing runtime components are reported and handled without terminating the process.
    • Detects and reports ambiguous template matches (multiple templates) and execution failures more clearly.
  • Tests

    • Tests updated to accommodate the new error-aware loading behavior.

Claim

Total prize pool $200
Total paid $0
Status Pending
Submitted February 02, 2026
Last updated February 02, 2026

Contributors

ER

Erdogan Kervanli

@erdogan98

100%

Sponsors

PR

ProjectDiscovery

@projectdiscovery

$100
MA

Madhavan Deepak

@Madhavan-Deepak

$100