cuallee icon indicating copy to clipboard operation
cuallee copied to clipboard

Bump getdaft from 0.2.19 to 0.2.24

Open dependabot[bot] opened this issue 9 months ago • 2 comments

Bumps getdaft from 0.2.19 to 0.2.24.

Release notes

Sourced from getdaft's releases.

v0.2.24

Changes

✨ New Features

🚀 Performance Improvements

👾 Bug Fixes

📖 Documentation

🧰 Maintenance

⬆️ Dependencies

... (truncated)

Commits

Dependabot compatibility score

Dependabot will resolve any conflicts with this PR as long as you don't alter it yourself. You can also trigger a rebase manually by commenting @dependabot rebase.


Dependabot commands and options

You can trigger Dependabot actions by commenting on this PR:

  • @dependabot rebase will rebase this PR
  • @dependabot recreate will recreate this PR, overwriting any edits that have been made to it
  • @dependabot merge will merge this PR after your CI passes on it
  • @dependabot squash and merge will squash and merge this PR after your CI passes on it
  • @dependabot cancel merge will cancel a previously requested merge and block automerging
  • @dependabot reopen will reopen this PR if it is closed
  • @dependabot close will close this PR and stop Dependabot recreating it. You can achieve the same result by closing it manually
  • @dependabot show <dependency name> ignore conditions will show all of the ignore conditions of the specified dependency
  • @dependabot ignore this major version will close this PR and stop Dependabot creating any more for this major version (unless you reopen the PR or upgrade to it yourself)
  • @dependabot ignore this minor version will close this PR and stop Dependabot creating any more for this minor version (unless you reopen the PR or upgrade to it yourself)
  • @dependabot ignore this dependency will close this PR and stop Dependabot creating any more for this dependency (unless you reopen the PR or upgrade to it yourself)

dependabot[bot] avatar May 13 '24 13:05 dependabot[bot]

@canimus

I have tried to bump the version of daft from 0.2.19 to 0.2.24 on python version 3.11.9, I can not pass any test successfully.

For example, the current implementation of the has_min check:

def has_min(self, rule: Rule, dataframe: daft.DataFrame) -> Union[bool, int]:
    perdicate = daft.col(rule.column).min()
    return dataframe.select(perdicate).to_pandas().iloc[0, 0] == rule.value

It will raise this error:

cuallee\__init__.py:1199: in validate
    return self.compute_engine.summary(self, dataframe)
cuallee\daft_validation.py:513: in summary
    unified_results = {
cuallee\daft_validation.py:514: in <dictcomp>
    rule.key: [operator.methodcaller(rule.method, rule, dataframe)(compute)]
cuallee\daft_validation.py:98: in has_min
    return dataframe.select(perdicate).to_pandas().iloc[0, 0] == rule.value
.venv\Lib\site-packages\daft\api_annotations.py:26: in _wrap
    return timed_method(*args, **kwargs)
.venv\Lib\site-packages\daft\analytics.py:189: in tracked_method
    result = method(*args, **kwargs)
.venv\Lib\site-packages\daft\dataframe\dataframe.py:662: in select
    builder = self._builder.select(self.__column_input_to_expression(columns))
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _

self = * Source:
|   Number of partitions = 1
|   Output schema = id#Int32

to_select = [min(col(id))]

    def select(
        self,
        to_select: list[Expression],
    ) -> LogicalPlanBuilder:
        to_select_pyexprs = [expr._expr for expr in to_select]
>       builder = self._builder.select(to_select_pyexprs)
E       daft.exceptions.DaftCoreException: DaftError::ValueError Aggregation expressions are not currently supported in project: min(col(id))
E       If you would like to have this feature, please see https://github.com/Eventual-Inc/Daft/issues/1979#issue-2170913383

There are some internal changes in Daft package that might cause this, there are more information here. I have also commented this there.

Suggestion

This method (and others) should be update like this:

def has_min(self, rule: Rule, dataframe: daft.DataFrame) -> Union[bool, int]:
    col = daft.col(rule.column)
    return dataframe.select(col).min(col).to_pandas().iloc[0, 0] == rule.value

dsaad68 avatar May 15 '24 22:05 dsaad68

@canimus based on the information provided by @kevinzwang, in here; I need to modify the methods in daft_validation.py to solve this problem. It seems the suggested workaround above is going to be backward compatible.

dsaad68 avatar May 16 '24 14:05 dsaad68

Looks like getdaft is up-to-date now, so this is no longer needed.

dependabot[bot] avatar May 26 '24 15:05 dependabot[bot]