Working now, thankyou.

On Tue, Mar 28, 2023 at 11:16 AM Andi Vajda <va...@apache.org> wrote:

>
> On Tue, 28 Mar 2023, S Less wrote:
>
> > I'm able to successfully perform indexing and searching within Python.
> > I was hoping to try the Monitor
> > <
> https://lucene.apache.org/core/9_4_1/monitor/org/apache/lucene/monitor/Monitor.html
> >
> > class however this line fails
> >
> > from org.apache.lucene.monitor import Monitor
> >
> > Traceback (most recent call last):
> >  File "/Users/akeers/Documents/git_work/pylucene-test/test2.py", line 2,
> > in <module>
> >    from org.apache.lucene.monitor import Monitor
> > ModuleNotFoundError: No module named 'org.apache.lucene.monitor';
> > 'org.apache.lucene' is not a package
>
> Indeed, the org.apache.lucene.monitor package is not built into PyLucene.
> Why ? I didn't know about it.
>
> Here is a diff you can apply to Makefile to get the Monitor stuff included
> in PyLucene:
>
> ------ SNIP ------
> Index: Makefile
> ===================================================================
> --- Makefile    (revision 1904983)
> +++ Makefile    (working copy)
> @@ -97,6 +97,7 @@
>   JARS+=$(KUROMOJI_JAR)           # japanese analyzer module
>   JARS+=$(MEMORY_JAR)             # single-document memory index
>   JARS+=$(MISC_JAR)               # misc
> +JARS+=$(MONITOR_JAR)            # monitor
>   JARS+=$(MORFOLOGIK_JAR)         # morfologik analyzer module
>   JARS+=$(NORI_JAR)               # korean analyzer module
>   #JARS+=$(PHONETIC_JAR)           # phonetic analyzer module
> @@ -135,6 +136,7 @@
>
> KUROMOJI_JAR=$(LUCENE)/analysis/kuromoji/build/runtimeJars/lucene-analysis-kuromoji-$(LUCENE_VER)-SNAPSHOT.jar
>
> MEMORY_JAR=$(LUCENE)/memory/build/runtimeJars/lucene-memory-$(LUCENE_VER)-SNAPSHOT.jar
>
> MISC_JAR=$(LUCENE)/misc/build/runtimeJars/lucene-misc-$(LUCENE_VER)-SNAPSHOT.jar
>
> +MONITOR_JAR=$(LUCENE)/monitor/build/runtimeJars/lucene-monitor-$(LUCENE_VER)-SNAPSHOT.jar
>
> NORI_JAR=$(LUCENE)/analysis/nori/build/runtimeJars/lucene-analysis-nori-$(LUCENE_VER)-SNAPSHOT.jar
>
> PHONETIC_JAR=$(LUCENE)/analysis/phonetic/build/runtimeJars/lucene-analysis-phonetic-$(LUCENE_VER)-SNAPSHOT.jar
>
> QUERIES_JAR=$(LUCENE)/queries/build/runtimeJars/lucene-queries-$(LUCENE_VER)-SNAPSHOT.jar
> ------ SNIP ------
>
> Andi..
>

Reply via email to