Skip to content

Allow clients: false per contract in scaffold.yml - #614

Merged
zachfedor merged 10 commits into
mainfrom
fix/clients-false
Oct 12, 2026
Merged

zachfedor merged 10 commits into
mainfrom
fix/clients-false

Conversation

@zachfedor

Copy link
Copy Markdown
Contributor

Keeping feature parity with the old environments.toml config, allow users to opt-out of generating a client for a contract in scaffold.yml. This is helpful for contract dependencies (like listing a SAC for seeding the local network that another contract might rely on) and for --no-template contract only projects.

NOTE: this pins the stellar/quickstart image to a specific tag that still supports protocol 27. The quick jump from 28 to 29 made this more noticeable, but the testing tag we were using only supports the most recent two protocol versions even though it silently accepts earlier versions with --protocol-version. This is why we have failing tests in #599 .

@zachfedor
zachfedor requested review from chadoh and pselle October 9, 2026 03:20

@pselle pselle left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Various questions, marking as request changes so it's clear the review is blocked pending more info.

I don't see any docs/ changes in this PR -- the docs on main still describe config v1 as supported. Projects made with 0.0.27 can set custom contract and client folders in an older scaffold.yml format, but this PR no longer reads them. build, clean and doctor will quietly fall back to the default folders (no error or warning).

It looks like the branch generally needs a rebase and docs, some new settings (client, allow-http, package-manager) aren't documented.

The description covers client: false and the image pin, but this also changes package-manager handling, the generated clients and v1 config support. Is that intended?

@zachfedor

Copy link
Copy Markdown
Contributor Author

I rebased on main, everything should be up to date. I have a stacked PR with all the docs changes you mentioned as missing, it's on a separate branch since I started this out as a docs-only community templates guide before realizing I needed a fix or three in code.

I was probably a little too cavalier in removing v1 scaffold.yml support. It was only live for a short while before this new v2 config. I'll try to add the quickest fix I can to support the parameters from it instead of silently failing.

@pselle

pselle commented Oct 9, 2026

Copy link
Copy Markdown
Contributor

Updating docs in follow-on sounds fine (I don't see a PR opened yet tho, fyi)

Overall looks like only one unresolved conversation, I'm not closing it in case you're still actively working on this. Ping me when you want a re-review, please!

@pselle
pselle self-requested a review October 12, 2026 12:01
@zachfedor
zachfedor merged commit 55c036b into main Oct 12, 2026
9 checks passed
@zachfedor
zachfedor deleted the fix/clients-false branch October 12, 2026 15:51
@aha-release-plz aha-release-plz Bot mentioned this pull request Oct 12, 2026
zachfedor added a commit that referenced this pull request Oct 14, 2026
Stacked on top of #614

This adds the guide for maintaining 3rd party UI templates consumable by
`scaffold init` and expands on some relevant configuration options (e.g.
versioned package manager support, opt-out client generation per
contract, allow HTTP override for RPC URL, etc.)
zachfedor pushed a commit that referenced this pull request Oct 14, 2026
## 🤖 New release

* `stellar-scaffold-ext-types`: 0.0.3 -> 0.0.4 (✓ API compatible
changes)
* `stellar-scaffold-cli`: 0.0.27 -> 0.0.28 (⚠ API breaking changes)
* `stellar-scaffold-reporter`: 0.1.2 -> 0.1.3 (✓ API compatible changes)

### ⚠ `stellar-scaffold-cli` breaking changes

```text
--- failure constructible_struct_adds_field: struct exhaustively constructible through public API adds field ---

Description:
A pub struct that could be exhaustively constructed with a literal using only public API has a new pub field, breaking existing exhaustive literals.
        ref: https://doc.rust-lang.org/reference/expressions/struct-expr.html
       impl: https://github.com/obi1kenobi/cargo-semver-checks/tree/v0.51.0/src/lints/constructible_struct_adds_field.ron

Failed in:
  field Contract.resolved in /tmp/.tmpkeJfYY/cli/crates/stellar-scaffold-cli/src/commands/build/env_toml.rs:204
  field Args.network in /tmp/.tmpkeJfYY/cli/crates/stellar-scaffold-cli/src/commands/build/clients.rs:77
  field Args.plan in /tmp/.tmpkeJfYY/cli/crates/stellar-scaffold-cli/src/commands/build/clients.rs:80
  field Network.allow_http in /tmp/.tmpkeJfYY/cli/crates/stellar-scaffold-cli/src/commands/build/env_toml.rs:158
  field Environment.from_scaffold_yml in /tmp/.tmpkeJfYY/cli/crates/stellar-scaffold-cli/src/commands/build/env_toml.rs:66

--- failure enum_missing: pub enum removed or renamed ---

Description:
A publicly-visible enum cannot be imported by its prior path. A `pub use` may have been removed, or the enum itself may have been renamed or removed entirely.
        ref: https://doc.rust-lang.org/cargo/reference/semver.html#item-remove
       impl: https://github.com/obi1kenobi/cargo-semver-checks/tree/v0.51.0/src/lints/enum_missing.ron

Failed in:
  enum stellar_scaffold_cli::commands::build::scaffold_yml::Error, previously in file /tmp/.tmpKvelwu/stellar-scaffold-cli/src/commands/build/scaffold_yml.rs:10

--- failure enum_variant_added: enum variant added on exhaustive enum ---

Description:
A publicly-visible enum without #[non_exhaustive] has a new variant.
        ref: https://doc.rust-lang.org/cargo/reference/semver.html#enum-variant-new
       impl: https://github.com/obi1kenobi/cargo-semver-checks/tree/v0.51.0/src/lints/enum_variant_added.ron

Failed in:
  variant Error:Config in /tmp/.tmpkeJfYY/cli/crates/stellar-scaffold-cli/src/commands/build/mod.rs:74
  variant Error:ScaffoldYmlEdit in /tmp/.tmpkeJfYY/cli/crates/stellar-scaffold-cli/src/commands/init/instantiate.rs:64
  variant Error:Doctor in /tmp/.tmpkeJfYY/cli/crates/stellar-scaffold-cli/src/commands/mod.rs:144
  variant Error:Config in /tmp/.tmpkeJfYY/cli/crates/stellar-scaffold-cli/src/commands/mod.rs:146
  variant Error:ContractsFailed in /tmp/.tmpkeJfYY/cli/crates/stellar-scaffold-cli/src/commands/build/clients.rs:169
  variant Error:MissingMainnetAccount in /tmp/.tmpkeJfYY/cli/crates/stellar-scaffold-cli/src/commands/build/clients.rs:173
  variant Cmd:Doctor in /tmp/.tmpkeJfYY/cli/crates/stellar-scaffold-cli/src/commands/mod.rs:118
  variant Cmd:Config in /tmp/.tmpkeJfYY/cli/crates/stellar-scaffold-cli/src/commands/mod.rs:121

--- failure function_missing: pub fn removed or renamed ---

Description:
A publicly-visible function cannot be imported by its prior path. A `pub use` may have been removed, or the function itself may have been renamed or removed entirely.
        ref: https://doc.rust-lang.org/cargo/reference/semver.html#item-remove
       impl: https://github.com/obi1kenobi/cargo-semver-checks/tree/v0.51.0/src/lints/function_missing.ron

Failed in:
  function stellar_scaffold_cli::commands::build::scaffold_yml::check_version, previously in file /tmp/.tmpKvelwu/stellar-scaffold-cli/src/commands/build/scaffold_yml.rs:88

--- failure function_parameter_count_changed: pub fn parameter count changed ---

Description:
A publicly-visible function now takes a different number of parameters.
        ref: https://doc.rust-lang.org/cargo/reference/semver.html#fn-change-arity
       impl: https://github.com/obi1kenobi/cargo-semver-checks/tree/v0.51.0/src/lints/function_parameter_count_changed.ron

Failed in:
  stellar_scaffold_cli::commands::build::docker::start_local_stellar now takes 1 parameters instead of 0, in /tmp/.tmpkeJfYY/cli/crates/stellar-scaffold-cli/src/commands/build/docker.rs:18

--- failure inherent_method_missing: pub method removed or renamed ---

Description:
A publicly-visible method or associated fn is no longer available under its prior name. It may have been renamed or removed entirely.
        ref: https://doc.rust-lang.org/cargo/reference/semver.html#item-remove
       impl: https://github.com/obi1kenobi/cargo-semver-checks/tree/v0.51.0/src/lints/inherent_method_missing.ron

Failed in:
  PackageManagerSpec::write_to_package_json, previously in file /tmp/.tmpKvelwu/stellar-scaffold-cli/src/commands/mod.rs:145

--- failure module_missing: pub module removed or renamed ---

Description:
A publicly-visible module cannot be imported by its prior path. A `pub use` may have been removed, or the module may have been renamed, removed, or made non-public.
        ref: https://doc.rust-lang.org/cargo/reference/semver.html#item-remove
       impl: https://github.com/obi1kenobi/cargo-semver-checks/tree/v0.51.0/src/lints/module_missing.ron

Failed in:
  mod stellar_scaffold_cli::commands::build::scaffold_yml, previously in file /tmp/.tmpKvelwu/stellar-scaffold-cli/src/commands/build/scaffold_yml.rs:1

--- failure pub_module_level_const_missing: pub module-level const is missing ---

Description:
A public const is missing or renamed
        ref: https://doc.rust-lang.org/cargo/reference/semver.html#item-remove
       impl: https://github.com/obi1kenobi/cargo-semver-checks/tree/v0.51.0/src/lints/pub_module_level_const_missing.ron

Failed in:
  CURRENT_SCHEMA_VERSION in file /tmp/.tmpKvelwu/stellar-scaffold-cli/src/commands/build/scaffold_yml.rs:7
  CONFIG_FILE in file /tmp/.tmpKvelwu/stellar-scaffold-cli/src/commands/build/scaffold_yml.rs:4

--- failure struct_missing: pub struct removed or renamed ---

Description:
A publicly-visible struct cannot be imported by its prior path. A `pub use` may have been removed, or the struct itself may have been renamed or removed entirely.
        ref: https://doc.rust-lang.org/cargo/reference/semver.html#item-remove
       impl: https://github.com/obi1kenobi/cargo-semver-checks/tree/v0.51.0/src/lints/struct_missing.ron

Failed in:
  struct stellar_scaffold_cli::commands::build::scaffold_yml::ScaffoldConfig, previously in file /tmp/.tmpKvelwu/stellar-scaffold-cli/src/commands/build/scaffold_yml.rs:36
```

<details><summary><i><b>Changelog</b></i></summary><p>

## `stellar-scaffold-ext-types`

<blockquote>

##
[0.0.4](stellar-scaffold-ext-types-v0.0.3...stellar-scaffold-ext-types-v0.0.4)
- 2026-10-12

### Other

- Feat/scaffold config v2 docs
([#612](#612))
</blockquote>

## `stellar-scaffold-cli`

<blockquote>

##
[0.0.28](stellar-scaffold-cli-v0.0.27...stellar-scaffold-cli-v0.0.28)
- 2026-10-12

### Other

- Allow `clients: false` per contract in scaffold.yml
([#614](#614))
- Feat/scaffold config v2 docs
([#612](#612))
- Feat/scaffold config v2 build
([#611](#611))
- Feat/scaffold config v2
([#610](#610))
- Feat/doctor command
([#593](#593))
</blockquote>

## `stellar-scaffold-reporter`

<blockquote>

##
[0.1.3](stellar-scaffold-reporter-v0.1.2...stellar-scaffold-reporter-v0.1.3)
- 2026-10-12

### Other

- Feat/scaffold config v2 docs
([#612](#612))
</blockquote>


</p></details>

---
This PR was generated with
[release-plz](https://github.com/release-plz/release-plz/).

Co-authored-by: aha-release-plz[bot] <211513279+aha-release-plz[bot]@users.noreply.github.com>
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.

2 participants