Skip to content

Commit

Permalink
Fixed concerns raised by LGTM.
Browse files Browse the repository at this point in the history
  • Loading branch information
paulsaxe committed Feb 4, 2021
1 parent 8bc825c commit dd0968e
Showing 1 changed file with 1 addition and 28 deletions.
29 changes: 1 addition & 28 deletions psi4_step/psi4.py
Original file line number Diff line number Diff line change
Expand Up @@ -558,34 +558,7 @@ def _convert_structure(self, name=None):
structure.append('molecule ' + name + ' {')

# Charge and multiplicity
if False and 'extras' in configuration:
extras = configuration['extras']

if 'open' in extras and extras['open'] is not None:
openshell = extras['open']
if (
(
isinstance(openshell, tuple) or
isinstance(openshell, list)
) and len(openshell) > 1
):
nopen = openshell[0]
norbitals = openshell[1]
if nopen != norbitals:
raise NotImplementedError(
f"Handling of open shell = '{openshell}'"
)
else:
nopen = openshell
norbitals = nopen

if 'net_charge' in extras and extras['net_charge'] is not None:
structure.append(f" {extras['net_charge']} {nopen}")
else:
structure.append(f' 0 {nopen}')
else:
if 'net_charge' in extras and extras['net_charge'] is not None:
structure.append(f" {extras['net_charge']} 1")
# not handled yet!!!!

elements = configuration.atoms.symbols
coordinates = configuration.atoms.coordinates
Expand Down

0 comments on commit dd0968e

Please sign in to comment.