Skip to content

[Bug]: Avalonia VS previewer no longer sees my configured previewer host project #200

Open

Description

@TomEdwardsEnscape

Describe the bug

We have multiple projects for which the real BuildAvaloniaApp entry point cannot be used for the Avalonia VS Previewer. The reasons are things such as the project being a plugin for another application or being an OS service, so nothing which can be changed.

For these projects we have set up supporting test projects which mock dependencies and generally alter the setup of the Avalonia application to create something which can load our views in both the Avalonia VS Previewer and our unit tests.

These projects no longer appear in the VS Previewer's project select combo box. This is probably related to the change "Smarter previewer project selection and remembering" in version 12.3.0 of the VS Extension. This issue prevents us from using the previewer at all.

The projects which do appear can be class libraries or console applications, so this doesn't seem to be the problem. Is the new logic specifically excluding test projects?

To Reproduce

Unknown

Product(s)

Avalonia for Visual Studio

Platform

Windows

License Tier

Pro

Avalonia version

12.1.2

Tool/Control Version

12.3.1.0

Relevant log output

Additional context

No response

Activity

  1. mrlacey commented on Sep 30, 2026

    @mrlacey
    Contributor

    on it.

  2. mrlacey commented on Sep 30, 2026

    @mrlacey
    Contributor

    I'm testing a hotfix release for this with a view to releasing it tomorrow.

  3. mrlacey commented on Oct 1, 2026

    @mrlacey
    Contributor

    Version 12.3.2 is now in the marketplace and includes a fix that addresses this issue.
    If you find you still have issues, please let us know.

    Sorry again that you had this problem. The change that caused this was intended to help those who were seeing lots of entries in the list that were inappropriate. We were obviously a bit too enthusiastic in what was filtered out.

  4. TomEdwardsEnscape commented on Oct 1, 2026

    @TomEdwardsEnscape
    Author

    Thank you for the quick response, the previewer now works again.

    Alongside the test project containing our special AppBuilder, the change reintroduces quite a lot of other test projects to the list which shouldn't be there because they always fail with this error:

    Unable to resolve AppBuilder from [foo] assembly. AutoGeneratedProgram should include BuildAvaloniaApp method. Or assembly should contain Application subtype.

    These ones can definitely be removed.

  5. reopened this on Oct 1, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions