Python custom module name not defined
<p>I have a custom package called 'package' and a custom module in that package called 'module' which has a function returning 'test' when called. When I import my package if I do:</p>

<pre><code>from package import module
</code></pre>

<p>Everything works fine but if I do:</p>

<pre><code>from package import *
</code></pre>

<p>Or</p>

<pre><code>import package
</code></pre>

<p>Then when trying to use the 'module' module it comes up with an error name 'module' is not defined. Why is it not importing the module when I use import * or when I import the package?</p>

<p>The code in the module I am trying to call is this:</p>

<pre><code>def printTest():
    return("Test")
</code></pre>

<p>The code in the file calling the module is this:</p>

<pre><code>import package

print(module.printTest())
</code></pre>