Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Visit summary graph is cached in mail client #4250

Open
anonymous-matomo-user opened this issue Oct 28, 2013 · 10 comments
Open

Visit summary graph is cached in mail client #4250

anonymous-matomo-user opened this issue Oct 28, 2013 · 10 comments
Labels
Bug For errors / faults / flaws / inconsistencies etc. c: Usability For issues that let users achieve a defined goal more effectively or efficiently. Waiting for user feedback Indicates the Matomo team is waiting for feedback from the author or other users.

Comments

@anonymous-matomo-user
Copy link

I've noticed this behavior in the iOS mail client for a long time, and it looks like Mail.app in Mavericks may have started this "helpful" behavior as well. I get about 30-40 email reports from Piwik each week. When I scroll through them the Visits Summary graphic gets cached and is the same image in every email. Im attaching two example screenshots. It seems the mail client is caching the inline attachment.

Looking at the email itself, I see that the filename is static:

Content-Type: image/png
Content-Transfer-Encoding: base64
Content-ID: <VisitsSummary_get>
Content-Disposition: inline; filename="Visits Summary.png"

Im going to make a guess that if a random string were appended to that filename and modified in the HTML body that it would no longer have this caching issue.

@anonymous-matomo-user
Copy link
Author

Attachment:
example1.png

@anonymous-matomo-user
Copy link
Author

Attachment:
example2.png

@anonymous-matomo-user
Copy link
Author

In 108c105: fixes #4250

@anonymous-matomo-user
Copy link
Author

I was thinking this change would have gotten into the 2.0.x release but as of 2.0.2 it is not there. Image names still use the same file name and the mail client still caches them. Can this get added into the release code?

@julienmoumne
Copy link
Member

This change has been released, see https://github.com/piwik/piwik/blob/2.0.2/plugins/ScheduledReports/API.php#L912

If it's still not working, please provide the necessary data to investigate the issue (such as the relevant mail source code fragments).

@mattab
Copy link
Member

mattab commented Dec 25, 2013

@julien is the 'cid' the fix? where is it used in the email source?

@mattab
Copy link
Member

mattab commented Feb 6, 2014

Removing owner from tickets. from now on, I suggest we assign tickets to ourselves for cases when we we plan to actively work on them in the coming days/weeks. let's discuss if needed during our team call.

@mattab
Copy link
Member

mattab commented Mar 16, 2014

I can confirm the bug I could reproduce, eg. the source code is:

=0A        </table>=0A        <br/>=0A    <a style=3D"text-decoration:no=
ne; color: rgb(126,115,99); font-size: 9pt;" href=3D"#reportTop">=0A   =
     Retour haut de page=0A    </a>=0A<h2 id=3D"VisitsSummary_get" style=
=3D"color: rgb(126,115,99); font-size: 11pt;">=0A    R=C3=A9capitulatif=
 des visites=0A</h2>=0A=0A            <img alt=3D""=0A                 =
                   src=3D"cid:VisitsSummary_get"=0A                    =
            height=3D"200"=0A                width=3D"700"/>=0A    =0A =

the image reads: cid:VisitsSummary_get and the cache buster is missing.

@julienmoumne
Copy link
Member

The fix I committed changes the filename but not the cid indeed.

At line [https://github.com/piwik/piwik/blob/2.0.2/plugins/ScheduledReports/API.php#L924] I would suggest :

$additionalFile['cid'] = $additionalFile['filename'];

html_report_body.tpl would also need to be updated.

This would need to be tested on different mail clients as Iam not sure we can set arbitrary characters in the cid attribute.

@anonymous-matomo-user anonymous-matomo-user added this to the 2.x - The Great Piwik 2.x Backlog milestone Jul 8, 2014
@mattab mattab removed P: low labels Aug 3, 2014
sabl0r pushed a commit to sabl0r/piwik that referenced this issue Sep 23, 2014
@mattab mattab modified the milestones: Mid term, Short term Oct 11, 2014
@mattab mattab added the c: Usability For issues that let users achieve a defined goal more effectively or efficiently. label Apr 9, 2015
@tsteur
Copy link
Member

tsteur commented Feb 20, 2024

Hi, if anyone still has this issue please comment

@sgiehl sgiehl added the Waiting for user feedback Indicates the Matomo team is waiting for feedback from the author or other users. label Mar 25, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Bug For errors / faults / flaws / inconsistencies etc. c: Usability For issues that let users achieve a defined goal more effectively or efficiently. Waiting for user feedback Indicates the Matomo team is waiting for feedback from the author or other users.
Projects
None yet
Development

No branches or pull requests

5 participants