Exemple #1
0
def function_main():
    update_variable()
    print(main_module_variable_1)
    save_variables(
    )  #write this line to save updated variables when you are about to use them
    #in the other modules at the next line(Gate ways to other modules)
    return module_2.function_2()
Exemple #2
0
def function_main():
    update_variable_1()
    module_3.update_variable_2()

    load_variables(
    )  # it's better to define another function for print and use load_variables() at its first line
    print('1:', main_module_variable_1, main_module_variable_2)
    #save_variables() # Don't use save_variables() all at once in such lines like gate ways.
    # Use save_variables() separtly for each function that changes a variable.
    return module_2.function_2()
Exemple #3
0
def update_all():
    load_variables()

    save_variables()
    module_2.update_variable_1()
    module_3.update_variable_2_3()
    load_variables(
    )  # it's better to define another function for print and use load_variables() at its first line

    save_variables()
    print_variables()
    return module_2.function_2()
Exemple #4
0
def function_main():
    update_variable()
    print(main_module_variable)
    return module_2.function_2()