Open
Conversation
jdavcs
pushed a commit
that referenced
this pull request
Sep 21, 2021
jdavcs
added a commit
that referenced
this pull request
Feb 8, 2024
Reason: late evaluation of arguments causes errors in mypy; also this seems to be the more common (as per SA docs) and more readable method compared to lambdas. Downside #1: a typo in the string value won't be caught by lint tools. Downside #2: if there's a sufficiently complex statement, it will be hard to read if it's all on one line; primaryjoin = "and_(HistoryDatasetAssociation.history_id == History.id, not_(HistoryDatasetAssociation.deleted), HistoryDatasetAssociation.visible)" splitting across lines will require surrounding each line with quotes: primaryjoin = ( "and_(" "HistoryDatasetAssociation.history_id == History.id," "not_(HistoryDatasetAssociation.deleted)," "HistoryDatasetAssociation.visible," ")" ) Still, I think it's better than the alternative (lambda + multiple type-ignores after each line: primaryjoin = lambda( and_( HistoryDatasetAssociation.history_id == History.id, # type:ignore[has-type, arg-type] not_(HistoryDatasetAssociation.deleted), # type:ignore[has-type, arg-type] HistoryDatasetAssociation.visible, # type:ignore[has-type, arg-type] ) )
jdavcs
pushed a commit
that referenced
this pull request
Mar 18, 2024
jdavcs
pushed a commit
that referenced
this pull request
Nov 20, 2024
Change JobState Retry-Strategy
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
test