Pyblish By Example
1.8
1.8
  • Introduction
  • Hello World
  • Quickstart
  • Files
  • Coordination
  • Architecture
  • Branching I
  • Branching II
  • Branching III
  • Sharing
  • Validating I
  • Validating II
  • CVEI I
  • CVEI II
  • CVEI III
  • CVEI IV
  • Data
  • Report I
  • Report II
  • Report III
  • Report IV
  • Report V
  • Callback I
  • Callback II
  • Callback III
  • Logging
  • Filtering
  • Next Steps
Powered by GitBook
On this page

Was this helpful?

CVEI IV

Sometimes you need more control over ordering, and that's when it can be useful to know that you can offset the built-in orders.

import pyblish.api

class PreCollector(pyblish.api.ContextPlugin):
  order = pyblish.api.CollectorOrder - 0.1

  def process(self, context):
    context.create_instance("SpecialInstance")


class Collector(pyblish.api.ContextPlugin):
  order = pyblish.api.CollectorOrder

  def process(self, context):
    special_instance = context["SpecialInstance"]
    special_instance.data["specialData"] = 42

You can offset any plug-in from negative 0.499.. to positive 0.499.. A value beyond that will inadvertently transition your plug-in into the next built-in order.

Ranges

-0.5 to 0.499.. = Collection
0.5 to 1.499.. = Validation
1.5 to 2.499.. = Extraction
2.5 to 3.499.. = Integration
PreviousCVEI IIINextData

Last updated 5 years ago

Was this helpful?