refresh() got an unexpected keyword argument 'index' - django

I'm currently working on a django project that uses Haystack/elasticsearch.
I've had much trouble installing elasticsearch on windows, finally using this setup: http://ruilopes.com/elasticsearch-setup/
With a bit of tweaking for the elasticsearch.bat it finally worked after running the bat file.
Now I'm trying to register a user on the website which gives me this error:
refresh() got an unexpected keyword argument 'index'
in this line:
x:\development\xxxx\xxxx\src\django-haystack\haystack\backends\elasticsearch_backend.py in update
174.self.conn.refresh(index=self.index_name)

I was getting the same error until I upgraded pyelasticsearch. These two versions worked together:
django_haystack-2.1.0
pyelasticsearch-0.6.1

Related

No module named 'django.conf.urls.defaults'

I upgraded from django 3.2.5 to django 4.0.4.
I know that this 'django.conf.urls.defaults' must be deprecated.
My problem is that I don't get this error in the development environment but when I push to production, it shows the error. Why is this so???
Also I tried to locate the file so that I can change that line of code to the correct one but could find it's location. It's giving me this path which I can't see how to get to (/workspace/.heroku/python/lib/python3.9/site-packages/django/conf/urls/__init__.py))
After trying all the possibles at my level , I had to revert to django 3.2.5

omcljs basic tutorial giving error: Uncaught Error: Assert failed: No target specified to om.core/root (not (nil? target))

I am attempting om's basic tutorial, and run into an error even before changing any code.
I followed the instructions, running lein new figwheel om-tut -- --om, cd om-tut, and lein figwheel.
http://localhost:3449/ then displays the html text, not the app-state text which it should be displaying instead. Furthermore, when I open my dev tools to the console I see the error message shown in the following screenshot.
This is unexpected because I have not changed the tutorial at all, just downloaded and run following the instructions to a T. It is also unexpected because the tutorial seemed to work for me just yesterday, running on my same machine.
Any one know what could be the issue?
This is a really old bug in the om.root https://github.com/swannodette/mies-om/issues/2. It should have been fixed by now.

Sulu not running on PHP7

was any one of you able to install sulu on a webserver running Apache and PHP7?
When I try to clear the cache, I get an error PHP Fatal error: Cannot use 'String' as class name as it is reserved in /var/www/foobar/vendor/doctrine/phpcr-odm/lib/Doctrine/ODM/PHPCR/Mapping/Annotations/String.php on line 28
We are already working on that. The main problem is the usage of a class named String in the PHPCR-ODM. They fixed that in version 1.3. Also there are some tests still failing, but we are already working on that. You can follow the progress on the corresponding PR.

django, haystack, and pyelasticsearch best versions

Basically, I am getting a unreasonable amount of errors using these libraries:
django==1.4.3
pyelasticsearch==0.6
simplejson==3.3.0
django-haystack==2.1.0
The errors I get are:
From python2.7/site-packages/haystack/query.py:
index_queryset() got an unexpected keyword argument 'using'
I just remove this and it works locallay
/srv/www/projects/k-state-union/lib/haystack/backends/elasticsearch_backend.py:
raise MissingDependency("The 'elasticsearch' backend requires the installation of 'pyelasticsearch'. Please refer to the documentation.")
This error occurs when pyelasticsearch fails to be imported. If I let it fail naturally:
/srv/www/.virtualenvs/k-state-union/lib/python2.6/site-packages/pyelasticsearch/client.py:
from simplejson import JSONDecodeError
Which works in the python interpreter.
The errors seem to indicate that I am not using the intended versions of pyelasticsearch and haystack. What do I need to do to get this up and running?
There are two different python libraries for Elasticsearch out there. I switched from pyelasticsearch to elasticsearch and it worked.

Dajaxice not being parsed by template renderer?

Well i recently put my site into production and this is the last of a few bugs i need to fix. Basically dajaxice/dajaxice.core.js in returning this error in console Uncaught SyntaxError: Unexpected token %. I have placed that particular folder into static and run collect static. The file is fetched however upon opening up the file from the error the django code embedded within the file is not being rendered.
I have placed the file wihtin the head of my base file. Does anyone have any suggestions as to why this is occuring. In my local envionment (development) it is working flawlessly. The only difference i had when installing the two is that i used pip to install it on production and on local i directly downloaded the file and installed it from github. How do i find the version of Dajaxice that is installed?
Does anyone have any ideas as to why this is occuring?
Thanks