Skip to content

Fix CI: resolve unmerged conflicts in factory/farming-pool crates - #107

Merged
prodbycorne merged 1 commit into
mainfrom
fix/ci-merge-corruption-factory-farming-pool
Jul 28, 2026
Merged

Fix CI: resolve unmerged conflicts in factory/farming-pool crates#107
prodbycorne merged 1 commit into
mainfrom
fix/ci-merge-corruption-factory-farming-pool

Conversation

@prodbycorne

Copy link
Copy Markdown
Contributor

Summary

main's CI has been red because several previously-merged PRs left their merge conflicts unresolved — both sides of the conflict were concatenated into the source instead of reconciled. This surfaced as a long chain of compile errors and test failures across the factory and farming-pool Soroban contract crates:

  • Duplicate Cargo.toml dependency keys
  • Duplicate/spliced function bodies referencing undefined variables (pos, rate)
  • Duplicate FactoryError/PoolError discriminants
  • A duplicate require_auth() call causing Error(Auth, ExistingValue) at runtime
  • Orphan statement fragments with no receiver
  • Call sites left out of sync after signature changes (missing global_multiplier/min_stake_amount args)

While getting the suite green, also found and fixed a genuine (non-merge-artifact) bug: Factory::create_pool deployed and initialized new pools without ever passing min_stake_amount through to the pool's initialize, even though farming-pool::initialize had gained that as a required parameter — every real create_pool call was hitting a hard MismatchingParameterLen VM error. create_pool now accepts min_stake_amount and forwards it.

Also regenerated the stale checked-in factory/tests/fixtures/farming_pool.wasm integration-test fixture to match current farming-pool source, per the regeneration steps already documented at the top of factory_pool_integration.rs.

Test plan

  • cargo build --workspace --target wasm32v1-none --release — passes
  • cargo fmt --all -- --check — clean
  • cargo clippy --workspace --all-targets -- -D warnings — zero warnings
  • cargo test --workspace — 173/173 passing (48 factory unit + 5 factory integration + 100 farming-pool + 20 vesting-wallet)

These are the exact steps .github/workflows/ci.yml runs.

…an crates

main was left in a broken state where multiple PRs' merge conflicts were
never actually resolved: both sides of several conflicts were concatenated
instead of reconciled. This produced duplicate Cargo.toml dependency keys,
duplicate/spliced function bodies referencing undefined variables, duplicate
error enum discriminants, a duplicate require_auth() causing
Error(Auth, ExistingValue), orphan statement fragments with no receiver, and
call sites left out of sync with signature changes (missing
global_multiplier/min_stake_amount args).

Also fixes a genuine gap uncovered while getting tests green:
Factory::create_pool deployed and initialized pools without ever passing
min_stake_amount through to the pool's initialize, even though farming-pool's
initialize had gained that required parameter — causing a hard
MismatchingParameterLen VM error on every real create_pool call.
create_pool now takes min_stake_amount and forwards it.

Regenerated the stale checked-in factory/tests/fixtures/farming_pool.wasm
integration-test fixture to match the current farming-pool source, per the
regeneration instructions already documented in factory_pool_integration.rs.

cargo fmt --check, cargo clippy --workspace --all-targets -D warnings, and
cargo test --workspace (173 tests) all pass locally, matching CI's exact
steps.
@netlify

netlify Bot commented Jul 28, 2026

Copy link
Copy Markdown

Deploy Preview for sdcontracts ready!

Name Link
🔨 Latest commit 1e07b3d
🔍 Latest deploy log https://app.netlify.com/projects/sdcontracts/deploys/6a68fe3102e89a0008496630
😎 Deploy Preview https://deploy-preview-107--sdcontracts.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify project configuration.

@prodbycorne
prodbycorne merged commit dde48e4 into main Jul 28, 2026
5 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant