Tuesday, April 3, 2012

Computer Problems

So I've been re-installing Ubuntu on my laptop for the past couple of weeks since it had an intermittent hard-drive-likes-to-go-into-read-only-mode-every-once-and-a-while problem.  This just happen to occur during a system update, so as you could probably tell it won't boot anymore.  So I just decided to update the OS to a newer Ubuntu version and fix this in the process.  The first install worked fine and all my stuff was still there, but nothing would run.  It would just say that it couldn't run any of the binary files.  I then realized I had accidentally gotten the 32 bit version where as the previous was 64.  No problem, I went and downloaded the correct version and after installing that one it now has Kernel Panics.  I always thought those were such a silly thing.  I could just imagine the Kernel just sitting there with its knees shaking having a nervous breakdown.  Doesn't seem as bad as what it really means.  I'm trying to re-install it to see if it somehow fixes it.

In the meantime, I've switched developing to my desktop which was for gaming only before.  Sadly, it is a Windows machine, so most third party things don't exist.  For the gui, there wasn't anything I needed other than python itself so this wasn't a problem.  Now though, to integrate the Daemon controls to the launchpad I need to install the third party daemon library.  I got the easy_install program that installs python packages, and ran "easy_install daemon".  Eclipse still didn't recognize the package, so I checked to see if it was in my PYTHONPATH variable.  Turns out that var didn't exist.  So in order to create it I had to add a new system variable.  I didn't remember the location of the python home on the file system, so I decided to open up the windows explorer and find out.  I open it up.... nothing shows up in the screen.  I then start to hear some funny noises repeat from my computer.  A few moments later the application crashes and the start menu and all that disappears.  After a few moments all that comes back though.  Great, now this computer is having problems as well.  Good thing all the code and stuff is on SVN.

This has spurred new energy into the restore my laptop project.  It is currently installing again and hopefully should be up tonight.  Good thing most of the heavy lifting in the project is done.  If all goes to hell I can still do stuff on the C.S. machines, but I don't have the ability to install these third party applications there in a timely fashion.  Lets hope it doesn't come to that.

EDIT:

Despite this, I've still managed to accomplish 2 of the features that Ackley suggested:

* The save menu item is disabled when there are no changes to save

* Navigation options allow you to go back and forth from the launchpad.

On the last item, I'm really happy that I've had experience with making Guis of this style before.  In order to make this happen, all I had to do was add a 3 line method to the controller.  The add and remove functions for all of the windows were already implemented, I just had to make it go back as well.  I could see how not building the gui in such a modular way would make things like this nontrivial.  My gui's may not be pretty, but they sure as hell work right.

Thursday, March 29, 2012

Night before Gui Demo

I've dubbed it the Gui demo, because most of the requested items are Gui related.  There are background things that need to be implemented for the Gui stuff to work, and that is what I'm currently waiting on.  Unless I get feedback from my group members, I'm pretty much done with my part.  I'm at the point now with python/Tkinter that adding or changing things goes by really quickyl, due to my knowledge of how it all works and the methods I used to set up things before.  I have only programmed for 2 hours so far today, and I finished the last half of the items I needed for the demo.  I do have an idea on how to improve the Launchpad though, so I'll probably go and do that real quick.  Today I added these enhancements:

  • Completed change notification elements
  • Title bar tells you what file you're working with
  • Reporting manager lets you switch to other reports
  • Improved the New menu command
  • Fixed the layout of the Scheduling tab.

That's it so far.  I'm waiting on method to be implemented that I've created hooks for in my code, so all I'll have to do is call their stuff.

EDIT:

I did what I wanted to do with the launchpad.  It is the rest of the team's fault for letting me design it.  :)

The gui's scheme is gray, black, and white.
 I've asked them a few times for feedback on how to make the gui look better, but I didn't get any.  So I'm just going to do what I want.

For evidence reasons, this is the commit log of the past week:

Commit log of the past week

Wednesday, March 28, 2012

Gui Enhancement

Well the big ticked item for this weeks demo is just Gui enhancements.  It is best summed by this email sent to the group about what we should be doing:

Chris: Report Framework, Scheduler Check/reload, Daemon start/stop/restart, slides for Friday's presentation.

Daniel: Email Item Report selection

BrianK: GUI launchpad, Reporting pane, GUI Polish, Change Detection and Save option, daysBack slider 1-10 + inf, gui option to start/stop/restart daemon.
Reporting window needs (Ad-Hoc Reporting):
Browse button for .nessus file
List box with available report list
Text box for description
Text box for example output
Save-To box/browse button to choose where the report will be saved

BrianD: setuptools/distutils

Alfonso: setuptools/distutils

 I guess I know what I'm doing for the rest of the week.  I started yesterday, but I did the most of it today.  All I really have left is Gui Polish, and the rest of the Reporting Pane.  The Reporting pane will allow you to pick already created reports and push it through a reporting module to process it and save the output.  This way you can do the last half of what the Daemon does without setting up a ScanEvent.  The other things, including Save, Change Detection, Scans To Keep slider (1-10+inf), and the gui options to start/stop the Daemon were really simple and I did almost all of them in an hour.

As for GUI Polish, I'm pretty much screwed.  I'm not good at making GUI's look good, just making good GUIs.  I'll have to look to feedback from the rest of the group for that one.  As far as functionality goes I've added scrollbars and resizing stuff all around, but the GUI itself isn't aesthetically pleasing.  I don't really think there should be much done other than redoing the layout of the Scheduling tab, which is just a bunch of stuff thrown in without any concern whatsoever for looks.  The other tabs are pretty simple and well laid out.  Other than that all I can think of is some padding and changing of colors/borders.  All of these are pretty low on my list of things to do right now.

This awesome coding session brought to you by the awesome song:

http://www.youtube.com/watch?v=hmf34m42JyI

Heads up, this is best listened to loudly.

Tuesday, March 27, 2012

Editor Enhancements

So the big goal for me for the next demo is to add new features to the ScanEventEditor.  Well, not really new features, but common ones.  A "Save" menu item for one thing, and the ability for the editor to know when something has actually changed.  Ackley said it himself, that in order to determine this it is non-trivial if you didn't build the gui right.  Well, it took me all of 5 minutes to implement the "save" menu item, and it is starting to look like the "hasChanged" feature is going to be pretty easy.  I've already done most of the work.  One thing I really like about the gui library in python is for almost all of the input widgets you can set up special variables that when the input changes the variable changes.  You can also add a method that will be called when the variable changes.  So all I have to do is add a method for each one and check the current value with a previous one.  Done deal.  Some days I hate python (most of them) some I like it.

I know there were more features he wanted implemented, but I don't remember what they were.  I don't think the other ones were all too scary, the "hasChanged" feature was the hardest.  I asked my group for a list of things that he wanted changed (Brian D usually takes notes) but I haven't heard anything from them for the past few days.

Before we all left after the client meeting last Friday I told everyone that I would be not working on the project for the whole weekend, as I had 2 take home midterms and a bunch of other stuff to take care of.  Well, they decided to schedule a group programming session that I had no choice but to miss.  So much for trying to make meetings more.  I feel as one of the good programmers in the group I should be kept in the loop a little more.

Monday, March 26, 2012

After Big Demo

Well the big demo is over, and we met if not exceeded his expectations for that meeting.  I'm happy that we were able to do it, but it came down to the wire on a few things.  I think from here on out the project should be much easier than it was for the last few weeks.

I haven't done much in the past 3 days, I've been working on other classes including 2 take home midterms and another group project.  This week I need to get the gui in better working shape with some added features common to most guis.  This includes a save button (not just save as) and some things to track if a save is actually needed.  This will be the most challenging, but I already have a plan of attack on this.

Thursday, March 22, 2012

Before Demo

Well, I'm sitting here at 8:40pm waiting on responses from pretty much everyone on the team about the status of the demo we need to get working tonight.  I've upheld my part of the bargain.  The Gui can fully configure a ScanEvent and save/load it back up.  I don't know how the rest of the system is going though.  I've asked the group multiple times, but I've only heard from Daniel Chee.  He helped me on the gui a lot.   I think this lack of communication is going to really hurt us in the long run.  Chris is supposed to make sure it is working before tomorrow, but I haven't heard from him all day.  On a scale from 1 to worried, I'm worried.

Before the Big Deadline

Well, I came back from Spring Break a little late, I missed all classes/meetings on monday.  We (UNM SC2 Team) were driving back from texas and we arrive home at about 5-6pm.  Next time I talked to my group, it seemed like not much had occurred while I was gone.  I was hoping that the project would be mostly done, in terms of what is asked of us but it does not seem like it is the case.  The demo is supposed to happen tomorrow, and I don't really know what needs to be finished up.  Before I left it seemed like I just had to tighten up some stuff about configuring to a ScanEvent and back in the Editor.  I talked to everyone yesterday and it still seems to be the case.  I'm not too confident though.  I'd feel better if I was doing everything, but I know I can't.  I'm going to try and keep in communication with everyone, so I can help out if needed in a heartbeat.

To make the tension worse, I was in the middle of a system update with my laptop - which I use for development - when the file system went into read only mode.  The only thing I can really do is restart it from there.  This usually isn't a problem, but it didn't finish configuring the update, so when I went to restart it goes through the BIOS, but then immediatly shuts off again.  This started last night, but I just got it back up and running by updating the OS.  I kept all of my files, so I should be good to go again.  Surely didn't help the tension with the deadline tomorrow.