Hacktoberfest 2026: the issues maintainers tagged for October, open and beginner-friendly. Browse Hacktoberfest issues

KeyError in save_project_info_file when IRC endpoints do not match the wells

Open Beginner friendly
#1,067 0 comments 0 reactions 0 assignees View on GitHub

Maintainers usually reply within 1 day

Nobody has claimed this yet.

Assessment

Difficulty
2/5
Estimated time
1-3 hours
Newbie friendliness
75/100
Issue type
Bug
Clarity
Clearly specified
Activity status
Active
Tech stack
python
Domain
backend

Research direction

Start with save_project_info_file in arc/main.py and trace how IRC endpoint species are added to species_list in arc/scheduler.py around line 4168. Reproduce the case where optimized IRC endpoints do not match the reaction wells, then check whether the project summary is written without a traceback. The issue is fixed when this case terminates normally and writes the project info file.

Written by the indexing model from the issue text.

Description

Summary

When the IRC endpoints of a TS do not correspond to the reaction's wells, ARC finishes all calculations and then crashes while writing the project summary:

  File "arc/main.py", line 641, in _execute
    self.save_project_info_file()
  File "arc/main.py", line 736, in save_project_info_file
    failed = '' if self.output[species.label]['convergence'] else ' (Failed!)'
KeyError: 'IRC_TS1_1'

The results are already on disk at that point, so nothing is lost, but the run exits with a traceback instead of terminating normally, and the project info file is not written.

When it happens

A reaction with compute_rates: true, a TS that converges with one imaginary frequency, and an IRC whose optimized endpoints ARC then reports as not corresponding to the reactants and products:

Error: The optimized IRC endpoints of TS TS1 do NOT correspond to the reactants and products of reaction ...

Runs of the same input in which every IRC matched its wells terminated normally.

Cause

Scheduler appends a species for each IRC endpoint (IRC_<ts label>_<index>, arc/scheduler.py around line 4168) to species_list during the run. save_project_info_file (arc/main.py, line 737 on main) then indexes self.output[species.label] for every species without a guard, and on this path the IRC endpoint species has no entry in self.output.

Possible fix

Guard the lookup, e.g. self.output.get(species.label, {}).get('convergence'), or skip IRC_* species in that loop. It may also be worth checking why the endpoint species lacks an output entry only when the endpoint check fails.

Environment

ARC main (also reproduced on a worktree of main with #1041 and #1044 merged), Gaussian 16 for opt/freq/IRC, ORCA 6 for single points.

Dominant language
Python
Stars
51
Forks
25
Avg merge
20h 31m
Merged PRs (30d)
3

Getting set up

  • Ships a Dockerfile or Docker Compose file
  • No pull request template
  • No contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

More from ReactionMechanismGenerator/ARC

All issues in ReactionMechanismGenerator/ARC

Similar issues

More Python issues

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.