pygobject / pycairo

Python bindings for cairo
https://pycairo.readthedocs.io
Other
613 stars 83 forks source link

Pydroid 3 subprocess error #314

Closed Nsifiok closed 1 year ago

Nsifiok commented 1 year ago

I had an error arising from the subprocess on installation of pycairo on the pip of pydroid 3

stuaxo commented 1 year ago

Can you paste the error here ?

Nsifiok commented 1 year ago
    note: This error originates from a subprocess, and is likely not a problem with pip.
    ERROR: Failed building wheel for pycairo
  Failed to build pycairo
  ERROR: Could not build wheels for pycairo, which is required to install pyproject.toml-based projects
  [end of output]

note: This error originates from a subprocess, and is likely not a problem with pip. error: subprocess-exited-with-error

× pip subprocess to install build dependencies did not run successfully. │ exit code: 1 ╰─> See above for output.

Nsifiok commented 1 year ago

The whole problem started from 'pip install pyobject' to run a tkinter code. This is part (beginning) of it: import tkinter as tk from playsound import playsound

class RingtoneRadioButton(tk.Frame): def init(self, master=None, text="", value=None, ringtone=None, kwargs): super().init(master, kwargs) self.var = tk.StringVar(value=value) self.radio_button = tk.Radiobutton(self, text=text, var=self.var, value=value, bd=0, highlightthickness=0, \

stuaxo commented 1 year ago

I has a quick play with pydroid + the example. It looks like the playsound library doesn't know about Android and it is treating it like Linux + expecting pygobject to work.

It may be worth opening a bug with the playsound library to support Pydroid on Android, in the meantime try using something else to play a sound, see this example - https://stackoverflow.com/questions/70600035/how-to-play-audio-on-pydroid3