You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
See reproduction which broke when updating from 2.40.0 to 2.44.0. It seems ray.data.Dataset.add_column is not setting for all elements properly.
Versions / Dependencies
Ray 2.44.0
Reproduction script
importunittestimportrayimportray.dataimportpandasaspdclassMyTest(unittest.TestCase):
deftest_add_column(self):
defset_x(df: pd.DataFrame) ->pd.Series:
returnpd.Series([1] *len(df))
df=pd.DataFrame({"a": [1, 2, 3]})
# error does not present with 1 for override_num_blocks# second two are nan with 3 for override_num_blocksds=ray.data.from_pandas(df, 2)
forrowinds.add_column("x", set_x, batch_format="pandas").take(3):
self.assertEqual(row["x"], 1) # last one is nan and failsif__name__=="__main__":
unittest.main()
Issue Severity
High: It blocks me from completing my task.
The text was updated successfully, but these errors were encountered:
ivanthewebber
added
bug
Something that is supposed to be working; but isn't
triage
Needs triage (eg: priority, bug/not-bug, and owning component)
labels
Mar 27, 2025
FAIL: test_add_column (__main__.MyTest.test_add_column)
----------------------------------------------------------------------
Traceback (most recent call last):
File "/home/zhilong/test_issue.py", line 18, in test_add_column
self.assertEqual(row["x"], 1) # last one is nan and fails
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
AssertionError: nan != 1
----------------------------------------------------------------------
Ran 1 test in 3.777s
FAILED (failures=1)```
What happened + What you expected to happen
See reproduction which broke when updating from 2.40.0 to 2.44.0. It seems
ray.data.Dataset.add_column
is not setting for all elements properly.Versions / Dependencies
Ray 2.44.0
Reproduction script
Issue Severity
High: It blocks me from completing my task.
The text was updated successfully, but these errors were encountered: