nim-codex/codex
Eric de88fd2c53
feat: create logging proxy (#663)
* implement a logging proxy

The logging proxy:
- prevents the need to import chronicles (as well as export except toJson),
- prevents the need to override `writeValue` or use or import nim-json-seralization elsewhere in the codebase, allowing for sole use of utils/json for de/serialization,
- and handles json formatting correctly in chronicles json sinks

* Rename logging -> logutils to avoid ambiguity with common names

* clean up

* add setProperty for JsonRecord, remove nim-json-serialization conflict

* Allow specifying textlines and json format separately

Not specifying a LogFormat will apply the formatting to both textlines and json sinks.

Specifying a LogFormat will apply the formatting to only that sink.

* remove unneeded usages of std/json

We only need to import utils/json instead of std/json

* move serialization from rest/json to utils/json so it can be shared

* fix NoColors ambiguity

Was causing unit tests to fail on Windows.

* Remove nre usage to fix Windows error

Windows was erroring with `could not load: pcre64.dll`. Instead of fixing that error, remove the pcre usage :)

* Add logutils module doc

* Shorten logutils.formatIt for `NBytes`

Both json and textlines formatIt were not needed, and could be combined into one formatIt

* remove debug integration test config

debug output and logformat of json for integration test logs

* Use ## module doc to support docgen

* bump nim-poseidon2 to export fromBytes

Before the changes in this branch, fromBytes was likely being resolved by nim-stew, or other dependency. With the changes in this branch, that dependency was removed and fromBytes could no longer be resolved. By exporting fromBytes from nim-poseidon, the correct resolution is now happening.

* fixes to get compiling after rebasing master

* Add support for Result types being logged using formatIt
2024-01-22 23:35:03 -08:00
..
blockexchange feat: create logging proxy (#663) 2024-01-22 23:35:03 -08:00
contracts feat: create logging proxy (#663) 2024-01-22 23:35:03 -08:00
erasure feat: create logging proxy (#663) 2024-01-22 23:35:03 -08:00
manifest feat: create logging proxy (#663) 2024-01-22 23:35:03 -08:00
merkletree Build slots (#668) 2024-01-11 08:45:23 -08:00
purchasing feat: create logging proxy (#663) 2024-01-22 23:35:03 -08:00
rest feat: create logging proxy (#663) 2024-01-22 23:35:03 -08:00
sales feat: create logging proxy (#663) 2024-01-22 23:35:03 -08:00
slots feat: create logging proxy (#663) 2024-01-22 23:35:03 -08:00
stores feat: create logging proxy (#663) 2024-01-22 23:35:03 -08:00
streams feat: create logging proxy (#663) 2024-01-22 23:35:03 -08:00
utils feat: create logging proxy (#663) 2024-01-22 23:35:03 -08:00
blockexchange.nim Change every dagger to codex (#102) 2022-05-19 13:56:03 -06:00
blocktype.nim feat: create logging proxy (#663) 2024-01-22 23:35:03 -08:00
chunker.nim feat: create logging proxy (#663) 2024-01-22 23:35:03 -08:00
clock.nim feat: update expiry when data downloaded and slot filled (#619) 2023-11-22 10:09:12 +00:00
codex.nim feat: create logging proxy (#663) 2024-01-22 23:35:03 -08:00
codextypes.nim Build slots (#668) 2024-01-11 08:45:23 -08:00
conf.nim feat: create logging proxy (#663) 2024-01-22 23:35:03 -08:00
contracts.nim feat: contract address management (#405) 2023-05-03 09:24:25 +02:00
discovery.nim feat: create logging proxy (#663) 2024-01-22 23:35:03 -08:00
erasure.nim Improving proc/func formatting consistency (#454) 2023-06-22 08:11:18 -07:00
errors.nim Build slots (#668) 2024-01-11 08:45:23 -08:00
indexingstrategy.nim Wire sampler (#676) 2024-01-17 11:24:34 -08:00
logutils.nim feat: create logging proxy (#663) 2024-01-22 23:35:03 -08:00
manifest.nim Update multicodecs (#665) 2023-12-22 13:04:01 +01:00
market.nim chore: improve log information (#656) 2023-12-19 04:29:18 +00:00
merkletree.nim Build slots (#668) 2024-01-11 08:45:23 -08:00
namespaces.nim Blockexchange uses merkle root and index to fetch blocks (#566) 2023-11-14 13:02:17 +01:00
node.nim feat: create logging proxy (#663) 2024-01-22 23:35:03 -08:00
periods.nim Validator (#387) 2023-04-19 15:06:00 +02:00
purchasing.nim Storage/purchases endpoint (#609) 2023-11-13 11:30:27 +00:00
rng.nim track latest nim-libp2p's master branch (#248) 2022-11-02 11:40:28 -06:00
sales.nim feat: create logging proxy (#663) 2024-01-22 23:35:03 -08:00
slots.nim Wire sampler (#676) 2024-01-17 11:24:34 -08:00
stores.nim Rework merkle tree (#654) 2023-12-21 06:41:43 +00:00
streams.nim adding AsyncStreamWrapper (#110) 2022-06-14 09:19:35 -06:00
systemclock.nim Blockstore maintenance (#347) 2023-03-08 16:04:54 +01:00
units.nim feat: create logging proxy (#663) 2024-01-22 23:35:03 -08:00
utils.nim Rework merkle tree (#654) 2023-12-21 06:41:43 +00:00
validation.nim feat: create logging proxy (#663) 2024-01-22 23:35:03 -08:00