Open Issues Need Help
View All on GitHubAI Summary: The task involves modifying the validation logic within the `go-header` library's syncer. Specifically, the condition checking for the absence of synchronization parameters (`SyncFromHeight`, `SyncFromHash`, `PruningWindow`) needs to be corrected to ensure that only when all three are simultaneously zero or empty, the validation fails. This requires updating a conditional statement in the `options.go` file.
Go library with all the services needed to request, sync and store blockchain headers.
AI Summary: Optimize the `go-header` library's head and tail advancement algorithms. The current linear iteration and full header loading should be replaced with a more efficient method that only checks for header presence, similar to the existing `Has` method. This will improve performance by avoiding unnecessary header loading.
Go library with all the services needed to request, sync and store blockchain headers.
AI Summary: Migrate all instances of `context.WithTimeout` in the `go-header` library to `context.WithTimeoutCause`. This improves error handling by providing more informative error messages when timeouts occur, replacing the generic "context deadline exceeded" with the specific cause of the timeout.
Go library with all the services needed to request, sync and store blockchain headers.
AI Summary: The task involves refactoring the `go-header` Go library's data store to replace the use of `Batch` operations with database transactions (`Txn`) for improved atomicity, particularly in methods like `DeleteTo`. This ensures that multiple deletions are performed atomically, preventing inconsistencies. The refactoring requires identifying all places where `Batch` is used inappropriately and replacing them with `Txn`.
Go library with all the services needed to request, sync and store blockchain headers.