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

Allow a default color_formula to be defined on the factory #707

Merged
merged 1 commit into from
Oct 3, 2023

Conversation

samn
Copy link
Contributor

@samn samn commented Oct 3, 2023

instead of needing it to be passed through query params.

What I am changing

  • Add a color_formula_dependency field to BaseTilerFactory & MosaicTilerFactory (defaulting to the existing ColorFormulaParams) so users can override the logic for supplying a color formula. This lets us define a default color formula from a separate config without needing to include it in the query params for every request.

How I did it

  • Added a dependency to get the color_formula value, rather than using a Query directly that can't be overridden.

How you can test it

  • Via the integration tests, or by using the color_formula_dependency in an existing application.

instead of needing it to be passed through query params.
@samn samn force-pushed the color-formula-dependency branch from 45589a2 to f2efd36 Compare October 3, 2023 20:21
@vincentsarago
Copy link
Member

Thank you @samn 🙏

@vincentsarago vincentsarago merged commit 50934c9 into developmentseed:main Oct 3, 2023
9 checks passed
@samn samn deleted the color-formula-dependency branch October 3, 2023 20:40
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