Skip to content

pac copilot pack rejects the workflows/ directory that clone and pull create #185

Description

Environment

  • PAC CLI 2.11.2+g47bc199
  • Windows 11
  • Dataverse environment in EMEA

Summary

pac copilot pack refuses to package an agent workspace that contains a
workflows/ directory. The same directory is produced by pac copilot clone,
recreated by pac copilot pull, and required by pac copilot push for an
agent flow definition to reach the environment.

The result is that a workspace which is valid for the inner development loop is
invalid for packaging, and the transition is silent until pack fails.

Repro

  1. Create or clone an agent workspace that contains an agent flow:

    my-agent/
      .mcs/
      agent.mcs.yml
      settings.mcs.yml
      topics/
      workflows/MyFlow-<guid>/
        metadata.yml
        workflow.json
    
  2. Run:

    pac copilot pack --publisher-prefix <prefix> --project-dir my-agent --output-path out
    

Actual

Error: ... is not a valid agent workspace. Unsupported directory: workflows/.

Expected

Either the directory is packaged, or it is ignored with a warning. Failing hard
on a directory that the tool itself creates is surprising.

Isolation

The cause was isolated with an A/B test: the identical workspace with
workflows/ removed packs successfully and produces a valid solution zip
containing bots/ and botcomponents/. Re-adding the directory reproduces the
error every time.

pac copilot pull recreates the directory on every pull, so a workspace that
was made packable reverts to unpackable after the next sync.

Why this matters for this repo

The plugin covers clone, push, pull and validation, but a CI pipeline that
ends in pac copilot pack plus pac solution import hits this immediately.
A check in the validate or manage-agent skill - "workspace contains
workflows/, pack will refuse it" - would catch it before the pipeline does.

Happy to contribute the check if that would be useful.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions