---
title: "Django 2.2.7 release notes"
version: 3.0
locale: zh-hans
source: https://docs.djangoproject.com/zh-hans/3.0/releases/2.2.7/
canonical: https://djangodocs.dev/zh-hans/3.0/releases/2.2.7/
---
# Django 2.2.7 release notes

*November 4, 2019*

Django 2.2.7 fixes several bugs in 2.2.6.

## Bugfixes

- Fixed a crash when using a `contains`, `contained_by`, `has_key`,
  `has_keys`, or `has_any_keys` lookup on
  [`JSONField`](/zh-hans/3.0/ref/contrib/postgres/fields/#django.contrib.postgres.fields.JSONField), if the right or left hand
  side of an expression is a key transform ([#30826](https://code.djangoproject.com/ticket/30826)).
- Prevented [`migrate --plan`](/zh-hans/3.0/ref/django-admin/#cmdoption-migrate-plan) from showing that `RunPython` operations
  are irreversible when `reverse_code` callables don't have docstrings or
  when showing a forward migration plan ([#30870](https://code.djangoproject.com/ticket/30870)).
- Fixed migrations crash on PostgreSQL when adding an
  [`Index`](/zh-hans/3.0/ref/models/indexes/#django.db.models.Index) with fields ordering and
  [`opclasses`](/zh-hans/3.0/ref/models/indexes/#django.db.models.Index.opclasses) ([#30903](https://code.djangoproject.com/ticket/30903)).
- Restored the ability to override
  [`get_FOO_display()`](/zh-hans/3.0/ref/models/instances/#django.db.models.Model.get_FOO_display) ([#30931](https://code.djangoproject.com/ticket/30931)).
