[ckan-changes] [ckan/ckan] 298181: [#1902] Don't show private datasets to group membe...

GitHub noreply at github.com
Wed Oct 1 12:20:53 UTC 2014


  Branch: refs/heads/master
  Home:   https://github.com/ckan/ckan
  Commit: 298181d4a7257ba6d891f16ed4c54d4b59566174
      https://github.com/ckan/ckan/commit/298181d4a7257ba6d891f16ed4c54d4b59566174
  Author: Sean Hammond <git at seanh.cc>
  Date:   2014-09-05 (Fri, 05 Sep 2014)

  Changed paths:
    M ckan/lib/dictization/model_dictize.py

  Log Message:
  -----------
  [#1902] Don't show private datasets to group members

1. User Sean creates organization my-org
2. Sean adds private dataset my-dataset to my-org
3. Sean creates group my-group
4. Sean adds private dataset my-dataset to my-group
5. Sean adds user Fred to my-group
6. The group_show API will now show the private dataset my-dataset to
   Fred, even though Fred is not a member of my-org.

For some reason the private dataset does not show on the group's page,
but it does show in ther API.

This commit removes it from the API.

If backported this commit will also fix a problem present on 2.2 and
2.2.1 (but not master) that after following the steps above Fred will
see the private dataset on the site front page.

Arguably you should not be able to add private datasets to groups at
all, but you could add a public dataset to a group and then make the
dataset private and it would still belong to the group, so we do need to
filter private datasets out of groups.


  Commit: ee9199cafcd97821b38ac41a37f7f072f986b270
      https://github.com/ckan/ckan/commit/ee9199cafcd97821b38ac41a37f7f072f986b270
  Author: Sean Hammond <git at seanh.cc>
  Date:   2014-09-05 (Fri, 05 Sep 2014)

  Changed paths:
    M ckan/new_tests/logic/action/test_get.py

  Log Message:
  -----------
  [#1902] Test that group_show() doesn't show private datasets


  Commit: ce873cd0833db2e54195d7383423fd29854d5f41
      https://github.com/ckan/ckan/commit/ce873cd0833db2e54195d7383423fd29854d5f41
  Author: Sean Hammond <git at seanh.cc>
  Date:   2014-09-05 (Fri, 05 Sep 2014)

  Changed paths:
    M ckan/new_tests/logic/action/test_get.py

  Log Message:
  -----------
  [#1902] PEP8


  Commit: 567c195cc1c86bc1c7b03248ee396a57bf74585b
      https://github.com/ckan/ckan/commit/567c195cc1c86bc1c7b03248ee396a57bf74585b
  Author: joetsoi <joe.yeung.tsoi at gmail.com>
  Date:   2014-10-01 (Wed, 01 Oct 2014)

  Changed paths:
    M ckan/lib/dictization/model_dictize.py
    M ckan/new_tests/logic/action/test_get.py

  Log Message:
  -----------
  Merge branch '1902-private-datasets-in-groups'


Compare: https://github.com/ckan/ckan/compare/f166300d7251...567c195cc1c8


More information about the ckan-changes mailing list