tensorflow / tensorflow/tensorflow

Missing type annotations

Open
#99,580 3 comments 1 reaction 1 assignee View on GitHub

@Venkat6871 is already working on this.

Since Sep 1, 2025.

type:docs-feature type:feature
Dominant language
C++
Stars
200k
Forks
76.9k
Avg merge
2d 3h
Merged PRs (30d)
433

Description

Issue type

Documentation Feature Request

Have you reproduced the bug with TensorFlow Nightly?

No

Source

binary

TensorFlow version

2.19.1

Custom code

Yes

OS platform and distribution

AlmaLinux 9

Mobile device

No response

Python version

No response

Bazel version

No response

GCC/compiler version

No response

CUDA/cuDNN version

No response

GPU model and memory

No response

Current behavior?

Some type annotations seem to be missing and pyright complains about them.

Standalone code to reproduce the issue
import tensorflow as tf

x = tf.Variable([1.0, 2.0, 3.0])
y = x.numpy()
print(y)
Relevant log output
Cannot access attribute "numpy" for class "Variable"    Attribute "numpy" is unknown

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.