Kivy AttributeError: 'NoneType' object has no attribute 'ids'
Und da reicht alle halbe Stunde gucken nicht? Das muss fein granular einstellbar sein? Und warum schaltet man das überhaupt aus? Will man keine aktuellen Zahlen? Wenn man aktuelle Zahlen will, warum fragst du dann nicht ab, wenn der Benutzer interagiert?
Oh...
leider habe ich gerade bemerkt dass das ursprüngliche Themagegessen ist...
ich habe ein Popup mit einem Label erställt auf dem ein besonders günstiger Preis angezeigt werden soll.
kv code:
python code:
error:
womit wir wieder beim ursprünglichen Thema angekomne wären...
was kann ich dagegen tun?
leider habe ich gerade bemerkt dass das ursprüngliche Thema
doch noch nicht so ganz durchKivy AttributeError: 'NoneType' object has no attribute 'ids'
Code: Alles auswählen
def __init__(self):
super().__init__()
ich habe ein Popup mit einem Label erställt auf dem ein besonders günstiger Preis angezeigt werden soll.
kv code:
Code: Alles auswählen
#:import Factory kivy.factory.Factory
<CheapPricePopup@Popup>:
on_open: root.test()
title:"Es gibt derzeit günstiges Benzin"
size_hint: None,None
size: 500,500
auto_dismiss: False
BoxLayout:
orientation: "vertical"
ScrollView:
size_hint: None,None
size: 475,400
BoxLayout:
orientation: "vertical"
size_hint: None,None
height:1450
BoxLayout:
Label:
id:lalalal
text:"Preis:/Tankstelle"
Label:
text:"Benzinsorte:/Tankstelle:"
BoxLayout:
#orientation: "vertical"
Button:
size_hint_y: None
height: 100
text: "Okay"
on_release: root.dismiss()
Code: Alles auswählen
class CheapPricePopup(Popup):
def __init__(self):
super().__init__()
def test(self):
print("test")
Code: Alles auswählen
[INFO ] [Logger ] Record log in C:\Users\MupfSpace\.kivy\logs\kivy_19-02-09_51.txt
[INFO ] [Kivy ] v1.10.1
[INFO ] [Python ] v3.7.2 (tags/v3.7.2:9a3ffc0492, Dec 23 2018, 22:20:52) [MSC v.1916 32 bit (Intel)]
[INFO ] [Factory ] 194 symbols loaded
[INFO ] [Image ] Providers: img_tex, img_dds, img_sdl2, img_gif (img_pil, img_ffpyplayer ignored)
[INFO ] [Window ] Provider: sdl2
[INFO ] [GL ] Using the "OpenGL" graphics system
[INFO ] [GL ] GLEW initialization succeeded
[INFO ] [GL ] Backend used <glew>
[INFO ] [GL ] OpenGL version <b'4.5.0 - Build 22.20.16.4771'>
[INFO ] [GL ] OpenGL vendor <b'Intel'>
[INFO ] [GL ] OpenGL renderer <b'Intel(R) HD Graphics 620'>
[INFO ] [GL ] OpenGL parsed version: 4, 5
[INFO ] [GL ] Shading version <b'4.50 - Build 22.20.16.4771'>
[INFO ] [GL ] Texture max size <16384>
[INFO ] [GL ] Texture max units <32>
[INFO ] [Window ] auto add sdl2 input provider
[INFO ] [Window ] virtual keyboard not allowed, single mode, not docked
[INFO ] [Text ] Provider: sdl2
[WARNING] [Call to deprecated function __init__ in C]\Python37\lib\site-packages\kivy\uix\listview.py line 845.Called from C:\Python37\lib\site-packages\kivy\lang\builder.py line 582 by _apply_rule().
[WARNING] [Call to deprecated function __init__ in C]\Python37\lib\site-packages\kivy\adapters\simplelistadapter.py line 49.Called from C:\Python37\lib\site-packages\kivy\uix\listview.py line 859 by __init__().
[WARNING] [Call to deprecated function __init__ in C]\Python37\lib\site-packages\kivy\adapters\adapter.py line 111.Called from C:\Python37\lib\site-packages\kivy\adapters\simplelistadapter.py line 55 by __init__().
[WARNING] [Call to deprecated function __init__ in C]\Python37\lib\site-packages\kivy\uix\abstractview.py line 42.Called from C:\Python37\lib\site-packages\kivy\uix\listview.py line 865 by __init__().
[INFO ] [GL ] NPOT texture support is available
[WARNING] [Call to deprecated function __init__ in C]\Python37\lib\site-packages\kivy\adapters\listadapter.py line 185.Called from <string> line 634 by <module>().
[WARNING] [Call to deprecated function __init__ in C]\Python37\lib\site-packages\kivy\adapters\adapter.py line 111.Called from C:\Python37\lib\site-packages\kivy\adapters\listadapter.py line 186 by __init__().
Diesel;1.189;Super E10;1.229;Super E5;1.249;MaxxMotion: Super 100;1.429;MaxxMotion: Diesel;1.369
Autogas LPG;0.659;Diesel;1.269;Super E10;1.299;Super E5;1.319;SuperPlus;1.399
Diesel;1.199;Super E10;1.229;Super E5;1.269;V-Power: Racing;1.459;V-Power: Diesel;1.389;LKW Diesel;1.199
[INFO ] [Base ] Start application main loop
[WARNING] [Call to deprecated function __init__ in C]\Python37\lib\site-packages\kivy\uix\selectableview.py line 38.Called from C:\Python37\lib\site-packages\kivy\uix\listview.py line 593 by __init__().
[INFO ] [Base ] Leaving application in progress...
Traceback (most recent call last):
File "c:\Users\MupfSpace\.vscode\extensions\ms-python.python-2019.1.0\pythonFiles\ptvsd_launcher.py", line 45, in <module>
main(ptvsdArgs)
File "c:\Users\MupfSpace\.vscode\extensions\ms-python.python-2019.1.0\pythonFiles\lib\python\ptvsd\__main__.py", line 348, in main
run()
File "c:\Users\MupfSpace\.vscode\extensions\ms-python.python-2019.1.0\pythonFiles\lib\python\ptvsd\__main__.py", line 253, in run_file
runpy.run_path(target, run_name='__main__')
File "C:\Python37\lib\runpy.py", line 263, in run_path
pkg_name=pkg_name, script_name=fname)
File "C:\Python37\lib\runpy.py", line 96, in _run_module_code
mod_name, mod_spec, pkg_name, script_name)
File "C:\Python37\lib\runpy.py", line 85, in _run_code
exec(code, run_globals)
File "c:\Users\MupfSpace\Desktop\App test1\mainpy3v7.0.py", line 1101, in <module>
main()
File "c:\Users\MupfSpace\Desktop\App test1\mainpy3v7.0.py", line 1098, in main
app.run()
File "C:\Python37\lib\site-packages\kivy\app.py", line 826, in run
runTouchApp()
File "C:\Python37\lib\site-packages\kivy\base.py", line 502, in runTouchApp
EventLoop.window.mainloop()
File "C:\Python37\lib\site-packages\kivy\core\window\window_sdl2.py", line 727, in mainloop
self._mainloop()
File "C:\Python37\lib\site-packages\kivy\core\window\window_sdl2.py", line 460, in _mainloop
EventLoop.idle()
File "C:\Python37\lib\site-packages\kivy\base.py", line 337, in idle
Clock.tick()
File "C:\Python37\lib\site-packages\kivy\clock.py", line 581, in tick
self._process_events()
File "kivy\_clock.pyx", line 384, in kivy._clock.CyClockBase._process_events
File "kivy\_clock.pyx", line 414, in kivy._clock.CyClockBase._process_events
File "kivy\_clock.pyx", line 412, in kivy._clock.CyClockBase._process_events
File "kivy\_clock.pyx", line 167, in kivy._clock.ClockEvent.tick
File "C:\Python37\lib\site-packages\kivy\animation.py", line 352, in _update
self.stop(widget)
File "C:\Python37\lib\site-packages\kivy\animation.py", line 217, in stop
self.dispatch('on_complete', widget)
File "kivy\_event.pyx", line 703, in kivy._event.EventDispatcher.dispatch
File "kivy\_event.pyx", line 1214, in kivy._event.EventObservers.dispatch
File "kivy\_event.pyx", line 1138, in kivy._event.EventObservers._dispatch
File "C:\Python37\lib\site-packages\kivy\uix\modalview.py", line 195, in <lambda>
a.bind(on_complete=lambda *x: self.dispatch('on_open'))
File "kivy\_event.pyx", line 703, in kivy._event.EventDispatcher.dispatch
File "kivy\_event.pyx", line 1214, in kivy._event.EventObservers.dispatch
File "kivy\_event.pyx", line 1098, in kivy._event.EventObservers._dispatch
File "C:\Python37\lib\site-packages\kivy\lang\builder.py", line 64, in custom_callback
exec(__kvlang__.co_value, idmap)
File "<string>", line 7, in <module>
File "kivy\weakproxy.pyx", line 30, in kivy.weakproxy.WeakProxy.__getattr__
AttributeError: 'CheapPricePopup' object has no attribute 'test'
was kann ich dagegen tun?
- __blackjack__
- User
- Beiträge: 13117
- Registriert: Samstag 2. Juni 2018, 10:21
- Wohnort: 127.0.0.1
- Kontaktdaten:
@MupfSpace: Das `None` keine Attribute hat ist irgendwie nicht das gleiche Thema wie das `CheapPricePopup` ein Attribut nicht hat.
Lass mal das ``@Popup`` in der kv-Datei weg. Die `__init__()` macht so auch keinen Sinn – wenn man da eh nur die von der Basisklasse aufruft, kann man sie auch weglassen.
Falls das nicht hilft, wäre ein minimales, lauffähiges Beispiel nett, welches das Problem demonstriert, damit man das mal ausprobieren kann.
Lass mal das ``@Popup`` in der kv-Datei weg. Die `__init__()` macht so auch keinen Sinn – wenn man da eh nur die von der Basisklasse aufruft, kann man sie auch weglassen.
Falls das nicht hilft, wäre ein minimales, lauffähiges Beispiel nett, welches das Problem demonstriert, damit man das mal ausprobieren kann.
„All religions are the same: religion is basically guilt, with different holidays.” — Cathy Ladman
@__blackjack__
Danke das mit dem @popup weglassen funktioniert
@__deets__
Bist du jezt stolz auf mich?
Danke das mit dem @popup weglassen funktioniert
@__deets__
Ich hab das jezt mit einer einzigen .ini Datei und configparser und dem selbstgeschriebenen (aber unfertigen ) Modul iniparser gemacht.
Bist du jezt stolz auf mich?
Ich versuche jezt schon seit längerer Zeit etwas an der Benachrichtigung zu verändern.
Und zwar möchte ich das wenn man auf die Benachrichtigung clickt etwas passiert.
Mit plyer ist das anscheinend nicht möglich.
Ich habe im Internet nachgesehen und etwas über pyjnius gefunden davon aber nichts kapiert.
Ich habe außerdem auf einer github seite:
https://github.com/Bakterija/android-no ... on-buttons
Etwas über noti_builder Notification_Builder gefunden verstehe aber nicht was mit: Kopiere den noti_builder Ordner in den /Service Ordner.
Welche Service Ordner ist damit gemeint.
Oder gibt es noch andere Möglichkeiten Benachrichtigungen auf android zu erstellen?
Und zwar möchte ich das wenn man auf die Benachrichtigung clickt etwas passiert.
Mit plyer ist das anscheinend nicht möglich.
Ich habe im Internet nachgesehen und etwas über pyjnius gefunden davon aber nichts kapiert.
Ich habe außerdem auf einer github seite:
https://github.com/Bakterija/android-no ... on-buttons
Etwas über noti_builder Notification_Builder gefunden verstehe aber nicht was mit: Kopiere den noti_builder Ordner in den /Service Ordner.
Welche Service Ordner ist damit gemeint.
Oder gibt es noch andere Möglichkeiten Benachrichtigungen auf android zu erstellen?
Wenn es keine andere Möglichkeit gibt wie funktioniert das dann mit pyjnius und / oder noti_builder
Im Internet finde ich zwar immer wieder Sachen dazu aber meist sind das immer Dinge die nicht funktionieren.
Was kann ich tun?
Im Internet finde ich zwar immer wieder Sachen dazu aber meist sind das immer Dinge die nicht funktionieren.
Was kann ich tun?
Ich benutze kein Android. Ich kann das also auch nicht ausprobieren. Das von dir genannte Framework hat eine Beispielanwendung. Probier die zum laufen zu bringen Und frag beim Autor des Tools nach, wenn du damit Probleme hast. Dann gewinnst du hoffentlich Erkenntnisse, wie das funktioniert.
ich habe es nicht geschafft die Beispiel Anwendung zum laufen zu bringen
es könnte daran liegen dass "noti_builder" pyjnius verwendet:
Erste zeile von noti_builder:
ich habe es verucht zu installieren aber bekomme immer diesen fehler
es könnte daran liegen dass "noti_builder" pyjnius verwendet:
Erste zeile von noti_builder:
Code: Alles auswählen
from jnius import autoclass, detach
Code: Alles auswählen
Collecting pyjnius
Using cached https://files.pythonhosted.org/packages/b6/57/c90acf31322e6417f06c90410dbfcb149633a6006b7efbf99dfebe177c1f/pyjnius-1.2.0.tar.gz
Requirement already satisfied: six>=1.7.0 in c:\users\mupfspace\appdata\roaming\python\python37\site-packages (from pyjnius) (1.12.0)
Requirement already satisfied: cython in c:\python37\lib\site-packages (from pyjnius) (0.29.6)
Building wheels for collected packages: pyjnius
Building wheel for pyjnius (setup.py) ... error
Complete output from command c:\python37\python.exe -u -c "import setuptools, tokenize;__file__='C:\\Users\\MUPFSP~1\\AppData\\Local\\Temp\\pip-install-6x0l7_5g\\pyjnius\\setup.py';f=getattr(tokenize, 'open', open)(__file__);code=f.read().replace('\r\n', '\n');f.close();exec(compile(code, __file__, 'exec'))" bdist_wheel -d C:\Users\MUPFSP~1\AppData\Local\Temp\pip-wheel-p37h30j9 --python-tag cp37:
WARNING: Not able to assign machine() = AMD64 to a cpu value!
Using cpu = 'i386' instead!
JDK_HOME: C:\Program Files\Java\jdk-11.0.2\bin
JRE_HOME: None
warning: [options] bootstrap class path not set in conjunction with -source 6
warning: [options] source value 6 is obsolete and will be removed in a future release
warning: [options] target value 1.6 is obsolete and will be removed in a future release
warning: [options] To suppress warnings about obsolete options, use -Xlint:-options.
4 warnings
running bdist_wheel
running build
running build_py
creating build
creating build\lib.win32-3.7
copying jnius_config.py -> build\lib.win32-3.7
creating build\lib.win32-3.7\jnius
copying jnius\reflect.py -> build\lib.win32-3.7\jnius
copying jnius\signatures.py -> build\lib.win32-3.7\jnius
copying jnius\__init__.py -> build\lib.win32-3.7\jnius
creating build\lib.win32-3.7\jnius\src
creating build\lib.win32-3.7\jnius\src\org
creating build\lib.win32-3.7\jnius\src\org\jnius
copying jnius\src\org\jnius\NativeInvocationHandler.class -> build\lib.win32-3.7\jnius\src\org\jnius
copying jnius\src\org\jnius\NativeInvocationHandler.java -> build\lib.win32-3.7\jnius\src\org\jnius
running build_ext
cythoning jnius\jnius.pyx to jnius\jnius.c
c:\python37\lib\site-packages\Cython\Compiler\Main.py:367: FutureWarning: Cython directive 'language_level' not set, using 2 for now (Py2). This will change in a later release! File: C:\Users\MUPFSP~1\AppData\Local\Temp\pip-install-6x0l7_5g\pyjnius\jnius\jnius.pyx
tree = Parsing.p_module(s, pxd, full_module_name)
building 'jnius' extension
creating build\temp.win32-3.7
creating build\temp.win32-3.7\Release
creating build\temp.win32-3.7\Release\jnius
C:\Program Files (x86)\Microsoft Visual Studio\2017\Community\VC\Tools\MSVC\14.16.27023\bin\HostX86\x86\cl.exe /c /nologo /Ox /W3 /GL /DNDEBUG /MD "-IC:\Program Files\Java\jdk-11.0.2\bin\include" "-IC:\Program Files\Java\jdk-11.0.2\bin\include\win32" -Ic:\python37\include -Ic:\python37\include "-IC:\Program Files (x86)\Microsoft Visual Studio\2017\Community\VC\Tools\MSVC\14.16.27023\ATLMFC\include" "-IC:\Program Files (x86)\Microsoft Visual Studio\2017\Community\VC\Tools\MSVC\14.16.27023\include" "-IC:\Program Files (x86)\Windows Kits\10\include\10.0.17763.0\ucrt" "-IC:\Program Files (x86)\Windows Kits\10\include\10.0.17763.0\shared" "-IC:\Program Files (x86)\Windows Kits\10\include\10.0.17763.0\um" "-IC:\Program Files (x86)\Windows Kits\10\include\10.0.17763.0\winrt" "-IC:\Program Files (x86)\Windows Kits\10\include\10.0.17763.0\cppwinrt" /Tcjnius\jnius.c /Fobuild\temp.win32-3.7\Release\jnius\jnius.obj
jnius.c
jnius\jnius.c(593): fatal error C1083: Datei (Include) kann nicht ge”ffnet werden: "jni.h": No such file or directory
error: command 'C:\\Program Files (x86)\\Microsoft Visual Studio\\2017\\Community\\VC\\Tools\\MSVC\\14.16.27023\\bin\\HostX86\\x86\\cl.exe' failed with exit status 2
----------------------------------------
Failed building wheel for pyjnius
Running setup.py clean for pyjnius
Failed to build pyjnius
Installing collected packages: pyjnius
Running setup.py install for pyjnius ... error
Complete output from command c:\python37\python.exe -u -c "import setuptools, tokenize;__file__='C:\\Users\\MUPFSP~1\\AppData\\Local\\Temp\\pip-install-6x0l7_5g\\pyjnius\\setup.py';f=getattr(tokenize, 'open', open)(__file__);code=f.read().replace('\r\n', '\n');f.close();exec(compile(code, __file__, 'exec'))" install --record C:\Users\MUPFSP~1\AppData\Local\Temp\pip-record-438q2p2q\install-record.txt --single-version-externally-managed --compile:
WARNING: Not able to assign machine() = AMD64 to a cpu value!
Using cpu = 'i386' instead!
JDK_HOME: C:\Program Files\Java\jdk-11.0.2\bin
JRE_HOME: None
warning: [options] bootstrap class path not set in conjunction with -source 6
warning: [options] source value 6 is obsolete and will be removed in a future release
warning: [options] target value 1.6 is obsolete and will be removed in a future release
warning: [options] To suppress warnings about obsolete options, use -Xlint:-options.
4 warnings
running install
running build
running build_py
creating build
creating build\lib.win32-3.7
copying jnius_config.py -> build\lib.win32-3.7
creating build\lib.win32-3.7\jnius
copying jnius\reflect.py -> build\lib.win32-3.7\jnius
copying jnius\signatures.py -> build\lib.win32-3.7\jnius
copying jnius\__init__.py -> build\lib.win32-3.7\jnius
creating build\lib.win32-3.7\jnius\src
creating build\lib.win32-3.7\jnius\src\org
creating build\lib.win32-3.7\jnius\src\org\jnius
copying jnius\src\org\jnius\NativeInvocationHandler.class -> build\lib.win32-3.7\jnius\src\org\jnius
copying jnius\src\org\jnius\NativeInvocationHandler.java -> build\lib.win32-3.7\jnius\src\org\jnius
running build_ext
skipping 'jnius\jnius.c' Cython extension (up-to-date)
building 'jnius' extension
creating build\temp.win32-3.7
creating build\temp.win32-3.7\Release
creating build\temp.win32-3.7\Release\jnius
C:\Program Files (x86)\Microsoft Visual Studio\2017\Community\VC\Tools\MSVC\14.16.27023\bin\HostX86\x86\cl.exe /c /nologo /Ox /W3 /GL /DNDEBUG /MD "-IC:\Program Files\Java\jdk-11.0.2\bin\include" "-IC:\Program Files\Java\jdk-11.0.2\bin\include\win32" -Ic:\python37\include -Ic:\python37\include "-IC:\Program Files (x86)\Microsoft Visual Studio\2017\Community\VC\Tools\MSVC\14.16.27023\ATLMFC\include" "-IC:\Program Files (x86)\Microsoft Visual Studio\2017\Community\VC\Tools\MSVC\14.16.27023\include" "-IC:\Program Files (x86)\Windows Kits\10\include\10.0.17763.0\ucrt" "-IC:\Program Files (x86)\Windows Kits\10\include\10.0.17763.0\shared" "-IC:\Program Files (x86)\Windows Kits\10\include\10.0.17763.0\um" "-IC:\Program Files (x86)\Windows Kits\10\include\10.0.17763.0\winrt" "-IC:\Program Files (x86)\Windows Kits\10\include\10.0.17763.0\cppwinrt" /Tcjnius\jnius.c /Fobuild\temp.win32-3.7\Release\jnius\jnius.obj
jnius.c
jnius\jnius.c(593): fatal error C1083: Datei (Include) kann nicht ge”ffnet werden: "jni.h": No such file or directory
error: command 'C:\\Program Files (x86)\\Microsoft Visual Studio\\2017\\Community\\VC\\Tools\\MSVC\\14.16.27023\\bin\\HostX86\\x86\\cl.exe' failed with exit status 2
----------------------------------------
Command "c:\python37\python.exe -u -c "import setuptools, tokenize;__file__='C:\\Users\\MUPFSP~1\\AppData\\Local\\Temp\\pip-install-6x0l7_5g\\pyjnius\\setup.py';f=getattr(tokenize, 'open', open)(__file__);code=f.read().replace('\r\n', '\n');f.close();exec(compile(code, __file__, 'exec'))" install --record C:\Users\MUPFSP~1\AppData\Local\Temp\pip-record-438q2p2q\install-record.txt --single-version-externally-managed --compile" failed with error code 1 in C:\Users\MUPFSP~1\AppData\Local\Temp\pip-install-6x0l7_5g\pyjnius\
Kenne mich mit Python-auf-Android nicht aus, aber dein Android hat garantiert kein x86er CPU. Kann es sein, dass du das fuer das normale System und dein Python da installierst? Das geht dann wohl in die Hose.
Aber wie gesagt, da kenne ich mich nicht aus. Ich benutze iOS.
Aber wie gesagt, da kenne ich mich nicht aus. Ich benutze iOS.
@ Deets
Das Überascht mich jetzt
Ich hätte vermutet du bist der Root-Android-Kali-Linux-Lineageos Smartphone User schlechthin und kein schnödes "Apfel aus der Box"
@MS
Schau dir mal diese Gruppe an
https://groups.google.com/forum/embed/# ... kivy-users da sind viele Infos und Probleme bereits beschrieben. Vielleicht findest du da etwas.
AUßER dein Fehler! Ich würde vermuten du nutzt eine IDE auf Windows und so wie es eben aussieht wird dieser Code auch auf Win ausgeführ und nicht auf dem Handy. Interpreter richtig gesetzt?
Das Überascht mich jetzt
Ich hätte vermutet du bist der Root-Android-Kali-Linux-Lineageos Smartphone User schlechthin und kein schnödes "Apfel aus der Box"
@MS
Schau dir mal diese Gruppe an
https://groups.google.com/forum/embed/# ... kivy-users da sind viele Infos und Probleme bereits beschrieben. Vielleicht findest du da etwas.
AUßER dein Fehler! Ich würde vermuten du nutzt eine IDE auf Windows und so wie es eben aussieht wird dieser Code auch auf Win ausgeführ und nicht auf dem Handy. Interpreter richtig gesetzt?
Laut Doku funktioniert der Install auf Android auch nicht mit Pip
https://pyjnius.readthedocs.io/en/stabl ... or-android
https://pyjnius.readthedocs.io/en/stabl ... or-android
Ja um dann die App auf Android zu verwenden musst ich mit buildozer eine apk erstellen. Aber damit die Sachen von pyjnius in die Apk kommen muss ich es erst auf dem Computer installieren und da kommt eben der Fehler:
Code: Alles auswählen
Collecting pyjnius
Using cached https://files.pythonhosted.org/packages/b6/57/c90acf31322e6417f06c90410dbfcb149633a6006b7efbf99dfebe177c1f/pyjnius-1.2.0.tar.gz
Requirement already satisfied: six>=1.7.0 in c:\users\mupfspace\appdata\roaming\python\python37\site-packages (from pyjnius) (1.12.0)
Requirement already satisfied: cython in c:\python37\lib\site-packages (from pyjnius) (0.29.6)
Building wheels for collected packages: pyjnius
Building wheel for pyjnius (setup.py) ... error
Complete output from command c:\python37\python.exe -u -c "import setuptools, tokenize;__file__='C:\\Users\\MUPFSP~1\\AppData\\Local\\Temp\\pip-install-6x0l7_5g\\pyjnius\\setup.py';f=getattr(tokenize, 'open', open)(__file__);code=f.read().replace('\r\n', '\n');f.close();exec(compile(code, __file__, 'exec'))" bdist_wheel -d C:\Users\MUPFSP~1\AppData\Local\Temp\pip-wheel-p37h30j9 --python-tag cp37:
WARNING: Not able to assign machine() = AMD64 to a cpu value!
Using cpu = 'i386' instead!
JDK_HOME: C:\Program Files\Java\jdk-11.0.2\bin
JRE_HOME: None
warning: [options] bootstrap class path not set in conjunction with -source 6
warning: [options] source value 6 is obsolete and will be removed in a future release
warning: [options] target value 1.6 is obsolete and will be removed in a future release
warning: [options] To suppress warnings about obsolete options, use -Xlint:-options.
4 warnings
running bdist_wheel
running build
running build_py
creating build
creating build\lib.win32-3.7
copying jnius_config.py -> build\lib.win32-3.7
creating build\lib.win32-3.7\jnius
copying jnius\reflect.py -> build\lib.win32-3.7\jnius
copying jnius\signatures.py -> build\lib.win32-3.7\jnius
copying jnius\__init__.py -> build\lib.win32-3.7\jnius
creating build\lib.win32-3.7\jnius\src
creating build\lib.win32-3.7\jnius\src\org
creating build\lib.win32-3.7\jnius\src\org\jnius
copying jnius\src\org\jnius\NativeInvocationHandler.class -> build\lib.win32-3.7\jnius\src\org\jnius
copying jnius\src\org\jnius\NativeInvocationHandler.java -> build\lib.win32-3.7\jnius\src\org\jnius
running build_ext
cythoning jnius\jnius.pyx to jnius\jnius.c
c:\python37\lib\site-packages\Cython\Compiler\Main.py:367: FutureWarning: Cython directive 'language_level' not set, using 2 for now (Py2). This will change in a later release! File: C:\Users\MUPFSP~1\AppData\Local\Temp\pip-install-6x0l7_5g\pyjnius\jnius\jnius.pyx
tree = Parsing.p_module(s, pxd, full_module_name)
building 'jnius' extension
creating build\temp.win32-3.7
creating build\temp.win32-3.7\Release
creating build\temp.win32-3.7\Release\jnius
C:\Program Files (x86)\Microsoft Visual Studio\2017\Community\VC\Tools\MSVC\14.16.27023\bin\HostX86\x86\cl.exe /c /nologo /Ox /W3 /GL /DNDEBUG /MD "-IC:\Program Files\Java\jdk-11.0.2\bin\include" "-IC:\Program Files\Java\jdk-11.0.2\bin\include\win32" -Ic:\python37\include -Ic:\python37\include "-IC:\Program Files (x86)\Microsoft Visual Studio\2017\Community\VC\Tools\MSVC\14.16.27023\ATLMFC\include" "-IC:\Program Files (x86)\Microsoft Visual Studio\2017\Community\VC\Tools\MSVC\14.16.27023\include" "-IC:\Program Files (x86)\Windows Kits\10\include\10.0.17763.0\ucrt" "-IC:\Program Files (x86)\Windows Kits\10\include\10.0.17763.0\shared" "-IC:\Program Files (x86)\Windows Kits\10\include\10.0.17763.0\um" "-IC:\Program Files (x86)\Windows Kits\10\include\10.0.17763.0\winrt" "-IC:\Program Files (x86)\Windows Kits\10\include\10.0.17763.0\cppwinrt" /Tcjnius\jnius.c /Fobuild\temp.win32-3.7\Release\jnius\jnius.obj
jnius.c
jnius\jnius.c(593): fatal error C1083: Datei (Include) kann nicht ge”ffnet werden: "jni.h": No such file or directory
error: command 'C:\\Program Files (x86)\\Microsoft Visual Studio\\2017\\Community\\VC\\Tools\\MSVC\\14.16.27023\\bin\\HostX86\\x86\\cl.exe' failed with exit status 2
----------------------------------------
Failed building wheel for pyjnius
Running setup.py clean for pyjnius
Failed to build pyjnius
Installing collected packages: pyjnius
Running setup.py install for pyjnius ... error
Complete output from command c:\python37\python.exe -u -c "import setuptools, tokenize;__file__='C:\\Users\\MUPFSP~1\\AppData\\Local\\Temp\\pip-install-6x0l7_5g\\pyjnius\\setup.py';f=getattr(tokenize, 'open', open)(__file__);code=f.read().replace('\r\n', '\n');f.close();exec(compile(code, __file__, 'exec'))" install --record C:\Users\MUPFSP~1\AppData\Local\Temp\pip-record-438q2p2q\install-record.txt --single-version-externally-managed --compile:
WARNING: Not able to assign machine() = AMD64 to a cpu value!
Using cpu = 'i386' instead!
JDK_HOME: C:\Program Files\Java\jdk-11.0.2\bin
JRE_HOME: None
warning: [options] bootstrap class path not set in conjunction with -source 6
warning: [options] source value 6 is obsolete and will be removed in a future release
warning: [options] target value 1.6 is obsolete and will be removed in a future release
warning: [options] To suppress warnings about obsolete options, use -Xlint:-options.
4 warnings
running install
running build
running build_py
creating build
creating build\lib.win32-3.7
copying jnius_config.py -> build\lib.win32-3.7
creating build\lib.win32-3.7\jnius
copying jnius\reflect.py -> build\lib.win32-3.7\jnius
copying jnius\signatures.py -> build\lib.win32-3.7\jnius
copying jnius\__init__.py -> build\lib.win32-3.7\jnius
creating build\lib.win32-3.7\jnius\src
creating build\lib.win32-3.7\jnius\src\org
creating build\lib.win32-3.7\jnius\src\org\jnius
copying jnius\src\org\jnius\NativeInvocationHandler.class -> build\lib.win32-3.7\jnius\src\org\jnius
copying jnius\src\org\jnius\NativeInvocationHandler.java -> build\lib.win32-3.7\jnius\src\org\jnius
running build_ext
skipping 'jnius\jnius.c' Cython extension (up-to-date)
building 'jnius' extension
creating build\temp.win32-3.7
creating build\temp.win32-3.7\Release
creating build\temp.win32-3.7\Release\jnius
C:\Program Files (x86)\Microsoft Visual Studio\2017\Community\VC\Tools\MSVC\14.16.27023\bin\HostX86\x86\cl.exe /c /nologo /Ox /W3 /GL /DNDEBUG /MD "-IC:\Program Files\Java\jdk-11.0.2\bin\include" "-IC:\Program Files\Java\jdk-11.0.2\bin\include\win32" -Ic:\python37\include -Ic:\python37\include "-IC:\Program Files (x86)\Microsoft Visual Studio\2017\Community\VC\Tools\MSVC\14.16.27023\ATLMFC\include" "-IC:\Program Files (x86)\Microsoft Visual Studio\2017\Community\VC\Tools\MSVC\14.16.27023\include" "-IC:\Program Files (x86)\Windows Kits\10\include\10.0.17763.0\ucrt" "-IC:\Program Files (x86)\Windows Kits\10\include\10.0.17763.0\shared" "-IC:\Program Files (x86)\Windows Kits\10\include\10.0.17763.0\um" "-IC:\Program Files (x86)\Windows Kits\10\include\10.0.17763.0\winrt" "-IC:\Program Files (x86)\Windows Kits\10\include\10.0.17763.0\cppwinrt" /Tcjnius\jnius.c /Fobuild\temp.win32-3.7\Release\jnius\jnius.obj
jnius.c
jnius\jnius.c(593): fatal error C1083: Datei (Include) kann nicht ge”ffnet werden: "jni.h": No such file or directory
error: command 'C:\\Program Files (x86)\\Microsoft Visual Studio\\2017\\Community\\VC\\Tools\\MSVC\\14.16.27023\\bin\\HostX86\\x86\\cl.exe' failed with exit status 2
----------------------------------------
Command "c:\python37\python.exe -u -c "import setuptools, tokenize;__file__='C:\\Users\\MUPFSP~1\\AppData\\Local\\Temp\\pip-install-6x0l7_5g\\pyjnius\\setup.py';f=getattr(tokenize, 'open', open)(__file__);code=f.read().replace('\r\n', '\n');f.close();exec(compile(code, __file__, 'exec'))" install --record C:\Users\MUPFSP~1\AppData\Local\Temp\pip-record-438q2p2q\install-record.txt --single-version-externally-managed --compile" failed with error code 1 in C:\Users\MUPFSP~1\AppData\Local\Temp\pip-install-6x0l7_5g\pyjnius\
Auf dem Screenshot hast du versucht pyjnius via pip zu installieren.
Von dem Javakram hab ich noch weniger Ahnung als mit Python. Aber Google sagt was mit "path"
https://stackoverflow.com/questions/111 ... er-windows
Hast du den gemäß der pyjnius Doku die Pfade gesetzt?
https://pyjnius.readthedocs.io/en/stabl ... or-windows
Cave! Reine Mutmaßung! Ich hab kein Plan davon
Von dem Javakram hab ich noch weniger Ahnung als mit Python. Aber Google sagt was mit "path"
https://stackoverflow.com/questions/111 ... er-windows
Hast du den gemäß der pyjnius Doku die Pfade gesetzt?
https://pyjnius.readthedocs.io/en/stabl ... or-windows
Cave! Reine Mutmaßung! Ich hab kein Plan davon