cuddly-jelly-27016
05/29/2025, 4:39 PMfrom flytekit import task
from click.testing import CliRunner
import os
from flytekit.clis.sdk_in_container import pyflyte
@task()
def example_task(flag: bool) -> bool:
return flag
if __name__ == "__main__":
runner = CliRunner()
path = os.path.realpath(__file__)
result = runner.invoke(pyflyte.main, ["run", "remote-task", "example.example_task", "--no-flag"])
print("Remote Execution: ", result.output)
[image](https://private-user-images.githubusercontent.com/139771199/424582498-f186a4c0-0330-4527-8a11-28ca5c150a89.png?jwt=eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpc3MiOiJnaXRodWIuY29tIiwiYXVkIjoicmF3LmdpdGh1YnVzZXJjb250ZW50LmNvbSIsImtleSI6ImtleTUiLCJleHAiOjE3NDg1MzcwNjksIm5iZiI6MTc0ODUzNjc2OSwicGF0aCI6Ii8xMzk3NzExOTkvNDI0NTgyNDk4LWYxODZhNGMwLTAzMzAtNDUyNy04YTExLTI4Y2E1YzE1MGE4OS5wbmc_WC1BbXotQWxnb3JpdGhtPUFXUzQtSE1BQy1TSEEyNTYmWC1BbXotQ3JlZGVudGlhbD1BS0lBVkNPRFlMU0E1M1BRSzRaQSUyRjIwMjUwNTI5JTJGdXMtZWFzdC0xJTJGczMlMkZhd3M0X3JlcXVlc3QmWC1BbXotRGF0ZT0yMDI1MDUyOVQxNjM5MjlaJlgtQW16LUV4cGlyZXM9MzAwJlgtQW16LVNpZ25hdHVyZT03YTllNWQ0ODUxZjIyYjdhZjNhMTJjMDFlNjlhNmRmYWE3YjNjOWUzMzliOWJjMDcyZWUzNTE0ZWU3ZWNlODMxJlgtQW16LVNpZ25lZEhlYWRlcnM9aG9zdCJ9.kdI0BqxZbtQuvH6O_f2yEENdoEkGHi0p8TvDzSXf3bM)
### Setup process
### Screenshots
## Check all the applicable boxes
• I updated the documentation accordingly.
• All new and existing tests passed.
• All commits are signed-off.
## Related PRs
## Docs link
https://bito.ai#summarystart|
### Summary by Bito
This pull request fixes a bug in remote-task execution by ensuring boolean parameters default to False instead of None, preventing type conversion errors. It also enhances the test suite to cover scenarios involving boolean flags for better validation and includes additional tests for boolean flag handling, improving the reliability of the functionality.
flyteorg/flytekitcuddly-jelly-27016
05/29/2025, 4:39 PM