Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Remove FutureWarning when use cache in the context manager #1848

Merged
merged 1 commit into from
Oct 13, 2020

Conversation

itholic
Copy link
Contributor

@itholic itholic commented Oct 13, 2020

When use CachedDataFrame in the context manager, It raises FutureWarning as below.

>>> kdf = ks.range(10)
>>> with kdf.spark.cache() as cached:
...     cached.spark.storage_level
...
StorageLevel(True, True, False, True, 1)
.../koalas/databricks/koalas/frame.py:10593: FutureWarning: DataFrame.unpersist is deprecated as of DataFrame.spark.unpersist. Please use the API instead.

This warning is unavoidable since It's fixed in the code, so this PR proposes removing this.

>>> kdf = ks.range(10)
>>> with kdf.spark.cache() as cached:
...     cached.spark.storage_level
...
StorageLevel(True, True, False, True, 1)

@HyukjinKwon HyukjinKwon merged commit d01d9a7 into databricks:master Oct 13, 2020
@ueshin
Copy link
Collaborator

ueshin commented Oct 13, 2020

nice.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants