diff --git a/.github/workflows/project_actions.yml b/.github/workflows/project_actions.yml index b21946f0ee..3589b4acc2 100644 --- a/.github/workflows/project_actions.yml +++ b/.github/workflows/project_actions.yml @@ -25,7 +25,11 @@ jobs: if: | (github.event_name == 'issue_comment' && github.event.pull_request.head.repo.owner.login == 'ynput' && github.event.comment.user.id != 82967070) || (github.event_name == 'pull_request_review_comment' && github.event.pull_request.head.repo.owner.login == 'ynput' && github.event.comment.user.type != 'Bot') || - (github.event_name == 'pull_request_review' && github.event.pull_request.head.repo.owner.login == 'ynput' && github.event.review.state != 'changes_requested' && github.event.review.user.type != 'Bot') + (github.event_name == 'pull_request_review' && + github.event.pull_request.head.repo.owner.login == 'ynput' && + github.event.review.state != 'changes_requested' && + github.event.review.state != 'approved' && + github.event.review.user.type != 'Bot') steps: - name: Move PR to 'Review In Progress' uses: leonsteinhaeuser/project-beta-automations@v2.1.0 @@ -70,10 +74,7 @@ jobs: size-label: name: pr_size_label runs-on: ubuntu-latest - if: | - (github.event_name == 'pull_request' && github.event.action == 'assigned') || - (github.event_name == 'pull_request' && github.event.action == 'opened') - + if: github.event.action == 'assigned' || github.event.action == 'opened' steps: - name: Add size label uses: "pascalgn/size-label-action@v0.4.3" @@ -94,9 +95,7 @@ jobs: label_prs_branch: name: pr_branch_label runs-on: ubuntu-latest - if: | - (github.event_name == 'pull_request' && github.event.action == 'assigned') || - (github.event_name == 'pull_request' && github.event.action == 'opened') + if: github.event.action == 'assigned' || github.event.action == 'opened' steps: - name: Label PRs - Branch name detection uses: ffittschen/pr-branch-labeler@v1 @@ -106,9 +105,7 @@ jobs: label_prs_globe: name: pr_globe_label runs-on: ubuntu-latest - if: | - (github.event_name == 'pull_request' && github.event.action == 'assigned') || - (github.event_name == 'pull_request' && github.event.action == 'opened') + if: github.event.action == 'assigned' || github.event.action == 'opened' steps: - name: Label PRs - Globe detection uses: actions/labeler@v4.0.3 diff --git a/openpype/hosts/maya/plugins/create/create_review.py b/openpype/hosts/maya/plugins/create/create_review.py index 786c795a1a..75a1a5bf08 100644 --- a/openpype/hosts/maya/plugins/create/create_review.py +++ b/openpype/hosts/maya/plugins/create/create_review.py @@ -39,7 +39,7 @@ class CreateReview(plugin.Creator): super(CreateReview, self).__init__(*args, **kwargs) data = OrderedDict(**self.data) - project_name = legacy_io.Session["AVALON_PROJECT"] + project_name = get_current_project_name() profiles = get_project_settings( project_name )["maya"]["publish"]["ExtractPlayblast"]["profiles"] @@ -49,7 +49,7 @@ class CreateReview(plugin.Creator): self.log.warning("No profiles present for extract playblast.") else: asset_doc = get_asset_by_name(project_name, data["asset"]) - task_name = legacy_io.Session["AVALON_TASK"] + task_name = get_current_task_name() task_type = asset_doc["data"]["tasks"][task_name]["type"] filtering_criteria = { diff --git a/openpype/hosts/maya/plugins/publish/extract_thumbnail.py b/openpype/hosts/maya/plugins/publish/extract_thumbnail.py index ee64c11ca4..67d085e2f5 100644 --- a/openpype/hosts/maya/plugins/publish/extract_thumbnail.py +++ b/openpype/hosts/maya/plugins/publish/extract_thumbnail.py @@ -26,8 +26,9 @@ class ExtractThumbnail(publish.Extractor): families = ["review"] def process(self, instance): - project_name = legacy_io.Session["AVALON_PROJECT"] - profiles = get_project_settings( + project_name = instance.context.data["projectName"] + project_settings = instance.context.data["project_settings"] + profiles = project_settings["maya"]["publish"]["ExtractPlayblast"]["profiles"] project_name )["maya"]["publish"]["ExtractPlayblast"]["profiles"] diff --git a/openpype/pipeline/create/context.py b/openpype/pipeline/create/context.py index 22cab28e4b..382bbea05e 100644 --- a/openpype/pipeline/create/context.py +++ b/openpype/pipeline/create/context.py @@ -596,7 +596,14 @@ class AttributeValues(object): self[_key] = _value def pop(self, key, default=None): - return self._data.pop(key, default) + value = self._data.pop(key, default) + # Remove attribute definition if is 'UnknownDef' + # - gives option to get rid of unknown values + attr_def = self._attr_defs_by_key.get(key) + if isinstance(attr_def, UnknownDef): + self._attr_defs_by_key.pop(key) + self._attr_defs.remove(attr_def) + return value def reset_values(self): self._data = {} diff --git a/openpype/plugins/publish/collect_otio_review.py b/openpype/plugins/publish/collect_otio_review.py index 4d8147e70d..f0157282a1 100644 --- a/openpype/plugins/publish/collect_otio_review.py +++ b/openpype/plugins/publish/collect_otio_review.py @@ -87,7 +87,9 @@ class CollectOtioReview(pyblish.api.InstancePlugin): otio_review_clips.append(otio_gap) if otio_review_clips: - instance.data["label"] += " (review)" + # add review track to instance and change label to reflect it + label = instance.data.get("label", instance.data["subset"]) + instance.data["label"] = label + " (review)" instance.data["families"] += ["review", "ftrack"] instance.data["otioReviewClips"] = otio_review_clips self.log.info( diff --git a/openpype/settings/entities/color_entity.py b/openpype/settings/entities/color_entity.py index a542f2fa38..f838a6b0ad 100644 --- a/openpype/settings/entities/color_entity.py +++ b/openpype/settings/entities/color_entity.py @@ -11,10 +11,10 @@ class ColorEntity(InputEntity): def _item_initialization(self): self.valid_value_types = (list, ) + self.use_alpha = self.schema_data.get("use_alpha", True) self.value_on_not_set = self.convert_to_valid_type( self.schema_data.get("default", [0, 0, 0, 255]) ) - self.use_alpha = self.schema_data.get("use_alpha", True) def set_override_state(self, *args, **kwargs): super(ColorEntity, self).set_override_state(*args, **kwargs) @@ -66,6 +66,6 @@ class ColorEntity(InputEntity): new_value.append(item) # Make sure - if hasattr(self, "use_alpha") and not self.use_alpha: + if not self.use_alpha: new_value[3] = 255 return new_value