Skip to content

core, repair: migrate port bindings for tests to non-overlapping solution#7104

Closed
puhtaytow wants to merge 68 commits intoanza-xyz:masterfrom
puhtaytow:core-repair-service-replace-bind-to-0
Closed

core, repair: migrate port bindings for tests to non-overlapping solution#7104
puhtaytow wants to merge 68 commits intoanza-xyz:masterfrom
puhtaytow:core-repair-service-replace-bind-to-0

Conversation

@puhtaytow
Copy link
Copy Markdown

@puhtaytow puhtaytow commented Jul 23, 2025

Problem

A bunch of tests still relies on either hardcoded ports or bind_to_localhost and bind_to_unspecified. This creates flaky tests in cases where unique port ranges are needed.

This PR is the step in the journey toward resolving the issue.

Related to #7055

Summary of Changes

  • Fixed bug with inclusive end port in test_request_repair_for_shred_from_address
  • Migrated instances across core, repair tests that had in place obsolete bind_to_unspecified

@puhtaytow puhtaytow marked this pull request as draft July 23, 2025 10:23
@mergify mergify Bot requested a review from a team July 23, 2025 10:23
@puhtaytow puhtaytow force-pushed the core-repair-service-replace-bind-to-0 branch from 6566be3 to a9477ae Compare July 23, 2025 10:45
@puhtaytow puhtaytow changed the title core, repair service: swap bind_to to new bind_to_localhost_unique WIP: swap old bind_to, to the new bind_to_localhost_unique Jul 23, 2025
@puhtaytow puhtaytow changed the title WIP: swap old bind_to, to the new bind_to_localhost_unique WIP: migrate old port bindings for tests Jul 23, 2025
@puhtaytow puhtaytow changed the title WIP: migrate old port bindings for tests core, repair: WIP / migrate old port bindings for tests Jul 23, 2025
@puhtaytow puhtaytow changed the title core, repair: WIP / migrate old port bindings for tests core, repair: migrate port bindings for tests Jul 23, 2025
@puhtaytow puhtaytow changed the title core, repair: migrate port bindings for tests core, repair: migrate port bindings for tests to non-overlapping solution Jul 23, 2025
@puhtaytow puhtaytow marked this pull request as ready for review July 24, 2025 14:36
@puhtaytow puhtaytow marked this pull request as draft July 24, 2025 14:39
steveluscher and others added 13 commits July 24, 2025 17:16
* clean up naming

* accumulates and reports included transaction fees

* only collect total prioritization fee
* move benchmarks to bencher 0.1.5

* use std::hint::black_box where possible
…z#7045)

- Ran cargo clippy with Rust 1.88.0 set in rust-toolchain.toml
- Ran cargo fmt with format_strings = true in rustfmt.toml
* runtime: Inline `extend_and_hash`

#### Problem

`solana_sha256_hasher::extend_and_hash` requires dynamic allocation
because of the vec creation, which means adding a `std` feature to the
crate.

However, the function is only used in one place, so it would be easier
to remove it and simplify the hasher crate.

#### Summary of changes

Inline the usage of `extend_and_hash` so it can be safely removed from
the hasher crate.

* Simplify extend_and_hash impl
…` and `SlotNotEpochBoundaryErrorData` (anza-xyz#6962)

* Add `slot` to the error context of `EpochRewardsPeriodActiveErrorData` and `SlotNotEpochBoundaryErrorData`

* Add CHANGELOG entries

* Directly serialize the JSON-RPC error data, rather than bouncing it through a struct

* Make `EpochRewardsPeriodActiveErrorData` from the perspective of deserializing _old_ data by making `slot` an Option
…a-xyz#6516)

* Don't construct or notify `RpcSubscriptions` when the RPC is off

* Less dumb Rust

* Keep going? Can't get it to typecheck.

* Revert some places that still need `Arc`s due to threads

* Cleanup tests, avoid a clone in tpu

---------

Co-authored-by: Jon C <me@jonc.dev>
samkim-crypto and others added 26 commits July 24, 2025 17:16
This function provided a hack to change threadpool sizes to avoid
observed performance issues. The users of this function have since been
updated to have CLI args wired up to control the threadpool sizes. So,
the hack is no longer necessary and can be deprecated
* move verify_args_struct_by_command_run_with_no_genesis_fetch()

* move verify_args_struct_by_command_run_with_no_snapshot_fetch

* move verify_args_struct_by_command_run_with_check_vote_account

* move verify_args_struct_by_command_run_with_only_known_rpc

* move verify_args_struct_by_command_run_with_incremental_snapshot_fetch

* wording
…#7086)

SnapshotConfig has a non-trivial amount of arguments, operations and
checks that occur. Shift all of this logic into a side function to help
organize and de-clutter
* build(deps): bump io-uring from 0.7.8 to 0.7.9

Bumps [io-uring](https://github.com/tokio-rs/io-uring) from 0.7.8 to 0.7.9.
- [Commits](https://github.com/tokio-rs/io-uring/commits)

---
updated-dependencies:
- dependency-name: io-uring
  dependency-version: 0.7.9
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>

* Update all Cargo files

---------

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
A default function is certainly useful for tests to avoid tons of
copy/paste. However, we should avoid it in production code to reduce the
chance of accidental misconfiguration or forgetting to update somewhere
…ata_direct_mapping` (anza-xyz#7056)

* Reverts the disabling of enable_stack_frame_gaps in bpf_account_data_direct_mapping.

* Adjusts test_stack_heap_zeroed.
A Default impl for this config struct is a potential footgun; we should
be explicitly specifying all fields in production code. Note that the
default_for_test() function is left as-is to avoid copy/past in tests
* add sort workspace to cargo fmt script

* remove obsolete formatting script
…dditionalDataV2 (anza-xyz#7118)

Remove deprecated AccountAdditionalData and AccountAdditionalDataV2
accounts-db: Remove deprecated is_hash_valid()
…yz#7097)

The merkle_variant parameter has been removed as well
@mergify
Copy link
Copy Markdown

mergify Bot commented Jul 24, 2025

If this PR represents a change to the public RPC API:

  1. Make sure it includes a complementary update to rpc-client/ (example)
  2. Open a follow-up PR to update the JavaScript client @solana/kit (example)

Thank you for keeping the RPC clients in sync with the server API @puhtaytow.

@mergify
Copy link
Copy Markdown

mergify Bot commented Jul 24, 2025

The Firedancer team maintains a line-for-line reimplementation of the
native programs, and until native programs are moved to BPF, those
implementations must exactly match their Agave counterparts.
If this PR represents a change to a native program implementation (not
tests), please include a reviewer from the Firedancer team. And please
keep refactors to a minimum.

@mergify
Copy link
Copy Markdown

mergify Bot commented Jul 24, 2025

For your information, the zk-keygen and zk-sdk directories are
scheduled to be relocated to solana-program/zk-elgamal-proof in a
separate repository. Additionally, the zk-token-sdk directory will
be removed. Please take these upcoming changes into account when
making modifications.

@puhtaytow puhtaytow closed this Jul 24, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.