[data] add autocompletion to datapipes#86960
[data] add autocompletion to datapipes#86960edward-io wants to merge 2 commits intopytorch:masterfrom
Conversation
🔗 Helpful Links🧪 See artifacts and rendered test results at hud.pytorch.org/pr/86960
Note: Links to docs will display an error until the docs builds have been completed. ✅ No FailuresAs of commit ac383e5: This comment was automatically generated by Dr. CI and updates every 15 minutes. |
|
@edward-io has imported this pull request. If you are a Meta employee, you can view this diff on Phabricator. |
NivekT
left a comment
There was a problem hiding this comment.
LGTM! @edward-io can you check if the autocomplete is still working with VSCode or PyCharm? I believe it should still work but it doesn't hurt to double check.
|
@NivekT do you mean autocomplete for the actual methods like register_function, set_getstate_hook? looks like it still works, it relies on the actual method signatures |
|
@edward-io has imported this pull request. If you are a Meta employee, you can view this diff on Phabricator. |
I assume something like |
I don't think this has ever been supported because the static analyzer in PyCharm/VSCode can't interpret dynamic attributes, which prompted this investigation. Let me know if thats not the case. |
|
discussed with @NivekT offline, he'll follow up with investigation on why pyi stubs aren't being generated properly in nightlies @pytorchbot merge |
Merge startedYour change will be merged once all checks pass (ETA 0-4 Hours). Learn more about merging in the wiki. Questions? Feedback? Please reach out to the PyTorch DevX Team |

In REPLs (e.g. jupyter notebook) autocomplete now works:
even with custom data pipes:
Unfortunately I wasn't able to figure out how to get autocomplete to work for non-REPLs (e.g. VSCode) - may need to generate fake pyi stubs, which 1) won't work for custom datapipes and 2) is a larger project to tackle :)