Resources

Edited Transcript

Hello, and welcome to the announcements video for CC 410 in spring 2021, for week seven. So some quick updates for this week I posted last week. But hopefully you all saw this I have moved all the course deadlines from Sundays to Mondays. Part of that is to give you a little bit more time to work on the projects. But also a lot of that is to give you the chance to work on the weekends, and then give me a chance to catch up with questions on Mondays. Unfortunately, the next few weekends are not going to be as available as I had planned. And so I wanted to make sure I give you ample time to ask questions and get a response for me before the projects are due. That said, it’s a really good idea if you can start on the projects before the weekend. That way, if you do run into any early questions, I can help solve those really quick. Hopefully the example videos do a pretty good job of getting you set up for the projects. But if not, feel free to ask questions, let me know things that I can clarify. So as far as content, I just released module seven on Canvas, I’ve got module eight on deck, I’m just waiting for the example videos for module eight, and then it will be released. And then I’ve got modules nine and 10 written I’m just waiting on finishing the examples and getting all the videos recorded in modules nine and 10 will be kind of the last modules of this chunk of the class, they’ll be very similar to what we did for weeks four and five, where there’ll be two weeks together. Also, I do realize I’m a week behind on grading. So I’m going to be doing a lot of grading probably today to get caught up on grading. So you should be a lot of see a lot of grades post to Canvas pretty quickly so I can get caught back up.

So this week, we’ve got two topics that we’re covering, we’re covering parallel programming, which describes a little bit about how we use threads and processes in our computers, I have to cover this topic because it leads into what we do next time, which is Event Driven Programming. With Event Driven Programming, we’re actually writing the events that work within our GUIs. And our GUI requires multiple threads. So I had to spend a little bit of time talking about parallel programming. The parallel programming example is not very complex, it should take half an hour or so. And then you’ll be able to do the example for Event Driven Programming after that.

For the milestone this week, milestone five, this is where we start doing events in our GUIs. And so this milestone you’re going to take the GUI that you developed last week where you have all the buttons, and you’re actually going to add a lot of the button click handlers to those buttons. We’re also going to refine the GUI structure a little bit. In my original example, I was intending to use a list in the sidebar, I realized as I was working on this milestone that that’s not going to work very well. So we’re going to go through and refine that to use a tree structure. Instead, I show you all the code how to do this in the example video for that project. So check out the example follow that code, you should be able to change it pretty quickly. Once you get done with this milestone, you should have a mostly functional GUI you can create orders you can customize items, you should be able to populate that sidebar with any order. And then in the next couple of milestones, we’ll look at actually building an order object, we’ll build a combo objects, and then the milestone after that we’ll actually integrate that into our GUI and finalize the project using checkouts. Do make sure you read the hints for this project. There are some hints at the bottom of the milestone of unit tests you might want to include and some different methods that will help you jump back and forth between different parts of your GUI. This is one of the milestones where it starts to get a little bit more complex where I give you a little bit less structure. And you have to figure out the structure yourself. For example, in one of your GUI panels, when you click the Save button, how do you actually get the item from that GUI panel into your sidebar panel, there are some things that you can do to make that happen. So this one starts to be a little bit more open ended. So if you’re not sure how to do something, feel free to ask and let me know. As with all of these I have written a full model solution. So I at least know that it does work and there is at least one way to do it. So if you get stuck, let me know.

One thing that we are running into with these projects as they get larger is testing issues. Especially if you’re taking the Java version of this class, you’ve probably seen me in some of the example videos get frustrated with Gradle. This is mainly due to the fact that the Codio boxes we’re using only have 512 megabytes of RAM and Gradle tries to use a lot more than that. So there are some things you can do to get around that. In Java, if you’re having trouble with Gradle if you do Gradle space dash dash stop from within your project directory that will stop all the running Gradle daemons. If you get any messages about stopped or hung daemons or anything like that you can stop those. You can also go through and restart the Codio box that is running your project. If you click the project menu and click Restart box, it will come up sometimes it takes 30 seconds or so to do that. And then after you do that refresh your web browser and everything should work a little bit better. But sometimes with Gradle if you see messages where the Gradle process crashes, just try it again and eventually it will go through in Python however We did discover that the pytest method that we’re using is very memory inefficient. And so the easiest way to get around that in Python is to run the tests in batches instead of running them all in one talk all at one time. So I show a new tox.ini file that you can use for Python that allows you to create batches for your tests. And actually, in the later milestones, we refine that even further because I continued to have this problem. But either way, you should be able to get around that absolute worst case, if you’re interested, it is possible to do these projects outside of Codio. The biggest benefit to that would be, you’d be able to work on your own machine and you’d have a lot more horsepower. The biggest downside is I wouldn’t be able to directly see your project in Codio so you’d have to commit your code to git and I can walk through it there. So if you’re interested in that, let me know, my eventual plan for CC 410 is to include a video toward the beginning of the semester explaining how to do that. I didn’t get to that this semester, but it’s something that I’d like to add in the future.

So looking ahead, as we’ve talked about module eight is going to be on design patterns and combos, I’m super excited about module eight, I’ve always wanted to teach design patterns. And so I think this is going to be a really interesting opportunity to see how that works. As part of that, we’re also going to look at test doubles. So test mocks and stubs and how we can make our unit tests a lot more efficient. Modules nine and 10, we’re going to deal with external libraries and how to create a release of our project. So by the end of module 10, you’ll know how to make a JAR file or a Python wheel file and how to actually make your project available as an external project for somebody else to use. So week 9 and 10 is going to be very similar to weeks four and five, where we have two things going on at the same time. So that’s something to keep in mind. And then of course after week 10 will go into things like web API’s and some external stuff. Mostly those restaurant milestones will start to be a little bit smaller, and it will start giving you a little bit more time to work toward your final project as we get toward the end of the class.

So other than that we’re very close to halfway through the class so I hope you’re enjoying things so far. If you have any questions, comments or concerns you can always contact me via via the cc410-help email address or on Discord I’m always happy to help. Otherwise, I look forward to seeing your GUIs when I start grading them today, and if you have any questions just let me know. Good luck.