Christopher McCarthy f7638ddb0c Merged PR 60: #1355 - Carried out full renaming in node.py, active_node.py, passive_node.py...
**The following changes are made to constructor params in the Node class and its children (ActiveNode, PassiveNode, and ServiceNode):**
- _id -> node_id
- _name -> name
- _type -> node_type
- _priority -> priority
- _state -> hardware_state
- _ip_address -> ip_address
- _os_state -> software state
- _file_system_state -> file_system_state
- _config_values -> config_values
- Add type hints to all params.

(node_id, name, and ip_address are str, states and other defines types are the respective enums, leave config_values without a type for now.)

**The following changes are made to instance variables in the Node class and its children:**
- self.type -> self.node_type
- self.operating_state -> self.hardware_state
- self.os_state -> self.software_state
- Add type hints to all instance variables.

(node_id, name, and ip_address are str, states and other defines types are the respective enums, leave config_values without a type for now.)

**The following changes are made to the config files where itemType is NODE:**
- itemType -> item_type
- id -> node_id
- portsList -> ports_list
- serviceList -> service_list
- baseType -> base_type
- nodeType -> node_type
- hardwareState -> hardware_state
- ipAddress -> ip_address
- softwareState -> software_state
- fileSystemState -> file_system_state

**The following changes are made in the primaite/environment/primaite_env.py module:
In the create_node function, the id of the node needs to be retrieved using the new "node_id" key.**
- _id -> node_id
- _name -> name
- _type -> node_type
- _priority -> priority
- _state -> hardware_state
- _ip_address -> ip_address
- _os_state -> software state
- _file_system_state -> file_system_state
- _config_values -> config_values

**Few other cosmetic/code style changes too:**
- Enum classes renamed to use CamelCase.
Started refactoring out unnescessary getters and setters by using `@property` and `@<property name>.setter`.
- Have started to add Type Hints.
- Have started to move docstrings over to the Sphinx ReStructured text format.

Related work items: #1355
2023-05-26 09:01:21 +00:00

PrimAITE

Description
ARCD Primary-Level AI Training Environment (PrimAITE)
Readme 21 MiB
Languages
Python 80.2%
Jupyter Notebook 19.8%