Skip to content

fix: preserve the type when indexed by an empty array#3678

Merged
TaiSakuma merged 6 commits intoscikit-hep:mainfrom
TaiSakuma:fix-2377
Oct 17, 2025
Merged

fix: preserve the type when indexed by an empty array#3678
TaiSakuma merged 6 commits intoscikit-hep:mainfrom
TaiSakuma:fix-2377

Conversation

@TaiSakuma
Copy link
Copy Markdown
Member

This PR is for part of #2377.
It fixes the problem where indexing with an empty array changes the type.
The PR includes associated tests.

@codecov
Copy link
Copy Markdown

codecov bot commented Oct 16, 2025

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 82.68%. Comparing base (b749e49) to head (fad6052).
⚠️ Report is 444 commits behind head on main.

Additional details and impacted files
Files with missing lines Coverage Δ
src/awkward/contents/content.py 77.12% <100.00%> (+2.30%) ⬆️

... and 196 files with indirect coverage changes

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

@github-actions
Copy link
Copy Markdown

The documentation preview is ready to be viewed at http://preview.awkward-array.org.s3-website.us-east-1.amazonaws.com/PR3678

@ianna
Copy link
Copy Markdown
Member

ianna commented Oct 16, 2025

@all-contributors please add @TaiSakuma for code

@allcontributors
Copy link
Copy Markdown
Contributor

@ianna

I've put up a pull request to add @TaiSakuma! 🎉

Copy link
Copy Markdown
Member

@ianna ianna left a comment

Choose a reason for hiding this comment

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

@TaiSakuma - This looks great! Thank you. The tests pass - it's good to be merged. Please, go ahead and merge it if you are done with it. I will leave it up to you if you would like to tackle the ak.flatten issue as a separate PR. Thanks!

@TaiSakuma TaiSakuma merged commit 340a1aa into scikit-hep:main Oct 17, 2025
41 checks passed
@TaiSakuma
Copy link
Copy Markdown
Member Author

@ianna, thanks. I'll look into the ak.flatten issue.

@TaiSakuma TaiSakuma deleted the fix-2377 branch October 17, 2025 14:52
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