mersenneforum.org

mersenneforum.org (https://www.mersenneforum.org/index.php)
-   Software (https://www.mersenneforum.org/forumdisplay.php?f=10)
-   -   Script-based Primenet assignment management (https://www.mersenneforum.org/showthread.php?t=22334)

ewmayer 2017-05-24 08:19

Script-based Primenet assignment management
 
I am considering adding such functionality to my next Mlucas release - auto-comms functionality like that built into the main client is not an option for me because it involves 'secret sauce' code, i.e. violates open-source-ness. I also greatly value build and maintenance simplicity, hence the appeal of a simple cronscript-type solution.

Would appreciate any advice re. the best way to go here - perusing the non-main-client areas of the forum I see stuff about Misfit and at least one other user-written script (need to dig out the thread for that from my saved-link archives). For the near future, we can restrict assignment types here to LL (either 1st-time or DC), and consider only Linux and OS X by way of operating systems (any Windows support will be via a Linux emulation environment like mingw64).

I envision a script which reads the user's primenet credentials from a local file and uses those to exchange data (read from the results.txt file and - for interim-progress updates - the worktodo and exponent-specific status files) with the manual tests forms, but first I want to look at how misfit (and that other 3rd-party script I mentioned, if I can find the thread about that) do things. For a first crack at this for Mlucas doing it via script completely external to the LL client seems best to me.

Thanks for any tips!

Mark Rose 2017-05-24 14:40

You're probably thinking of [url=https://github.com/MarkRose/primetools/blob/master/mfloop.py]this one[/url]. I want to rewrite it, as it's not well done. It basically submits forms and scrapes pages. It doesn't use an API.

ewmayer 2017-05-25 01:21

[QUOTE=Mark Rose;459657]You're probably thinking of [url=https://github.com/MarkRose/primetools/blob/master/mfloop.py]this one[/url]. I want to rewrite it, as it's not well done. It basically submits forms and scrapes pages. It doesn't use an API.[/QUOTE]

Yes, that's it - now that I see it I distinctly recall the 'teknohog' moniker. How difficult do you estimate it would be for a non-Python-expert like me to adapt to do the LL-test-related functionality I outlined above?

And, since I need to support LL rather than TF, don't I want to be looking at llloop.py instead of mfloop.py?

Mark Rose 2017-05-25 04:02

[QUOTE=ewmayer;459691]Yes, that's it - now that I see it I distinctly recall the 'teknohog' moniker. How difficult do you estimate it would be for a non-Python-expert like me to adapt to do the LL-test-related functionality I outlined above?

And, since I need to support LL rather than TF, don't I want to be looking at llloop.py instead of mfloop.py?[/QUOTE]

Yeah, teknohog wrote the original. I forked it for my own use. I haven't used the other scripts in the repository. That may in fact be the better script to start with.

Python is very easy to pick up. The only real gotcha is that it uses indentation instead of { and } to denote scope.


All times are UTC. The time now is 15:19.

Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2021, Jelsoft Enterprises Ltd.