-
Notifications
You must be signed in to change notification settings - Fork 2.1k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
DM XMLs: switch 1.4 to use alchemy #37201
Conversation
sed -i -e '$a\' data_model/1.4/device_types/* sed -i -e '$a\' data_model/1.4/clusters/*
PR #37201: Size comparison from 22cd392 to 3e7e20e Full report (71 builds for bl602, bl702, bl702l, cc13x4_26x4, cc32xx, cyw30739, efr32, esp32, linux, nrfconnect, nxp, psoc6, qpg, stm32, telink, tizen)
|
PR #37201: Size comparison from 22cd392 to 9db4651 Full report (3 builds for cc32xx, stm32)
|
PR #37201: Size comparison from 22cd392 to e42a7eb Full report (71 builds for bl602, bl702, bl702l, cc13x4_26x4, cc32xx, cyw30739, efr32, esp32, linux, nrfconnect, nxp, psoc6, qpg, stm32, telink, tizen)
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Seems reasonable at a first glance. Lists default saying empty
vs []
may require special handling and type names are a bit changed, however not having ref_
is great.
PR #37201: Size comparison from 22cd392 to 4928663 Full report (71 builds for bl602, bl702, bl702l, cc13x4_26x4, cc32xx, cyw30739, efr32, esp32, linux, nrfconnect, nxp, psoc6, qpg, stm32, telink, tizen)
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I did not nitpick every single xml file, but seems like the generation is fine 👍🏻
Note that this contains a significant number of changes in one commit, and I apologise for that, but the new spec cannot be scraped with the DM editor, so I needed to swap to alchemy to get the new spec scraped. Hence this contains both the alchemy formatting changes (as outlined in project-chip#37201 as well as the changes from the last ballot to the current ballot.
Note that this contains a significant number of changes in one commit, and I apologise for that, but the new spec cannot be scraped with the DM editor, so I needed to swap to alchemy to get the new spec scraped. Hence this contains both the alchemy formatting changes (as outlined in project-chip#37201 as well as the changes from the last ballot to the current ballot.
* Run dos2unix on all DM XML files in 1.4 * Add newlines at end of all DM XML files for 1.4 sed -i -e '$a\' data_model/1.4/device_types/* sed -i -e '$a\' data_model/1.4/clusters/* * DM XMLs: switch 1.4 DM XMLs to alchemy * Generator updates to alchemy * Update 1.4 using alchemy 1.5.0 * Restyled by autopep8 * Add the in-progress defines to match the 1.5 0.7 spec ballot * Fix define processing for alchemy, add tag file * Fix linter, add check for non-existent tag file * Remove a leftover file - this isn't generated by alchemy * Remove file from gni list --------- Co-authored-by: Restyled.io <commits@restyled.io>
* Add 1.4.1 as a direct copy of 1.4 This can be used to see a diff between these two releases * Update alchemy version on 1.4 changes contraints - will update on tot soon, but don't want to wait for the PR to land before this goes in. * data model files at the 1.4.1 tag * Add 1.4.1 to parser with tests. * Restyled by isort * Fixup includes * Update 1.4 DM XMLs to latest (#37146) * Update 1.4 DM XMLs to latest * Fix CI checker so it properly checks spec_sha * DM XMLs: switch 1.4 to use alchemy (#37201) * Run dos2unix on all DM XML files in 1.4 * Add newlines at end of all DM XML files for 1.4 sed -i -e '$a\' data_model/1.4/device_types/* sed -i -e '$a\' data_model/1.4/clusters/* * DM XMLs: switch 1.4 DM XMLs to alchemy * Generator updates to alchemy * Update 1.4 using alchemy 1.5.0 * Restyled by autopep8 * Add the in-progress defines to match the 1.5 0.7 spec ballot * Fix define processing for alchemy, add tag file * Fix linter, add check for non-existent tag file * Remove a leftover file - this isn't generated by alchemy * Remove file from gni list --------- Co-authored-by: Restyled.io <commits@restyled.io> --------- Co-authored-by: Restyled.io <commits@restyled.io>
* Fix line endings for master DM XMLs * Add newline at end of file for master DM XMLs * Add closures as a file exception - device types all in one file * DM XMLs: Update master to 0.7 of 1.5 and use alchemy Note that this contains a significant number of changes in one commit, and I apologise for that, but the new spec cannot be scraped with the DM editor, so I needed to swap to alchemy to get the new spec scraped. Hence this contains both the alchemy formatting changes (as outlined in #37201 as well as the changes from the last ballot to the current ballot. * Update file list in build file * Fix unit tests to expect clusters removed in 1.5 * Update device type parsing to warn on non-int IDs rather than failing This happens on ID-TBD in the ballot. * Add test to ensure all spec device types are OK. * Add a stringifier to XmlFeature XmlCommand * Restyled by autopep8 * Restyled by isort --------- Co-authored-by: Restyled.io <commits@restyled.io>
* Run dos2unix on all DM XML files in 1.4 * Add newlines at end of all DM XML files for 1.4 sed -i -e '$a\' data_model/1.4/device_types/* sed -i -e '$a\' data_model/1.4/clusters/* * DM XMLs: switch 1.4 DM XMLs to alchemy * Generator updates to alchemy * Update 1.4 using alchemy 1.5.0 * Restyled by autopep8 * Add the in-progress defines to match the 1.5 0.7 spec ballot * Fix define processing for alchemy, add tag file * Fix linter, add check for non-existent tag file * Remove a leftover file - this isn't generated by alchemy * Remove file from gni list --------- Co-authored-by: Restyled.io <commits@restyled.io>
* Fix line endings for master DM XMLs * Add newline at end of file for master DM XMLs * Add closures as a file exception - device types all in one file * DM XMLs: Update master to 0.7 of 1.5 and use alchemy Note that this contains a significant number of changes in one commit, and I apologise for that, but the new spec cannot be scraped with the DM editor, so I needed to swap to alchemy to get the new spec scraped. Hence this contains both the alchemy formatting changes (as outlined in project-chip#37201 as well as the changes from the last ballot to the current ballot. * Update file list in build file * Fix unit tests to expect clusters removed in 1.5 * Update device type parsing to warn on non-int IDs rather than failing This happens on ID-TBD in the ballot. * Add test to ensure all spec device types are OK. * Add a stringifier to XmlFeature XmlCommand * Restyled by autopep8 * Restyled by isort --------- Co-authored-by: Restyled.io <commits@restyled.io>
With some of the new data model markings, we now need to use alchemy to scrape the spec text for 1.5. Before scraping the 1.5 spec, I am moving the 1.4 scrape over to alchemy to prove it out in the CI. 1.4 is the current version, so it is the one being tested currently. Going forward, 1.4.1 and the 1.5 ballots will use alchemy. The swap for 1.3 may happen later.
Alchemy has a number of small changes from the DM editor. The XML formatting changes are listed below along with descriptions of how these affect testing (none do). Alchemy also uses unix line endings and add a newline at the end of all files. In an effort to reduce what is already an extremely large diff, I've moved these changes out into separate commits. To view only the functional changes, view only the one commit.
This PR also includes changes to the generator script to support alchemy.
Changes from DM editor to alchemy:
Testing
DM XMLs are used in the device conformance and device composition tests that are run in the CI. They are also tested in the TestSpecParsingSupport.py and TestSpecParsingDeviceTypes.py tests.