(q, a)
| 87 | p.join() |
| 88 | |
| 89 | def child(q, a): |
| 90 | print("entering child") # @bp |
| 91 | assert q.get() == "foo?" |
| 92 | a.put(Foo()) |
| 93 | |
| 94 | assert q.get() == "child_pid?" |
| 95 | a.put(("child_pid", os.getpid())) |
| 96 | |
| 97 | print("spawning child of child") |
| 98 | p = multiprocessing.Process(target=grandchild, args=(q, a)) |
| 99 | p.start() |
| 100 | p.join() |
| 101 | |
| 102 | print("leaving child") |
| 103 | |
| 104 | def grandchild(q, a): |
| 105 | print("entering grandchild") |