- pkg/protocol/ws/client.go
- Changed `break` to `return` to ensure proper error handling flow in `client.go`.
this bug was causing the CPU usage to go very high from fmt.Errorf statements. changed them to errorf.E so they printed and were visible.
- pkg/crypto/p256k/btcec/btcec_test.go
- Added `orly.dev/pkg/utils` import.
- pkg/protocol/ws/client.go
- Commented out unused logging related to filter matching.
- pkg/version/version
- Bumped version from `v0.8.1` to `v0.8.2`.
- pkg/protocol/ws/client.go
- Added logging for received subscription events.
- Optimized subscription ID assignment.
- pkg/protocol/nwc/client.go
- Implemented `Subscribe` function to handle event subscriptions.
- cmd/walletcli/main.go
- Added support for `subscribe` command to handle notifications.
- Replaced `ctx` with `c` for context usage across all commands.
- pkg/crypto/p256k/helpers.go
- Removed unnecessary logging from `HexToBin` function.
- pkg/database/save-event.go
- Added `noVerify` parameter to `SaveEvent` function
- Added check for existing event using `GetSerialById` when `noVerify` is false
- Modified logic to handle event verification based on `noVerify` flag
- pkg/app/relay/server-publish.go
- Added `false` as third argument to `SaveEvent` calls
- pkg/database/export_test.go
- Added `false` as third argument to `SaveEvent` call
- pkg/database/query-for-tags_test.go
- Added `false` as third argument to `SaveEvent` call
- pkg/database/query-for-kinds-authors_test.go
- Added `false` as third argument to `SaveEvent` call
- pkg/database/query-for-kinds-tags_test.go
- Added `false` as third argument to `SaveEvent` call
- pkg/database/query-for-serials_test.go
- Added `false` as third argument to `SaveEvent` call
- main.go
- Modified pprof handling to support different profiling types (cpu, memory, allocation)
- Changed `Pprof` configuration from boolean to string with enum values
- pkg/app/config/config.go
- Changed `Pprof` field type from `bool` to `string` with enum values
- pkg/database/query-for-kinds-authors-tags_test.go
- Added `false` as third argument to `SaveEvent` call
- pkg/version/version
- Bumped version from v0.2.12 to v0.2.13
- pkg/database/fetch-event-by-serial_test.go
- Added `false` as third argument to `SaveEvent` call
- pkg/database/query-for-kinds_test.go
- Added `false` as third argument to `SaveEvent` call
- pkg/database/get-serials-by-range_test.go
- Added `false` as third argument to `SaveEvent` call
- pkg/database/query-events-multiple-param-replaceable_test.go
- Added `false` as third argument to `SaveEvent` calls
- pkg/database/query-events_test.go
- Added `false` as third argument to `SaveEvent` calls
- pkg/interfaces/store/store_interface.go
- Updated `Saver` interface to include `noVerify` parameter in `SaveEvent` method
- Added `SerialByIder` interface with `GetSerialById` method
- pkg/database/save-event_test.go
- Added `false` as third argument to `SaveEvent` calls
- Added new test case for saving existing event
- pkg/database/query-for-ids_test.go
- Added `false` as third argument to `SaveEvent` call
- pkg/protocol/ws/client.go
- Changed comment about context cancellation from "context is canceled" to "context is cancelled"
- pkg/app/relay/spider-fetch.go
- Added signature checker for WebSocket connections
- Modified logic to check for existing events before saving
- Added logging and memory optimization improvements
- Added `Export` method in `database/database.go` to export events to an io.Writer
- Implemented detailed logic for exporting all or specific pubkeys' events
- Removed placeholder `Export` function with TODO comment from `database/database.go`
- Updated error handling in `handleReq.go` and `publisher.go` by using `err != nil` instead of `chk.E(err)`
- Added more detailed logging in privilege check conditions in both `publisher.go` and `handleReq.go`
- Introduced new imports such as `"fmt"` in `connection.go` for improved error message formatting
- Created a new file `export.go` under the `database` package with complete implementation of export functionality