sheriferson / Visualize.mmBundle

:bar_chart: Visualize email history and trends.
4 stars 2 forks source link

localDateTime preventing visualization #4

Closed nickreich closed 8 years ago

nickreich commented 9 years ago

This looks like a sweet new tool for visualizing my email data. I tried to use the Visualize bundle but the data seems to have not exported right from MailMate. I installed Visualize, highlighted a bunch of sent emails, and chose the "visualize by time" from the Command menu. The following screen pops up in Safari: screen shot 2015-08-23 at 12 18 26 pm

I checked the csv file that the url suggests the data is coming from and I noticed that the localDateTime column is not populated: screen shot 2015-08-23 at 12 19 41 pm

Is this due to a local setting in my version of MailMate? I'm using Version 1.9.1 (5084) on a MacBook Pro running OS X 10.9.5.

nickreich commented 9 years ago

FWIW - When I choose to organize by sender, the graphics are created and look good.

sheriferson commented 9 years ago

Thank you for reporting this (and thank you for trying the bundle). I tried what you described (select a bunch of emails in Sent, and then ^T for "Emails by time") and couldn't reproduce the problem -- plots worked fine for me.

A few questions:

  1. If you select another bunch of emails in Sent (try a completely different bunch), does it work?
  2. If you select a bunch of emails from Inbox or some other mailbox and try "Emails by time", does it work?

It's possible there is one (or several) email(s) that are causing the issue, or it could be a more general MailMate issue related to localizations or something similar. I'll bring this thread to the attention of Benny, the developer, in case he has any insight.

freron commented 9 years ago

Sorry about the late reply. It does look strange that all of the emails fail to get a local date. It might be worth trying to replace #date.#local with just #date to see if any dates then come through. And if they do I'd like to know the location of nickreich such that I can try to reproduce it.

nickreich commented 9 years ago

Yup, I tried selecting several small batches of recent emails and none had any localDateTime entries. I'm not sure how to change the field name in the code for the visualize module as freron suggests. (assuming the suggestion was just to do it locally on my machine?) Is that something that I could do by hand without blowing up MailMate? I'd be happy to try if so.

freron commented 9 years ago

Yes, as a quick hack, you can replace this file:

~/Library/Application\ 

Support/MailMate/Managed/Bundles/Visualize.mmbundle/Commands/byTime.mmCommand

With the following text content:

{   command = "#!/bin/bash\n\"${MM_BUNDLE_SUPPORT}/bin/display\" 
byTime\n";
    executionMode = "multipleMessages";
    formatString = 
"\"${from.name:?${from.name/\"/\"\"/g}:${from.address/\"/\"\"/g}}\",\"${from.address/\"/\"\"/g}\",\"${subject/\"/\"\"/g}\",\"${#mailer.name/\"/\"\"/g}\",${#date},1";
    input = "formatted";
    keyEquivalent = "^t";
    name = "Emails by time";
    uuid = "82B369F4-7281-4C55-93C3-71779ACBB432";
}

I've just changed #date.#local to #date.

sheriferson commented 8 years ago

@nickreich The latest update to the plugin through the MailMate app should now automatically exclude emails missing date headers. Let me know if you still run into any trouble.