RejectedSoftware Forums

Sign up

Splitting Vibe into subpackages

I often find myself adding a dependency on vibe just for it's Json serialization, however I'd prefer not to pull in the entire library for a number of reasons. The existence of the vmeta [0] package shows I'm not the only one.

Putting vibe.data and vibe.internal in subpackages is quite straightforward: vibe.internal has no dependencies on other packages, and vibe.data only depends on vibe.internal (except for three imports of vibe.core.log. Two are unused [1][2], the other one looks like cruft from a debugging session [3]).

I understand if you don't want vibe split into subpackages, but if you are in favor I'd gladly do the work.

[0] http://code.dlang.org/packages/vmeta
[1] https://github.com/rejectedsoftware/vibe.d/blob/master/source/vibe/data/bson.d#L11
[2] https://github.com/rejectedsoftware/vibe.d/blob/master/source/vibe/data/json.d#L845
[3] https://github.com/rejectedsoftware/vibe.d/blob/master/source/vibe/data/json.d#L1625

Re: Splitting Vibe into subpackages

On Tue, 31 Mar 2015 21:29:37 GMT, Rene Zwanenburg wrote:

I often find myself adding a dependency on vibe just for it's Json serialization, however I'd prefer not to pull in the entire library for a number of reasons. The existence of the vmeta [0] package shows I'm not the only one.

Putting vibe.data and vibe.internal in subpackages is quite straightforward: vibe.internal has no dependencies on other packages, and vibe.data only depends on vibe.internal (except for three imports of vibe.core.log. Two are unused [1][2], the other one looks like cruft from a debugging session [3]).

I understand if you don't want vibe split into subpackages, but if you are in favor I'd gladly do the work.

[0] http://code.dlang.org/packages/vmeta
[1] https://github.com/rejectedsoftware/vibe.d/blob/master/source/vibe/data/bson.d#L11
[2] https://github.com/rejectedsoftware/vibe.d/blob/master/source/vibe/data/json.d#L845
[3] https://github.com/rejectedsoftware/vibe.d/blob/master/source/vibe/data/json.d#L1625

See https://github.com/rejectedsoftware/vibe.d/blob/subpackages/dub.json. The major problem is that this is currently blocked by a bug in DUB (will be fixed with the next release later this week). Before this can be made public, we'd have to wait at least for one more DUB release to avoid breaking too many builds.

Re: Splitting Vibe into subpackages

On Tue, 31 Mar 2015 21:40:54 GMT, Sönke Ludwig wrote:

On Tue, 31 Mar 2015 21:29:37 GMT, Rene Zwanenburg wrote:

I often find myself adding a dependency on vibe just for it's Json serialization, however I'd prefer not to pull in the entire library for a number of reasons. The existence of the vmeta [0] package shows I'm not the only one.

Putting vibe.data and vibe.internal in subpackages is quite straightforward: vibe.internal has no dependencies on other packages, and vibe.data only depends on vibe.internal (except for three imports of vibe.core.log. Two are unused [1][2], the other one looks like cruft from a debugging session [3]).

I understand if you don't want vibe split into subpackages, but if you are in favor I'd gladly do the work.

[0] http://code.dlang.org/packages/vmeta
[1] https://github.com/rejectedsoftware/vibe.d/blob/master/source/vibe/data/bson.d#L11
[2] https://github.com/rejectedsoftware/vibe.d/blob/master/source/vibe/data/json.d#L845
[3] https://github.com/rejectedsoftware/vibe.d/blob/master/source/vibe/data/json.d#L1625

See https://github.com/rejectedsoftware/vibe.d/blob/subpackages/dub.json. The major problem is that this is currently blocked by a bug in DUB (will be fixed with the next release later this week). Before this can be made public, we'd have to wait at least for one more DUB release to avoid breaking too many builds.

Also, vibe.internal is considered internal. We already broke some backward compability with it, and I'd like to keep a place where we can break backward compatibility.
However, if that's judged useful, we could provide a 'meta' library.

Re: Splitting Vibe into subpackages

On Tue, 31 Mar 2015 21:40:54 GMT, Sönke Ludwig wrote:

See https://github.com/rejectedsoftware/vibe.d/blob/subpackages/dub.json. The major problem is that this is currently blocked by a bug in DUB (will be fixed with the next release later this week). Before this can be made public, we'd have to wait at least for one more DUB release to avoid breaking too many builds.

Ah, very nice :)

Until then I can work with my own branch, I'm not planning on putting my project on the registry very soon anyway.

Re: Splitting Vibe into subpackages

On Wed, 01 Apr 2015 07:42:10 GMT, Mathias LANG wrote:

Also, vibe.internal is considered internal. We already broke some backward compability with it, and I'd like to keep a place where we can break backward compatibility.
However, if that's judged useful, we could provide a 'meta' library.

That could be useful. Personally I'm using the UDA stuff from vibe.internal.meta in one of my projects since Phobos doesn't really have something to help with common UDA patterns yet.

Re: Splitting Vibe into subpackages

On 2015-03-31 21:29:37 +0000, Rene Zwanenburg said:

I often find myself adding a dependency on vibe just for it's Json
serialization, however I'd prefer not to pull in the entire library for
a number of reasons. The existence of the vmeta [0] package shows I'm
not the only one.

Putting vibe.data and vibe.internal in subpackages is quite
straightforward: vibe.internal has no dependencies on other packages,
and vibe.data only depends on vibe.internal (except for three imports
of vibe.core.log. Two are unused [1][2], the other one looks like cruft
from a debugging session [3]).

I understand if you don't want vibe split into subpackages, but if you
are in favor I'd gladly do the work.

[0] http://code.dlang.org/packages/vmeta

[1]
https://github.com/rejectedsoftware/vibe.d/blob/master/source/vibe/data/bson.d#L11

[2]
https://github.com/rejectedsoftware/vibe.d/blob/master/source/vibe/data/json.d#L845

[3]
https://github.com/rejectedsoftware/vibe.d/blob/master/source/vibe/data/json.d#L1625

Some of these should just be in phobos, and I believe Sönke is doing
the work to get them in.

-Shammah