Where communities thrive

  • Join over 1.5M+ people
  • Join over 100K+ communities
  • Free without limits
  • Create your own community
Repo info
  • Jan 13 22:51
    MacSim75 commented #4326
  • Jan 13 10:06
    rakeshjames commented #2770
  • Jan 13 10:05
    rakeshjames commented #4081
  • Jan 13 00:30
  • Jan 11 13:06
    slayerment opened #4325
  • Jan 10 09:56
    MrTimber commented #4265
  • Jan 10 09:56
    MrTimber commented #4265
  • Jan 10 09:54
    MrTimber commented #4265
  • Jan 10 09:54
    MrTimber commented #4265
  • Jan 10 09:47
    MrTimber commented #4265
  • Jan 10 09:46
    MrTimber commented #4265
  • Jan 07 10:04
  • Jan 05 17:11
    mac-dev commented #4265
  • Dec 31 2021 00:41
    nomad-mystic starred hechoendrupal/drupal-console
  • Dec 20 2021 00:57
    MatrixOfDeath commented #4310
  • Dec 14 2021 11:18
    awilhelm13 commented #4273
  • Dec 12 2021 13:36
  • Dec 08 2021 10:33
  • Dec 04 2021 16:11
    lhridley commented #4323
Jesus Manuel Olivas

I get this error message when using drupal config:export

[ERROR] <em class="placeholder">Warning</em>: unlink(../config/sync/language): Operation not permitted in <em          
         class="placeholder">Drupal\Console\Command\Config\ExportCommand-&gt;execute()</em> (line <em                   
         class="placeholder">106</em> of <em                                                                            
         m>). <pre class="backtrace">Drupal\Console\Command\Config\ExportCommand-&gt;execute(Object, Object) (Line:     
         Symfony\Component\Console\Command\Command-&gt;run(Object, Object) (Line: 978)                                  
         Symfony\Component\Console\Application-&gt;doRunCommand(Object, Object, Object) (Line: 255)                     
         Symfony\Component\Console\Application-&gt;doRun(Object, Object) (Line: 185)                                    
         Drupal\Console\Core\Application-&gt;doRun(Object, Object) (Line: 64)                                           
         Drupal\Console\Application-&gt;doRun(Object, Object) (Line: 148)                                               
         Symfony\Component\Console\Application-&gt;run() (Line: 89)                                                     
         require(&#039;/Users/efalzon/Sites/JdP8M7b/vendor/drupal/console/bin/drupal.php&#039;) (Line: 4)               

Any idea?

Hello folks, I am learning drupal and its exciting. From what I have seen in a couple of videos, the console qualifies as a super tool. I'm on windows 10 and dev desktop and tried to instal it but got this error. Being from a windows & .net background this is like a foreign language. Anyone able to help? PHP Fatal error: Uncaught RuntimeException: Your environment or operation system isn't supported in C:\Users\charl\Sites\devdesktop\Sandbox\vendor\webmozart\path-util\src\Path.php:257
Frederick Henderson
@cmutunga I am run Linux here, but maybe this will help. https://evolvingweb.ca/blog/installing-drupal-console-windows
@frederickjh Tried that already, in fact read a ton of stuff on the web:). There are no windows users on this forum? Thanks Fred
Frederick Henderson
@cmutunga you could take a look at the code that is reporting the error. It is right there in the output.
the 257 at the ends says the code on line 257 is what was last run, but with PHP always look at the lines before that as they too could be the culprit.
Seems like something to do with the home directory
public static function getHomeDirectory()
// For UNIX support
if (getenv('HOME')) {
return static::canonicalize(getenv('HOME'));
// For >= Windows8 support
if (getenv('HOMEDRIVE') && getenv('HOMEPATH')) {
return static::canonicalize(getenv('HOMEDRIVE').getenv('HOMEPATH'));
throw new RuntimeException("Your environment or operation system isn't supported");
This is interesting because I saw this issue on the drupal console git site
"DrupalConsole should guess HOME environment variable" it was resolved but the fix is not clear to me anyway
Frederick Henderson
@cmutunga Not sure how you would check them in Windows but you need to see if the environment variables $HOMEDRIVE and $HOMEPATH are set and that they are correct.
Thanks a lot, I'll dig around and check. BTW @jmolivas , who I notice was involved in the fix is on this forum.
Frederick Henderson
@cmutunga The issue you mention was closed because it should be fixed in another repository. @novia713 closed hechoendrupal/drupal-console#3612 and then opened hechoendrupal/drupal-console-core#255 in the correct repository to deal with this issue. If you are still having problems with this you could at least subscribe to that issue so you are updated when it is fix or you can help give feedback as you are having this happen to you.
@cmutunga Maybe this would be of help Where are User Environment Variables %homedrive%, %homepath% set?. However as you said before being from a Linux background this is like a foreign language to me.
I'm trying to install Drupal Console using the phar. Following the instructions using curl etc. works fine until I try any "drupal" command, then I get "Parse error: parse error, expecting "identifier (T_STRING)"' or"variable (T_VARIABLE)"' or '{'' or'$'' in phar:///usr/local/bin/drupal/vendor/symfony/yaml/Parser.php on line 42." I'm running MAMP 3.5.2, PHP 7.0.8, on Mac OS 10.9. Tips please.
Smeet J Thakkar
Hi Guys, I have been scratching my head trying to find the database table in D7 where the image URL path can be stored?
Can anyone help me out on ^^?
Image URL path example = local.drupal.com/files/style/square_thumbnail/public/media/image-name000.jpg
URL host is set
can find the name of the image in files_managed
can't seem to find where the styles applied can be found.
Smeet J Thakkar
How do I generate a relative path for a Drupal image through DB query (without using any D7 functions)?
I am able to get something like public://media/... form the files_managed table
but want something which like files/styles/square_thumbnail/public/media/...
Thomas M. Charging Hawk
I'm trying to install drupal console with composer and run it through docksal, hit a wall with this:
$ fin drupal --version --debug
Drupal Console Launcher version 1.7.0
Launcher path: /usr/local/bin/drupal
Drupal Console version 1.8.0
Per-Site path: /var/www/vendor/drupal/console/bin/drupal

✔ Creating request
✔ Creating Drupal kernel
✔ Registering dynamic services
✔ Rebuilding container

In AnnotationException.php line 54:

[Semantical Error] The annotation "@Drupal\Console\Annotations\DrupalCommand" in class Drupal\Console\Command\Rest\DisableCommand does not exist, or could not be auto-loaded.
presumably something's wrong with the autoloader?
hi. i have an outdated version of .console/chain/update-gitbook.yml
which repo should i update?

Hi, an error in debug:module commnad documentation:

Display all installed modules

$ drupal mod --status=installed
instead of
drupal debug:module --status=installed
Piotr Butkiewicz

Hi all, I'm trying to add Drupal Console to an existing Drupal 8 installation that was built with Acquia. I followed the documentation to install the global launcher and used composer to require drupal/console to my project, which seems to install fine without reporting any errors.

Then from the project root directory I run `vendor/bin/drupal init to copy the config files to the project in directory <project-root>/console.

However, once I do all that setup, all my drupal console commands response with errors like:

[ERROR] Command "site:status", is not a valid command name.


[ERROR] Command "generate:entity:content", is not a valid command name.

When i try vendor/bin/drupal list in terminal it responds with the full list of commands, but ends with a strange error:

[ERROR] The "/Users/pbutkiewicz/Sites/devdesktop/mysite-dev/docroot/vendor/drupal/console//config/services"       
         directory does not exist.

Seems like drupal console is looking for sth in the wrong place. ANy advice is much appreciated =)

I validated that the global launcher works as I could spin up a new site using drupal site:new then drupal site:install then composer require... and once it's set up I can run drupal console commands normally. However, I've been unsuccessful in adding drupal console to any existing Drupal 8 projects we've built through Acquia...
I'm installing a Drupal8 site with Console.
I want to add a table prefix. But when I add --db-prefix="test_", the install completes without any reported error.
But no table prefix is actually added.
Is this supposed to work currently? Or maybe a known bug?
Kevin Gautreau
Hi all !
following this issue : hechoendrupal/drupal-console#4086
I tried to install the dev version of drupal console : "drupal/console": "dev-master"
but it seems that the 1.9.1 version of console-core was not tagged yet but it's on the console's composer.json, So it end up with the following error :
Your requirements could not be resolved to an installable set of packages.

  Problem 1
    - drupal/console dev-master requires drupal/console-core 1.9.1 -> no matching package found.
but I just wanted to let you know
Edys Meza Palacio
Hi guys, someone can share me some reading for extending a Commands
Someone know if this steps for create a genereator command it is working yet? https://hechoendrupal.gitbooks.io/drupal-console/en/extending/generating-code.html
Hello. I just installed a drupal composer project and it comes with console installed, but when I list all the commands available, it does not show most of them and list generate just returns 3 commands, so basically console is useless. How is it supposed to be used?
Harold Juárez
Hi @edysmp_twitter That steps are still working. This is the new site of the docs https://drupalconsole.com/docs/en/extending/generating-code
alice13005 Hi, I'm trying to create an open source tool for the comunity and struggling on a technical point in relation with entities
alice13005 I want to integrate an custom entity reference in a field of an other custom entity. Both entities work and I even managed to integrate the user entity reference (a drupal core entity) in one of them, but I need help with the syntax of integrating entity references
I am getting below while trying to install downloaded Drupal in working directory (html and project folder name drupal2)
:/var/www/html/drupal2$ drupal site:install
[ERROR] Drupal Console is not installed at: "
Someone help, please.
How resolve this issue?
$ mv drupal.phar /usr/local/bin/drupal
mv: cannot move 'drupal.phar' to '/usr/local/bin/drupal': No such file or directory
Norah Shannon

When I use generate:module and select yes for Would you like to add module dependencies?:

$ fin drupal generate:module

 // Welcome to the Drupal module generator

 Enter the new module name:
 > test

 Enter the module machine name [test]:

 Enter the module Path [modules/custom]:

 Enter module description [My Awesome Module]:

 Enter package name [Custom]:

 Enter Drupal Core version [8.x]:

 Do you want to generate a .module file? (yes/no) [yes]:

 Define module as feature (yes/no) [no]:

 Do you want to add a composer.json file to your module? (yes/no) [yes]:

 Would you like to add module dependencies? (yes/no) [no]:
 > yes

 Module dependencies separated by commas (i.e. context, panels):
 > simplenews

 Do you want to generate a unit test class? (yes/no) [yes]:
 > no

 Do you want to generate a themeable template? (yes/no) [yes]:
 > no

 Do you want proceed with the operation? (yes/no) [yes]:

I get the following error:

 // generate:composer
Error: Call to a member function getPath() on null in /var/www/vendor/drupal/console/src/Generator/ComposerGenerator.php on line 46 #0 /var/www/vendor/drupal/console/src/Command/Generate/ComposerCommand.php(410): Drupal\Console\Generator\ComposerGenerator->generate(Array)
#1 /var/www/vendor/symfony/console/Command/Command.php(255): Drupal\Console\Command\Generate\ComposerCommand->execute(Object(Symfony\Component\Console\Input\ArrayInput), Object(Drupal\Console\Core\Style\DrupalStyle))
#2 /var/www/vendor/drupal/console-core/src/EventSubscriber/CallCommandListener.php(76): Symfony\Component\Console\Command\Command->run(Object(Symfony\Component\Console\Input\ArrayInput), Object(Drupal\Console\Core\Style\DrupalStyle))
#3 /var/www/vendor/symfony/event-dispatcher/EventDispatcher.php(212): Drupal\Console\Core\EventSubscriber\CallCommandListener->callCommands(Object(Symfony\Component\Console\Event\ConsoleTerminateEvent), 'console.termina...', Object(Symfony\Component\EventDispatcher\EventDispatcher))
#4 /var/www/vendor/symfony/event-dispatcher/EventDispatcher.php(44): Symfony\Component\EventDispatcher\EventDispatcher->doDispatch(Array, 'console.termina...', Object(Symfony\Component\Console\Event\ConsoleTerminateEvent))
#5 /var/www/vendor/symfony/console/Application.php(1014): Symfony\Component\EventDispatcher\EventDispatcher->dispatch('console.termina...', Object(Symfony\Component\Console\Event\ConsoleTerminateEvent))
#6 /var/www/vendor/symfony/console/Application.php(255): Symfony\Component\Console\Application->doRunCommand(Object(Drupal\Console\Command\Generate\ModuleCommand), Object(Symfony\Component\Console\Input\ArgvInput), Object(Symfony\Component\Console\Output\ConsoleOutput))
#7 /var/www/vendor/drupal/console-core/src/Application.php(188): Symfony\Component\Console\Application->doRun(Object(Symfony\Component\Console\Input\ArgvInput), Object(Symfony\Component\Console\Output\ConsoleOutput))
#8 /var/www/vendor/drupal/console/src/Application.php(64): Drupal\Console\Core\Application->doRun(Object(Symfony\Component\Console\Input\ArgvInput), Object(Symfony\Component\Console\Output\ConsoleOutput))
#9 /var/www/vendor/symfony/console/Application.php(148): Drupal\Console\Application->doRun(Object(Symfony\Component\Console\Input\ArgvInput), Object(Symfony\Component\Console\Output\ConsoleOutput))
#10 /var/www/vendor/drupal/console/bin/drupal.php(89): Symfony\Component\Console\Application->run()
#11 /var/www/vendor/drupal/console/bin/drupal(4): require('/var/www/vendor...')
#12 {main}
Error: Call to a member function getPath() on null in Drupal\Console\Generator\ComposerGenerator->generate() (line 46 of /var/www/vendor/drupal/console/src/Generator/ComposerGenerator.php).

Any idea what is going on here?


How resolve this issue?
$ mv drupal.phar /usr/local/bin/drupal
mv: cannot move 'drupal.phar' to '/usr/local/bin/drupal': No such file or directory

Windows doesn't have a /user/local/bin folder
See these instructions: https://www.drupal.org/docs/8/installing-and-configuring-the-drupal-console-with-windows-10-xampp