Closed atharva-2001 closed 11 months ago
That line can be updated to do an explicit "None" check. Are you interested in contributing / opening a PR?
Yes I would be very happy to! I would open a PR in sometime today!
@noahnu Would you mind looking at https://github.com/tophat/syrupy/pull/789? Is the change alright? Also could you please review my code a bit as well? Is it safe to extend the class in the way I did from a sustainability perspective?
We are planning to add this library for our tests in TARDIS- https://tardis-sn.github.io/, https://github.com/tardis-sn and might be doing this across several repos.
Could the classes I made stay as is for at least 3-4 years?
Yes the API you're using is stable. I was thinking about renaming some of the methods to remove the underscore, however I have no immediate plans to do so, and if that happens, it'd be in a new major version with a migration guide.
Dear Syrupy Team, Thank you for this great package. I wanted to extend the
SingleFileSnapshotExtension
to save Pandas and NumPy objects to HDF files and.dat
files respectively. I used the functions that you mentioned could be overridden(except theserialize
function) to save these files in these new formats. However this specific line inget_assert_diff
is causing an error that I just can't get past.Both Dataframes and Arrays have no bool values, which is why doing something like
dataframe or ""
raises a ValueError.Any help on how I can get past this error? Am I doing the wrong thing? Here are a few references-![image](https://github.com/tophat/syrupy/assets/55894364/3b4dc7d6-e56a-4b50-8f05-34bed429ea6b)
Here is the extension that I wrote- https://github.com/atharva-2001/syrupy-pandas-numpy/blob/main/tests/test_pd.py