-
Notifications
You must be signed in to change notification settings - Fork 11
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
paragraph bundle not exported/imported #28
Comments
@robertgarrigos Interesting! Any ideas? @serundeputy can I drag you into this one for input? |
I'd create a paragraph bundle on a dev site and import the config via Backdrop UI (sans drush) and see if the config takes.
|
Thanks @serundeputy! @robertgarrigos can you try the above and let me know the result? |
Right, I'm having different issues with config import/export. I have two "gited" blank local sites (with lando, backdrop1 and backdrop2), with paragraph enabled on both (default profile), create one bundle (in backdrop1 only) and add it a bundle field (text). Then: drushdrush export config and git push on backdrop1, git pull and drush import on backdrop2. Results: the bundle paragraph is not created. BUT: you can create a bundle with the same name and you get the bundle WITH the bundle text field listed in it. HOWEVER: it's a ghost field. It shows as created in the bundle but when you go to delete it, you get an error about a missing table for that bundle field. Thus, the bundle field is listed but not created. webexport config on backdrop1 with web form and import it on backdrop2 with web form. The bundle doesn't get created and if you create it again with the same name, as before, the bundle field doesn't show listed, nor it is created either. |
Seems a but with Have not looked at this code, but seems like the bug is a paragraphs bug. |
@serundeputy If you have a second to gander at these lines -- is this our problem on this issue? |
@laryn I don't think this export() method is ever called. There is not such a method in entity.class (its parent). |
I believe this bug is triggered due to the lack of any hook_config_* functions in paragraphs. Am I right?? |
I think this would be fixed by implementing the hook_config_create function (maybe also the update one) which should trigger paragraphs_save_bundle() function, as the only thing missing in the backdrop install is the entry of the bundle in the paragraphs_bundle table in ddbb. |
@robertgarrigos Could this also be related to the fact that Paragraph bundles/types haven't (yet) been converted to CMI in the same way that content types were in core? Your concept sounds worth testing -- but I won't have time to create a PR in the near future. If you are able sooner I will definitely test. |
Once this PR (#66) is merged I will fix this issue, as it does much more sense to have paragraphs bundles as CMI before. |
@robertgarrigos I've merged your bundles -> CMI PR. Thanks for that! Happy to also review any PRs here if/when you get to it. |
I experienced this problem where a Paragraphs bundle wasn't appearing on a new site after importing config. After reading the above, I updated to the latest dev version of this module which has the CMI patch. That allowed the Paragraphs bundle to get exported from the old site, which wasn't happeneing previously. Then, when I tried importing it to the new site, I got an error about no module owning that file. Some research turned up the need for modules to implement |
Thanks @BWPanda -- one minor comment in the PR. |
@laryn Cool, PR updated. |
Thanks @BWPanda ! |
I created a new paragraph bundle in a dev site, added a new field to it, checked that it was working and then exported the new configurations with
drush bcex
. Commited and pushed changes to my git repository and pulled from my staging site. Then imported the new configurations withdrush bcim
to the staging site and pargraph bundle was missing. Checked back again that config files were present, cleared cache a few times, but paragraph bundle was sill missing.Finally, I just created manually the paragraph bundle with the same machine name and voilà! it appeared again with its field. Wondering why...
The text was updated successfully, but these errors were encountered: