Closed zjp closed 1 year ago
This is the only change you all need? Will the attempt to import pandas cause you trouble? Or the fact that pandas is currently listed as a dependency in the pyproject.toml?
We regularly patch libraries that we use at install-time, but those patches are rarely of the scope to be upstreamed. In this case my patch just puts the pandas import in a try block that catches and ignores ModuleNotFoundError and ImportError. Another one moves the ipykernel import down into the viewSeries function.
This probably isn't the last PR related to pandas, it's just a quick one that'll reduce the complexity of the patch when it makes it to PyPI.
Got it. I pushed out a new release yesterday that includes these things.
The pandas dependency is mostly guarded in this function as-is, except for the dataframe at the very top of the function. This PR puts it under the same if...s as other usages of pandas later on.