diff --git a/CHANGELOG.md b/CHANGELOG.md index 30c15a500..7f8d43e61 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -8,8 +8,15 @@ The format is based on [Keep a Changelog], and this project adheres to [Semantic ### Added -- evm.node: Requesting logs for multiple blocks at once for EVM nodes to improve performance -- evm.subsquid: Added metrics for Subsquid Cloud deploy. +- evm.subsquid: Added Prometheus metrics required for Subsquid Cloud deployments. + +### Fixed + +- cli: Don't suppress uncaught exceptions when performance monitoring is disabled. + +### Performance + +- evm.subsquid.events: Request logs in batches to speed up the last mile indexing. ### Security diff --git a/src/dipdup/cli.py b/src/dipdup/cli.py index 2818acc1c..baa19aa5c 100644 --- a/src/dipdup/cli.py +++ b/src/dipdup/cli.py @@ -86,7 +86,7 @@ def red_echo(message: str) -> None: echo(message, err=True, fg='red') -def _print_help(error: Exception, report_id: str) -> None: +def _print_help_atexit(error: Exception, report_id: str) -> None: """Prints a helpful error message after the traceback""" from dipdup.exceptions import Error @@ -123,12 +123,10 @@ async def wrapper(ctx: click.Context, *args: Any, **kwargs: Any) -> None: except Exception as e: package = ctx.obj.config.package if ctx.obj else 'unknown' report_id = save_report(package, e) - _print_help(e, report_id) - - if metrics: - raise e - sys.exit(1) + _print_help_atexit(e, report_id) + raise e + # NOTE: If indexing was interrupted by signal, save report with just performance metrics. if fn.__name__ == 'run': package = ctx.obj.config.package save_report(package, None)