junrushao1994 commented on a change in pull request #6369:
URL: https://github.com/apache/incubator-tvm/pull/6369#discussion_r485829747
##########
File path: python/tvm/target/tag.py
##########
@@ -28,7 +28,9 @@ def list_tags() -> Dict[str, Target]:
tag_dict : Dict[str, Target]
The dict of tags mapping each tag name to to its corresponding target
"""
- return _ffi_api.TargetTagListTags()
+ if hasattr(_ffi_api, "TargetTagListTags"):
+ return _ffi_api.TargetTagListTags()
+ return None
Review comment:
I will go with Optional
----------------------------------------------------------------
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.
For queries about this service, please contact Infrastructure at:
[email protected]