Hello, When I run `gd deploy` via the cli in notic...
# gooddata-cloud
p
Hello, When I run
gd deploy
via the cli in notice that the filter contexts are gone; each deploy resets the saved filters for logged in embedded users. Is that expected behavior? Is there a way around this?
m
Hi Patrick, yes, this is the expected behavior that running
gd deploy
via the CLI resets the saved filter contexts for logged in embedded users. The
deploy
command replaces the entire workspace with the local analytical objects, which overwrites any existing filter settings.
deploy
is designed to completely replace the workspace, which has the side effect of resetting the filter contexts. Using
clone
or manually setting the filters after deployment would be the best ways to maintain the saved filter settings when updating the objects.
p
So you are saying that
gd clone
can be used to export the existing filter contexts? Can you give an example? Or where the feature is documented? When I run that I do not get any filter settings in the yaml produced. I am confused.
t
Hello Patrick,
gd clone
currently does not take filter contexts into account. Only our Python SDK does so. As @Michael Ullock mentioned,
gd deploy
replaces the full workspace content. To be sure I understand the issue completely, can you describe me the situation after deploy? I’m interested to understand how how does this filter reset your users experience look like, Thanks in advance.
Here is a link to the Python SDK method that stores analytics model (including filter contexts) as YAML files. https://www.gooddata.com/docs/python-sdk/latest/workspace-content/analytics-model/store_analytics_model_to_disk/
p
Basically on your end we track the filter id in the web ui, when the we deploy the filter contexts are cleared, so logged in users get a 500. the only way around this has been to export the context manually (via that sdk) before each deploy. It would be great if filter contexts were preserved when using the cli.
I am not sure if tracking the filter contexts is very useful as the SDK does, but not deleting or exporting them to a /something in the folder structure would at least let us capture them, patch with the changes, and then upload the updates via the cli
Is adding filter context support to the CLI planned?
t
Hi Patrick, to be honest this is the first time we hear about these kind of issues, thus the work with filter contexts in GoodData for VS Code is not planned at the moment. I still would like to better understand how does your workflow look like. Do I understand correctly that you create and save the filter contexts for specific users? To mimic a missing functionality of GoodData?