Module Not found error: office365 not found

I have seen this issue with some resolutions already, but none have worked for my issue. I have pip installed the latest version of office365(v 2.2.0) to my knowledge using the command:

pip install office365-rest-client

I am trying to import using the following lines of code:

    from office365.runtime.auth.authentication_context import AuthenticationContext
    from office365.sharepoint.client_context import ClientContext
    from office365.sharepoint.files.file import File

I receive the following error:

ModuleNotFoundError: No module named 'office365'

Just to test it out, I uninstalled and reinstalled pandas, then successfully imported pandas into my project.


You also need to install the office365 library as well as office365-rest-client

pip install office365