171 Commits

Author SHA1 Message Date
philknows
62d3e49f28 chore: bump package versions to 1.38.0 2025-12-10 11:44:00 -05:00
Progress Ochuko Eyaadah
868300d7ae chore: remove holesky configs and update tests to hoodi (#8622)
**Motivation**

Replace deprecated Holesky network support with Hoodi testnet
configuration. Hoodi is a new Ethereum testnet that will serve as a
replacement testnet, and this change updates Lodestar to support the new
network configuration.

**Description**

This PR removes Holesky network configuration and replaces all
references with Hoodi testnet support. Changes include:

- Removed `packages/cli/src/networks/holesky.ts` network file
- Removed `packages/config/src/chainConfig/networks/holesky.ts` chain
config
- Updated all network references from "holesky" to "hoodi" across CLI,
config, and test files
- Added Hoodi network configuration with proper chain parameters,
genesis data, and bootnodes
- Updated default environment configuration
- Updated unit tests to reflect the network change


<!-- Link to issues: https://github.com/ChainSafe/lodestar/issues/8595
-->

Closes #https://github.com/ChainSafe/lodestar/pull/8615

**AI Assistance Disclosure**

- [ ] External Contributors: I have read the [contributor
guidelines](https://github.com/ChainSafe/lodestar/blob/unstable/CONTRIBUTING.md#ai-assistance-notice)
and disclosed my usage of AI below.

<!-- Insert any AI assistance disclosure here -->
-PR content was developed using Cursor for code updates and
explanations; I reviewed and verified all changes manually.
2025-12-08 15:44:36 +01:00
Cayman
362bd5ea5d feat: support and test node 24 (#8645)
**Motivation**

- Support the latest LTS

**Description**

- support node 24

---------

Co-authored-by: Nico Flaig <nflaig@protonmail.com>
2025-12-03 13:32:11 -05:00
philknows
2303b06a91 chore: bump package versions to 1.37.0 2025-11-28 10:17:20 -05:00
philknows
6eb05a083a chore: bump package versions to 1.36.0 2025-11-04 12:28:29 -05:00
Nazar Hussain
a0d00ac6dc chore: cleanup types exports for all packages (#8434)
**Motivation**

Make the types exports consistent for all packages. 

All modern runtimes support [conditional
exports](https://nodejs.org/api/packages.html#conditional-exports) and
there are caveats when we have both conditional exports and normal
exports present in a package.json. This PR tend to make all exports
follow same consistent and modern pattern.

**Description**

- We were using subpath exports for some packages and module exports for
other
- Keep all the types export consistent as subpath exports.
- Remove "types" and "exports` directive from package.json 
- Remove `typesVersions`, this is useful only if we have different
version of types for different versions of Typescript. Or having
different types files for different file paths.


**Steps to test or reproduce**

- Run all CI
2025-10-20 09:03:08 -04:00
philknows
825a186b76 chore: bump package versions to 1.35.0 2025-10-08 18:10:13 -04:00
Nico Flaig
47470aab65 chore: remove remaining usage of SECONDS_PER_SLOT (#8476)
Follow up on https://github.com/ChainSafe/lodestar/pull/8091 to clean up
remaining usage of `SECONDS_PER_SLOT`.

---------

Co-authored-by: gemini-code-assist[bot] <176961590+gemini-code-assist[bot]@users.noreply.github.com>
2025-09-26 19:45:55 +01:00
NC
39be8f0882 feat: use bps instead of INTERVALS_PER_SLOT for deadlines (#8091)
Closes #8013

---------

Co-authored-by: Nico Flaig <nflaig@protonmail.com>
2025-09-25 19:01:20 -07:00
Nazar Hussain
8689cc3545 chore: add src to the package to have working source map (#8460)
**Motivation**

Add `src` directory to package sources along with the `lib` files to
have working source map.

**Description**

- Add `src` to the files.


**Steps to test or reproduce**

- Run all tests
2025-09-25 07:23:58 -04:00
Cayman
6494939cd0 chore: add bun exports to packages (#8448)
**Motivation**

- #7280 

**Description**

- Add `"bun"` export to all packages that points to the _typescript
source_ rather than the transpiled javascript
- Allows for bun to use typescript directly
2025-09-23 12:19:11 +01:00
Nazar Hussain
feed916580 chore: enable organize imports for linting (#8410)
**Motivation**

Enable the organize import back which was disabled in #7982 to isolate
the changes for import ordering

**Description**

- Update the organize import config 
- Fix all linting errors

**Steps to test or reproduce**

- Run all tests

---------

Co-authored-by: Cayman <caymannava@gmail.com>
2025-09-19 19:59:28 -04:00
Nazar Hussain
0c6f50771f chore: use latest TS module resolution (#8419)
**Motivation**

Use latest `module` and `moduleResolution` for TS.

**Description**

- To use [subpath
imports](https://nodejs.org/api/packages.html#subpath-imports) in the PR
#8320 we need to update the module solution strategy for TS.
- That requires to change the `module` for the TS as well. 
- Earlier tried to stay with `node18` or `node20`, but the `ts-node`
does not work with that.
- Maintaining different tsconfig for ts-node is more of hassle on wrong
run.
- So decided to stick with `nodenext` strategy for `moduleResolution` 

**Steps to test or reproduce**

Run all tests

---------

Co-authored-by: Cayman <caymannava@gmail.com>
2025-09-18 11:36:48 -04:00
Phil Ngo
86490969b7 chore: bump package versions to 1.34.1 2025-09-10 16:34:42 -04:00
Phil Ngo
1a17514b02 chore: bump package versions to 1.34.0 2025-09-05 12:24:08 -04:00
Nazar Hussain
11ca515d52 test: upgrade sim tests to use post-electra images (#8303)
**Motivation**

Use the newer client versions to support only post-electra forks.

**Description**

- Update images versions
- Update the runner script
- Update tests


**Steps to test or reproduce**

- Run all tests

---------

Co-authored-by: Nico Flaig <nflaig@protonmail.com>
2025-09-02 20:40:00 +01:00
Nazar Hussain
22a04f4543 chore: upgrade @biomejs/biome to newer type aware version (#7982)
**Motivation**

Use the more type aware version of Biome to get benefit from type safety
rules.

**Description**

- Keep the rules matching to previous behavior 
- Add explanation to all ignore as it's required in new version

**Steps to test or reproduce**

Run all tests

---------

Co-authored-by: Nico Flaig <nflaig@protonmail.com>
2025-09-02 16:53:47 +02:00
Nazar Hussain
b9950594aa refactor: remove cpu features direct dependency (#8261)
**Motivation**

Make the code transition for compatibility with the Bun. 

**Description**

- The dependency `cpu-features` is not compatible with the `Bun`
- Removed the direct dependency
- Upgrade the `@chainsafe/persistent-merkle-tree` and `@chainsafe/ssz`
so the hasher detection is done implicitly.
- Latest commit for
[hahstree](e86a8b136a)
has the support for fallback, which is not used in the
`@chainsafe/persistent-merkle-tree`


**Steps to test or reproduce**

Run all tests
2025-08-25 17:22:23 -04:00
Phil Ngo
7afce97ce3 chore: bump package versions to 1.33.0 2025-07-31 15:05:32 -04:00
Phil Ngo
36dbfb2cfe chore: bump package versions to 1.32.0 2025-07-09 14:35:57 -04:00
Nico Flaig
4a12abd772 feat: switch to rust kzg for async proof verification (#7989)
**Motivation**

Bring changes from https://github.com/ChainSafe/lodestar/pull/7936 to
unstable branch.

**Description**

- deneb relevant changes from
https://github.com/ChainSafe/lodestar/pull/7936
- remove `--chain.trustedSetup` flag as file is part of kzg library now
- remove trusted setup files

Closes https://github.com/ChainSafe/lodestar/issues/7970
2025-06-23 04:08:07 -04:00
Phil Ngo
8847b4a92b chore: bump package versions to 1.31.0 2025-06-03 14:16:18 -04:00
Matthew Keil
9f5ab00bab fix: remove arm check (#7897)
**Motivation**

Removes check for arm for mac compatibility.  
Removes log statement because the log happens in #7896
2025-06-01 23:51:37 -04:00
Matthew Keil
065cb80811 fix: avx check in conditional (#7893)
**Motivation**

Fix check for AVX conditional.  Needs to follow what was done in:
https://github.com/OffchainLabs/hashtree/blob/main/bindings_amd64.go

Original PR just looked at the hashtree bindings here:
https://github.com/OffchainLabs/hashtree/blob/main/src/hashtree.c#L42
2025-05-30 15:57:42 +01:00
Matthew Keil
b3a6f4660e fix: default to as-sha256 if no chip support for AVX (#7887)
**Motivation**

A crash was reported by several parties running Lodestar on a VPS. The
problem was tracked down to no AVX support on the host which causes
OffchainLabs/hashtree to crash. The go binding do a similar check, at
the bindings level, and revert to a non-assembly SHA256 lib. This PR
does the same. Checks the hardware for the supported AVX types and
returns `as-sha256` hasher from the `hashtree` hasher so there is no
crash.



67979dccfc/src/hashtree.c (L53-L67)
2025-05-30 09:02:12 -04:00
Phil Ngo
123eb2d9fb chore: bump package versions to 1.30.0 2025-05-09 12:15:00 -04:00
Phil Ngo
3ebe983765 chore: update beacon api and consensus spec refs post electra (#7804)
**Motivation**

This PR is to update specification references for new Beacon APIs
(v3.1.0) and Consensus specs (v2.5.0) released post-Electra.

**Description**

Closes https://github.com/ChainSafe/lodestar/issues/7463
2025-05-07 15:16:48 -04:00
Nico Flaig
fa898bb319 chore: restructure tests (#7793)
Follow up to https://github.com/ChainSafe/lodestar/pull/7610 with a few
restructuring suggestions, see comments below for detailed changes,
revives constants tests we are no longer running in CI and makes each
package executable separately again, ie. `cd packages/<package-name>`
into `yarn test:unit` works for all packages again.

One major change is that unit tests default should be written with
`mainnet` preset in mind as I noticed that makes a lot more sense for a
bunch of existing tests, eg. we have tests that depend on external
fixtures, like api spec tests for events and those are not compatible
with `minimal` preset. Also there doesn't seem to be much downside in
most cases for unit tests to use `mainnet` preset as it does not run
through all the epoch, like for example a e2e or sim test does. So
overall, it allows us to use mainnet fixtures / more "real world" data
which seems better with little to no downside.


Time comparison running unit tests on `unstable` vs. this branch

**unstable**

![image](https://github.com/user-attachments/assets/ba9c8e68-ec1a-4cb7-90fc-eb00cedae4bf)

**nflaig/restructure-tests**

![image](https://github.com/user-attachments/assets/0ffab5a4-4a71-42e1-a26e-32fc5627b873)

There is just a difference of 2 seconds (might be a fluke) in a 6 minute
run, this seems acceptable to me considering the benefits of using
`mainnet` preset noted above.
2025-05-07 18:21:12 +01:00
Nazar Hussain
57f8f00d93 chore: reuse the shared biome config (#7763)
**Motivation**

Use consistent linting rules for all projects. 

**Description**

- Reuse the `@chainsafe/biome-config` package to have consistent 


**Steps to test or reproduce**

Run CI

---------

Co-authored-by: Cayman <caymannava@gmail.com>
2025-05-07 11:59:36 -04:00
Nazar Hussain
2ff1784005 chore: remove unused eslint directives (#7803)
**Motivation**

Remove any unused or inactive codebase.

**Description**

Remove all unused eslint directives as we are using `biome` now. 

**Steps to test or reproduce**

Run lint rules and all tests
2025-05-07 17:25:34 +02:00
Nazar Hussain
c91cd9c141 test: use vitest workspace to run all tests (#7610)
**Motivation**

Vitest workspaces is feature to mimic the package manager workspaces for
the tests only.

It provides following benefits:

1. Minimize the need the bunch of config files at every package root 
2. Consolidate vitest configuration in project groups
3. Use consistent test configuration for all projects in the monorepo
4. Providing consistent test environment for all packages
5. Speed up visual interaction with tests in the IDEs (e.g. Visual
Studio Code)

**Description**

- Remove all unnecessary config files
- Update package json scripts to use `--project` flag

Closes #7603


Now we have following test directories. 

| Directory | Description | CurrentPreset | Old Preset | 
|---|---|---|---|
| test/unit | Unit tests | minimal | Default export from `params`
package |
| test/unit-mainnet | Unit tests | mainnet | mainnet | 
| test/e2e | End-to-End Tests | minimal | Default export from `params`
package |
| test/e2e-mainnet | End-to-End Tests | mainnet | Never existed before,
mixed up pattern in different packages |
| test/spec | Spec tests | minimal | Default export from `params`
package, but common perception among team was that it's running with
`minimal` |
| test/spec-mainnet` | Spec tests | mainnet | Never existed as
directory, but mixed up among packages |
| test/browser | Symlink to `unit` for packages which supports browsers
| minimal | Default export from `params` package |
| test/types | Types test | minimal | Default export from `params`
package |


**Steps to test or reproduce**

Run all tests
2025-04-22 11:33:36 +02:00
Nico Flaig
51613f0fb0 chore: bump package versions to 1.29.0 2025-04-19 16:27:49 +01:00
twoeths
5bc61255df feat: ssz v1.2.0 (#7608)
**Motivation**

- as v1.28.0 was released, we want to upgrade to ssz v1.2.0 to test the
batch hash asap and unblock other works

**Description**

- replace ssz v1.0.2 by v1.2.0

---------

Co-authored-by: Tuyen Nguyen <twoeths@users.noreply.github.com>
2025-03-23 15:03:30 +07:00
Phil Ngo
300bed85d8 chore: re-merge v1.28.1 back to unstable (#7613) 2025-03-20 16:09:19 -04:00
Phil Ngo
40d04deac5 chore: bump package versions to 1.28.1 2025-03-20 13:35:15 -04:00
Nazar Hussain
23195c050b chore: upgrade biomejs to 1.9.4 (#7533)
**Motivation**

Keep the tooling updated.

**Description**

- Enable different useable new rules. 

**Steps to test or reproduce**

Run all tests. 


## Please review commit by commit
For reviewers please review commit by commit.

<img width="426" alt="image"
src="https://github.com/user-attachments/assets/e6ad3082-d311-4e11-896a-99abf715ca8a"
/>
2025-03-19 18:07:18 +00:00
Nico Flaig
461532eeed chore: bump package versions to 1.28.0 2025-03-18 18:38:52 +00:00
Nazar Hussain
9f78c9dad8 chore: fix broken type check for test files (#7567)
**Motivation**

Check the types for test files

**Description**

- Add `test` folder for the `tsconfig.json` files

**Steps to test or reproduce**

- Run all tests
2025-03-13 13:47:22 +00:00
Nazar Hussain
51efa3d604 chore: update the test runner (#7404)
**Motivation**

Update vitest and browser engine.

**Description**

- Move root level shared configs to `configs` directory
- Update to vitest 3.x
- Migrate from `webdriverio` to `playwright` which is more stable and
recommended by Vitest.

**NOTE**
Reverted the `playwright` upgrade. See the comments. 


d2a7af0308/configs/vitest.config.base.browser.ts (L41-L43)

**Steps to test or reproduce**

Run all tests
2025-02-27 10:27:43 -05:00
Nazar Hussain
b2ebe4921b deps: upgrade tyepscript to 5.7 (#7160)
**Motivation**

Keep the deps updated.

**Description**

Use latest features provided by Typescript. See the comments below. 

**Steps to test or reproduce**

- Run all tests
2025-02-25 14:24:14 +01:00
Phil Ngo
d1f9f7b32a Merge branch 'stable' into unstable 2025-02-24 11:36:34 -05:00
Nico Flaig
3b0ca8df3b chore: bump package versions to 1.27.1 2025-02-24 14:58:39 +00:00
Nico Flaig
2b1c82a795 chore: fix verification of README code snippets (#7471)
Replacement for https://github.com/ChainSafe/lodestar/pull/6868 which
got a bit stale and had workarounds in it which are no longer required.

Closes https://github.com/ChainSafe/lodestar/issues/6300
2025-02-14 22:14:43 +00:00
Phil Ngo
2ddcd2052c chore: bump package versions to 1.27.0 2025-02-13 09:06:43 -05:00
Matthew Keil
734705659d feat: rename pre/post fork designations and fork guards (#7441)
**Motivation**

Start of resolution to #7183. Driven by peerDAS branch. `isForkBlobs` is
not longer semantically correct in `fulu` because that branch does not
have blobs, it has columns. Is the first major feature that was removed
so the types/typeguard naming semantics we were using kinda broke.
Updated to reflect pre/post fork instead of post"Feature".

**Description**

Rename pre/post fork names and type guards.

---------

Co-authored-by: Nico Flaig <nflaig@protonmail.com>
2025-02-12 12:15:05 +00:00
Phil Ngo
6fb5b9a81b chore: bump package versions to 1.26.0 2025-01-31 11:25:02 -05:00
Nico Flaig
cf23839116 chore: correctly set ssz hasher in prover cli (#7396)
**Motivation**

E2E tests are failing due to this

**Description**

Correctly set ssz hasher in prover CLI
2025-01-24 10:27:36 -05:00
Phil Ngo
e30fd40c05 chore: bump package versions to 1.25.0 2025-01-10 12:07:35 -05:00
Cayman
ca315d4d9e chore: bump package versions to 1.24.0 2024-12-20 10:16:01 -05:00
Phil Ngo
ffdfb2e517 docs: batch commit typos and update contributor readme (#7312)
* batch commit typos and update contributor readme

* update donation text

Co-authored-by: Nico Flaig <nflaig@protonmail.com>

* correct spelling

Co-authored-by: Nico Flaig <nflaig@protonmail.com>

---------

Co-authored-by: Nico Flaig <nflaig@protonmail.com>
2024-12-19 19:44:42 +00:00