0

I have the following custom script created for blender https://github.com/Korchy/Ozbend_Engraving_Internal

Im trying to use it via SSH like this

blender -b -P __init__.py

But im getting the following error
AL lib: (WW) alc_initconfig: Failed to initialize backend "pulse"
ALSA lib confmisc.c:767:(parse_card) cannot find card '0'
ALSA lib conf.c:4528:(_snd_config_evaluate) function snd_func_card_driver returned error: No such file or directory
ALSA lib confmisc.c:392:(snd_func_concat) error evaluating strings
ALSA lib conf.c:4528:(_snd_config_evaluate) function snd_func_concat returned error: No such file or directory
ALSA lib confmisc.c:1246:(snd_func_refer) error evaluating name
ALSA lib conf.c:4528:(_snd_config_evaluate) function snd_func_refer returned error: No such file or directory
ALSA lib conf.c:5007:(snd_config_expand) Evaluate error: No such file or directory
    ALSA lib pcm.c:2501:(snd_pcm_open_noupdate) Unknown PCM default
    AL lib: (EE) ALCplaybackAlsa_open: Could not open playback device 'default': No such file or directory
Traceback (most recent call last):
  File "/home/solomio/public_html/engravingcreator/__init__.py", line 19, in <module>
    from . import engraving_internal_ops
SystemError: Parent module '' not loaded, cannot perform relative import

How can i solve this ?

5
  • There is no critical error in presented log (no sound - but it is fine). From what you've presented it looks like the script finished its exectuion. What does you script contain? What do you think it should do? What makes you think didn't run? Commented Apr 11, 2018 at 13:35
  • The script should take an image + scene + an object and render an image Commented Apr 11, 2018 at 13:38
  • I hae added 3 more lines on the error log Commented Apr 11, 2018 at 13:41
  • Take what image? What scene? Render to where? It's all unspecified, so it is a speculation or false expectations. Error is self-descriptive, but take a look at 'your' script, its only 10 lines of code. It calls register in main context, that is all. At best case it registers operators in blender, but said operator will never be called because there is no code to do so. It is supposed to be called interactively via GUI (which it adds itself to) or by writing separate script that will specify all required parameters, call operator, and save result somewhere. Commented Apr 11, 2018 at 13:50
  • I.e. you need to install addon via UI, enable it, save user defaults - then you can use it from background script, which you need to write. Commented Apr 11, 2018 at 13:51

1 Answer 1

1

The "script" you are trying to run is an addon. You don't run that script, you install and enable the addon to add extra features to blender. Once the addon is enabled you can run a python script that runs the operator it provides, similar to any built-in operators.

This answer shows how to automate that while running blender in the background, for the addon you link to, download a zip of the repo and pass the path to the zip file to addon_install.

The command to make the addon perform should be bpy.ops.engravinginternal.start()

Sign up to request clarification or add additional context in comments.

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.