Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Cleaner enabling of development service #260

Merged
merged 12 commits into from
Feb 23, 2021
Merged

Conversation

JoshOrndorff
Copy link
Contributor

Solves #231

This PR continues to improve the development service from both architectural and UX perspectives.

Reduced Code Duplication

On the architectural side, this further reduces duplicated code between the development and full services. There is are no longer separate files for the two services. The two services now share their native_executor_instance! invocation and their entire new_partial functions.

As a side benefit, this also works around an issue I discovered with manual seal where we weren't properly checking inherents paritytech/substrate#8164 That's the issue that caused me to incorrectly conclude that the initial pass at the author filtering was working as expected.

This is still not the end of the road for service code de-duplication. There is more improvement possible, that will come if future PRs.

UX Improvements

This allows users to explicitly request the dev service by using a dedicated --dev-service flag. We are now no longer abusing the --dev flag, so its role can return to being a quick shortcut flag that uses all the right defaults for a simple local one-node network.

We also allow chain specs to request the dev service by using the string "dev-service" in the relay_chain field.

Checklist

  • ❌ Does it require a purge of the network?
  • ❌ You bumped the runtime version if there are breaking changes in the runtime ?
  • ✔️ : Does it require changes in documentation/tutorials ? -- It may. It preserves functionality of the --dev flag, so I don't think anything broke. But there are new nice features that can be documented. I'll discuss all this stuff at our learning session Friday. (cc @albertov19)

@JoshOrndorff JoshOrndorff added A0-pleasereview Pull request needs code review. B5-clientnoteworthy Changes should be mentioned in any downstream projects' release notes C3-medium Elevates a release containing this PR to "medium priority". labels Feb 22, 2021
@JoshOrndorff JoshOrndorff added the A1-needsburnin Pull request needs to be tested on a live validator node before merge. label Feb 22, 2021
node/src/service.rs Outdated Show resolved Hide resolved
node/src/service.rs Outdated Show resolved Hide resolved
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
A0-pleasereview Pull request needs code review. A1-needsburnin Pull request needs to be tested on a live validator node before merge. B5-clientnoteworthy Changes should be mentioned in any downstream projects' release notes C3-medium Elevates a release containing this PR to "medium priority".
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants