When I type tihs code: **python3 -m unittest discover -s . -p 'test_*.py'**
Here is the traceback:
............./home/mokey2/Desktop/behavior_tree_learning/src/behavior_tree_learning/core/logger/logplot.py:88: ResourceWarning: unclosed file <_io.TextIOWrapper name='logs/test/fitness_log.txt' mode='x' encoding='UTF-8'>
open(fitness_log_path, "x")
ResourceWarning: Enable tracemalloc to get the object allocation traceback
/home/mokey2/Desktop/behavior_tree_learning/src/behavior_tree_learning/core/logger/logplot.py:89: ResourceWarning: unclosed file <_io.TextIOWrapper name='logs/test/population_log.txt' mode='x' encoding='UTF-8'>
open(population_log_path, "x")
ResourceWarning: Enable tracemalloc to get the object allocation traceback
.No handles with labels found to put in legend.
No handles with labels found to put in legend.
No handles with labels found to put in legend.
./home/mokey2/Desktop/behavior_tree_learning/src/behavior_tree_learning/core/logger/logplot.py:88: ResourceWarning: unclosed file <_io.TextIOWrapper name='logs/test1/fitness_log.txt' mode='x' encoding='UTF-8'>
open(fitness_log_path, "x")
ResourceWarning: Enable tracemalloc to get the object allocation traceback
/home/mokey2/Desktop/behavior_tree_learning/src/behavior_tree_learning/core/logger/logplot.py:89: ResourceWarning: unclosed file <_io.TextIOWrapper name='logs/test1/population_log.txt' mode='x' encoding='UTF-8'>
open(population_log_path, "x")
ResourceWarning: Enable tracemalloc to get the object allocation traceback
/home/mokey2/Desktop/behavior_tree_learning/src/behavior_tree_learning/core/logger/logplot.py:88: ResourceWarning: unclosed file <_io.TextIOWrapper name='logs/test2/fitness_log.txt' mode='x' encoding='UTF-8'>
open(fitness_log_path, "x")
ResourceWarning: Enable tracemalloc to get the object allocation traceback
/home/mokey2/Desktop/behavior_tree_learning/src/behavior_tree_learning/core/logger/logplot.py:89: ResourceWarning: unclosed file <_io.TextIOWrapper name='logs/test2/population_log.txt' mode='x' encoding='UTF-8'>
open(population_log_path, "x")
ResourceWarning: Enable tracemalloc to get the object allocation traceback
No handles with labels found to put in legend.
.............FF..................Fallback
--> c0
--> c0
Fallback
(-) Fallback
--> c0
--> c0
Fallback
(-) Fallback
--> c0
--> c0
(-) Sequence
--> c0
--> c0
Fallback
(-) Fallback
--> c0
--> c0
(-) Fallback
(-) Sequence
--> c0
Fallback
(-) Fallback
--> c0
--> c0
Fallback
(-) Fallback
--> c0
.F
FAIL: test_add_node (test_sbt_btsr.TestBehaviorTreeStringRepresentation)
Tests add_node function
Traceback (most recent call last):
File "/home/mokey2/Desktop/behavior_tree_learning/src/behavior_tree_learning/tests/test_sbt_btsr.py", line 249, in test_add_node
self.assertEqual(btsr.bt, ['s(', 'a0', 'a3', 'a0', ')'])
AssertionError: Lists differ: ['s(', 'a0', 'a5', 'a0', ')'] != ['s(', 'a0', 'a3', 'a0', ')']
First differing element 2:
'a5'
'a3'
- ['s(', 'a0', 'a5', 'a0', ')']
? ^
- ['s(', 'a0', 'a3', 'a0', ')']
? ^
======================================================================
FAIL: test_change_node (test_sbt_btsr.TestBehaviorTreeStringRepresentation)
Tests change_node function
Traceback (most recent call last):
File "/home/mokey2/Desktop/behavior_tree_learning/src/behavior_tree_learning/tests/test_sbt_btsr.py", line 225, in test_change_node
self.assertEqual(btsr.bt, ['s(', 'f(', 'a0', 'a0', ')', 'a0', ')'])
AssertionError: Lists differ: ['s(', 'f(', 'a2', 'a0', ')', 'a0', ')'] != ['s(', 'f(', 'a0', 'a0', ')', 'a0', ')']
First differing element 2:
'a2'
'a0'
- ['s(', 'f(', 'a2', 'a0', ')', 'a0', ')']
- ['s(', 'f(', 'a0', 'a0', ')', 'a0', ')']
======================================================================
FAIL: test_str_from_bt (test_sbt_pytree.TestStringBehaviorTree)
Traceback (most recent call last):
File "/home/mokey2/Desktop/behavior_tree_learning/src/behavior_tree_learning/tests/test_sbt_pytree.py", line 69, in test_str_from_bt
self.assertEqual(bt.to_string(), sbt)
AssertionError: Lists differ: ['f(', '(-) f(', 'c0', 'c0', '(-) f(', '(-) s(', 'c0', ')'] != ['f(', 'f(', 'c0', 'c0', ')', 'f(', 's(', 'c0', ')', ')', ')']
First differing element 1:
'(-) f('
'f('
Second list contains 3 additional elements.
First extra element 8:
')'
- ['f(', '(-) f(', 'c0', 'c0', '(-) f(', '(-) s(', 'c0', ')']
? ---- -- ^ ----
- ['f(', 'f(', 'c0', 'c0', ')', 'f(', 's(', 'c0', ')', ')', ')']
? ^^^^ ++++++++++
Ran 50 tests in 0.919s
FAILED (failures=3)
Can you help me on this?