Re: [Evolution] HTML email problem

2020-01-07 Thread Joe Wade Pulley via evolution-list
That worked perfectly.  Thank you!

Joe

On Tue, 2020-01-07 at 14:55 +0100, Ángel wrote:
> On 2020-01-07 at 08:05 -0500, Joe Wade Pulley wrote:
> > Thanks for figuring out the problem, but the sed command doesn't
> work
> > for me.
> > 
> > I don't have anything with a .evolution in its name.
> > 
> 
> > Inside cur/ is a file
> > 1578136602.6469_0.:2,S
> 
>  
> Sorry, I didn't realize that such 'evolution' was my local hostname.
> 
> 
> > If I apply your sed command to that file it does indeed fix it, but
> I'm
> > not familiar enough with sed to know how to make it find all the
> > occurrences in each folder recursively in
> > ~/.local/share/evolution/mail/local/
> > in each email and apply the fix.
> > 
> > Did I do something incorrectly when I set up evolution that gave me
> > this file structure instead of what you expected?
> 
> No. Your setup right. I just made the matching too strict.
> 
> The command should be relatively safe, but I still didn't want to
> make
> that to too broad.
> 
> You could apply it to all emails inside
> ~/.local/share/evolution/mail/local/ with the command:
> 
> find ~/.local/share/evolution/mail/local/ -type f -name \*:2,\* -exec
> sed -i  '0,/^$/ { s!^Content-Type: multipart/alternate!Content-Type:
> multipart/alternative! }' \{\} +
> 
> 
> If you imported your pst into a specific route, you don't need to
> search
> on the whole ~/.local/share/evolution/mail/local/
> 
> The sed is simply looking at the headers of each mail and replacing
> multipart/alternate into multipart/alternative in the Content-Type:
> header.
> 
> 
> Best regards
> 

___
evolution-list mailing list
evolution-list@gnome.org
To change your list options or unsubscribe, visit ...
https://mail.gnome.org/mailman/listinfo/evolution-list


Re: [Evolution] HTML email problem

2020-01-07 Thread Ángel
On 2020-01-07 at 08:05 -0500, Joe Wade Pulley wrote:
> Thanks for figuring out the problem, but the sed command doesn't work
> for me.
> 
> I don't have anything with a .evolution in its name.
> 

> Inside cur/ is a file
> 1578136602.6469_0.:2,S

 
Sorry, I didn't realize that such 'evolution' was my local hostname.


> If I apply your sed command to that file it does indeed fix it, but I'm
> not familiar enough with sed to know how to make it find all the
> occurrences in each folder recursively in
> ~/.local/share/evolution/mail/local/
> in each email and apply the fix.
> 
> Did I do something incorrectly when I set up evolution that gave me
> this file structure instead of what you expected?

No. Your setup right. I just made the matching too strict.

The command should be relatively safe, but I still didn't want to make
that to too broad.

You could apply it to all emails inside
~/.local/share/evolution/mail/local/ with the command:

find ~/.local/share/evolution/mail/local/ -type f -name \*:2,\* -exec sed -i  
'0,/^$/ { s!^Content-Type: multipart/alternate!Content-Type: 
multipart/alternative! }' \{\} +


If you imported your pst into a specific route, you don't need to search
on the whole ~/.local/share/evolution/mail/local/

The sed is simply looking at the headers of each mail and replacing
multipart/alternate into multipart/alternative in the Content-Type:
header.


Best regards

___
evolution-list mailing list
evolution-list@gnome.org
To change your list options or unsubscribe, visit ...
https://mail.gnome.org/mailman/listinfo/evolution-list


Re: [Evolution] HTML email problem

2020-01-07 Thread Joe Wade Pulley via evolution-list
Thanks for figuring out the problem, but the sed command doesn't work
for me.

I don't have anything with a .evolution in its name.

My emails are stored in my home directory as 
~/.local/share/evolution/mail/local/./cur/

For example "Test.pst" I sent to you shows as a folder under
"On This Computer" 
in evolution.  

It is stored as
~/.local/share/evolution/mail/local/.Test/
with subfolders
cur/
new/
tmp/

Inside cur/ is a file
1578136602.6469_0.:2,S

If I apply your sed command to that file it does indeed fix it, but I'm
not familiar enough with sed to know how to make it find all the
occurrences in each folder recursively in
~/.local/share/evolution/mail/local/
in each email and apply the fix.

Did I do something incorrectly when I set up evolution that gave me
this file structure instead of what you expected?

Thanks
Joe


On Tue, 2020-01-07 at 01:21 +0100, Ángel wrote:
> On 2020-01-04 at 06:45 -0500, Joe Wade Pulley wrote:
> > Thanks for the reply.  
> > 
> > I've created a Test.pst file containing 1 email in Outlook.  
> > 
> > I wasn't sure how to show you the way it looks for me in Evolution
> so I
> > took a screenshot of what I see showing the header, the text
> portion at
> > the top of the email and the beginning of the HTML display of the
> email
> > at the bottom of the screen.  I also attached a pdf of what I see
> in
> > Outlook.  Except for some font issues (likely not installed on
> Ubuntu)
> > the HTML portion looks fine in Evolution.
> > 
> > If there is something else you need in order to see what I'm
> talking
> > about please let me know.
> > 
> > Thanks,
> > Joe
> 
> I have been able to import the email myself and reproduce the issue.
> 
> Looking at the source of the imported mail, it has the header:
> > Content-Type: multipart/alternate; boundary="=-
> m7pctIXGHnNa8SIElS5Z"
> > 
> which is wrong, it should be multipart/alternative, per rfc 1341 (and
> later, up to rfc 2046)
> 
> It's true that it is used to specify alternate contents, but the
> right
> name is multipart/alternative.
> 
> Reviewing the code, it is a bug of the pst importer, that sets the
> mime
> to multipart/alternate rather than multipart/alternative.
> 
> https://gitlab.gnome.org/GNOME/evolution/blob/master/src/plugins/pst-import/pst-importer.c#L1322
> 
> 
> I have opened bug 745 about this, along with the trivial fix as a
> merge
> request:
> https://gitlab.gnome.org/GNOME/evolution/issues/745
> https://gitlab.gnome.org/GNOME/evolution/merge_requests/42
> 
> (hope it is right from a procedimental pov, though)
> 
> 
> Joe, as you are using the evolution version packaged by Ubuntu 19.10
> I
> see a few options.
> * You could switch to a newer version -with this bug fixed- based on
> Flatpack.
> * You could try to get Ubuntu maintainers to include this fix
> * You could patch your own evolution version (this is a trivial fix,
> so
> it'd be very simple)
> * You could continue using the broken importer and deal with it
> fixing
> the imported entries later. Just running the following sed command on
> the folder containing the imported files would fix them:
> 
> sed -i  '0,/^$/ { s!^Content-Type: multipart/alternate!Content-Type:
> multipart/alternative! }' *.evolution:*
> 
> 
> Kind regards
> 

___
evolution-list mailing list
evolution-list@gnome.org
To change your list options or unsubscribe, visit ...
https://mail.gnome.org/mailman/listinfo/evolution-list


Re: [Evolution] HTML email problem

2020-01-06 Thread Ángel
On 2020-01-04 at 06:45 -0500, Joe Wade Pulley wrote:
> Thanks for the reply.  
> 
> I've created a Test.pst file containing 1 email in Outlook.  
> 
> I wasn't sure how to show you the way it looks for me in Evolution so I
> took a screenshot of what I see showing the header, the text portion at
> the top of the email and the beginning of the HTML display of the email
> at the bottom of the screen.  I also attached a pdf of what I see in
> Outlook.  Except for some font issues (likely not installed on Ubuntu)
> the HTML portion looks fine in Evolution.
> 
> If there is something else you need in order to see what I'm talking
> about please let me know.
> 
> Thanks,
> Joe

I have been able to import the email myself and reproduce the issue.

Looking at the source of the imported mail, it has the header:
> Content-Type: multipart/alternate; boundary="=-m7pctIXGHnNa8SIElS5Z"
> 
which is wrong, it should be multipart/alternative, per rfc 1341 (and
later, up to rfc 2046)

It's true that it is used to specify alternate contents, but the right
name is multipart/alternative.

Reviewing the code, it is a bug of the pst importer, that sets the mime
to multipart/alternate rather than multipart/alternative.

https://gitlab.gnome.org/GNOME/evolution/blob/master/src/plugins/pst-import/pst-importer.c#L1322


I have opened bug 745 about this, along with the trivial fix as a merge
request:
https://gitlab.gnome.org/GNOME/evolution/issues/745
https://gitlab.gnome.org/GNOME/evolution/merge_requests/42

(hope it is right from a procedimental pov, though)


Joe, as you are using the evolution version packaged by Ubuntu 19.10 I
see a few options.
* You could switch to a newer version -with this bug fixed- based on
Flatpack.
* You could try to get Ubuntu maintainers to include this fix
* You could patch your own evolution version (this is a trivial fix, so
it'd be very simple)
* You could continue using the broken importer and deal with it fixing
the imported entries later. Just running the following sed command on
the folder containing the imported files would fix them:

sed -i  '0,/^$/ { s!^Content-Type: multipart/alternate!Content-Type:
multipart/alternative! }' *.evolution:*


Kind regards

___
evolution-list mailing list
evolution-list@gnome.org
To change your list options or unsubscribe, visit ...
https://mail.gnome.org/mailman/listinfo/evolution-list


Re: [Evolution] HTML email problem

2020-01-03 Thread Ángel
On 2020-01-02 at 15:08 -0500, Joe Wade Pulley via evolution-list wrote:
> Andre and all,
> 
> Never mind.  I just figured out the issue.
> 
> For emails that are newly received directly from the server, there is
> no problem.
> 
> The emails that have a problem as I have described are ones that I have
> imported from an Outlook .pst file.
> 
> Any idea how to fix the formatting on those?  Not a big issue as I can
> deal with it on an email by email basis, but if someone has solved this
> before I'd appreciate any insight.
> 
> Thanks!
> 
> Joe

Hello Joe

It looks like emails being malformed. The divider string you see is
probably the boundary. If the email didn't properly state the boundary
it uses, it could end up being interpreted that way.
We would need to see an actual broken mail to study what is wrong with
it.

Since it is only happening for emails imported from a pst file, it may
actually be a bug in the pst importer, that resulted in _some_ emails
being imported incorrectly.

I wouldn't be surprised if Outlook did some weird thing when saving the
emails, either.

The ideal test case would be having the original mail, a pst file
created by Outlook with that file and the resulting broken email
message.

Obviously, don't share an email that contains anything confidential. I
can send you some test messages if you want.

Kind regards

___
evolution-list mailing list
evolution-list@gnome.org
To change your list options or unsubscribe, visit ...
https://mail.gnome.org/mailman/listinfo/evolution-list


Re: [Evolution] HTML email problem

2020-01-02 Thread Joe Wade Pulley via evolution-list
Andre and all,

Never mind.  I just figured out the issue.

For emails that are newly received directly from the server, there is
no problem.

The emails that have a problem as I have described are ones that I have
imported from an Outlook .pst file.

Any idea how to fix the formatting on those?  Not a big issue as I can
deal with it on an email by email basis, but if someone has solved this
before I'd appreciate any insight.

Thanks!

Joe

On Thu, 2020-01-02 at 19:30 +0100, Andre Klapper wrote:
> Hi and welcome!
> 
> On Thu, 2020-01-02 at 11:16 -0500, Joe Wade Pulley wrote:
> > Here's my problem.
> >
> > When I receive HTML email from some senders, the top section of the
> > email displays text and links.  Then there is a "divider" and the
> > usual
> > HTML formatted images and links are displayed (mostly correctly).
> >
> > This doesn't happen for all senders. Home Depot emails, for
> example,
> > only have the HTML showing.
> >
> > I understand about security etc. when allowing HTML emails, but I
> > really would like to see only the HTML version and not the text
> > version.  Is there anything that I can do to turn off the text
> piece?
> >
> > Evolution 3.34.1-2
> > Ubuntu 19.10
> 
> See Help 🡒 Contents 🡒 Mail Management 🡒 Display of a message.
> 
> Cheers,
> andre
> --
> Andre Klapper  |  ak...@gmx.net
> https://blogs.gnome.org/aklapper/
> 
> 
> ___
> evolution-list mailing list
> evolution-list@gnome.org
> To change your list options or unsubscribe, visit ...
> https://mail.gnome.org/mailman/listinfo/evolution-list

___
evolution-list mailing list
evolution-list@gnome.org
To change your list options or unsubscribe, visit ...
https://mail.gnome.org/mailman/listinfo/evolution-list


Re: [Evolution] HTML email problem

2020-01-02 Thread Joe Wade Pulley via evolution-list
Andre,

I have looked through the help section, Googled the issue and changed
various settings on the HTML messages tab of Mail preferences.  All to
no avail.

I haven't found anything in the help sections that discusses having
both plain text AND HTML showing, only one OR the other.

For me, the HTML version is displayed, but I have to scroll down past a
bunch of text to get to it.  

Also, some emails, specifically all emails from ebay, won't display at
all.  I can show the source and get the information from the email, but
the HTML won't display.

Can you be any more specific with your answer?  Everything I see in the
section you pointed me to says to enable HTML messages on the HTML tab.
I've done that for all emails.

Sorry if I'm being dense.

Thanks.

Joe

On Thu, 2020-01-02 at 19:30 +0100, Andre Klapper wrote:
> Hi and welcome!
> 
> On Thu, 2020-01-02 at 11:16 -0500, Joe Wade Pulley wrote:
> > Here's my problem.
> >
> > When I receive HTML email from some senders, the top section of the
> > email displays text and links.  Then there is a "divider" and the
> > usual
> > HTML formatted images and links are displayed (mostly correctly).
> >
> > This doesn't happen for all senders. Home Depot emails, for
> example,
> > only have the HTML showing.
> >
> > I understand about security etc. when allowing HTML emails, but I
> > really would like to see only the HTML version and not the text
> > version.  Is there anything that I can do to turn off the text
> piece?
> >
> > Evolution 3.34.1-2
> > Ubuntu 19.10
> 
> See Help 🡒 Contents 🡒 Mail Management 🡒 Display of a message.
> 
> Cheers,
> andre
> --
> Andre Klapper  |  ak...@gmx.net
> https://blogs.gnome.org/aklapper/
> 
> 
> ___
> evolution-list mailing list
> evolution-list@gnome.org
> To change your list options or unsubscribe, visit ...
> https://mail.gnome.org/mailman/listinfo/evolution-list

___
evolution-list mailing list
evolution-list@gnome.org
To change your list options or unsubscribe, visit ...
https://mail.gnome.org/mailman/listinfo/evolution-list


Re: [Evolution] HTML email problem

2020-01-02 Thread Andre Klapper
Hi and welcome!

On Thu, 2020-01-02 at 11:16 -0500, Joe Wade Pulley wrote:
> Here's my problem.
>
> When I receive HTML email from some senders, the top section of the
> email displays text and links.  Then there is a "divider" and the
> usual
> HTML formatted images and links are displayed (mostly correctly).
>
> This doesn't happen for all senders. Home Depot emails, for example,
> only have the HTML showing.
>
> I understand about security etc. when allowing HTML emails, but I
> really would like to see only the HTML version and not the text
> version.  Is there anything that I can do to turn off the text piece?
>
> Evolution 3.34.1-2
> Ubuntu 19.10

See Help 🡒 Contents 🡒 Mail Management 🡒 Display of a message.

Cheers,
andre
--
Andre Klapper  |  ak...@gmx.net
https://blogs.gnome.org/aklapper/


___
evolution-list mailing list
evolution-list@gnome.org
To change your list options or unsubscribe, visit ...
https://mail.gnome.org/mailman/listinfo/evolution-list