Closed khanzf closed 6 years ago
From here, I edit requirements.txt to include pysqlite.
One quick thing to try would be, is there a system package for python sqlite support? A quick google around suggests there may be a "py-sqlite3" package. If you can find one, could you please try with that rather than installing via requirements.txt?
I spun up a freebsd EC2 instance to try this out real quick, and followed your instructions but did pkg install py27-sqlite3
rather than putting it in requirements.txt. With that configuration gmake test
seems to run successfully for me.
Hi,
I installed the package py27-sqlite3
. However, I still get the same errors.
It seems that the first error message is:
AppError: Bad response: 503 Service Unavailable (not 200 OK or 3xx redirect for http://localhost:5000/1.5/58556/storage/client)
"application error: crash id 20a9eec45a734859fc29a7f8c4199448"
Whereas every successive error is a variation of the following:
OperationalError: (pysqlite2.dbapi2.OperationalError) cannot start a transaction within a transaction [SQL: u'BEGIN EXCLUSIVE TRANSACTION /* [queryName=BEGIN_TRANSACTION_WRITE] */']
Without understanding the nature of the tests, might this be an indication of what is happening?
I installed the package py27-sqlite3
In a clean build, or using your existing build? If the later, it might still be trying to use the locally-installed pysqlite2 from requirements.txt.
"application error: crash id 20a9eec45a734859fc29a7f8c4199448"
This is basically the syncserver software reporting a very generic user-visible error message that might be visible to the end-user. The successive errors are the real traceback, about "cannot start a transaction". They suggest some sort of issue with the sqlite database connector, for example that it may be trying to re-use the same db connection across multiple threads.
As discussed on IRC, I deleted the syncserver/local directory. I then ran gmake build
again with the same result.
If I understand your explanation, perhaps there is still a problem with the database? If so, if you can show me where that code is, I can try to enter the virtualenv and try to resolve it.
Sorry, I should also have said "and remove pysqlite2 from your requirements.txt".
If you're still seeing tracebacks that say "pysqlite2.dbapi2.OperationalError" then it's probably still using the one build from requirements.txt rather than the one provided by your package manager.
That appeared to be it. I added the packages:
sqlite-2.8.17_4
sqlite3-3.23.0
py36-sqlite3-3.6.5_7
And now it appears that it passed all tests, while skipping 208. Great! Unless there is something to add, we can close out this issue.
Great to to hear! :-)
Hi all, I am trying to hack this code to work on FreeBSD 11.1. I got it to successfully compile, but the tests fail. Here is what I did so far:
From here, I edit requirements.txt to include
pysqlite
. FreeBSD places sqlite3.h in /usr/local/include, so I added-I/usr/local/include
to the end of the CFLAGS variable in Makefile.From here, I ran a simple
gmake build
, which worked just fine. When I rangmake test
I received a lot of what I believe are database errors. Here is a sampling:I do not understand this error, but I am willing to assist in helping to debug the issue. Thanks