title: ModuleNotFoundError: No module named 'python'
body: <p>I have a python project and want to write a command line launcher.  My project works fine when I run tests or launch from my IDE (pycharm).  However when I try to launch via the command line I get a <code>ModuleNotFoundError: No module named 'python'</code> error.</p>
  <p>Here is my directory structure:</p>
  <pre><code>.
  ├── Makefile
  ├── Pipfile
  ├── Pipfile.lock
  ├── README.md
  ├── create_jenkins_jobs.sh
  └── python
      ├── __init__.py
      ├── create_credentials.py
      ├── create_jenkins_jobs_cli.py
      ├── credential_builder.py
      ├── jenkins_multibranch_job_builder.py
      ├── templates
      │   ├── job.xml
      │   ├── multibranch_job_template.xml
      │   ├── ssh_cred_template.xml
      │   └── user_pw_cred_template.xml
      └── tests
          ├── __init__.py
          ├── integration
          │   ├── __init__.py
          │   ├── build_credential_test.py
          │   ├── build_job_test.py
          │   ├── conftest.py
          │   ├── test_id_rsa
          │   └── test_id_rsa.pub
          └── unit
  </code></pre>
  <p>The shell script <code>create_jenkins_jobs.sh</code> contains:</p>
  <pre><code>#!/bin/bash
  python3 python/create_jenkins_jobs_cli.py &quot;${@}&quot;
  </code></pre>
  <p>the file <code>create_jenkins_jobs_cli.py</code> contains the following code:</p>
  <pre class="lang-py prettyprint-override"><code>from typing import Set
  from shared.common import preflight_env_check
  
  from python.jenkins_multibranch_job_builder import JenkinsMultibranchJobBuilder
  def configure_jenkins_jobs(git_repos: Set[str]):
      jenkins_job_builder = JenkinsMultibranchJobBuilder(jenkins_server_url=JENKINS_BASE_SERVER_URL,
                                                         jenkins_folder=JENKINS_ROOT_JOB_FOLDER,
                                                         user=JENKINS_USER, token=JENKINS_TOKEN,
                                                         git_cred_id=GIT_SSH_CRED_ID,
                                                         git_repos=git_repos)
      jenkins_job_builder.configure_jobs()
  
  
  configure_jenkins_jobs(GIT_REPOS)
  </code></pre>
  <p>When I launch <code>create_jenkins_jobs.sh</code> or <code>create_jenkins_jobs_cli.py</code> I always get</p>
  <pre><code>ModuleNotFoundError: No module named 'python'
  
  </code></pre>
  <pre><code>
  $&gt;./create_jenkins_jobs.sh
  /Users/pswenson/dev/cc-cicd-automation/.venv/bin/python3: Error while finding module specification for 'python/create_jenkins_jobs_cli.py' (ModuleNotFoundError: No module named 'python/create_jenkins_jobs_cli')
  
  </code></pre>
  <p>I've tried all sorts of different techniques to get this to work with PYTHONPATH, working directories, etc...</p>
  <p>It seems there is something basic about how python modules work that I don't understand.</p>