-
Notifications
You must be signed in to change notification settings - Fork 993
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
pass tests for Suor/django-cacheops repo #184
Comments
Related to #182 |
The solution I see is:
As a side note, redis guards global overrides in |
Given that this project is not under active development, you also have an option to just copy the files you need under |
Yes, this would be even easier if this is ok. I was just skeptical of keeping files around locally when a download seems "cleaner".
We need to make sure we don't accidentally overwrite the makefile when merging
We can. I suppose redis inlined builds because its just easier to inject a few source files rather than building separate projects and storing all of their files. All that cjson depends on is a lua include, which we would have after download. Are we going to add just cjson, or all of them? Not all libraries are hosted on github: http://bitop.luajit.org/download.html gives you a zip - but I guess this could also be unpacked with cmake . If we store them locally, instead of keeping the full projects, we can just have required source files. And inject them on main lua build. The redis way in short. The other way would be downloading the full projects and building them. I'm not sure its worth keeping full projects locally and building them separately, because joining the lua build requires just a few patched lines. |
I do not mind adding 3rd party lua modules under
Btw, if you look at DF lua code you can see that we already load some modules that lua provides natively - https://github.com/dragonflydb/dragonfly/blob/main/src/core/interpreter.cc#L200 |
Got it. So I'll add each project with its native make file and trigger its build from cmake after downloading lua? |
We support it natively, see https://github.com/romange/helio/blob/master/cmake/third_party.cmake#L269 for example. |
No, if you just copy .h,.c files into |
I took a look at bitops lib. Unfortunately, http://bitop.luajit.org/download.html version does not work with lua >= 5.3. I searched for answers in github and found this patch LuaJIT/LuaJIT#384 that should fix the issue. Hope it helps. |
@dranikpg Can we add a test now that covers django-cacheops ? |
We can, with global and non-atomic modes (possibly) I guess this is not the right issue to discuss such changes, but we need to keep two internal infos about the script for sure:
Based on this we can choose the most fitting execution mode internally, without the user needing to learn about DFs scheduling. How can it be controlled?
-- df:not-atomic
-- df:undeclared
redis.call('GET', 'anykey') |
With #871, cacheops tests will finally pass. Even in non atomic mode 🤨 (I ran them multiple times). I think we can close this issue then and continue our discussion about script settings elsewhere |
Now passing |
git clone https://github.com/Suor/django-cacheops
pip install -r ./requirements-test.txt
./run_tests.py 2> 1.err
The first failure is due to lack of support of cjson https://github.com/mpx/lua-cjson.
Redis just copied the files needed to build cjson into
deps/lua/src/
together with other libraries like msgpack, struct and bit.The text was updated successfully, but these errors were encountered: