Totally broken notes and saving in current git

Linus Torvalds torvalds at linux-foundation.org
Sun Jul 20 00:12:34 PDT 2014


Bisecting this disaster pinpoints it to commit bf7fc97b5037 ("Fix
saving and storing the dive plan notes when there's html on it")

Looking at that commit, I cannot for the life of me understand why it
was ever considered a good idea. "toHtml()"? Really? No, dive notes
are *NOT* some idiotic html. Really really not.

That thing needs to be reverted. It's complete and utter shit. And the
scary thing is, looking at that commit, it looks like it was done
*intentionally*.

Tomaz, what the hell?

                 Linus

On Sat, Jul 19, 2014 at 8:49 PM, Linus Torvalds
<torvalds at linux-foundation.org> wrote:
> I'd assume this is a show-stopper for a release, or a really *really*
> bad design decision.
>
> The notes are apparently now some totally mis-designed HTML doc-type.
> This is *not* about printing (which I saw had some similar issue),
> it's that the notes string itself is just fundamentally broken. I'm
> trying to save Danielas certification dives, and the end result is
> pure garbage.
>
> The note for the first dive I have is "OW1". Except the git save ends
> up looking like this:
>
> notes "<!DOCTYPE HTML PUBLIC \"-//W3C//DTD HTML 4.0//EN\"
> \"http://www.w3.org/TR/REC-html40/strict.dtd\">
>        <html><head><meta name=\"qrichtext\" content=\"1\" /><style
> type=\"text/css\">
>        p, li { white-space: pre-wrap; }
>        </style></head><body style=\" font-family:'DejaVu Sans';
> font-size:10pt; font-weight:400; font-style:normal;\">
>        <p style=\" margin-top:0px; margin-bottom:0px; margin-left:0px;
> margin-right:0px; -qt-block-indent:0;
> text-indent:0px;\">OW1</p></body></html>"
>
> I have no idea where this insanity started, but this is seriously
> useless and complete crap.
>
> The same is true of trip notes too.  WTF?
>
> Easy to reproduce: just create a dive. Save it. as either xml or git
> format, and look and despair at the disgusting mess.
>
>                    Linus


More information about the subsurface mailing list