Skip to content

Conversation

@Conarnar
Copy link
Contributor

Summary

An error would occur when trying to get the metadata for a method containing an input or output that isn't a tensor. This occurs because there wasn't a check for the input/output tag when generating the list of tensor metadata.

Now the list of tensor metadata will have undefined if the input/output in that index is not a tensor.

Test plan

Added unit tests to test the method metadata for a method that has ints in its input and outputs.
Added unit test to check if getMethod works if the module has multiple methods.

Unit tests are in the CI but can be ran with

bash scripts/build_wasm_tests.sh
cd cmake-out-wasm/extension/wasm/test/
npm test # after installing Jest

@pytorch-bot
Copy link

pytorch-bot bot commented Aug 18, 2025

🔗 Helpful Links

🧪 See artifacts and rendered test results at hud.pytorch.org/pr/pytorch/executorch/13496

Note: Links to docs will display an error until the docs builds have been completed.

❌ 2 New Failures

As of commit 71e681d with merge base d6b462d (image):

NEW FAILURES - The following jobs have failed:

This comment was automatically generated by Dr. CI and updates every 15 minutes.

@meta-cla meta-cla bot added the CLA Signed This label is managed by the Facebook bot. Authors need to sign the CLA before a PR can be reviewed. label Aug 18, 2025
@github-actions
Copy link

This PR needs a release notes: label

If your change should be included in the release notes (i.e. would users of this library care about this change?), please use a label starting with release notes:. This helps us keep track and include your important work in the next release notes.

To add a label, you can comment to pytorchbot, for example
@pytorchbot label "release notes: none"

For more information, see
https://github.com/pytorch/pytorch/wiki/PyTorch-AutoLabel-Bot#why-categorize-for-release-notes-and-how-does-it-work.

@Conarnar Conarnar merged commit ff8be27 into pytorch:main Aug 20, 2025
102 of 105 checks passed
agrima1304 pushed a commit to agrima1304/executorch that referenced this pull request Aug 26, 2025
### Summary
An error would occur when trying to get the metadata for a method
containing an input or output that isn't a tensor. This occurs because
there wasn't a check for the input/output tag when generating the list
of tensor metadata.

Now the list of tensor metadata will have `undefined` if the
input/output in that index is not a tensor.

### Test plan
Added unit tests to test the method metadata for a method that has ints
in its input and outputs.
Added unit test to check if getMethod works if the module has multiple
methods.

Unit tests are in the CI but can be ran with
```
bash scripts/build_wasm_tests.sh
cd cmake-out-wasm/extension/wasm/test/
npm test # after installing Jest
```
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

CLA Signed This label is managed by the Facebook bot. Authors need to sign the CLA before a PR can be reviewed.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants