Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[#602] Deprecate IDatasetForm's check_data_dict
With the new three-stage dataset creation form in CKAN 2.0 check_data_dict() no longer works as intended. For example, DefaultDatasetForm's check_data_dict() breaks any IDatasetForm plugins that are trying to use convert_to_extras() (if they inherit from DefaultDatasetForm). Remove the method from IDatasetForm and DefaultDatasetForm, but still call the method in all the places it would previously have been called _if_ the active IDatasetForm plugin has the method. Also remove three tests that seem to be testing check_data_dict()'s behaviours. Note that in the existing code, check_data_dict() seems to be called twice when creating a package, once by the package controller and once by package_create(), and the two are inconsistent in the number of params they expect check_data_dict() to take! On updating a package it's called just once, by package_update(). I have preserved these "legacy" behaviours. Also note that IGroupForm and IOrganizationForm still have check_data_dict() methods, we probably want to get rid of them in the future as well.
- Loading branch information
Sean Hammond
committed
Mar 15, 2013
1 parent
bd44895
commit 00c2898
Showing
7 changed files
with
34 additions
and
94 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters