Where communities thrive


  • Join over 1.5M+ people
  • Join over 100K+ communities
  • Free without limits
  • Create your own community
People
Activity
cbm
@cbm755:matrix.org
[m]
AHA!! Possibly breakthrough: if I go into SpeedGrader (first time for everything...) I CAN SEE THEM
fkobayashi
@fkobayashi:matrix.org
[m]
Oh perfect!
That’s where I’d been looking
Didn’t realize you could look elsewhere…?????
cbm
@cbm755:matrix.org
[m]
I look in Grades -> Quiz 1 -> Score -> click little arrow
I didn't now there was anywhere else :-)
haha, Kipling's blindmen describing the elephant here!
fkobayashi
@fkobayashi:matrix.org
[m]
At some point I need to finish my refactor of the canvas pushing code…the new version of what I refactored is substantially cleaner / more modular
cbm
@cbm755:matrix.org
[m]
thanks for your help, I will try to get this into a bug report via LT Support to fix the Comments view I've been using. Its also possible to upload files manually within speedgrader! which might be helpful in some cases!
(I thought this was an API-only feature)
fkobayashi
@fkobayashi:matrix.org
[m]
Oh yes you can add files manually
Well…glad I helped!! Haha
cbm
@cbm755:matrix.org
[m]
thanks
re: refactored... am I using this? I branched about a week ago
fkobayashi
@fkobayashi:matrix.org
[m]
Probably not…I think I only finished the download stage not the upload
cbm
@cbm755:matrix.org
[m]
push is already very nice to use, mainly I just had to delete stuff (b/c it wants to do all the plom stuff for me)
server I couldn't figure out because it wants to make its own server and I already have one, but I can see with some effort it could support that as well
Andrew Rechnitzer
@arechnitzer_gitlab
I can yell too
sorry - I CAN YELL TOO
fkobayashi
@fkobayashi:matrix.org
[m]
Asked friends about flask

Me:

fully unrelated: question about webserver things

plom people want to start up a very very lightweight webserver from a docker thing so that people can connect to a plom server from browser
do people generally use like...flask for this still?

Friend 1:

my understanding is flask is still the predominant python lightweight webserver
framework
I suppose in theory using python's built-in http is the most "lightweight" but flask is probably very good and much more pleasant
I think I like flask in a way that I do not like pandas

Friend 2:

Oh really
I like some pieces of flask but
The main loop is annoying
Like the part where the decorators are modifying this invisible global state in a sense
And then you kick off an eventloop that reads everything and turns it into a server
Does make it hard to compose with other stuff

Me:

is there an alternative you'd recommend?

Friend 2:

Nope!

Me:

ah, so like
classic python library situation then

Friend 2:

My bones tell me there should be an elegant asyncio version out there
But I use Flask in Hubert
With a wrapper that puts all of the state inside a class

Me:

I think we probably won't need something as..."flexible" as Hubert so maybe flask will be fine

Friend 2:

I think it'll be fine

Andrew Rechnitzer
@arechnitzer_gitlab
thats very helpful
Victoria Schuster
@vmschuster_gitlab
Have any of you encountered problems downloading jpegtran-cffi?
For whatever reason I lost some of the plom dependencies. Jpegtran-cffi is behaving as if I don't have turbojpeg installed despite it being installed and up to date... @cbm755:matrix.org I tried your suggestions in the jpegtran issues but no success.
Andrew Rechnitzer
@arechnitzer_gitlab
yes - I have. I had to install it via apt or simlar
cbm
@cbm755:matrix.org
[m]
head's up: jpegtran-cffi is no longer a required dependency (its still used if available and still included in our Docker instance)
cbm
@cbm755:matrix.org
[m]
(Hopefully) here comes 0.7.0: https://gitlab.com/plom/plom/-/pipelines/365299506, many thanks to all who contributed to this release!
cbm
@cbm755:matrix.org
[m]
0.7.1 is out, thanks especially to new contributors!
fkobayashi
@fkobayashi:matrix.org
[m]

Trying to figure out how to hotswap servers in the flask app and am struggling mightily

I think I just probably don't know enough about how it works internally to do this efficiently. arechnitzer , should I just push what I've done so far to a new branch?

I'm kind of doubtful it will be very useful, since I recently entered the "flail wildly in the code" stage of debugging...
Andrew Rechnitzer
@arechnitzer_gitlab
ha
I think in the short term the better solution for someone who wanted to look up what they did in the previous assignment would be to log into speedgrader or similar
better short term tasks = get the push back working nicely with flask idiocy
cbm
@cbm755:matrix.org
[m]
at least in the near-term, I think we anticipate containers with both a plom-server and a flask instance in them, one for each assessment.
Andrew Rechnitzer
@arechnitzer_gitlab
also - I think I recall Forest having a busy week... so very short term plan = Plom work doesnt make Forest supervisor angry
1 reply
fkobayashi
@fkobayashi:matrix.org
[m]
I was thinking of revisiting this, but I'm not sure if it'd be in alignment with your other design decisions?
cbm
@cbm755:matrix.org
[m]
forget what "this" is
fkobayashi
@fkobayashi:matrix.org
[m]
yep typing up a summary right now
fkobayashi
@fkobayashi:matrix.org
[m]

Goal: Be able to hotswap between servers (e.g. for different courses or for different assignments in the same course) without having to delete the current server directory and redownload all the student papers, etc.

Use case: When running multiple courses that use plom it might be helpful to be able to switch between different servers to look at how the marking process is going in each one. Or, sometimes when marking multiple sections of the same course it can be convenient to be able to switch quickly between sections (e.g., "I know somebody in the first section made this same mistake but I can't quite remember what I thought was wrong with it, let me go check what they said")

General approach:
Store servers for each class/assignment combo in different local directories. Whenever the user wants to switch (course, assignment), check if a directory for that exists already. If so, then try and launch a server from that directory. Else, make the directory and initialize all the data, etc.

Whenever user wants to switch to a different (course, assignment), give the option to either kill the current server and start a new one in the new directory, or keep the old server alive and choose a different port for the new server and launch the new server.

Details:

  • Add __init__() methods to CanvasServer and CanvasServerState so that we can do something like CanvasServer(course, assignment)
  • Determine CanvasServer.directory based on course and assignment instead of using a hardcoded path (already implemented a few days ago)
  • Make a global class LiveServers that holds a list of all currently-running CanvasServer objects
  • Add a pane to the flask app that lets the user manage currently-running servers and kill / resume old ones as they see fit. When killing a server it'd get removed from LiveServers and have its information (e.g. directory, port number, etc.) written to some file so that it's easy to later show the user something like "here are some servers you used in the past, do you want to start them back up?"
This is something I would like, since it makes the downloading step (very slow) a one-time thing
But I seem to recall you talking about running everything through docker containers in the future
Also not sure if it's really relevant to many people. Probably not many people will be running multiple servers on one machine, right?
cbm
@cbm755:matrix.org
[m]
ummm TL-DR: this looks like orchestration, where one flask is managing a bunch of Plom-servers, not all of which are running. Improvements to from plom.server import PlomServer to make this possible welcome
1 reply
HAve you looked at PlomServer?
fkobayashi
@fkobayashi:matrix.org
[m]
I just started to this afternoon
cbm
@cbm755:matrix.org
[m]
Its a background Plom Server you can launch, and in theory take down, restart
from say ipython
fkobayashi
@fkobayashi:matrix.org
[m]
Yeah although for some reason when I try PlomServer.server._server_proc.terminate() it doesn't seem to do it???
Caveat, I'm not sure if that's actually where the problem is, my code might be breaking before it reaches that point
1 reply
cbm
@cbm755:matrix.org
[m]
p = PlomLiteDemoServer(); p.stop?
can reproduce with that?