Skip to content

Commit

Permalink
fix sysconf import
Browse files Browse the repository at this point in the history
  • Loading branch information
tobiasdiez committed Jan 5, 2025
1 parent d4cc54e commit 0445ffb
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion src/sage/doctest/util.py
Original file line number Diff line number Diff line change
Expand Up @@ -23,8 +23,8 @@
# https://www.gnu.org/licenses/
# ****************************************************************************

from os import times
from time import time as walltime
from os import sysconf, times


def count_noun(number, noun, plural=None, pad_number=False, pad_noun=False):
Expand Down Expand Up @@ -204,6 +204,8 @@ def _proc_stat_cpu_seconds(self, path):
raise OSError(f"unable to parse {path}") from e

try:
from os import sysconf

hertz = sysconf("SC_CLK_TCK")
except (ValueError) as e:
# ValueError: SC_CLK_TCK doesn't exist
Expand Down

0 comments on commit 0445ffb

Please sign in to comment.