droptica / droopler_project

GNU General Public License v2.0
45 stars 30 forks source link

Error during installation #104

Closed valica closed 3 years ago

valica commented 3 years ago

Hello,

I tried to install Droopler using droopler_project profile using: composer create-project droptica/droopler-project "^8.2.0" composer install composer drupal:scaffold

And then start the drupal website usual install (web-based). I've got this error after installing the Demo:

_An AJAX HTTP error occurred. HTTP Result Code: 200 Debugging information follows. Path: /drooplertest/core/install.php?rewrite=ok&profile=droopler&langcode=en&id=5&op=do_nojs&op=do StatusText: OK ResponseText: Error: Call to a member function getValue() on null in lazy_preprocessfield() (line 194 of C:\Data\webdev\drupalProjects\test\web\modules\contrib\lazy\lazy.module).

More details here:

The website encountered an unexpected error. Please try again later. Error: Call to a member function getValue() on null in lazy_preprocess_field() (line 194 of modules\contrib\lazy\lazy.module).

lazy_preprocess_field(Array, 'field', Array) (Line: 287) Drupal\Core\Theme\ThemeManager->render('field', Array) (Line: 431) Drupal\Core\Render\Renderer->doRender(Array) (Line: 444) Drupal\Core\Render\Renderer->doRender(Array, 1) (Line: 200) Drupal\Core\Render\Renderer->render(Array, 1) (Line: 156) Drupal\Core\Render\Renderer->Drupal\Core\Render{closure}() (Line: 573) Drupal\Core\Render\Renderer->executeInRenderContext(Object, Object) (Line: 157) Drupal\Core\Render\Renderer->renderPlain(Array) (Line: 536) Drupal\node\Plugin\Search\NodeSearch->indexNode(Object) (Line: 500) Drupal\node\Plugin\Search\NodeSearch->updateIndex() (Line: 181) search_cron() call_user_func_array('search_cron', Array) (Line: 392) Drupal\Core\Extension\ModuleHandler->invoke('search', 'cron') (Line: 236) Drupal\Core\Cron->invokeCronHandlers() (Line: 134) Drupal\Core\Cron->run() (Line: 75) Drupal\Core\ProxyClass\Cron->run() (Line: 1860) install_finished(Array) (Line: 695) install_run_task(Array, Array) (Line: 570) install_run_tasks(Array, NULL) (Line: 118) install_drupal(Object) (Line: 44)

Could you tell me if you have a version where this is fixed ?

Kind regards, Vlad

grzegorz-pietrzak-droptica commented 3 years ago

Hi, latest stable version 2.1.1 of Droopler has a fix to it, actually "^8.2.0" constraint for droopler_project should download it. Could you have a look in the console what version of droptica/droopler and drupal/lazy was downloaded by composer?

valica commented 3 years ago

Hi Grzegorz, I tried with droptica/droopler 8.2.0 et 8.2.1 drupal/lazy: 3.6.0

Still same result.

grzegorz-pietrzak-droptica commented 3 years ago

Please try 8.2.1.1 of Droopler, this is the latest release. It should downgrade lazy to 3.4

valica commented 3 years ago

OK, I will do it now and be back.

grzegorz-pietrzak-droptica commented 3 years ago

I was talking about droptica/droopler version. The 8.2.1 version of droptica/droopler_project downloads latest version 8.2.1.* of droptica/droopler, so it should fetch 8.2.1.1, maybe something went wrong.

valica commented 3 years ago

I tested droptica/droopler v8.2.1.1 from scratch. It linked indeed to lazy v3.4. No more errors during installation -> OK.

But, at the end of the installation, the menus are not styled at all. I had a look to see if wemegamenu is enabled, and yes, it is. Al the menus are KO.

grzegorz-pietrzak-droptica commented 3 years ago

It's hard to say what happened, it works on our side. Was SCSS compilation succesful?

valica commented 3 years ago

OK, I had a look to compile logs. Indeed there were some errors there and some css were missing at the end. I deleted everything and started again and it worked more or less well, thank you.

I had however lots of warnings during compilation cause by a unique problem: WARNING: The make-container-max-widths mixin has been deprecated as of v4.5.2. It will be removed entirely in v5.

And other warnings: $ npm install npm WARN deprecated chokidar@2.1.8: Chokidar 2 will break on node v14+. Upgrade to chokidar 3 with 15x less dependencies. npm WARN deprecated urix@0.1.0: Please see https://github.com/lydell/urix#deprecated npm WARN deprecated fsevents@1.2.13: fsevents 1 will break on node v14+ and could be using insecure binaries. Upgrade to fsevents 2. npm WARN deprecated request@2.88.2: request has been deprecated, see https://github.com/request/request/issues/3142 npm WARN deprecated resolve-url@0.2.1: https://github.com/lydell/resolve-url#deprecated npm WARN deprecated har-validator@5.1.5: this library is no longer supported

Is it a migration planned for those warnings or maybe already solved in a dev branch? Dziękuję Ci

grzegorz-pietrzak-droptica commented 3 years ago

Hi, the warnings are not solved yet, we will probably move it to the version after the upcoming one (as it is harmless, and we want to check how does new Bootstrap behave)

valica commented 3 years ago

Hi Grzegorz, I would like to customize the site-footer which is defined in droopler_theme/scss/barrio/_site-footer. I tried to add my scss either in config folder or in a newly created folder and then reference it in _all.scss. After compilation I always get the initial .site-footer from the base theme which adds a padding: 35px 0 0;

The padding is the one I want to remove (to set to 0 0 0).

Is it something wrong in what I did ? How should I do ? Thank you for your answer. Kind regards, Vlad P.S. It's not linked to this issue that can be closed given the fact a solution exists.

dj12djdjs commented 3 years ago

I'm having the same problem during installation on both 8.2.0 and 8.2.1

Notice: Undefined index: #item in lazy_preprocess_field() (line 194 of modules/contrib/lazy/lazy.module). lazy_preprocess_field(Array, 'field', Array) (Line: 287) Drupal\Core\Theme\ThemeManager->render('field', Array) (Line: 431) Drupal\Core\Render\Renderer->doRender(Array) (Line: 444) Drupal\Core\Render\Renderer->doRender(Array, 1) (Line: 200) Drupal\Core\Render\Renderer->render(Array, 1) (Line: 156) Drupal\Core\Render\Renderer->Drupal\Core\Render{closure}() (Line: 573) Drupal\Core\Render\Renderer->executeInRenderContext(Object, Object) (Line: 157) Drupal\Core\Render\Renderer->renderPlain(Array) (Line: 536) Drupal\node\Plugin\Search\NodeSearch->indexNode(Object) (Line: 500) Drupal\node\Plugin\Search\NodeSearch->updateIndex() (Line: 181) search_cron() call_user_func_array('search_cron', Array) (Line: 392) Drupal\Core\Extension\ModuleHandler->invoke('search', 'cron') (Line: 236) Drupal\Core\Cron->invokeCronHandlers() (Line: 134) Drupal\Core\Cron->run() (Line: 75) Drupal\Core\ProxyClass\Cron->run() (Line: 1860) install_finished(Array) (Line: 695) install_run_task(Array, Array) (Line: 570) install_run_tasks(Array, NULL) (Line: 118) install_drupal(Object) (Line: 44)

Here are my steps to reproduce.

  1. composer create-project droptica/droopler-project
  2. cd droopler-project
  3. composer drupal:scaffold
  4. composer install
  5. cd droopler-project/web/themes/custom/droopler_subtheme
  6. npm install
  7. npm install bootstrap (Without this I get error during gulp compile because bootstrap is not found.)
  8. gulp compile
valica commented 3 years ago

I had similar problems but it worked at the end. I will write a note about the detailed procedure to follow. I'm sure droptica will update their website with the required information. Which the version of your composer? Vlad Valica

dj12djdjs commented 3 years ago

I've just tried manually telling composer to update to 8.2.1.1 and that solved the problem ✅

Originally I tried with composer 2.0.7 but It seemed one of the packages isn't compatible with composer 2 yet so I had to switch to 1.10.17 for this project.

valica commented 3 years ago

I had exactly the same composer V2 problem... And indeed using 8.2.1.1 as told by Grzegorz was the good solution. Now I try to find a way to customize the subtheme in a clean way. The style I want to customize is coming from barrio (in the base theme). Do you have a hint?

dj12djdjs commented 3 years ago

I'm not sure. I haven't worked directly with SCSS and Drupal theming before.

valica commented 3 years ago

ok, thanks.