ANN: FemtoCleaner, our newest robot intern

All,

please welcome femtocleaner[bot], the Julia community’s newest robot intern, joining the ranks of attobot and nanosoldier. Over the past two weeks it’s learned a lot about how to upgrade julia code from old versions to newer ones. Some examples:

Some highlights of the kinds of things it knows how to do:

  • Remove @compat from syntax that no longer requires it
  • Fix code for the parametric type change f{T}(x::T)f(x::T) where T
  • Remove obsolete VERSION checks

It’ll read your package’s REQUIRE file to figure out which changes it’s allowed to do. That’ll happen the first time you install it and then every time you update REQUIRE. The full user manual is available on the bot’s GitHub page.

Please pay particular attention to the bad bot command, which you can use to report any instances of incorrect behavior. While we’ve done some alpha testing, you should still consider this beta-quality software, so there may be bugs. If you do encounter a bug, just report it and leave the pull request open. Once the bug has been addressed, the bot will push a new commit with the (hopefully) correct changes and leave a comment to let you know it did that.

The installation flow for the bot will be familiar to all those who have used attobot before. To get started, simply go to https://github.com/apps/femtocleaner. I should note that the majority of the functionality in femtocleaner is designed to help with the 0.5->0.6 or later transition, so if your REQUIRE still claims support for a pre-0.6 version of julia (e.g. 0.5 or 0.6-), you will not get the full range of changes.

Lastly, I have some acknowledgements to make:

  1. First, the Sloan foundation whose recent grant to Julia Computing funded this work.
  2. Julia Computing for hosting the publicly available instance
  3. @ararslan For testing the alpha version of this and reporting a large number of issues
  4. @ZacLN for his work on CSTParser, which I leverage heavily in this work
  5. @jrevels for reviewing all my PRs to GitHub.jl

I hope you will find this useful.

38 Likes

Great stuff!

Is there some kind of status page or queue somewhere? Sometimes it’s good to keep an eye on our robot underling’s activities, e.g. whether your job’s been accepted or delayed, or if github went down and it didn’t restart, etc…

I have a GitHub-provided status page to get a general overview, but it’s not suitable for general consumption, because it may include authentication secrets, etc. I’ll think about hooking something up here. That said, something broke last night and GitHub stopped accepting the bot’s requests. I’ll look into it, but if you submitted a request in the past 10 or so hours, it got stuck and will be re-delivered soon.

1 Like

I think I’ve worked through the queue and everyone who wanted the bot has gotten it now. If you think the bot should have stopped by your repo, but didn’t, please let me know.

@Keno Any plans for the Upgrade-Bot-Fairy to visit https://github.com/Keno/AbstractTrees.jl ? :stuck_out_tongue_closed_eyes:

I think it is enough for the tag troll to visit that one.

1 Like

Is there a way to trigger FemtoCleaner to run again within the same pull request?

For example, I configured FemtoCleaner on a clone of SIUnits.jl and it created a PR with only minimal changes. Then I pushed some changes to REQUIRE on that same branch, hoping that FemtoCleaner would run again, but it seems like it only watches the REQUIRE file on master?

EDIT: actually, it seems like FemtoCleaner does get triggered but then just pushes the same first commit on the branch, removing my commit.

I wrote a blogpost about this, which has some additional data and results:
https://juliacomputing.com/blog/2017/08/17/femtocleaner.html

3 Likes

Is femtocleaner working?
I successfully used it a couple of days ago in a package: https://github.com/diegozea/PairwiseListMatrices.jl/pull/8.
But It’s not working right now on this one: https://github.com/diegozea/MIToS.jl/issues/36

Sorry about that. After some time of operation, it seems to start complaining about lack of entropy for TLS operations. Will have to investigate that. I’ve restarted it for now.

Thanks! It has worked well on my package https://github.com/diegozea/MIToS.jl/pull/37

I seem to be missing something as I can’t trigger FemtoCleaner to run: I tried making a release as well as a “Run femtocleaner” issue. There isn’t a reason for me to change the REQUIRE, so is there another way to trigger it? This is my repository: GitHub - klowrey/MuJoCo.jl: Julia wrapper for the MuJoCo Physics Engine

Femtocleaner has been having some trouble recently (first it kept running out of entropy, and then it hit a bug on some packages that caused it to fix deprecations in an infinite loop). @kristoffer.carlsson is looking into out. Sorry for the inconvenience.

There is a bug in the version of CSTParser that FemtoCleaner uses which causes it to hang in certain situations. It is fixed in a new version of CSTParser, however, since CSTParser does not have an official API, upgrading FemtoCleaner is proving quite challenging since many assumptions about the internals of CSTParser are no longer true.

A quick fix that I will try to do tomorrow is to backport the fix to CSTParser to the version Femtocleaner supports.
Hopefully, this should make it run again.