I just updated the module "Webform" and I receive the following error :
[warning] The following module is missing from the file system: contribute bootstrap.inc:268
www.domaine.com@vps000000 ~/public_html $ composer update --with-dependencies
Gathering patches for root package.
> DrupalProject\composer\ScriptHandler::checkComposerVersion
Loading composer repositories with package information
Updating dependencies (including require-dev)
Package operations: 0 installs, 1 update, 0 removals
Gathering patches for root package.
Gathering patches for dependencies. This might take a minute.
- Updating drupal/webform dev-5.x (fed2e5d => bfac696): Checking out bfac69619c
Writing lock file
Generating autoload files
Removing packages services cache file:
/home/www.domaine.com/public_html/vendor/drupal/console/extend.console.uninstall.services.yml
Creating packages services cache file:
/home/www.domaine.com/public_html/vendor/drupal/console/extend.console.uninstall.services.yml
> DrupalProject\composer\ScriptHandler::createRequiredFiles
www.domaine.com@vps308496 ~/public_html $ drush updatedb
[warning] The following module is missing from the file system: contribute bootstrap.inc:268
[success] No database updates required| Comment | File | Size | Author |
|---|---|---|---|
| #71 | webform-2951921-notice-from-update-8114.patch | 542 bytes | steven jones |
| #63 | 2951921-63.patch | 724 bytes | jrockowitz |
| #35 | 2951921-34.patch | 1.99 KB | jrockowitz |
| #31 | 2951921-31.patch | 2.16 KB | jrockowitz |
| #13 | 2951921-13.patch | 1.96 KB | jrockowitz |
Comments
Comment #2
jrockowitz commentedIt is related to #2951001: Move Contribute module's message into the Webform module and remove the dependency. I will upload a patch shortly.
Comment #3
zenimagine commentedOk thank you, so nothing serious? no need to restore my site?
Comment #4
jrockowitz commentedSince the Contribute module's dependency has been removed from the Webform module, the attached patch will manually uninstall the Contribute module. The update hook only executes the Contribute module is missing from the file system.
How to fix "The following module is missing from the file system..." warning messages
Comment #5
zenimagine commentedI do not understand what I have to do. I'm waiting for the next update or I apply the patch ?
Comment #6
jrockowitz commentedThere is a minor bug that is breaking automated testing. I just committed a fix and all tests should start passing.
Please test the patch and confirm that the warning is no longer being displayed.
Comment #7
zenimagine commentedI applied the patch but it does not correct the problem
Comment #8
jrockowitz commentedI am a little stumped because I can't replicate the issue locally.
You also need to update your version of the webform module so that you get the very last commit which fixes the broken test but I don't think this will fix the problem.
Comment #9
floown commentedHello,
I have apply the patch too, but the warning still exist.
Comment #10
zenimagine commentedThe patch is applied and webform is up to date with the latest version dev, but still the same problem
Comment #11
jrockowitz commentedThe previous patch is trying to detect if the contribute module is missing by looking for the contribute module's main directory.
The attached patch is specifically now looking for the contribute module's info.yml file.
Can you please look at your modules directory and see if there is a 'contribute' folder that is empty?
Comment #12
floown commentedI have no more contribute folder.
Comment #13
jrockowitz commentedThe attached patch is the same approach as #11 but fixes a broken path.
Comment #14
zenimagine commentedThe patch does not correct
Comment #15
jrockowitz commentedIf
drush updbdoes not executewebform_update_8114()the warning won't go away.You can use the below command to manually execute webform_update_8114().
drush php-eval 'module_load_include('install', 'webform'); webform_update_8114()';Comment #16
zenimagine commentedComment #17
zenimagine commentedWhat should be the path of the contribute folder ?
Comment #18
jrockowitz commentedSomewhere in /modules and most likely the same folder as the webform module.
Comment #19
zenimagine commentedI do not see any folder contribute
Comment #20
jrockowitz commentedI am marking this Critical because it is blocking #2951686: Release 8.x-5.0-rc4.
Comment #21
jrockowitz commented@zenimagine I forgot that you must clear cache via
drush crafter every update hook. I still don't think the update hook is working correctly. Can you trydrush cr; drush status;?The update hook is trying to determine if the Contribute module is still installed but the folder/code is missing and then it removes the module.
The below Drush command from https://www.drupal.org/node/2487215 should remove the warning and bypass the update hook
Can you please see if it works?
If it does work, we still need to figure out what is wrong with the update hook.
Comment #22
zenimagine commentedI do not control drush, here are the results :
Comment #23
jrockowitz commentedIf you are using a database prefixes the drush command has include curly brackets..
BTW,
drush status;should also be returning the warning.Comment #24
zenimagine commentedShould I enter the prefix instead of {key_value} ?
Comment #25
jrockowitz commentedYes please try the prefix key.
Comment #26
zenimagine commentedThe prefix of my base is g652hkdr_
Comment #27
jrockowitz commentedThis should work.
Comment #28
zenimagine commentedIt works, then I delete the patch 13 ?
Comment #29
jrockowitz commentedNow, we know the query works.
I need help figuring out what is wrong with the patch so that no one else has to manually fix this issue. Can you please revert your db and help me debug the patch.
Comment #30
zenimagine commentedYes, no problem I will be available in 4h. Tell me what you want.
Comment #31
jrockowitz commentedThe attached patch now outputs the below messages with the update hook. I also updated the database query to use Drupal database layer.
You can use the drush command to test it.
drush php-eval 'module_load_include('install', 'webform'); webform_update_8114()';Our goal is to get 'Contribute module does not exist and is now uninstalled.' outputted and the warning should go away. I suspect that the database prefix is causing the issue.
Comment #32
zenimagine commentedWebform is up to date with dev version. I applied the last patch. I entered the orders. Here is the result :
Comment #33
jrockowitz commentedDarn! the eval needs a print statement to see the message outside of the updatedb command and I am also adding a drush cr.
drush php-eval 'module_load_include('install', 'webform'); print webform_update_8114()'; drush cr;Comment #34
zenimagine commentedComment #35
jrockowitz commentedPlease try this patch which is only looking for the contribute.info.yml file.
Comment #36
zenimagine commentedComment #37
jrockowitz commentedDid that fix the issue?
Comment #38
zenimagine commentedyes the warning message has disappeared :-)
Comment #39
jrockowitz commented@zenimagine Thanks.
Maybe @floown can review the patch.
Comment #40
floown commentedFor me, the contribute module is not installed and the directory doesn't exist.
Sorry,I don't know what patch I should apply now.
Comment #41
zenimagine commented@float You must apply the fix #35 and the #33 command
Comment #42
floown commentedFix #35 :
Comment #43
floown commentedOk, it seems work even so!
Comment #45
jrockowitz commentedComment #46
jrockowitz commentedComment #47
zenimagine commentedI reestablished my database to test the new dev version and I have the same error.
Should you still enter the following command ?
drush php-eval 'module_load_include('install', 'webform'); print webform_update_8114()'; drush cr;Comment #48
jrockowitz commentedPlease don't use the drush command because it is bypassing the patch.
I just tagged a new release with the patch. Please test rc4.
If there any chance that you are reimporting the site's exported config and restoring the contribute.module which is now missing.
Comment #49
zenimagine commentedI updated to rc4 and rebuilt the cache, but still have the same warning.
Comment #50
floown commentedI have done a:
composer require "drupal/webform:5.0-rc4"…
Comment #51
jrockowitz commentedHere are my steps to test webform_update_8114().
If
webform_update_8114()is not executed during `drush updb` you will still see the errors. If you applied any of the above patches you need to revert your database to a state before testing the patches.Comment #52
zenimagine commentedMy backup was done on the dev version. How to get back to RC3?
Comment #53
jrockowitz commentedA 'dev' backup before you applied any patches from this ticket is fine.
Comment #54
zenimagine commentedPatch # 4 was applied and the database updated :-(
I deleted the patch to composer.
Comment #55
zenimagine commentedCurrently there is no Contribute module.
If I update the dev to an RC3, if I install "Contribute" and uninstall it.
Can it be corrected ?
Comment #56
jrockowitz commentedDrupal increments your module scheme (via update hooks) and it is pain to deincrement them.
You should just execute the below drush command to get rid of the message once the contribute module is deleted.
drush php-eval 'module_load_include('install', 'webform'); print webform_update_8114()'; drush cr;Comment #57
zenimagine commentedI entered the command on RC4 is it seems to work. Here is the result :
Comment #58
zenimagine commentedNo "Contribute" folder on my FTP and no "Contribute" module in drupal modules.
The problem is solved ?
Comment #59
jrockowitz commentedI think the problem is solved.
Comment #60
zenimagine commentedThe "Comtribute" module is now part of "Webform" is that it ?
Comment #61
jrockowitz commentedThe Contribute module's dependency has been removed from the Webform module. The Contribute's module message is being moved into the Webform module and replaces the 'About' section.
Comment #62
heddnI don't know if this should be re-opened or a new issue opened. But there fix from #44 doesn't resolve my problem. Because I'm failing on the earlier 8106 update hook.
And in my case, the module wasn't in the composer.json and it doesn't exist on the disk. So my deployment fails.
Comment #63
jrockowitz commented@heddn Please try the attached patch.
Comment #64
heddnComment #65
heddnAlthough, I've also seen leaving the hook and adding an inline comment as its contents stating this was removed intentionally. But #63 fixes the problem. So I'm not going to block on nit.
Comment #66
jrockowitz commented@heddn I think I want any reference to the contribute.module dependency removed from the Webform module's history. :)
I will commit the patch and tag another RC in few days. I would really like to resolve #2952718: Error when adding email handler: "Body default value (@format) is using the following invalid tokens:" ... before tagging another release.
Comment #68
jrockowitz commentedComment #70
steven jones commentedSorry to pop another comment on here, but we're updating webform on some sites, and we're seeing the warning:
Coming from
webform_update_8114, because it's doingdrupal_get_pathfor a module that doesn't exist.I appreciate that in this issue it seems like that's expected, and we should ignore it, but the trouble for our use-case is that we're updating thousands of sites, and we need to know when there are warnings and errors logged during database updates so we can go back and check, but this update adds a ton of noise to our systems, making it really hard to spot genuine issues.
I know for certain that the contribute module is gone from our codebase, but is there a reason that this check isn't an 'is contribute module installed' check?
Comment #71
steven jones commentedHere's a patch that simply suppresses the error. If anything else fails in that function, well, your Drupal will break in other ways, so isn't probably too bad a thing to do.
Comment #72
zenimagine commented