Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

cmd: Unwrap adapter modules to get underlying modules #5624

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

WeidiDeng
Copy link
Member

Fix 5621.

In addition, this also fixed several add(remove)-package related commands as they can't be used to add or remove adapter related modules.

Before,

image

After,

image

Copy link
Member

@mholt mholt left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Oh, thanks for this!

I was kind of thinking that we should rethink this command...

Technically, by "modules" I mean "config modules" i.e. an extension of the configuration.

I wonder if this command should actually be "list-plugins" to list all the plugins.

Or maybe the semantics shouldn't matter and we should just print everything.

The problem is that config adapters don't keep the same interface as a Caddy module... so we'd have to figure that out.

Can we talk about a fix where we don't wrap the adapters in the first place? I think I'd like that better. 😁

@mholt mholt added the under review 🧐 Review is pending before merging label Jul 10, 2023
@WeidiDeng
Copy link
Member Author

You mean adapters are not part of modules, and will not show as so. However, they will show in the new list-plugin command?

They are of course affected by add / remove package commands.

@WeidiDeng
Copy link
Member Author

What should be the definition of a plugin? Maybe just config-adapters are more expressive?

@francislavoie francislavoie changed the title fix: unwrap adapter modules to get underlying modules cmd: Unwrap adapter modules to get underlying modules Jul 10, 2023
@francislavoie francislavoie added the bug 🐞 Something isn't working label Jul 10, 2023
@francislavoie francislavoie added this to the v2.7.0 milestone Jul 10, 2023
@mholt
Copy link
Member

mholt commented Jul 10, 2023

Well, I'm not sure if a new list-plugins command is the right answer -- maybe it is. I need to think about it more, or maybe have a discussion about other good solutions.

@mholt mholt modified the milestones: v2.7.0, v2.7.1 Jul 25, 2023
@mholt mholt modified the milestones: v2.7.1, v2.7.2 Aug 3, 2023
@francislavoie francislavoie modified the milestones: v2.7.2, v2.7.3 Aug 3, 2023
@mholt mholt modified the milestones: v2.7.3, v2.7.4, 2.9.0 Aug 3, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug 🐞 Something isn't working under review 🧐 Review is pending before merging
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Adapters are counted as standard modules
3 participants