Where communities thrive


  • Join over 1.5M+ people
  • Join over 100K+ communities
  • Free without limits
  • Create your own community
People
Repo info
Activity
Erik Johansson
@Eiken
But none of the validations had a status
Marcus Ottosson
@mottosso
Ah, yes. It has to do with the fact that Lite resets when you show it
So it'll be busy resetting when you call validate()
You can hack it
from Qt import QtCore
import pyblish_lite

window = pyblish_lite.show()
QtCore.QTimer.singleShot(2000, window.validate)
Now it'll validate 2 seconds after showing
But I wouldn't rely on it :)
You could potentially hook window.validate up to was_reset
Erik Johansson
@Eiken
i'll keep it vanilla without validate until i gather some feedback :)
Marcus Ottosson
@mottosso
Sweet :)
Erik Johansson
@Eiken
So I got some feedback. Is it possible to add a tooltip on the Validators which could more in detail describe the issue?
Like if the validator is called "Validate Transforms" how can I more in detail describe the issue for the artists if the actions don't manage to fix it
Anything you have thought of addin or is it already there but I can't find it?
Erik Johansson
@Eiken
kinda like you can add
label = "Collect Geometries"
there would be a
tooltip = """
foo bar foo bar foo bar ... foo bar
foo bar foo bar foo bar ... foo bar
foo bar foo bar foo bar ... foo bar
"""
ahhh middle mouse
nevermind
Erik Johansson
@Eiken
it's funny how you always find stuff directly after asking
Paweł
@p4vv37
I've got a problem with instance plugins, like: https://learn.pyblish.com/chapters/07-branching-ii.html
They just do not work. Context plugins work, but the code from this example simply does not
Why may this happen?
by the way: Hi :)
Toke Jepsen
@tokejepsen

it's funny how you always find stuff directly after asking

Haha, yeah. This would still be the area for the Perspective view to get a better overview of what a plugin does.

Toke Jepsen
@tokejepsen

Why may this happen?

I can't do this either. Maybe @mottosso has a clue? Looking at what would make this print out what you need.

Toke Jepsen
@tokejepsen

Hey @p4vv37,

There is something wrong with using such high values for the order, but it should support it. I'll make a bug issue about it. If you run the following code with smaller order values, it should output the expected result:

import pyblish.api

items = ["john", "door"]


class CollectInstances(pyblish.api.ContextPlugin):

    order = 0

    def process(self, context):
        for item in items:
            context.create_instance(item)


class PrintInstances(pyblish.api.InstancePlugin):

    order = 1

    def process(self, instance):
        print("Instance is: %s" % instance)

pyblish.api.register_plugin(CollectInstances)
pyblish.api.register_plugin(PrintInstances)

import pyblish.util
context = pyblish.util.publish()
pyblish/pyblish-base#301
Paweł
@p4vv37
It does work now.
But I do not think it is an issue with high numbers: the issue is, that one of the plugins has to have an order of "0".
If You'd set the orders to 1 and 2 it still would not run.
Toke Jepsen
@tokejepsen
Yeah, I've made an issue about it, so we can sort it out asap.
Paweł
@p4vv37
ok, anyway, thank You :)
Toke Jepsen
@tokejepsen
You should be able to continue with learn by example though :) Thanks for bringing this to our attention.
Marcus Ottosson
@mottosso
Thanks @p4vv37, that definitely smells like a problem.
Marcus Ottosson
@mottosso
Hey @p4vv37, I'm curious about your Pyblish_exe project
It looks like what I'm interested in making as well
A self-contained pyblish-qml
Could you tell us a little bit about it? :)
Paweł
@p4vv37
Well, there's not much to talk about, it's just an exe that runs only the server, created with a use of pyinstaller and Python 3.X. I want to run pyblish-qml on different machines which have only Maya's Python 2.7 available, so I thought that distributing such exe and running it from the script that opens the pyblish gui would be the easiest way to achieve this.
Alternatively, I guess, I'd have to install Python 3 on every one of them and then from the maya's python run the server in this other python before opening the gui in maya and that seems a lot more problematic.
Marcus Ottosson
@mottosso
Good thinking
Yes, you could do that; install on every machine
But what most people do, is install PyQt5 on a central location
And point their PYTHONPATHs to it
Or, store the entire Python 3 + PyQt5 centrally, and launch via that one
There's a standalone PyQt5 for Python 2, here: https://github.com/pyqt/python-qt5
Paweł
@p4vv37
Thanks, I'll check it
Marcus Ottosson
@mottosso
Hi @p4vv37, the bug you reported has now been fixed; it was a problem with the documentation, from 4 to 11 if you'd like to take another look at those.
Erik Johansson
@Eiken
simple question of the day probably
after running an action the validator is still red
even if the action succedes at fixing the issue
any way to make it green so you dont have to refresh and rerun validation?
Toke Jepsen
@tokejepsen
Do you have an action icon?
Erik Johansson
@Eiken
yes, the action icon turns green