diff --git a/pyAmakCore/classes/schedulable.py b/pyAmakCore/classes/schedulable.py index 45d906cfd98594f3447dec26f4d314c88aaaeecc..7cd78bd28568908727fb6e3b5c6b5d93502508b0 100644 --- a/pyAmakCore/classes/schedulable.py +++ b/pyAmakCore/classes/schedulable.py @@ -9,7 +9,7 @@ sys.path.insert(0, str(pathlib.Path(__file__).parent)) from pyAmakCore.exception.override import ToOverrideWarning -class Schedulable(): +class Schedulable: """ Class Schedulable """ diff --git a/pyAmakCore/classes/scheduler.py b/pyAmakCore/classes/scheduler.py index 9c20e643c2fbdcc801123126f183c78a54d5a78a..a7c2b593b4f8147a604246af37fbc3c41ee366f4 100644 --- a/pyAmakCore/classes/scheduler.py +++ b/pyAmakCore/classes/scheduler.py @@ -11,7 +11,7 @@ sys.path.insert(0, str(pathlib.Path(__file__).parent)) from pyAmakCore.classes.schedulable import Schedulable -class Scheduler(): +class Scheduler: """ Scheduler class, to make sure that environment and amas are always sync together """ diff --git a/pyAmakCore/classes/tools/loggable.py b/pyAmakCore/classes/tools/loggable.py index 19eeb4d2c3e15453b8c4372d9d074b8103bc8acd..a74ba82837f2ee142aa621989c80e10dad95c939 100644 --- a/pyAmakCore/classes/tools/loggable.py +++ b/pyAmakCore/classes/tools/loggable.py @@ -2,6 +2,7 @@ class allowing to save the state of the system at a given moment """ from os import path +from typing import List from pandas import DataFrame @@ -14,7 +15,7 @@ class Loggable: self.__do_log = False self.__file_path = None - def to_csv(self, cycle, var_list): + def to_csv(self, cycle: int, var_list: List['Agent']) -> None: """ get cycle and agent list and print them """ @@ -34,8 +35,14 @@ class Loggable: else: dataframe.to_csv(path_or_buf=self.__file_path, index=False) - def set_do_log(self, boolean): + def set_do_log(self, boolean: bool) -> None: + """ + tell the amas if it should log or not + """ self.__do_log = boolean - def set_file_path(self, path_to_file): + def set_file_path(self, path_to_file: str) -> None: + """ + specify path to csv + """ self.__file_path = path_to_file diff --git a/pyAmakCore/enumeration/agent_phase.py b/pyAmakCore/enumeration/agent_phase.py index 56464f8aa0030c6e3fca7cc0ba585b617bbbaa5a..259a21e87d72f749556e4580280c7dc51a30c6ef 100644 --- a/pyAmakCore/enumeration/agent_phase.py +++ b/pyAmakCore/enumeration/agent_phase.py @@ -1,3 +1,6 @@ +""" +Agent phases +""" from enum import Enum, auto diff --git a/pyAmakCore/enumeration/executionPolicy.py b/pyAmakCore/enumeration/executionPolicy.py index 78fc09cd586362c974118a760a6dc53c0fbf6fd2..7adbd01392977e72e0a719d28a1ca57a5283e441 100644 --- a/pyAmakCore/enumeration/executionPolicy.py +++ b/pyAmakCore/enumeration/executionPolicy.py @@ -1,3 +1,6 @@ +""" +Agent execution policy +""" from enum import Enum, auto