Skip to content

Fix test_segments_cursor #565

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

Merged
merged 1 commit into from
Jun 10, 2025

Conversation

damian3031
Copy link
Member

Description

test_segments_cursor is passing on Trino 475, but failing on Trino 476 with error:

AttributeError: 'InlineSegment' object has no attribute 'uri'

My understanding is that after this change trinodb/trino#25940, some Segments are Inline, whereas before, all of them were Spooled.
Since InlineSegment doesn't contain uri and ack_uri, I added a check for the existence of these attributes before asserting their types.

Non-technical explanation

Release notes

( ) This is not user-visible or docs only and no release notes are required.
( ) Release notes are required, please propose a release note for me.
( ) Release notes are required, with the following suggested text:

* Fix some things. ({issue}`issuenumber`)

@cla-bot cla-bot bot added the cla-signed label Jun 10, 2025
@damian3031 damian3031 requested review from wendigo and hashhar June 10, 2025 10:48
@wendigo
Copy link
Contributor

wendigo commented Jun 10, 2025

@damian3031 incorrect. Inline and spooled segments were allowed from the beginning. Linked issue has nothing to do with it

@damian3031 damian3031 force-pushed the damian/fix-test-segment-cursor branch from 4a417dd to a75efd1 Compare June 10, 2025 12:25
@damian3031
Copy link
Member Author

@damian3031 incorrect. Inline and spooled segments were allowed from the beginning. Linked issue has nothing to do with it

@wendigo I mean that after Increasing inlining allowance in spooling protocol, we are getting some InlineSegments in this particular test, and before we were getting only SpooledSegments.

I changed it to make assertions based on segment type.

@wendigo wendigo merged commit 395b533 into trinodb:master Jun 10, 2025
12 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Development

Successfully merging this pull request may close these issues.

2 participants