Skip to content

Commit

Permalink
reformat code
Browse files Browse the repository at this point in the history
  • Loading branch information
Kaiyu Yang committed Feb 3, 2024
1 parent 59401e6 commit d0c5142
Show file tree
Hide file tree
Showing 11 changed files with 16 additions and 6 deletions.
1 change: 1 addition & 0 deletions src/lean_dojo/constants.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
"""Constants controlling LeanDojo's behaviors.
Many of them are configurable via :ref:`environment-variables`.
"""

import os
import re
import sys
Expand Down
1 change: 1 addition & 0 deletions src/lean_dojo/container.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@
Currently, LeanDojo supports two types of containers: ``docker`` and ``native``.
The former is the default and recommended option, while the latter is experimental.
"""

import os
import shlex
import signal
Expand Down
12 changes: 6 additions & 6 deletions src/lean_dojo/data_extraction/ast/lean4/node.py
Original file line number Diff line number Diff line change
Expand Up @@ -361,9 +361,9 @@ def from_data(cls, node_data: Dict[str, Any], lean_file: LeanFile) -> "GroupNode
class MathlibTacticLemmaNode4(Node4):
name: str
full_name: Optional[str] = None
_is_private_decl: Optional[
bool
] = False # `_is_private` doesn't play well with lxml.
_is_private_decl: Optional[bool] = (
False # `_is_private` doesn't play well with lxml.
)

@classmethod
def from_data(
Expand Down Expand Up @@ -1027,9 +1027,9 @@ def from_data(
class CommandTheoremNode4(Node4):
name: str
full_name: Optional[str] = None
_is_private_decl: Optional[
bool
] = False # `_is_private` doesn't play well with lxml.
_is_private_decl: Optional[bool] = (
False # `_is_private` doesn't play well with lxml.
)

@classmethod
def from_data(
Expand Down
1 change: 1 addition & 0 deletions src/lean_dojo/data_extraction/build_lean3_repo.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@
Only this file runs in Docker. So it must be self-contained.
"""

import os
import sys
import toml
Expand Down
1 change: 1 addition & 0 deletions src/lean_dojo/data_extraction/build_lean4_repo.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@
Only this file runs in Docker. So it must be self-contained.
"""

import os
import re
import shutil
Expand Down
1 change: 1 addition & 0 deletions src/lean_dojo/data_extraction/cache.py
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
"""Cache manager of traced repos.
"""

import os
import shutil
import tarfile
Expand Down
1 change: 1 addition & 0 deletions src/lean_dojo/data_extraction/lean.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
"""This module define classes for repos, files, and theorems in Lean.
Objects of these classes contain only surface information, without extracting any trace.
"""

import re
import os
import json
Expand Down
1 change: 1 addition & 0 deletions src/lean_dojo/data_extraction/trace.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@
To estimate the time for tracing a repo, a good rule of thumb is 1.5x the time for compiling the repo using :code:`leanpkg build`.
A repo has to be traced only once, and the traced repo will be stored in a cache for fast access in the future.
"""

import shutil
from pathlib import Path
from loguru import logger
Expand Down
1 change: 1 addition & 0 deletions src/lean_dojo/data_extraction/traced_data.py
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
"""This module defines traced repos/files/theorems.
"""

import re
import os
import ray
Expand Down
1 change: 1 addition & 0 deletions src/lean_dojo/interaction/parse_goals.py
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
"""Utilities for parsing Lean's pretty-printed proof goals.
"""

import re
from typing import List
from dataclasses import dataclass
Expand Down
1 change: 1 addition & 0 deletions src/lean_dojo/utils.py
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
"""Utility functions used internally by LeanDojo.
"""

import re
import os
import ray
Expand Down

0 comments on commit d0c5142

Please sign in to comment.