haddocking / haddock3

Official repo of the modular BioExcel version of HADDOCK
https://www.bonvinlab.org/haddock3
Apache License 2.0
106 stars 38 forks source link

'NoneType' object has no attribute 'identificator' #1106

Closed Liamlee97 closed 2 days ago

Liamlee97 commented 6 days ago

Hi, I have installed Haddock3 and CNS as per instructions provided by Haddock3 website. Running this via Jupyter connected to my institution's server.

When trying to run the code below with no modification to the .cfg code it gives me an error regarding NonType object with no attribute identificator. Would appreciate any help.

haddock3 docking-antibody-antigen-CDR-accessible-clt-test.cfg

The error is:

Starting HADDOCK3 v2024.10.0b6 on 2024-10-16 23:08:00

Python 3.9.20 | packaged by conda-forge | (main, Sep 30 2024, 17:49:10) 
[GCC 13.3.0]

[2024-10-16 23:08:16,442 libworkflow INFO] Reading instructions step 0_topoaa
[2024-10-16 23:08:16,442 libworkflow INFO] Reading instructions step 1_rigidbody
[2024-10-16 23:08:16,443 libworkflow INFO] Reading instructions step 2_caprieval
[2024-10-16 23:08:16,443 libworkflow INFO] Reading instructions step 3_clustfcc
[2024-10-16 23:08:16,443 libworkflow INFO] Reading instructions step 4_seletopclusts
[2024-10-16 23:08:16,443 libworkflow INFO] Reading instructions step 5_caprieval
[2024-10-16 23:08:16,443 libworkflow INFO] Reading instructions step 6_flexref
[2024-10-16 23:08:16,444 libworkflow INFO] Reading instructions step 7_caprieval
[2024-10-16 23:08:16,444 libworkflow INFO] Reading instructions step 8_emref
[2024-10-16 23:08:16,445 libworkflow INFO] Reading instructions step 9_caprieval
[2024-10-16 23:08:16,445 libworkflow INFO] Reading instructions step 10_clustfcc
[2024-10-16 23:08:16,445 libworkflow INFO] Reading instructions step 11_seletopclusts
[2024-10-16 23:08:16,445 libworkflow INFO] Reading instructions step 12_caprieval
[2024-10-16 23:08:16,494 base_cns_module INFO] Running [topoaa] module
[2024-10-16 23:08:16,495 __init__ INFO] [topoaa] Molecule 1: 4G6K_fv.pdb
[2024-10-16 23:08:16,498 __init__ INFO] [topoaa] Sanitizing molecule 4G6K_fv.pdb
[2024-10-16 23:08:16,508 __init__ INFO] [topoaa] Topology CNS input created
[2024-10-16 23:08:16,508 __init__ INFO] [topoaa] Molecule 2: 4I1B-matched.pdb
[2024-10-16 23:08:16,509 __init__ INFO] [topoaa] Sanitizing molecule 4I1B-matched.pdb
[2024-10-16 23:08:16,516 __init__ INFO] [topoaa] Topology CNS input created
[2024-10-16 23:08:16,516 __init__ INFO] [topoaa] Running CNS Jobs n=2
[2024-10-16 23:08:16,516 libutil INFO] Selected 2 cores to process 2 jobs, with 16 maximum available cores.
[2024-10-16 23:08:16,519 libparallel INFO] Using 2 cores
[2024-10-16 23:08:19,427 libparallel INFO] 2 tasks finished
[2024-10-16 23:08:19,428 __init__ INFO] [topoaa] CNS jobs have finished
[2024-10-16 23:08:19,434 base_cns_module INFO] Module [topoaa] finished.
[2024-10-16 23:08:19,434 __init__ INFO] [topoaa] took 3 seconds
[2024-10-16 23:08:20,640 base_cns_module INFO] Running [rigidbody] module
[2024-10-16 23:08:20,641 __init__ INFO] [rigidbody] crossdock=true
[2024-10-16 23:08:20,642 __init__ INFO] [rigidbody] Preparing jobs...
[2024-10-16 23:08:20,642 libutil INFO] Selected 16 cores to process 100 jobs, with 16 maximum available cores.
[2024-10-16 23:08:20,643 libparallel INFO] Using 16 cores
[2024-10-16 23:08:20,764 libparallel INFO] 100 tasks finished
[2024-10-16 23:08:20,766 __init__ INFO] [rigidbody] Preparation took 0.124139 seconds
[2024-10-16 23:08:20,778 __init__ INFO] [rigidbody] Running CNS Jobs n=100
[2024-10-16 23:08:20,778 libutil INFO] Selected 16 cores to process 100 jobs, with 16 maximum available cores.
[2024-10-16 23:08:20,780 libparallel INFO] Using 16 cores
[2024-10-16 23:10:38,738 libparallel INFO] 100 tasks finished
[2024-10-16 23:10:38,739 __init__ INFO] [rigidbody] CNS jobs have finished
[2024-10-16 23:10:38,880 base_cns_module INFO] Module [rigidbody] finished.
[2024-10-16 23:10:38,880 __init__ INFO] [rigidbody] took 2 minutes and 18 seconds
[2024-10-16 23:10:38,940 __init__ INFO] Running [caprieval] module
[2024-10-16 23:10:38,941 capri INFO] Found previous CNS step: 01_rigidbody
[2024-10-16 23:10:39,202 capri INFO] Saved scoring weights to: weights_params.json
[2024-10-16 23:10:39,926 libutil INFO] Selected 16 cores to process 100 jobs, with 16 maximum available cores.
[2024-10-16 23:10:39,927 libparallel INFO] Using 16 cores
[2024-10-16 23:10:40,024 libparallel WARNING] Exception in task execution: 
[....]
[2024-10-16 23:10:40,276 libparallel WARNING] Exception in task execution: 
[2024-10-16 23:10:40,285 libparallel INFO] 100 tasks finished
[2024-10-16 23:10:40,286 libutil ERROR] 'NoneType' object has no attribute 'identificator'
Traceback (most recent call last):
  File "/home/linlab/miniconda3/envs/haddock3/lib/python3.9/site-packages/haddock/libs/libutil.py", line 335, in log_error_and_exit
    yield
  File "/home/linlab/miniconda3/envs/haddock3/lib/python3.9/site-packages/haddock/clis/cli.py", line 195, in main
    workflow.run()
  File "/home/linlab/miniconda3/envs/haddock3/lib/python3.9/site-packages/haddock/libs/libworkflow.py", line 43, in run
    step.execute()
  File "/home/linlab/miniconda3/envs/haddock3/lib/python3.9/site-packages/haddock/libs/libworkflow.py", line 162, in execute
    self.module.run()  # type: ignore
  File "/home/linlab/miniconda3/envs/haddock3/lib/python3.9/site-packages/haddock/modules/__init__.py", line 245, in run
    self._run()
  File "/home/linlab/miniconda3/envs/haddock3/lib/python3.9/site-packages/haddock/modules/analysis/caprieval/__init__.py", line 131, in _run
    jobs = sorted(jobs, key=lambda capri: capri.identificator)
  File "/home/linlab/miniconda3/envs/haddock3/lib/python3.9/site-packages/haddock/modules/analysis/caprieval/__init__.py", line 131, in <lambda>
    jobs = sorted(jobs, key=lambda capri: capri.identificator)
AttributeError: 'NoneType' object has no attribute 'identificator'
[2024-10-16 23:10:40,288 libutil ERROR] 'NoneType' object has no attribute 'identificator'
[2024-10-16 23:10:40,288 libutil ERROR] An error has occurred, see log file. And contact the developers if needed.
[2024-10-16 23:10:40,288 libutil INFO] Finished at 16/10/2024 23:10:40. For any help contact us at https://github.com/haddocking/haddock3/issues. 再见! Dovidenia! Au revoir!.
rvhonorato commented 6 days ago

Thanks for reporting, @Liamlee97 could you please provide the full log?

Liamlee97 commented 6 days ago

Of course, please find attached. log.txt

rvhonorato commented 6 days ago

Thanks for the log, we can already see some issues.

To help us diagnose further could you please show us the output of this one https://github.com/haddocking/haddock3/blob/main/examples/analysis/contmap-test.cfg ?

Liamlee97 commented 6 days ago

Thanks for the quick reply. Here's the output txt and log txt files. log.txt Contmap-test output.txt

rvhonorato commented 5 days ago

Thanks again for these logs, weirdly none of us managed to replicate this error - our guess is that it has something to do with the jupyter configuration.

Could you try to run it outside this jupyter environment?

Liamlee97 commented 5 days ago

Thanks, I have been attempting to run haddock3 on local computer environment, but I seem to have issue with the very installation of haddock3 now... Using windows x64, VS code, miniconda. All VS build tools are in PATH, yet for some reason pip install . brings me error (see image below). image

But ideally I would like to make haddock work in institution's jupyter environment for visibility purposes - is there no way of troubleshooting this at all?

rvhonorato commented 4 days ago

Using windows x64, VS code, miniconda.

We do not support windows native, you could try running on via WSL tho

But ideally I would like to make haddock work in institution's jupyter environment for visibility purposes - is there no way of troubleshooting this at all?

Since we cannot replicate it's tricky to debug it - but could you try to install it from a fresh 3.12 environment? Also please send us the installation log generated by pip install -vvv haddock3 (it's going to be a very long one)

Liamlee97 commented 4 days ago

Thanks for your suggestions. Installing haddock3 from fresh with a new miniconda3 env with python 3.12 did the magic somehow! Functions are all working now. Many thanks again!

rvhonorato commented 2 days ago

Awesome! Guess sometimes you just need to "turn it off and on again" 🤓