Make WordPress Core

Opened 5 weeks ago

Last modified 26 hours ago

#44133 new enhancement

Should the Data Export indicate when we have no information on the user

Reported by: garrett-eclipse Owned by:
Milestone: 4.9.7 Priority: normal
Severity: normal Version: 4.9.6
Component: Privacy Keywords: has-screenshots has-patch needs-testing
Focuses: administration Cc:



If a data export is done for a non-existent user should we indicate in the .html file provided that we have no information on the subject? Currently the file is provided and just the initial table provided. If there's nothing else should a message be there to indicate that we currently have nothing stored on them?


Attachments (10)

Screen Shot 2018-05-17 at 1.42.03 PM.png (73.6 KB) - added by garrett-eclipse 5 weeks ago.
.html export when we have no data on subject
no-personal-data-found-version-1.jpg (27.0 KB) - added by birgire 5 weeks ago.
no-personal-data-found-version-2.jpg (26.2 KB) - added by birgire 5 weeks ago.
no-personal-data-found-version-3.jpg (27.0 KB) - added by birgire 5 weeks ago.
44133.diff (563 bytes) - added by birgire 5 weeks ago.
no-personal-data-found-in-email.jpg (26.9 KB) - added by birgire 5 weeks ago.
44133.2.diff (4.2 KB) - added by birgire 5 weeks ago.
44133.3.diff (5.4 KB) - added by birgire 3 weeks ago.
44133.4.diff (5.1 KB) - added by desrosj 3 weeks ago.
Minor docblock fixes.
44133.5.diff (6.9 KB) - added by desrosj 26 hours ago.

Download all attachments as: .zip

Change History (26)

5 weeks ago

.html export when we have no data on subject

#1 @desrosj
5 weeks ago

  • Version changed from trunk to 4.9.6

Marking Privacy change as introduced in 4.9.6.

5 weeks ago

#2 @birgire
5 weeks ago

  • Keywords has-patch has-screenshots added

I posted some ideas in

and attached a patch for the third version in 44133.diff.

It adds a Result row to the About group, with two possible values:

  • No personal data found.
  • Personal data found.

Another approach might be to only generate an export file, when personal data is found, and mention that in the email instead.

So instead of sending an export link to an "empty" export file, the email would say No personal data found.

Last edited 5 weeks ago by birgire (previous) (diff)

#3 @garrett-eclipse
5 weeks ago

Thanks @birgire that's awesome. In my opinion I think it would make the most sense to not generate an export and instead have the email indicate there was no data. Even with the result field of no data found in the .html you have to download a zip, open the .html to find there's nothing. Just seems like extra unnecessary steps. Cheers

5 weeks ago

#4 @birgire
5 weeks ago

@garrett-eclipse yes it's probably better user experience to not have to download a zip file and open it, and to discover that no personal data was found :).

The patch in 44133.2.diff is just a PoC patch.

The screenshot in no-personal-data-found-in-email.jpg is from Gmail.

#5 @garrett-eclipse
5 weeks ago

Niiice @birgire I like that alot thank you. And I agree it feels nicer to remove the extra steps when they're not needed. Cheers

This ticket was mentioned in Slack in #gdpr-compliance by desrosj. View the logs.

4 weeks ago

#7 @desrosj
4 weeks ago

  • Milestone changed from Awaiting Review to 4.9.7

#8 @desrosj
3 weeks ago

  • Keywords needs-refresh added

+1 for not generating and sending a ZIP when no data is found for a user.

@birgire the patch looks good overall and just needs a refresh. Here is some general feedback.

  • Can we change the wp_privacy_send_personal_data_export_email() documentation to make note that an email is sent to a user if no data is found.
  • wp_privacy_personal_data_email_content bool type for the new parameter is misaligned.
  • A @since 4.9.7 tag should be added to the wp_privacy_send_personal_data_export_email() function and wp_privacy_personal_data_email_content filter noting the introduction of the new $has_data_export parameter.

Also, is there any reason a plugin would want to override the value of $has_data_export? If so, a filter could be added there.

3 weeks ago

3 weeks ago

Minor docblock fixes.

#9 @desrosj
3 weeks ago

  • Keywords needs-refresh removed

44133.4.diff makes some minor improvements:

  • @param and @return tags shouldn't be aligned together.
  • The @since 4.9.7 should be added and the @since 4.9.6 should remain. The 4.9.7 comment should describe that the parameter was added.

#10 @birgire
3 weeks ago

Thanks for good suggestions @desrosj

I got some unexpected interruption, earlier today, so I couldn't finish adding the patch and the writeup :)

Looks like you covered it in the latest patch, thanks.

The patch also includes a missing comment for translators.

Regarding a special filter for $has_data_export, I don't see a reason for it, at the moment. It might be considered later, if requested with a good use-case example. In the meanwhile there are workarounds, with current filters, if needed.

I now wonder if $has_export_data sounds better than $has_data_export ?

This ticket was mentioned in Slack in #core-privacy by desrosj. View the logs.

3 weeks ago

#12 @allendav
3 weeks ago

This (e.g. no data found) is a good first candidate for a row notice for export (like what erase does today). See also #43974

Last edited 3 weeks ago by allendav (previous) (diff)

This ticket was mentioned in Slack in #core-privacy by desrosj. View the logs.

5 days ago

#14 @desrosj
26 hours ago

  • Keywords needs-patch added; has-patch removed

Patch is no longer applying cleanly.

#15 @desrosj
26 hours ago

  • Keywords has-patch needs-refresh added; needs-patch removed

26 hours ago

#16 @desrosj
26 hours ago

  • Keywords needs-testing added; needs-refresh removed

44133.5.diff is a refresh with the following changes:

  • Only run the wp_privacy_personal_data_email_content filter on the email content sent with a successful export file link.
  • Introduce the wp_privacy_personal_data_email_content_no_data filter for filtering the email text sent when no data is found.
  • Only fire the wp_privacy_personal_data_export_file action when data is found for exporting.
  • Add the $request variable as a parameter for the wp_privacy_personal_data_export_file action.
  • Introduce the wp_privacy_personal_data_export_no_data action that fires when no data is found for the request. This will allow plugins to perform custom code when a request data has been gathered and determined to be empty.
Note: See TracTickets for help on using tickets.