Skip to content

sampler add raise parse kv error#355

Merged
tiankongdeguiji merged 4 commits intoalibaba:masterfrom
chengaofei:feature/sampler_add_raise_parse_kv
Dec 25, 2025
Merged

sampler add raise parse kv error#355
tiankongdeguiji merged 4 commits intoalibaba:masterfrom
chengaofei:feature/sampler_add_raise_parse_kv

Conversation

@chengaofei
Copy link
Collaborator

sampler add raise parse kv error

if element.is_valid:
element.cast(data_type, safe=False)
except Exception:
index = start + i
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

remove index = start + i

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

fix

break
index = (index - 1) / 2
for j, c in enumerate(offsets):
if index < c.as_py():
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

if i < c.as_py()

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

fix

]


def _cast_data(
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

_cast_data -> _safe_cast_kv_data

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

fix

@tiankongdeguiji tiankongdeguiji merged commit c87aba6 into alibaba:master Dec 25, 2025
6 checks passed
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.

2 participants