Repository: django-wiki/django-wiki

Issue:
TypeError: render_to_response() got an unexpected keyword argument 'context_instance'
I installed the git version and get this:
```
Internal Server Error: /_revision/merge/14/89/preview/
Traceback (most recent call last):
  File "/home/jens/django_wiki_venv/local/lib/python2.7/site-packages/django/core/handlers/exception.py", line 39, in inner
    response = get_response(request)
  File "/home/jens/django_wiki_venv/local/lib/python2.7/site-packages/django/core/handlers/base.py", line 249, in _legacy_get_response
    response = self._get_response(request)
  File "/home/jens/django_wiki_venv/local/lib/python2.7/site-packages/django/core/handlers/base.py", line 187, in _get_response
    response = self.process_exception_by_middleware(e, request)
  File "/home/jens/django_wiki_venv/local/lib/python2.7/site-packages/django/core/handlers/base.py", line 185, in _get_response
    response = wrapped_callback(request, *callback_args, **callback_kwargs)
  File "/home/jens/django_wiki_venv/src/django-wiki/testproject/wiki/decorators.py", line 177, in wrapper
    return func(request, article, *args, **kwargs)
  File "/home/jens/django_wiki_venv/src/django-wiki/testproject/wiki/views/article.py", line 878, in merge
    return render_to_response(template_file, context_instance=c)
TypeError: render_to_response() got an unexpected keyword argument 'context_instance'
```

I just installed by:
```
pip install Pillow -e git+git://github.com/django-wiki/django-wiki.git#egg=django-wiki
```

and get this:
```
$ pip freeze
Django==1.10.3
django-classy-tags==0.8.0
django-mptt==0.8.6
django-nyt==1.0b1
django-sekizai==0.10.0
Markdown==2.6.7
Pillow==3.4.2
pkg-resources==0.0.0
six==1.10.0
sorl-thumbnail==12.3
-e git://github.com/django-wiki/django-wiki.git@6b2cb1a5b23e8c0ca83954cdc4c8dfb7ed6c8787#egg=wiki
```


Discussion:
Thanks for reporting this, seems to be an issue with Django 1.10.

Resolving patch:
diff --git a/wiki/views/accounts.py b/wiki/views/accounts.py
--- a/wiki/views/accounts.py
+++ b/wiki/views/accounts.py
@@ -47,7 +47,7 @@ def dispatch(self, request, *args, **kwargs):
             c = RequestContext(
                 request, {
                     'error_msg': _('Account signup is only allowed for administrators.'), })
-            return render_to_response("wiki/error.html", context_instance=c)
+            return render_to_response("wiki/error.html", context=c)
 
         return super(Signup, self).dispatch(request, *args, **kwargs)
 
diff --git a/wiki/views/article.py b/wiki/views/article.py
--- a/wiki/views/article.py
+++ b/wiki/views/article.py
@@ -875,7 +875,7 @@ def merge(
                                  'merge2': article.current_revision,
                                  'merge': True,
                                  'content': content})
-    return render_to_response(template_file, context_instance=c)
+    return render_to_response(template_file, context=c)
 
 
 class CreateRootView(FormView):


Test patch:
diff --git a/wiki/tests/test_views.py b/wiki/tests/test_views.py
--- a/wiki/tests/test_views.py
+++ b/wiki/tests/test_views.py
@@ -3,6 +3,7 @@
 import pprint
 
 from django.contrib.auth import authenticate
+from wiki import models
 from wiki.models import reverse
 
 from .base import ArticleWebTestBase, WebTestBase
@@ -345,3 +346,51 @@ def test_update_profile(self):
 
         self.assertNotEqual(test_auth, None)
         self.assertEqual(test_auth.email, 'test@test.com')
+
+
+class MergeViewTest(ArticleWebTestBase):
+
+    def test_merge_preview(self):
+        """Test merge preview"""
+
+        c = self.c
+        example_data = {
+            'content': 'More modifications\n\nMerge new line',
+            'current_revision': '1',
+            'preview': '0',
+            'save': '1',
+            'summary': 'testing merge',
+            'title': 'wiki test'
+        }
+
+        previous_revision = self.root_article.current_revision.id
+
+        # save a new revision
+        c.post(
+            reverse('wiki:edit', kwargs={'path': ''}),
+            example_data
+        )
+
+        response = c.get(
+            reverse(
+                'wiki:merge_revision_preview',
+                kwargs={'article_id': self.root_article.id, 'revision_id': previous_revision}
+            ),
+        )
+
+        new_revision = models.Article.objects.get(
+            id=self.root_article.id
+        ).current_revision.id
+
+        self.assertContains(
+            response,
+            'Previewing merge between:'
+        )
+        self.assertContains(
+            response,
+            '#{rev_id}'.format(rev_id=previous_revision)
+        )
+        self.assertContains(
+            response,
+            '#{rev_id}'.format(rev_id=new_revision)
+        )