Automattic / wp-calypso

The JavaScript and API powered WordPress.com
https://developer.wordpress.com
GNU General Public License v2.0
12.42k stars 1.99k forks source link

Activity Log: Backup points don't include pages #45247

Open coder-karen opened 4 years ago

coder-karen commented 4 years ago

When a backup is complete, the Activity Log will give a brief snapshot indicating the number of plugins, themes, uploads and posts backed up. While this is just a snapshot, it omits pages which has caused some confusion.

Could the UI include pages in the Activity Log backup snapshot?

screenshot (10)

Steps to reproduce

  1. Starting at URL: https://wordpress.com/activity-log/YOUR-SITE-ADDRESS
  2. Scroll to any completed backup snapshots, and notice that pages are missing

What I expected

What happened instead

Context / Source

P1597913249003000-slack-jetpack-yamato 3233472-zd-woothemes

folletto commented 4 years ago

I think the simplest approach from a UI perspective is to just add pages to the text:

17 plugins, 4 themes, 11324 uploads, 108 posts, 23 pages.

How challenging would that be technically?

singerb commented 4 years ago

I think the simplest approach from a UI perspective is to just add pages to the text:

17 plugins, 4 themes, 11324 uploads, 108 posts, 23 pages.

How challenging would that be technically?

Not very challenging, but it would not work for historical events, since it requires us changing our data collection slightly (we count DB rows for each table for stats like this, but we also do the "special" count of published posts for the wp_posts table, so we'd have to add the published pages count there too). So as long as we're fine with it only being on new events, this requires a minor change on the backend to count pages, and a minor change in the activity stream item to add that data if it's present. No Calypso (or activity log ES) changes needed.

folletto commented 4 years ago

Is there any problem if we start from now onward given it's simple, and then if we find out it's a problem for past events, do more work, or would the change create some backward incompatibility in doing the second change later?

singerb commented 4 years ago

Doing this for historical events is essentially impossible (or, so far outside the technical design of how activity log events work as to make it not worth it). So no, doing this fix now doesn't change that at all :-)

github-actions[bot] commented 3 years ago

This issue is stale because it has been 180 days with no activity. You can keep the issue open by adding a comment. If you do, please provide additional context and explain why you’d like it to remain open. You can also close the issue yourself — if you do, please add a brief explanation and apply one of relevant issue close labels.