msgthr user+dev discussion/patches/pulls/bugs/help
 help / color / mirror / code / Atom feed
From: Eric Wong <e@80x24.org>
To: Dimid Duchovny <dimidd@gmail.com>
Cc: msgthr-public@80x24.org
Subject: Re: library usage
Date: Sun, 31 Dec 2017 22:22:07 +0000	[thread overview]
Message-ID: <20171231222207.GA1541@80x24.org> (raw)
In-Reply-To: <CANKvuDeipqNad-0YAeezX_VcAeGm=BuOPY853FerXtmVG3+W7Q@mail.gmail.com>

Dimid Duchovny <dimidd@gmail.com> wrote:
> Thank you very much Eric!
> As a matter of fact, I did find an issue, which I'm not sure is a bug;
> consider this line from the `add` method:
> cur = @id_table[mid] ||= Msgthr::Container.new(mid)
> 
> If `mid` is the empty string or a string which only contains
> whitespace, it's considered a valid key for `id_table`.
> However, I'd expect an empty string and (arguably) whitespace-only
> strings to be equivalent to nil.

If msgthr were only for RFC822-like (email/news) messages, I'd
be inclined to agree with you.  However, msgthr could also be
loading messages off something like an SQL DB, where
"" and NULL are distinctly different (yet still likely a bug in
the DB design/code).  So in that case; I don't think we should
be assuming anything about the users' data and potentially
hiding bugs.

> Happy new year!

Same to you :)  I'm looking forward to having more time to work on
mail-related tools in 2018.

      reply	other threads:[~2017-12-31 22:22 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-12-27 12:22 library usage Dimid Duchovny
2017-12-27 18:01 ` Eric Wong
2017-12-27 19:06   ` Dimid Duchovny
2017-12-28  1:43     ` Eric Wong
2017-12-31 13:06       ` Dimid Duchovny
2017-12-31 22:22         ` Eric Wong [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

  List information: https://80x24.org/msgthr/README

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20171231222207.GA1541@80x24.org \
    --to=e@80x24.org \
    --cc=dimidd@gmail.com \
    --cc=msgthr-public@80x24.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this public inbox

	https://80x24.org/msgthr.git/

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).