#ckan

/

      • tomkralidis joined the channel
      • tomkralidis has quit
      • tomkralidis joined the channel
      • tomkralidis has quit
      • LondonAppDev__ joined the channel
      • yanik joined the channel
      • yanik joined the channel
      • yanik joined the channel
      • yanik joined the channel
      • trickvi has quit
      • yanik joined the channel
      • shellac joined the channel
      • trickvi joined the channel
      • knud joined the channel
      • knud
        Hello. Given a user, what's the best way to figure out then organization they are a member of?
      • I have a working SQL query, but maybe there is a better way?
      • shellac joined the channel
      • amercader
        knud: organization_list_for_user is the action you should use: http://docs.ckan.org/en/latest/api/index.html#c...
      • but note that due to a bug it will currently only return the orgs that the user is admin of, not editor or member: https://github.com/ckan/ckan/pull/2457
      • I need to add tests there to get it properly merged, if someone wants to help feel free to jump in
      • knud
        amercader: thanks! How did I not see that in the docs… ?
      • trickvi has quit
      • trickvi joined the channel
      • yanik has quit
      • tomkralidis joined the channel
      • tomkralidis has quit
      • tomkralidis joined the channel
      • yanik joined the channel
      • tomkralidis has quit
      • tomkralidis joined the channel
      • tomkralidis has quit
      • tomkralidis joined the channel
      • wardi
        amercader: the tracking details on ckan <= 2.4 in solr used to get stale, unless users reindexed regularly
      • "hot" datasets is a useful feature though
      • How about a parameter on package_search to add the latest tracking details to its results? Shouldn't be an expensive query
      • amercader
        wardi: the tracking docs do say that you need to reindex hourly via the cron job, but yes most users probably forget
      • adding them afterwards sounds good but it could add up if there are a lot of results
      • wardi
        it would just do the current page of results, no?
      • or we could go back to storing the tracking results in solr. I am planning to revert 1105 since it's not actually helping most users
      • amercader
        yeah, I mean for API calls with `&rows=100`
      • wardi
        I'm on the fence. it's data about views of the record so it feels like it shouldn't be part of the record itself
      • I might be over-thinking it :-)
      • re-indexing regularly should be listed as a best-practice in the docs because of the other data (e.g. org names) that doesn't get updated otherwise
      • amercader: what do you think? Should I just put the tracking info back in solr? usefulness should trump purity, right?
      • amercader
        sorry, I'm having a little psql panic, back in a sec
      • knud has quit
      • kalxas joined the channel
      • yanik joined the channel
      • georgiabullen joined the channel
      • georgiabullen has quit
      • georgiabullen joined the channel
      • LaurentGoderre joined the channel
      • LaurentGoderre
        Hey,, I have a question about tests
      • It's about the ckan.root_path settings. If you have both the root_path set in your ini and somehow have that path in the SCRIPT_NAME server variable, the url_for helper uses both, creating an invalid URL
      • I found a fix to ensure that CKAN uses the root_path instead of the SCRIPT_NAME for generating scripts.
      • However, I am unable to create a test to demonstrate that
      • shellac has quit
      • LaurentGoderre has quit
      • tomkralidis has quit
      • tomkralidis joined the channel
      • yanik joined the channel
      • trickvi has quit
      • tomkralidis has quit
      • shellac joined the channel
      • georgiabullen has quit
      • yanik joined the channel
      • yanik joined the channel
      • trickvi joined the channel
      • trickvi has quit
      • kalxas has quit
      • yanik joined the channel
      • yanik has quit
      • tomkralidis joined the channel