You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Description
I'm an amateur and I've spent days starting lean_dojo :(
My error occurs when trying to run lean_dojo with a specific Lean4 repository. The process fails with a CalledProcessError when attempting to execute the lake env lean --threads 4 --run ExtractData.lean command.
Detailed Steps to Reproduce the Behavior
Use the following code to reproduce the error:
importosfromlean_dojoimport*importsubprocess# Set environment variable VERBOSE to 1os.environ['VERBOSE'] ='1'repo=LeanGitRepo("https://github.com/yangky11/lean4-example", "fd14c4c8b29cc74a082e5ae6f64c2fb25b28e15e")
theorem=Theorem(repo, "Lean4Example.lean", "hello_world")
try:
withDojo(theorem) as (dojo, init_state):
print(init_state)
result=dojo.run_tac(init_state, "rw [add_assoc, add_comm b, ←add_assoc]")
assertisinstance(result, ProofFinished)
print(result)
exceptsubprocess.CalledProcessErrorase:
print("Command failed with exit status", e.returncode)
print("Command output:", e.output.decode())
print("Command stderr:", e.stderr.decode())
print("Current working directory:", os.getcwd())
exceptExceptionase:
print("An unexpected error occurred:", str(e))
print("Current working directory:", os.getcwd())
Observe the error during the execution.
Logs in Debug Mode
Command failed with exit status 1
Command output: [0/1] Building Lean4Example
Command stderr:
2024-06-22 00:05:49.396 | INFO | __main__:main:165 - Building lean4-example
2024-06-22 00:05:51.908 | INFO | __main__:main:188 - Tracing lean4-example
2024-06-22 00:05:51.929 | DEBUG | __main__:main:193 - lake env lean --threads 4 --run ExtractData.lean
0%| | 0/721 [00:05<?, ?it/s]Traceback (most recent call last):
File "/tmp/tmpokt8c1we/workspace/build_lean4_repo.py", line 200, in <module>
main()
File "/tmp/tmpokt8c1we/workspace/build_lean4_repo.py", line 194, in main
run_cmd(cmd, capture_output=True)
File "/tmp/tmpokt8c1we/workspace/build_lean4_repo.py", line 29, in run_cmd
res = subprocess.run(cmd, shell=True, capture_output=capture_output, check=True)
File "/usr/lib/python3.10/subprocess.py", line 526, in run
raise CalledProcessError(retcode, process.args,
subprocess.CalledProcessError: Command 'lake env lean --threads 4 --run ExtractData.lean' returned non-zero exit status 1.
Platform Information
Windows WSL
Python 3.10.12
Lean 4.6.0-rc1
Elan 3.1.1
Lake version 5.0.0-5cc0c3f
LeanDojo Version 1.8.2
The text was updated successfully, but these errors were encountered:
I had the same issue, but with lake build, and not lake env lean --threads 4 --run ExtractData.lean. I solved it by making sure all the lean files in the directory did not have any errors in them.
Description
I'm an amateur and I've spent days starting lean_dojo :(
My error occurs when trying to run
lean_dojo
with a specific Lean4 repository. The process fails with aCalledProcessError
when attempting to execute thelake env lean --threads 4 --run ExtractData.lean
command.Detailed Steps to Reproduce the Behavior
Use the following code to reproduce the error:
Logs in Debug Mode
Command failed with exit status 1
Command output: [0/1] Building Lean4Example
Command stderr:
Platform Information
The text was updated successfully, but these errors were encountered: