You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
According to the API documentation (http://docs.ckan.org/en/latest/api/), ckan.logic.action.get.package_list(context, data_dict) and `ckan.logic.action.get.current_package_list_with_resources(context, data_dict) both return 'return a list of the site’s datasets (packages)' (with the latter being a list of dicts that include the resources for each dataset.
Based on the docs, if no parameters are set, both functions should return lists with all the site's datasets and the length of the two lists for a given site should be the same.
Please describe the actual behavior
While package_list does return a list of all of a site's datasets, current_package_list_with_resources returns a list with only ten datasets, regardless of how many datasets the site has.
What steps can be taken to reproduce the issue?
Case 1:
import requests
r = requests.get(url='http://demo.ckan.org/api/3/action/current_package_list_with_resources')
plist_resources = r.json()
r = requests.get(url='http://demo.ckan.org/api/3/action/package_list')
just_plist = r.json()
print(len(plist_resources['result']))
print(len(just_plist['result']))
Case 2:
import requests
r = requests.get(url='http://beta.ckan.org/api/3/action/current_package_list_with_resources')
plist_resources = r.json()
r = requests.get(url='http://beta.ckan.org/api/3/action/package_list')
just_plist = r.json()
print(len(plist_resources['result']))
print(len(just_plist['result']))
The text was updated successfully, but these errors were encountered:
If the actual behavior is correct and the docs need to be updated or clarified, I'd be happy to do so. Likewise if current_package_list_with_resources needs to be tweaked to produce the expected behavior.
We decided to close old issues that are not actively worked on so that we can focus our effort and attention on issues affecting the current versions of CKAN.
If this issue is still affecting the version of CKAN you're working with now, please feel free to comment or reopen the issue.
If you do reopen this issue, please update it with new details. One reason it might not have been resolved in the past is that it wasn't clear how a contributor could address the issue.
CKAN Version if known (or site URL)
API ver. 3, http://demo.ckan.org and http://beta.ckan.org.
Please describe the expected behavior
According to the API documentation (http://docs.ckan.org/en/latest/api/),
ckan.logic.action.get.package_list(context, data_dict)
and `ckan.logic.action.get.current_package_list_with_resources(context, data_dict) both return 'return a list of the site’s datasets (packages)' (with the latter being a list of dicts that include the resources for each dataset.Based on the docs, if no parameters are set, both functions should return lists with all the site's datasets and the length of the two lists for a given site should be the same.
Please describe the actual behavior
While
package_list
does return a list of all of a site's datasets,current_package_list_with_resources
returns a list with only ten datasets, regardless of how many datasets the site has.What steps can be taken to reproduce the issue?
Case 1:
Case 2:
The text was updated successfully, but these errors were encountered: