| Files | Last commit | Last update |
|---|---|---|
refactor(python): follow the PEP 8 layout rules in Python sources What: - Reformat the tracked Python sources (scripts, tools, generators, tests, samples, the commit-msg hook and the mw-perf-collect launcher) so flake8 --max-line-length 120 --select E,W reports no findings, apart from W503/W504, which contradict each other and are off by default. - Whitespace, indentation, blank lines, one statement per line, split "import a, b" lines and lines kept within 120 columns. - Assigned lambdas became small def functions; mid-file imports moved to the top of the file where nothing has to run first; standard-library imports now come before third-party imports. - Over-long string literals were split by implicit concatenation, so the values stay identical. - Imports that must follow a sys.path setup, long lines inside embedded C++/shell/Python templates, and five statements whose exact spelling a test checks keep a noqa marker. Why: - The code check reports thousands of layout findings in these files. Fixing the layout once keeps later findings readable. Verification: - Comparing syntax trees shows only the intended changes (lambda to def, moved imports, one reflowed docstring); comments are unchanged apart from the added noqa markers. - ibmw_gen, mw_perf_collect, core metrics, selfdev, transport benchmark and adapter Python tests give the same results as before the change. - scripts/tests/*.sh, ctest (75/75), docs governance and license header checks give the same results as before. Signed-off-by: fanglinxu <fanglinxu@huawei.com> | 5 days ago | |
chore(license): put the Apache-2.0 header on every source file, add OAT.xml What: Every source, script, build and configuration file now starts with the full Apache-2.0 license header and the copyright line "Copyright (c) 2025-2026 IB-Robot Group & openEuler Embedded SIG & openharmony-robot sig_RoboFrame." (no comma after the years). The "All rights reserved." line and the Mulan PSL v2 line of the loaned message demo are removed; the repository LICENSE is Apache-2.0. A shebang, coding line or XML declaration stays first. Jinja2 templates carry the header in a template comment, so it is not copied into rendered files. The new OAT.xml registers the copyright holders and the license, and filters files that cannot carry a header (JSON, golden generator output, patches, the recorded rosbag test data, documentation), each with its reason. Why: The OpenHarmony CI open-source audit reported 3527 fatal issues: files without a license header, copyright lines it does not accept, and binary files not registered. Only file headers and OAT.xml change; no code changes. Verification: Release hygiene and docs governance pass. The header script is idempotent (a second run changes nothing) and its diff only removes old header lines and the comment separators after them. ibmw_gen tests and scripts/tests give the same results as before the change; the installed-consumer test builds and installs the whole tree. Signed-off-by: fanglinxu <fanglinxu@huawei.com> | 5 days ago |