[ 
https://issues.apache.org/jira/browse/MESOS-5909?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15560805#comment-15560805
 ] 

Sebastian Castillo commented on MESOS-5909:
-------------------------------------------

osx 10.11.3 here and I noticed {{tokens}} is being sorted numerically while 
{{expected_gids}} is being sorted as strings. Also {{getgrouplist}} is missing 
5 gids.

{code}
$ id -G && id -G | wc -w
20 401 12 61 79 80 81 98 501 33 100 204 395 398 399
15
{code}

{code}
[ RUN      ] OsTest.User

gids_:
2 0   4 0 1   1 2   6 1   7 9   8 0   8 1   9 8   5 0 1   3 3

tokens:
12 20 33 401 501 61 79 80 81 98

gids:
20 401 12 61 79 80 81 98 501 33 100 204 395 398 399

expected gids:
100 12 20 204 33 395 398 399 401 501 61 79 80 81 98

../../../3rdparty/stout/tests/os_tests.cpp:716: Failure
Value of: expected_gids
  Actual: { "100", "12", "20", "204", "33", "395", "398", "399", "401", "501", 
"61", "79", "80", "81", "98" }
Expected: tokens.get()
Which is: { "12", "20", "33", "401", "501", "61", "79", "80", "81", "98" }
[  FAILED  ] OsTest.User (28 ms)
{code}

Missing gids:

{code}
100(_lpoperator),204(_developer),395(com.apple.access_ftp),398(com.apple.access_screensharing),399(com.apple.access_ssh)
{code}

[~h0tbird],  [~haosdent] have you added the new issue? I would like to try to 
fix it (I'm a newbie) :)

> Stout "OsTest.User" test can fail on some systems
> -------------------------------------------------
>
>                 Key: MESOS-5909
>                 URL: https://issues.apache.org/jira/browse/MESOS-5909
>             Project: Mesos
>          Issue Type: Bug
>          Components: stout
>            Reporter: Kapil Arya
>            Assignee: Mao Geng
>              Labels: mesosphere
>             Fix For: 1.1.0
>
>         Attachments: MESOS-5909-fix.diff
>
>
> Libc call {{getgrouplist}} doesn't return the {{gid}} list in a sorted manner 
> (in my case, it's returning "471 100") ... whereas {{id -G}} return a sorted 
> list ("100 471" in my case) causing the validation inside the loop to fail.
> We should sort both lists before comparing the values.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

Reply via email to