Hi all,

I'm trying to understand pyblish and I'm getting a problem just at the
beginning :)

I want to get this example working (
https://gist.github.com/mottosso/93399862c94f0ab4314f ) but substituting
pyblish_maya by my own.

So I register the host through a function like pyblish_maya.setup() but
they don't show as registered hosts outside my function.

I wrote in the script editor:
import fbShotGum.publish
fbShotGum.publish.register_host()

where  fbShotGum.publish.register_host() is:
def register_host():
    """Register supported hosts"""
    print(pyblish.api.registered_hosts())
    pyblish.api.register_host("mayabatch")
    pyblish.api.register_host("mayapy")
    pyblish.api.register_host("maya")
    print(pyblish.api.registered_hosts())

and I get this output:
['python']
['python', 'mayabatch', 'mayapy', 'maya']

but now if I write:
import pyblish.api
pyblish.api.registered_hosts()

I only get ['python']

So when I try to register the "ExtractRig" plugin like in the "Learn
Pyblish By Example - Quickstart 1.4" example, I can't because "maya" host
is not registered.

I suppose they are in different scopes? But I'm just trying to follow that
example. So what I'm doing wrong?

Thank you,
Miguel

-- 
You received this message because you are subscribed to the Google Groups 
"Python Programming for Autodesk Maya" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to python_inside_maya+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/python_inside_maya/CABbyGYxN3Z83SqEw7DUR31RRPUqvumRUOni6giGxNYgbUGiSmg%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to