← All challenges
easysympy/sympy · v1.9

Bug: maximum recusion depth error when checking is_zero of cosh expression

mathsymbolicbase 126f805781
Mode

60 minutes, the full token budget.

  • Time limit60 min
  • Token budgetup to 1M
  • Worth up to135 XP

Opens VS Code with an AI agent in a new tab. Prompts, tokens, tool calls and test runs are recorded and scored.

Problem statement

The following code causes a RecursionError: maximum recursion depth exceeded while calling a Python object error when checked if it is zero:

expr =sympify("cosh(acos(-i + acosh(-g + i)))")
expr.is_zero
The environment starts at commit 126f80578140 (sympy/sympy 1.9), dependencies installed and tests runnable from the first minute. You are graded by hidden tests taken from the fix that was actually merged upstream.