Univention Bugzilla – Bug 48478
rename recordUID to record_uid and sourceUID to source_uid
Last modified: 2019-03-12 10:50:30 CET
To be more consistent with other variable names, the configuration key "scheme:recordUID" should be renamed to "scheme:record_uid". The method "ImportUser.make_recordUID()" should be renamed to "ImportUser.make_record_uid()". To be more consistent with other variable names, the configuration key "sourceUID" and its associated command line argument "--sourceUID" should be renamed to "source_uid" and "--source_uid" respectively. The method "ImportUser.make_sourceUID()" shoudl be renamed to "ImportUser.make_source_uid()". This is a breaking change!
Documentation, code and tests have been adapted and an entry added to the changelog. [4.4] 432819479 Bug #48478: documentation of rename of recordUID to record_uid and sourceUID to source_uid [4.4] 709a12112 Bug #48478: rename recordUID to record_uid and sourceUID to source_uid [4.4] bba3489bd Bug #48478: adapt tests to rename of recordUID to record_uid and sourceUID to source_uid [4.4] 6c2602862 Bug #48478: advisory ucs-school-import (17.1.0-1) ucs-test-ucsschool (6.0.0-5)
(In reply to Daniel Tröder from comment #0) > To be more consistent with other variable names, the configuration key > "scheme:recordUID" should be renamed to "scheme:record_uid". Yes. I think this change can be easily done by all customers. > The method "ImportUser.make_recordUID()" should be renamed to > "ImportUser.make_record_uid()". → What about providing both names for some time, to not break all customer code extensions? → ImportUser.make_recordUID = ImportUser.make_record_uid > To be more consistent with other variable names, the configuration key > "sourceUID" and its associated command line argument "--sourceUID" should be > renamed to "source_uid" and "--source_uid" respectively. → what about accepting the both CLI option for some time, but only document the new one? Also --help should only output the new one. > The method "ImportUser.make_sourceUID()" shoudl be renamed to > "ImportUser.make_source_uid()". Same request here. See above.
Originally I did that (make_recordUID = make_record_uid), but decided that it's better to break code now (with the change to 4.4), than later. If we keep backwards compatible options/methods, users won't change their code and will then crash with 4.4 v2, a point release. IHMO better to have them crash now, as they are aware that they must test everything thoroughly.
We decided to make a hard break in 4.4 and add a deprecation warning to the 4.3v7 release notes.
The UCS@school import will support in UCS@school 4.3v7 the use of record_uid and source_uid. Breaking changes have been added to the changelog for 4.3v7 in doc/changelog/changelog-draft-for-4.3v7.xml. [4.3] 689944a07 Bug #48478: allow forward compatible use of record_uid and source_uid [4.3] 2f6a512d9 Bug #48478: advisory ucs-school-import (16.0.2-67)
Advisory & Changelog: OK Package installs: OK Notion in Release Notes of 4.3v7: OK Function alternate names present: OK Configuration works with alternate name (including conflict handling): OK To not forget this at a later point and to introduce the new name, the configuration hint of the ucs-school-testuser-import script should be adapted as well. We also might want to adapt the manual found here https://billy.knut.univention.de/~dtroeder/http-api-doc/test-data.html?highlight=sourceuid
(In reply to Ole Schwiegert from comment #6) > Advisory & Changelog: OK > Package installs: OK > Notion in Release Notes of 4.3v7: OK > Function alternate names present: OK > Configuration works with alternate name (including conflict handling): OK > > To not forget this at a later point and to introduce the new name, the > configuration hint of the ucs-school-testuser-import script should be > adapted as well. > > We also might want to adapt the manual found here > https://billy.knut.univention.de/~dtroeder/http-api-doc/test-data. > html?highlight=sourceuid This was already done for 4.4 in: [4.4] 709a12112 Bug #48478: rename recordUID to record_uid and sourceUID to source_uid I don't think we should change the documentation (including help texts) in 4.3. I have updated the online version on billy. I improved the documentation build process to not produce tracebacks for import errors in case the import code is already installed. I didn't rebuild the package for that change: [4.4 59834bf78] Bug #48478: improve documentation build process
[4.4 54048a300] Bug #48478: fix doc build [4.4 c0e168be3] Bug #48478: version bump
Works for me
UCS@school 4.3 v7 has been released. https://docs.software-univention.de/changelog-ucsschool-4.3v7-de.html If this error occurs again, please clone this bug.