Hacktoberfest 2026: the issues maintainers tagged for October, open and beginner-friendly. Browse Hacktoberfest issues

test_finfo fails on numpy

Open
#317 12 comments 1 reaction 0 assignees View on GitHub

Nobody has claimed this yet.

Assessment

Difficulty
3/5
Estimated time
1-2 days
Newbie friendliness
35/100
Issue type
Bug
Clarity
Mostly clear
Activity status
Stale
Tech stack
numpy, python
Domain
testing-qa

Research direction

Start by locating the test_finfo spec and the compatibility level mentioned in the report. Compare the expected type of xp.finfo(xp.float32).eps with the NumPy and JAX examples, then run the relevant test suite; done means the test behavior consistently reflects the supported array API implementations.

Written by the indexing model from the issue text.

Description

wontfix

The spec seems to imply that xp.finfo(xp.float32).eps is a python float, but numpy and jax.numpy use numpy scalars instead

In [1]: import torch

In [2]: torch.finfo(torch.float32).eps
Out[2]: 1.1920928955078125e-07

In [3]: type(torch.finfo(torch.float32).eps)
Out[3]: float

In [4]: import numpy as np

In [5]: type(np.finfo(np.float32).eps)
Out[5]: numpy.float32

In [6]: import jax.numpy as jnp

In [7]: type(jnp.finfo(jnp.float32).eps)
Out[7]: numpy.float32

Not hard to work around on the -compat level, even if having a wrapper for finfo feels a bit cheesy.

Dominant language
Python
Stars
74
Forks
54
Avg merge
4h 35m
Merged PRs (30d)
4

Contributor guide

No contributing guide indexed for this repository

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.

More from data-apis/array-api-tests

All issues in data-apis/array-api-tests

Similar issues

More Python issues

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.