You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@reef.apache.org by Markus Weimer <ma...@weimo.de> on 2017/07/28 16:12:34 UTC

Dependency on protobuf-net seems inconsistent

Hi,

I just stumbled across a curious issues: We seem to depend on two
different versions of protobuf-net.

In `Org.Apache.REEF.Client.nuspec`, line 40, we declare:

```
<dependency id="protobuf-net" version="2.0.0.668" />
```

Similarly ,`Org.Apache.REEF.Common\packages.config` refers to the same version:

```
<package id="protobuf-net" version="2.0.0.668" targetFramework="net45" />
```

There are many more instances of this in `.nuspecs` and `package.config` files.

Meanwhile, `build.props` defines in line 72:

```
<ProtobufVersion>2.1.0</ProtobufVersion>
```

Similarly, `build.DotNet.props` defines in line 43:

```
<ProtobufVersion>2.1.0</ProtobufVersion>
```

I assume this is a problem? If so, we should probably fix it before
the release and update all references to `2.1.0` and validate that
this works.

But this also raises another question for me: I merged the PR that did
this update based on the fact that things compiled on my machine and
tests passed. This issue clearly is machine-discoverable. Hence, I
wonder whether someone knows of tooling for .NET that can detect &
report these inconsistencies as part of the build? In Java, Maven
raises a warning when different projects in the same build have the
same dependency in different versions.

Markus

Re: Dependency on protobuf-net seems inconsistent

Posted by Scott Inglis <ms...@gmail.com>.
It definitely reduces the many "truths" of the version for a package since
it puts everything into the csproj file. But there is still a chance for
two projects to use two different versions. For that, we try to reduce it
to one "truth" by declaring a version variable in the  build.DotNet.props
that projects should use.


On Tue, Sep 12, 2017 at 3:35 PM, Markus Weimer <ma...@weimo.de> wrote:

> On Tue, Sep 12, 2017 at 10:05 AM, Scott Inglis <ms...@gmail.com> wrote:
> > Apologies -  I updated the project to Protobuf 2.1.0. Let me know if I
> can
> > help out with this.
>
> I think we are good. Julia is merging my PR as we speak.
>
> > I am not aware of any tooling for this, but I will take a look.
>
> In the new build format, this can't happen, right? We ran into this
> issue because packages.config and the .nuspec files disagreed on the
> version of the dependency. In the new format, that information would
> only be recorded once, in the .csproj file. Hence, we might just wait
> it out till we move over to .NET Core :)
>
> Markus
>

Re: Dependency on protobuf-net seems inconsistent

Posted by Markus Weimer <ma...@weimo.de>.
On Tue, Sep 12, 2017 at 10:05 AM, Scott Inglis <ms...@gmail.com> wrote:
> Apologies -  I updated the project to Protobuf 2.1.0. Let me know if I can
> help out with this.

I think we are good. Julia is merging my PR as we speak.

> I am not aware of any tooling for this, but I will take a look.

In the new build format, this can't happen, right? We ran into this
issue because packages.config and the .nuspec files disagreed on the
version of the dependency. In the new format, that information would
only be recorded once, in the .csproj file. Hence, we might just wait
it out till we move over to .NET Core :)

Markus

Re: Dependency on protobuf-net seems inconsistent

Posted by Scott Inglis <ms...@gmail.com>.
Markus -

Apologies -  I updated the project to Protobuf 2.1.0. Let me know if I can
help out with this.

I am not aware of any tooling for this, but I will take a look.

Scott


On Tue, Sep 12, 2017 at 9:08 AM, Markus Weimer <ma...@weimo.de> wrote:

> This turns out to be an issue for downstream consumers of REEF. I
> filled [REEF-1883] for it.
>
> Markus
>
> [REEF-1883]: https://issues.apache.org/jira/browse/REEF-1883
>

Re: Dependency on protobuf-net seems inconsistent

Posted by Markus Weimer <ma...@weimo.de>.
This turns out to be an issue for downstream consumers of REEF. I
filled [REEF-1883] for it.

Markus

[REEF-1883]: https://issues.apache.org/jira/browse/REEF-1883