Create the LogHandler.py file to create and write to the Log file for Mr. Keogh's port. This file will need the following functionality:
Log every atomic action within Mr Keogh's Port that is pertinent to legal specifications as outlined in our Project Pitch Slides. This includes:
Being written in plain ASCII,
Having the accurate time (including Daylight Savings Time)
Allowing special comments, signing in/out
Any crane movements outlined by our program.
Outputted as a .txt file that is saved on the desktop.
One log file per year is outputted, with the name “KeoghsPort[CurrentYear].txt”
The following are the specific formats:
For sign-in/sign-out (example)
“2024-01-30 16:00 Haocheng Mai signs out”
“2024-01-30 16:01 Suopa Idoru signs in”
For additional notes added to the log by the operator (example)
“2024-01-30: 11:02 I noticed that “Rhino Chew Toys” is about 10% over its stated weight, may be due to the rain on top, no further action taken.”
For loading/offloading containers (example)
Loading: “2024-01-30: 11:08 “Walmart Christmas Cat Toys” is onloaded.”
Offloading: “2024-01-30: 11:08 “Walmart Christmas Cat Toys” is offloaded.”
For balance operation (example)
For a ship that can meet the legal standards of balance by Maritime Law: “2024-1-30: 15:40 Balanced HMSJakartaExplorer within the Maritime Law’s definition of balance.”
For a ship that cannot meet the legal standards of balance: ”2024-1-30: 15:40 HMSThanatos cannot be balanced within Maritime Law’s definition of balance. Balanced ship to match the goal state of SIFT.”
For finishing a cycle (example)
After finishing all steps for a Load/Unload or Balance operation: “2024-01-30: 11:04 “Finished a Cycle. Manifest HMSJellycatJackOUTBOUND.txt was written to desktop, and a reminder pop-up to operator to send file was displayed.”
Create the LogHandler.py file to create and write to the Log file for Mr. Keogh's port. This file will need the following functionality:
The following are the specific formats: