ports.macports.org & improvements

Joshua Root jmr at macports.org
Sun Aug 11 09:54:28 UTC 2019


On 2019-8-11 17:39 , Mojca Miklavec wrote:
> (2.a) Getting more users aware of statistics submissions & invite them
> to participate.
> Every two weeks (?) we ask users something like "You didn't run
> clean-up for more that two weeks, would you like to do it now? [yes,
> no, never ask me again]". Could we do something similar for statistics
> submissions? It doesn't need to be every two weeks, once after the
> initial installation and once every major upgrade might be sufficient
> (and if users answer "never ask me again", they would of course never
> be bothered again).

That would be OK, but someone has to write the code, being aware that we
of course can't actually install the mpstats port unless running with
privileges.

I was thinking we could also print a news message at the end of
selfupdate, put a notice in the ReadMe and on the web site, and post to
the macports-announce list.

On a related note, should mpstats-gsoc be replaced_by mpstats at this point?

> (2.b) At the moment we only run a "cron job" for submissions once per
> week, never check whether it succeeded and if the computer is not
> online at that moment, submission doesn't attempt to be made until
> next week (when it might easily fail again). It would be nice if we
> recorded the time of last successful attempt and maybe check more
> often. If the last successful submission was less than a week ago,
> don't do anything. If it's more, try to re-submit. This could be
> either a timed command, or maybe it could be checked at the end of
> "port install", when users would likely be online, rather than in the
> middle of the night when computer is not even awake.

This is best solved in mpstats. It could easily wake up multiple times
per day and just immediately go back to sleep if it has made a
submission recently enough. I think you can also specify that a launchd
job needs an internet connection.

> (3) Default / negative variants
> Umesh pointed out (I didn't double-check) that we store negative
> variants to the port registry, but never actually use that information
> (there's no easy access to them from macports base helper functions;
> he apparently used that for "port migrate").
> On temporary development version you can see an example of variant counts:
>     http://ec2-52-34-234-111.us-west-2.compute.amazonaws.com/port/ffmpeg/?tab=stats
> It would be nice if we could tell what variants users enabled or
> disabled manually, but we would need to submit this information, so we
> would need to extract it first.
> Could someone else familiar with the base comment what could or should
> be done? How much effort would be needed to support at least some
> basic information?

We certainly do use negated variant information when upgrading. They are
also displayed by 'port -v installed', so there are two sets of example
code at least. :)

In general it's as simple as:

% package require registry2
2.0
% set entry [registry::entry search name fftw-3]
::registry::entry0
% $entry name
fftw-3
% $entry negated_variants
-gfortran

- Josh


More information about the macports-dev mailing list