I've been implementing a download API for buildout and have reached the
point where I'd like to try using it for downloading the base config files
referenced from a buildout config by the 'extends' option. This would have
the benefit of allowing to cache those config files and being able to run
a buildout using that feature while being offline.
However, I'd like to discuss two points about doing this:
- I think buildout should not unconditionally use a cached copy of a base
configuration file. While it is sensible in other use cases to never
access the network if a file is found in the cache, base configs can
be expected to change and should IMHO be taken from the cache only when
offline mode is active or an attempt at downloading failed.
- The download cache to be used is configured as one of the options that
are read from either ~/.buildout/default.cfg or buildout.cfg and their
respective bases. In order to keep things simple, I'd suggest to use a
download cache only if specified directly inside any of these two files,
and ignore download-cache options in any downloaded base configs. This
would be an exception to how options read from config files are
combined, but one I deem worthwhile.
I'd allow for configuring and using different download caches in those
two files, though. That way, bases of the user's default config can be
cached centrally while allowing to keep project-related stuff in a