Skip to content

Non-booking emails can still yield an invented flight number #291

Description

@Abrechen2

What a user sees

Importing an email that contains no booking — a fare advertisement, an airline
status notification — can create a flight with a made-up flight number. The
entry looks ordinary in the logbook, so it is easy to accept and hard to spot
later.

Status

The common shape is fixed on fix/forgejo-round-2 (not yet merged): German
price copy such as "ab 380 EUR" was read as flight AB380, and "Nur 7 …" as
NUR7. A guard for this existed but never fired — the candidate reached it in the
source's original case, so "ab" never matched the listed "AB", and only the
first two characters were compared, which cannot see a three-letter word. Both
holes are closed and covered by tests.

What is still open

Two shapes remain, and neither can be closed by extending the word list,
because each collides with a genuine airline code:

  1. An airline status email (no booking in it) yields DL3. DL is Delta.
  2. A real booking confirmation yields MO24, apparently from a German
    weekday and day-of-month ("Mo, 24."). MO is likewise assigned.

Banning either prefix outright would drop real bookings, so this needs
context — the surrounding words, a label, a nearby route — rather than a
blocklist.

A second defect, found alongside

On that same genuine confirmation the real flight numbers are missed entirely;
the invented one is what remains. So this is not only a false positive but also
a miss, and the two probably want fixing together.

Why the evidence rule does not catch these

The rule added for the earlier report accepts a candidate that carries a flight
number or a full route. An advertisement manufactures exactly a flight
number, so it satisfies the rule. Anyone reading that earlier fix as closing
this whole class will be misled — it does not.

Notes

Found by running the parser over an offline corpus of real booking and
marketing emails. That corpus belongs to a third party and is not part of this
repository; the reproductions above are described rather than quoted, and no
sample is attached.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions