4 ms·
I had to write a script to constantly monitor my school's class scheduling system to get into a couple of classes. It was an interesting script because the sys
by jandrese 8y ago
I had to write a script to constantly monitor my school's class scheduling system to get into a couple of classes. It was an interesting script because the system was an IBM 3270 style mainframe.
- seltzered_ 8y agoThis has been a thing for a long time. Back around 2003-2004 people at UTexas used a site called classgrabber. Back then people would also oversignup to classes then leave them after the first few class days of it didn’t work with schedule/etc.
- jandrese 8y agoI got into the AI class at my school (it was not overbooked) only to discover that I didn't have the necessary math background. Also, the class was going to be all math and wouldn't involve computers. It was not what I was expecting at all. Ended up dropping it after a week.
- deleted 8y ago[deleted]
- Wowfunhappy 8y agoHow did you test such a script? I always thought about doing this, but since class signups only opened twice a year (once per semester), and that was the same time I needed to actually sign up for the classes, I concluded there would never be a time to debug and refine such a script.
- EE84M3i 8y agoWhen I was in school, I just had a python script that diffed the relevant part of the web page, and sent an email/SMS to my cell phone on any changes in the output. It didn't automatically do the registration though, which would have been slick.
- Wowfunhappy 8y agoAh, sounds like your school's setup was different than mine. Our class signups opened once, at a set time and day, and it was just a matter of clicking the signup button fast enough. If people dropped, the spots would go to people on a waitlist, also determined at the original signup time.
- ryanmcbride 8y agoI've written a couple of scripts over the years to email me when certain things happen on things I don't own, and as long as you're cool with a few false positives, it's not too difficult. Say you're waiting for something on a website to become available. I'd look for some language on the page about availability that's likely to change when available. I don't know what they're going to change it to, but I know that it'll (probably change). I set up a script to run every few minutes to check that particular spot on the page. If it changes, I get an email. Maybe I got an email when it changed from 'unavailable' to 'available soon', but that's okay, that means it'll definitely work when it's available for real. There's always a chance that it won't work, but if you can reasonably assert what is likely to change, it's very easy to monitor it.
- TheLoneTechNerd 8y agoI've written this type of script before - I didn't need too much in the way of debugging. Mine (similar to GP, it seems) didn't actually do the registration, just save the current state of known divs or even the whole page. Then it would send me an update if that changed. So, I didn't need to debug what happens when the class shows "open" - I just saved the div that said "closed" and sent myself an email/text any time it didn't say exactly that.
- jandrese 8y agoYou could test it by having it sign up for undesirable classes like underwater basket weaving that had plenty of openings. The terminal interface was kind of gross to script, but the underlying data was pretty easy. You basically had to just send the correct number of arrow key presses to get the cursor to the correct field, send the digits, and then send the enter key. Parse the data that comes back, and add the routine to cursor over to the "add course" prompt when it says there is an availability. The script was totally gross looking but it worked.
- jandrese 8y agoAt my school the class signup system was open after the initial set had been loaded in to IIRC 2 weeks after class starts. This allowed students to shuffle classes around as needed, and it also gave me the opportunity to write a script against its interface. In short, you gave the school a list of the classes you wanted to take. The school loaded everybody's information into the computer and had it make the first set of assignments. Then you got back the schedule and discovered that the computer had put you in classes at 7AM, 11AM, 4PM, and 6PM MWF and only one class on TTh so you had to go in and shuffle your classes around until you got a reasonable schedule. Or you would discover that all of your electives filled up before you had a chance so now you're in a fight to get into the classes. It sounds all Mad Max, but the schedules were in such flux that it was usually possible to get the classes you wanted. I only remember getting screwed once, on a mandatory class with only two or three timeslots and one of which was highly undesirable (7AM MWF) and the other two timeslots never had an opening. Worse, the professor for that class had a heavy accent and tended to drone slowly in a monotone.
- andyv 8y agoThe 3270 was the terminal, not the mainframe itself. Many happy memories...