title: How to block import of specific python package?
body: <p>I need to programmatically block import of a python package and all child packages.</p>
  
  <p>For example, I need to block loading of the package "foo" and also ensure that all children of foo such as "foo.bar" cannot be imported.</p>
  
  <p>How can this be achieved in python 2.x without restructuring my site packages or PYTHONPATH?</p>
  
  <p>For context, the intent is to programmatically avoid the risk of importing proprietary code into GPL licensed code.</p>