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

Property-inheritence for export plugins #123

Open
phelps-sg opened this issue Dec 4, 2019 · 1 comment
Open

Property-inheritence for export plugins #123

phelps-sg opened this issue Dec 4, 2019 · 1 comment

Comments

@phelps-sg
Copy link
Contributor

Is your feature request related to a problem? Please describe.
The export plugins that ship contain many duplicated properties. Moreover, the documentation states that the procedure for creating a new export plugin is to manually copy one of the existing .json files, and then add or amend properties in the new file. This makes it hard to maintain export configurations, as it violates the once-and-only-once principle.

Describe the solution you'd like
Allow export configurations to inherit properties from a parent. This would make it simpler to maintain and configure export plugins.

Describe alternatives you've considered
Manually copying and/or updating all related .json files whenever a change is made.

Additional context
Add any other context or screenshots about the feature request here.

@chrisjsewell
Copy link
Owner

Hmm, I’m on the fence about inheritance, mainly because it can be abused with multiple inheritance, that leads to the configurations becoming very opaque to understand (which is what I really don’t like about the nbconvert jinja templates).
I can understand the use case though.
An alternative could be to allow multiple configurations to be specified, which are then merged (in the order specified) at runtime, e.g.

{
   “a”: 1,
   “b”: 2
}

Plus

{
   “b”: 3,
   “c”: 4
}

Goes to

{
   “a”: 1,
   “b”: 3,
   “c”: 4
}

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants