[ 
https://issues.apache.org/jira/browse/PYLUCENE-62?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17495042#comment-17495042
 ] 

Andi Vajda commented on PYLUCENE-62:
------------------------------------

I'd like which kind of jvm.dll is used to not be random with regards to client 
or server kind. But if you prefer both to be searchable as well, we can add 
support for a "both" --find_jvm_dll value, that searches "client", then 
"server" (or the opposite, but again, not random)The default should remain 
"client" since that is what it's been doing for years. Also, it would be good 
to emit a log statement of some sort that says what jvm.dll (its full path) was 
found and added to the DLL path.
Bullet 2: I can't bet that people wouldn't copy source code around. It's also 
easier to debug if the same code is emitted everywhere, regardless of platform, 
using conditional code as necessary.
The stuff after SHARED is unchanged, your patch didn't touch it, nor did my 
changes. I'm wondering what to do about it, though, as it is also messing with 
PATH. Are you using --shared mode ?
About "it doesn't work": I can't debug this as I don't have access to Windows. 
Here, on mac, the following works fine, of course: python -c "import jcc; 
print(jcc.__file__)". Could you please take the current patch and "make it 
work" or, if you'd like my help with debugging it, tell me more details about 
what doesn't actually work ? In particular, please, add print statements in the 
__init__.py  and windows.py files as to what is going on until it eventually 
fails and send me the output. Thanks !

> Not finding jvm.dll on windows
> ------------------------------
>
>                 Key: PYLUCENE-62
>                 URL: https://issues.apache.org/jira/browse/PYLUCENE-62
>             Project: PyLucene
>          Issue Type: Bug
>            Reporter: Petrus Hyvönen
>            Priority: Major
>         Attachments: add_dll_win-1.patch, add_dll_win.patch, jvm_dll.diff
>
>
> On recent versions of Python, the dll's seems to require to be added via the 
> os.add_dll_directory() function.
>  
> Apparently something changed in Python 3.8 regarding this, "Python 3.8 
> changed the DLL resolution order 
> [https://docs.python.org/3/whatsnew/3.8.html#bpo-36085-whatsnew]";
> Thanks to:
> [https://github.com/conda-forge/python-feedstock/issues/552]
>  
> Proposed fix in a patch below. It can likely be rewritten in some more neat 
> way. :)



--
This message was sent by Atlassian Jira
(v8.20.1#820001)

Reply via email to