# AMPL + amplpy + Gurobi 12.0.1: solver call stops with access violation on Windows

**URL:** <https://discuss.ampl.com/t/ampl-amplpy-gurobi-12-0-1-solver-call-stops-with-access-violation-on-windows/2210>\
**Category:** Support\
**Created:** [November 11, 2025, 4:44pm UTC](https://discuss.ampl.com/t/ampl-amplpy-gurobi-12-0-1-solver-call-stops-with-access-violation-on-windows/2210 "2025-11-11T16:44:48Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![irepiso](https://avatars.discourse-cdn.com/v4/letter/i/49beb7/32.png) [@irepiso](https://discuss.ampl.com/u/irepiso)\
**Post date:** [November 11, 2025, 4:44pm UTC](https://discuss.ampl.com/t/ampl-amplpy-gurobi-12-0-1-solver-call-stops-with-access-violation-on-windows/2210/1 "2025-11-11T16:44:48Z")

</div>

Hi everyone,

I’m encountering a reproducible crash when running a nonconvex (QCQP) AC-OPF model in AMPL through amplpy using Gurobi 12.0.1 on Windows 11. The same model and data run perfectly with IPOPT, but Gurobi terminates immediately with:

exit value 18446744072635809797

No additional diagnostic message appears, except the `<BREAK>` line.  
When I check the AMPL logs, I can see that the solver call stops right after:

Gurobi 12.0.1: qp:nonconvex = 2

I’ve verified that:

- AMPL Academic Community Edition (Version 20250626) is installed correctly
- amplpy runs fine with other solvers.
- The .mod and .m files (a 3-bus AC-OPF in rectangular form) load and expand correctly.
- The Gurobi 12.0.1 Python and AMPL licenses are both valid.

Has anyone else experienced similar behavior, or can someone from AMPL confirm whether this exit code corresponds to an access violation or internal failure in the solver interface?

Any hints on how to diagnose or bypass the issue (adjusting solver options, changing environment variables, trying different drivers, or whatever you think might help) would be greatly appreciated.

System details:

- Windows 11 Home (64-bit)
- Python 3.13.3 + amplpy
- Academic Community License of AMPL
- Gurobi 12.0.1
- Model: AC-OPF in rectangular coordinates (nonconvex QCQP)

Thanks a lot for any insight or pointer!

Best,  
Ignacio Repiso.

---

<div class="post-metadata">

**Author:** ![marcos](https://sea1.discourse-cdn.com/flex019/user_avatar/discuss.ampl.com/marcos/32/154_2.png) [@marcos](https://discuss.ampl.com/u/marcos)\
**Post date:** [November 12, 2025, 12:32pm UTC](https://discuss.ampl.com/t/ampl-amplpy-gurobi-12-0-1-solver-call-stops-with-access-violation-on-windows/2210/2 "2025-11-12T12:32:01Z")

</div>

Hi @irepiso,

`exit value 18446744072635809797` is a common exit value for solvers that crushed without providing further information (it may have ran out of memory, segmentation faults…).

Could you try updating Gurobi to the latest version?

```auto
python -m amplpy.modules install gurobi --upgrade

```

You can also update AMPL with the “base” [module](https://dev.ampl.com/ampl/python/modules.html), `python -m amplpy.modules install base --upgrade`.

---

<div class="post-metadata">

**Author:** ![system](https://us1.discourse-cdn.com/flex019/uploads/ampl/original/1X/fe81b84535503f21fc46872e013cff3b184f9119.png) [@system](https://discuss.ampl.com/u/system)\
**Post date:** [February 10, 2026, 12:32pm UTC](https://discuss.ampl.com/t/ampl-amplpy-gurobi-12-0-1-solver-call-stops-with-access-violation-on-windows/2210/3 "2026-02-10T12:32:38Z")

</div>

This topic was automatically closed 90 days after the last reply. New replies are no longer allowed.
