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

fix(core): fix caching issue in CMS between studio and bp #11631

Merged
merged 2 commits into from
Mar 17, 2022

Conversation

laurentlp
Copy link
Contributor

@laurentlp laurentlp commented Mar 15, 2022

This PR fixes an issue where overriding a bot inside the Bot Pipeline would not invalidate the CMS cache in the studio causing the UI not to display newly created content-elements.

Closes botpress/v12#1581

Closes DEV-2203

@linear
Copy link

linear bot commented Mar 16, 2022

DEV-2203 (BUG) Overriding a bot on a stage breaks DialogEngine and fails to update content-elements (botpress/botpress botpress/v12#1581)

Describe the bug
In a workspace with 3 pipeline stages when a bot on some stage is overridden (using on_request_change pipeline hook below):

  1. Newly added contents are not visible in the flow editor and contents page of the bot
    Screen Shot 2021-12-23 at 00 37 06
  2. Chat stops working
    Screen Shot 2021-12-23 at 00 35 48

May be related to this issue.

To Reproduce
Steps to reproduce the behavior:

  1. Set up a pipeline with 3 stages
  2. Create an empty bot
    Screen Shot 2021-12-23 at 00 27 33
  3. Add some initial content to it
    Screen Shot 2021-12-23 at 00 29 48
  4. Promote the bot to the next stage
    Screen Shot 2021-12-23 at 00 30 13
  5. Promoted bot should work for now
    Screen Shot 2021-12-23 at 00 31 49
  6. Add some new content to the original bot and promote it again
    Screen Shot 2021-12-23 at 00 32 35
  7. Open the studio for the promoted bot. You should see newly added content-elements rendered empty and webchat not working
    Screen Shot 2021-12-23 at 00 46 07
    Screen Shot 2021-12-23 at 00 35 48

Expected behavior
The promoted bot should have a working webchat and render newly added content-elements in the flow editor

Environment (please complete the following information):

  • OS: macOS
  • Browser Chrome
  • Browser Version Version 96.0.4664.110 (Official Build) (x86_64)
  • Botpress Version v12.26.7
  • NodeJS v12.18.1

Additional context
Add any other context about the problem here.

botpress/borpress botpress/v12#1581 by @ daukadolt

@laurentlp laurentlp merged commit e3c0c54 into master Mar 17, 2022
@laurentlp laurentlp deleted the llp_fix_cache_invalidation branch March 17, 2022 16:42
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.

[BUG] Overriding a bot on a stage breaks DialogEngine and fails to update content-elements
2 participants