Duplicating a view with an exposed form as data export causes issues

Created on 14 June 2018, over 6 years ago
Updated 22 March 2024, 9 months ago

I had duplicated the view form an existing view (that has an exposed form) as a data export. When I try to use VDE (CSV button) on that view, I get this:

Create a view of taxonomy data with an exposed filter.
Duplicate view for views_data_export
Try exporting the data
Error:

Error: Call to a member function preExecute() on null in Drupal\views\Plugin\views\display\DisplayPluginBase->preExecute() (line 2272 

The code it fails on is

    if ($this->usesExposed()) {
      /** @var \Drupal\views\Plugin\views\exposed_form\ExposedFormPluginInterface $exposed_form */
      $exposed_form = $this->getPlugin('exposed_form');
      $exposed_form->preExecute();
    }

I then did #10 and now it works fine.

πŸ› Bug report
Status

Postponed: needs info

Version

11.0 πŸ”₯

Component
Views UIΒ  β†’

Last updated 17 days ago

Created by

πŸ‡ΊπŸ‡ΈUnited States labboy0276

Live updates comments and jobs are added and updated live.
Sign in to follow issues

Comments & Activities

Not all content is available!

It's likely this issue predates Contrib.social: some issue and comment data are missing.

  • πŸ‡³πŸ‡ΏNew Zealand quietone

    I tested this today on a fresh Drupal 10.3.x, umami install. I installed views_data_export, made the view and exposed the 'published' filter, tested, duplicated the view and tested again. In all cases this worked without error.

    This still needs steps to reproduce. I am keeping the status at Postponed (maintainer needs more info). If we don't receive additional information to help with the issue, it may be closed after three months.

    Thanks!

  • πŸ‡³πŸ‡ΏNew Zealand quietone

    The work above was done at DrupalSouth 2024

  • πŸ‡¦πŸ‡ΊAustralia RichardGaunt Melbourne

    I've also been able to replicate by changing an exported data export display exposed form to `exposed_form: false` following #10

    And then reimporting config, the RestExport::usesExposed class that DataExport class inherits always returns true and so when an exposed form is not present it throws error.

    I was not able to replicate through the UI but just through manual manipulation of the configuration.

  • πŸ‡¦πŸ‡ΊAustralia griffynh Sydney

    Hola, this came up in the #bugsmash channel as the PMNMI daily triage target.

    Since we haven't had an update in nine months, if there is no update in the next three months, this issue may be closed.

Production build 0.71.5 2024