Exact same issue as #2307779: Generating >50 nodes or >10 comments does not work (batches not processed), for the same reason: batch is again set, but not processed.

Adding a batch_process line in ContentDevelGenerate::generateElements() for the batch case :

  • does insert the items in the drupal_batch:<bid>:0 queue
  • does not expose the batch id
  • if the batch id is passed to drush batch-process callbacks throw all kinds of bad argument errors
Support from Acquia helps fund testing for Drupal Acquia logo

Comments

fgm created an issue. See original summary.

JurriaanRoelofs’s picture

Having the same problem. More than 50 nodes in drush genc = no nodes.

vakulrai’s picture

I am using drupal v-8.3.4 and devel generate for nodes and content is working fine for me. The following command might work for you:-

1) drush generate-content n (where , n =number of contents you want to generate).
2) drush genc x y (where , x= number of contents you want to generate and y=number of comments per node you want).

vakulrai’s picture

Status: Active » Needs review
fgm’s picture

Status: Needs review » Active

Just checked with 1.x-dev HEAD and the problem is still present.

vakulrai : did you try with strictly more than 50 nodes (eg 51) or strictly more than 10 comments (eg 11) ? The drush command says it performed the generation but it actually has not when you look at the content admin page.

vakulrai’s picture

Hi @fgm I forgot to add :-

The Devel Generate module, which comes with Devel, has some Drush commands built in to generate dummy content. If you haven't already installed the Devel module, you can install and enable it with Drush.
Please follow the steps before running the above commands .

1) drush dl devel
2) drush en devel -y
3) drush en devel_generate -y
4)drush generate-content 53
5)drush genc x y

Thanks.

vakulrai’s picture

Status: Active » Needs review

  • moshe weitzman committed 5f4a6c1 on 8.x-1.x
    #2866990. Add processing for batch generate-content via Drush.
    
    Still...
moshe weitzman’s picture

Status: Needs review » Active

Use 'needs review' when a patch is posted.

Added a little code but still can't get drush batching to work (i.e. >50 nodes).

drugan’s picture

Status: Active » Needs review
FileSize
5.79 KB

I've encountered with the same issue while working on the Commerce Bulk Commerce Generate submodule's GenerateProducts (devel_generate) plugin. The whole reason is quite complex. If you have Drupal Commerce module installed you can try the drush generate-products command which implements the same functionality as in the patch. For now just Drush8 is tested. Let me know whether it works with your Drush9 install.

Status: Needs review » Needs work

The last submitted patch, 10: 2866990-10.patch, failed testing. View results
- codesniffer_fixes.patch Interdiff of automated coding standards fixes only.

drugan’s picture

FileSize
166.16 KB

Can't reproduce test fail on my local install:

green

vegantriathlete’s picture

Oleksiy’s picture

Status: Needs work » Needs review
FileSize
2.92 KB
2.42 KB

The test was OK on my local too.

andypost’s picture

vacho’s picture

Issue tags: +RTBC

The patch #14 woks fine for me for drush command:
e.g:

drush genc 55 --types=article
andypost’s picture

Status: Needs review » Reviewed & tested by the community
Issue tags: -RTBC +ContributionWeekend2019

  • moshe weitzman committed c158263 on 8.x-2.x authored by Oleksiy
    Issue #2866990 by drugan, Oleksiy, moshe weitzman: Generating >50 nodes...
moshe weitzman’s picture

Status: Reviewed & tested by the community » Fixed

Merged. Sorry to everyone for the long delay here.

salvis’s picture

@moshe:
Your commits aren't reflected on the front page — see #3017628-6: Commits are not showing on drupal user profile page.

moshe weitzman’s picture

Yeah, the block has 12 months ago for my name. Is that same issue as the one you linked to? The commits ARE associated with my d.o. user https://www.drupal.org/user/23/track/code

salvis’s picture

My guess is that you've changed either your Git email address or your d.o email address, and they're now out of sync.

Status: Fixed » Closed (fixed)

Automatically closed - issue fixed for 2 weeks with no activity.