MQTTnet icon indicating copy to clipboard operation
MQTTnet copied to clipboard

Reopen: nuget version of MQTTnet.Extensions.TopicTemplate is not up to date

Open clively opened this issue 1 year ago • 4 comments

I do not have the ability to reopen issues, so per github recommendations I am creating a new one.

Original issue: https://github.com/dotnet/MQTTnet/issues/2055

I have confirmed that the version numbers now match, however when attempting to use the packages with the sample project I get the following:

CS1929 'MqttClientSubscribeOptionsBuilder' does not contain a definition for 'WithTopicTemplate' and the best extension method overload 'TopicTemplateExtensions.WithTopicTemplate(MqttTopicFilterBuilder, MqttTopicTemplate, bool)' requires a receiver of type 'MQTTnet.MqttTopicFilterBuilder' MQTTnet.Samples C:<my project details>\Samples\Client\Client_Subscribe_Samples.cs 47

What I did was pull just that one project from your github repo. I then changed the project references to target the latest versions of the packages on nuget. And then I did a build. I'm attaching a screen shot.

It looks like the MqttClientSubscribeOptionsBuilder WithTopicTemplate extension method was not compiled into the package.

mqttnetissues

clively avatar Jul 30 '24 19:07 clively

What's the problem with using a MqttTopicFilterBuilder?

SeppPenner avatar Jul 31 '24 08:07 SeppPenner

I have the same problem.

What's the problem with using a MqttTopicFilterBuilder?

The "problem" is, that this is from the sample code from the current master branch, so the sample hast to be adapted or there is a bug.

@SeppPenner or can u light us up and show the working code with the MqttTopicFilterBuilder?

VedMod avatar Aug 15 '24 18:08 VedMod

Maybe this is not yet released @chkr1011 ?

SeppPenner avatar Aug 20 '24 15:08 SeppPenner

The issue is that the master examples depend on the master template extension. While unfortunate, it is a one-off and has an easy solution. When you open the full project solution (not just examples), things should work fine.

simonthum avatar Aug 25 '24 08:08 simonthum

@SeppPenner I think this can be closed.

simonthum avatar Sep 03 '24 12:09 simonthum