Skip to content

Don't require to set the PYTHONPATH when working with OneDrive #1275

Description

@RobertvanLoon

Windows 10, xlwings 0.17.1, Office 365, Python 3.7

Until yesterday my xlwings was working perfectly fine. This morning when I opened up the same spreadsheet I worked on the night before I got this error message:

ModuleNotFoundError: No module named 'Options_Pricer_RvL'
  File "<frozen importlib._bootstrap>", line 965, in _find_and_load_unlocked
  File "<frozen importlib._bootstrap>", line 983, in _find_and_load
  File "<frozen importlib._bootstrap>", line 1006, in _gcd_import
    return _bootstrap._gcd_import(name[level:], package, level)
  File "C:\Users\rober\Anaconda3\lib\importlib\__init__.py", line 127, in import_module
    module = import_module(module_name)
  File "C:\Users\rober\Anaconda3\lib\site-packages\xlwings\udfs.py", line 228, in get_udf_module
    module = get_udf_module(module_name)
  File "C:\Users\rober\Anaconda3\lib\site-packages\xlwings\udfs.py", line 447, in import_udfs
    return ToVariant(getattr(obj, method)(*pargs, **kwargs))
  File "C:\Users\rober\Anaconda3\lib\site-packages\xlwings\server.py", line 194, in Call
    return func(*args)
  File "C:\Users\rober\Anaconda3\lib\site-packages\win32com\server\policy.py", line 586, in _invokeex_
    return S_OK, -1, self._invokeex_(dispid, lcid, wFl

I did not change anything to any settings. The same issue appears on my desktop and my laptop. I've tried different sheets, all have the same problem. I am 100% sure the spreadsheet has the same name, and is in the same location, as the corresponding .py file.

Any idea what is going on? Help is much appreciated!

Thanks.

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Fields

    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions