TG: Adapt code to run in cloud9

Signed-off-by: filipe1309 <filipe1309@outlook.com>