gocheck in non test code
John Meinel
john at arbash-meinel.com
Tue Apr 21 13:49:38 UTC 2015
I think the difference is that if you do:
go list -f '{{join .Deps "\n"}}' github.com/juju/juju/cmd/juju
Then it only lists things that get imported by the "juju" binary.
However, if you do "github.com/juju/juju/..." then it recurses the
directory structure and finds everything imported by every directory.
John
=:->
On Tue, Apr 21, 2015 at 5:46 PM, John Meinel <john at arbash-meinel.com> wrote:
> I don't know if it is because of bad imports but I certainly see
> github.com/juju/juju/environs/testing
> github.com/juju/juju/juju/testing
> etc
> in the output of the go list output.
>
> John
> =:->
>
> On Tue, Apr 21, 2015 at 5:34 PM, Matthew Williams <
> matthew.williams at canonical.com> wrote:
>
>> Unless I misunderstand my usage of go list (which is an absolute
>> possibility) then those instances aren't included.
>>
>> On Tue, Apr 21, 2015 at 3:31 PM, John Meinel <john at arbash-meinel.com>
>> wrote:
>>
>>> Looking at the patch, that doesn't seem to filter "testing" packages,
>>> does it? Those intentionally have those dependencies, but should only be
>>> imported in *_test.go code.
>>>
>>> John
>>> =:->
>>>
>>>
>>> On Tue, Apr 21, 2015 at 5:17 PM, Matthew Williams <
>>> matthew.williams at canonical.com> wrote:
>>>
>>>> Hi Folks,
>>>>
>>>> There seem to be a number of places in core where we end up importing
>>>> gocheck in non test code. We should have a plan for reducing this down to
>>>> zero, and at some stage not merge code in that does this. That's not a
>>>> reasonable thing to do at the moment so I've just proposed a new rule in
>>>> the Makefile that we can use to track it:
>>>> http://reviews.vapour.ws/r/1460/
>>>>
>>>> Any implementation specific comments should go on the review. But I
>>>> wanted to email the list incase anyone wanted to discuss the idea in
>>>> general - and possible resolutions.
>>>>
>>>> Thanks all
>>>>
>>>> Matty
>>>>
>>>> --
>>>> Juju-dev mailing list
>>>> Juju-dev at lists.ubuntu.com
>>>> Modify settings or unsubscribe at:
>>>> https://lists.ubuntu.com/mailman/listinfo/juju-dev
>>>>
>>>>
>>>
>>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.ubuntu.com/archives/juju-dev/attachments/20150421/f799c635/attachment-0001.html>
More information about the Juju-dev
mailing list