Skip to content

Plugin infrastructure relies on type_name, despite non-uniqueness guarantees #20128

Open
@GhostMinerPlus

Description

@GhostMinerPlus

What problem does this solve or what need does it fill?

Here now, it seems that we use type names to check if a plugin has been added:
Image
But acturally, the type name is not a unique identifier in rust:
Image
So I think it is possible for different plugins to have the same type name. Once it happeded, our method above may lead to errors

What solution would you like?

Maybe we can use the TypeId instead

What alternative(s) have you considered?

...

Additional context

...

Metadata

Metadata

Assignees

No one assigned

    Labels

    A-AppBevy apps and pluginsC-BugAn unexpected or incorrect behaviorC-Code-QualityA section of code that is hard to understand or changeD-StraightforwardSimple bug fixes and API improvements, docs, test and examplesS-Ready-For-ImplementationThis issue is ready for an implementation PR. Go for it!X-ContentiousThere are nontrivial implications that should be thought through

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions