making an exception and deleting the old stealth-updated file

Joshua Root jmr at macports.org
Mon Jan 13 14:33:13 PST 2014


On 2014-1-14 09:08 , Mojca Miklavec wrote:
> I solved one part of the problem (on the user end) with the code below
> (http://trac.macports.org/changeset/115758).
> 
>    pre-fetch {
>        set file_abla "${prefix}/var/macports/distfiles/geant4/G4ABLA.3.0.tar.gz"
>        if {[file exists ${file_abla}]} {
>            if {[md5 file ${file_abla}] != "d7049166ef74a592cb97df0ed4b757bd"} {
>                # problematic md5: d2d4e99b14f7a5057f4c10d9c2d647dd
>                ui_warn "deleting an old '${file_abla}'"
>                file delete ${file_abla}
>            }
>        }
>    }
> 
> The other part of the problem on the buildbot (the buildbot first
> fetches the files from distfiles.macports.org which had the old file,
> so the build failed) ... was resolved automatically as mentioned
> above.

If the distfiles server didn't refresh the file, that wouldn't just be a
buildbot problem, as deleting it locally doesn't stop users from just
fetching it from distfiles.macports.org (or another server that mirrors
it) again if it has the lowest ping for them.

- Josh


More information about the macports-dev mailing list