You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@iceberg.apache.org by "Guillem96 (via GitHub)" <gi...@apache.org> on 2023/02/10 16:03:03 UTC

[GitHub] [iceberg] Guillem96 opened a new pull request, #6805: Fix TableScan typing

Guillem96 opened a new pull request, #6805:
URL: https://github.com/apache/iceberg/pull/6805

   TableScan is not a generic, to solve the issue of returning an instance of the same or sub-class it's better to use the `Self` new typing


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: issues-unsubscribe@iceberg.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@iceberg.apache.org
For additional commands, e-mail: issues-help@iceberg.apache.org


[GitHub] [iceberg] Fokko commented on pull request #6805: Fix TableScan typing

Posted by "Fokko (via GitHub)" <gi...@apache.org>.
Fokko commented on PR #6805:
URL: https://github.com/apache/iceberg/pull/6805#issuecomment-1426354103

   Thanks @Guillem96 for opening this. And I agree that `Self` would be much nicer. However, I see that there are mypy errors. Both the original author and I tried using Self, but ended up with weird errors: https://github.com/apache/iceberg/pull/6233#discussion_r1027642501


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: issues-unsubscribe@iceberg.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@iceberg.apache.org
For additional commands, e-mail: issues-help@iceberg.apache.org


[GitHub] [iceberg] Guillem96 commented on pull request #6805: Fix TableScan typing

Posted by "Guillem96 (via GitHub)" <gi...@apache.org>.
Guillem96 commented on PR #6805:
URL: https://github.com/apache/iceberg/pull/6805#issuecomment-1427479240

   @Fokko If you require python 3.11 I don't see the reason to be compatible with `typing_extensions`, but anyways your  `TypeVar` usage is wrong, because there's no need for the class to be a generic if you can leverage the method definition to bound the `TypeVar` type.
   
   I implemented properly use of `TypeVar` in this new PR #6819.
   
   With this implementation the type analyzer successfully keeps the `TableScan` type in the fluent calls of `select`, `filter`, etc.. 


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: issues-unsubscribe@iceberg.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@iceberg.apache.org
For additional commands, e-mail: issues-help@iceberg.apache.org


[GitHub] [iceberg] Guillem96 closed pull request #6805: Fix TableScan typing

Posted by "Guillem96 (via GitHub)" <gi...@apache.org>.
Guillem96 closed pull request #6805: Fix TableScan typing
URL: https://github.com/apache/iceberg/pull/6805


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: issues-unsubscribe@iceberg.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@iceberg.apache.org
For additional commands, e-mail: issues-help@iceberg.apache.org