buggy context v1
updated to a newer version of bfs
ready to merge into master