Testing and study of the APT source code show that this problem does
not exist anymore on Tails 3.3: APT checks the indices expiration date
only when it downloads them, not when it reads them to
install packages.

Testing procedure

I tried installing packages offline in Tails 3.3 using the following procedure on 14 Dec 2017:

start Tails online with persistence of apt packages and apt lists

install optipng (currently pulled from stretch/updates, which expires on 22 Dec 2017) and wdiff (from stretch, which doesn't expire) and add them to additional software list

reboot offline

the install works and optipng version is the one from stretch/updates

set the date 1 year in the future in the BIOS

reboot offline

the install works and optipng version is the one from stretch/updates

I went through the entire procedure 3 times and got the same results.
Basic offline operation is thus already working, and
#6260 seems to be have been resolved: recent APT
doesn't check Valid-Until on package installation.

One of the packages was not cached in the first place

When I run Tails 3.3, install a package with apt and add it to my
list of Additional Software Packages, then if I am offline when
I start Tails the next time, this package won't be installed.

The root cause of this problem was identified and a fix has been
committed for Tails 3.5 (#10958).

Incomplete online upgrade process

Assume that during an online Tails session, the APT indices are
successfully updated, but then Tails is shut down before the upgraded
Debian packages were downloaded. Then, if Tails is started offline the
next time, the packages that needed to be upgraded cannot
be installed.

This is the only remaining problem we should consider fixing.

Proposed solution

in the upgrade operation : save a copy of /var/lib/apt/lists/
before running the apt-get update. It could be stored to
a specific location, e.g.
/live/persistence/TailsData_unlocked/tails-additional-software/apt/lists.old/.
After a successful apt-get upgrade, remove this copy of the old
APT lists.

in the install operation : if there is a copy of the old APT lists, restore it before running apt-get install

Testing procedure

We should find a testing procedure, which doesn't look trivial, as the problem only occurs when there is an upgrade of an additional software package.