Commit Graph
14 Commits
Author SHA1 Message Date
iamamyth cb91dcee36 tests: Speed up p2p reorg test
Use a fixed, 240s deadline for the daemons to reach agreement and poll
with a suitable frequency (.25s), rather than polling up to 100 times at
roughly 10s intervals.
2025-03-24 11:18:57 -07:00
iamamythandlaanwj 446d9622f8 logging: Generalize terminal color detection
Assume the terminal supports color codes if TERM ends with `-color` or
`-256color`, rather than special-casing a handful of such terminals.

Add tests for terminal color detection.

Co-authored-by: laanwj <126646+laanwj@users.noreply.github.com>
2025-03-24 11:07:33 -07:00
iamamyth 8c43e33e35 logging: Fix easylogging++ init with blank config
The upstream version of el::base::TypedConfigurations::unsafeGetConfigByRef
accesses uninitialized memory if a key doesn't exist.
Commit b2c59af84d patched the library to
throw in this case, avoiding the invalid access, but the more suitable
pattern, both logically, and as evidenced by the behavior of
unsafeGetConfigByVal, would be to return a const reference to a
default-initialized value with static storage duration.
2025-02-19 15:02:08 -08:00
iamamyth 950ddbf30e tests: Improve p2p tx propagation functional test
Reduce the likelihood of false positive failures in the p2p
transaction propagation functional test by waiting up to a
maximum timeout for a transaction to propagate, rather than using a
fixed timeout, to reflect the random delay of Dandelion++ transaction
propagation. This strategy also speeds test execution in cases where
propagation occurs faster than the previously expected fixed delay.
2025-02-11 18:30:16 -08:00
iamamyth 274b5748da tests: Improve functional_tests_rpc startup
* Use a global startup timeout, and apply it to each socket's connect
  call, rather than repeating connection attempts with short timeouts.

* Avoid leaking sockets by closing them.
2025-01-31 21:15:20 -08:00
iamamyth ad782ded1d utils: Simplify python RPC Response implementation
Reduce bloat in the python RPC Response class by making better use of
superclass methods and recursion. As part of this change, add tests for
the Response class.
2025-01-31 17:47:55 -08:00
iamamyth b2140b6287 ci: Parallelize Arch Linux build
The "--parallel" flag got dropped from the Arch Linux build due to
unidentified, logical commit conflicts.
2025-01-25 15:11:04 -08:00
iamamyth f48a73d919 tests: Fix tools::is_hdd unit tests
Correct the unit tests for tools::is_hdd to avoid making assumptions
about the configuration of a particular device based solely on the
value of the __GLIBC__ preprocessor flag. Instead, rely on the
test invoker to provide paths for devices of specific types via
the process environment, thereby avoiding faulty assumptions and
improving the specificity of test assertions. To ensure appropriate
devices exist, add a script, tests/create_test_disks.sh, which
configures loopback devices mirroring relevant configurations.
2025-01-24 23:11:47 -08:00
iamamyth f18b966a96 build: auto-set GitHub runner make job count
Dynamically determine an appropriate number of make jobs for the GitHub
runner container, based upon the number of available CPU cores and RAM,
using the rule that each job requires a dedicated core and 2.25GiB of RAM.
2025-01-16 11:53:46 -08:00
iamamyth 4feb6b3e29 crypto: remove unused POD classes
Remove the following unused classes from the crypto namespace:
public_keyV, secret_keyV, and public_keyM.
2025-01-10 12:00:19 -08:00
iamamyth 07d93f01ad common: Remove resolved FIXME in pod-class.h
In src/common/pod-class.h, the POD_CLASS definition contained quite
a lot of detritus, including a long-ago resolved FIXME. Delete all the
noise.
2025-01-09 17:55:31 -08:00
iamamyth 978f1d7d41 Fix get_database_size on Windows
Replace all calls to epee::file_io::get_file_size with
boost::filesystem::file_size in order to avoid lossy conversions from
paths to strings, which tend to break filename resolution. This commit
fixes a bug on Windows where the get_info RPC call reported a zero
database size because BlockchainLMBD::get_database_size returned zero.
2025-01-06 10:38:12 -08:00
iamamythandselsta 163f83720f functional_tests: rewrite mining code, clearer timeout info 2020-09-24 20:04:05 +02:00
iamamyth 07cb087e5d blockchain: Fix alt chain generated coins overflow
Apply the overflow logic used for computing already_generated_coins in
the main chain to alternative chains.
2019-08-18 17:26:58 -07:00