Skip to content

v0.3.0

Compare
Choose a tag to compare
@klauer klauer released this 26 Feb 00:43
· 259 commits to master since this release
a4f241a

Changes / fixes / etc

A big release with an overhaul of most aspects of blark.

  • Add round-trippable Python dataclasses for structured text grammar
    • Source code -> dataclasses you can interact with -> source code
    • Comments and pragmas can be retained
    • Formatting is not retained (blark has an abstract - not full - syntax tree)
  • Added start of sphinx domain for code documentation generation
  • Added UNION, PROPERTY support and many other grammar fixes
  • Nested comments are handled fully
  • Added dependency store
    • Parse project + all dependencies that have source code available
    • Using the summary classes, relatively easily poke around with source code objects
  • Removed unused dataclasses + grammar rules
    • Closes #18
    • Up for discussion if I'm missing something
    • Task config, instruction lists, SFC networks, ...
  • Grammar fixes
    • Functions can return indirect types
    • Added variable attribute flags to blocks where accepted, according to infosys docs
  • Improved code summary utilities
    • Easier to use to find declarations and such
    • Add ProgramSummary, GlobalVariableSummary
    • Base type EXTENDS declarations are wrapped into the derived type
  • Added program and global variables to documentation generation (sphinx domain)
  • Added apischema-based serialization in the test suite
    • This helped improve the type annotations in places as round-tripping validation was failing
    • However, Python 3.9+ with apischema 0.17.5 (did not test other versions) is hitting an infinite loop when attempting to serialize most of the data structures. Serialization testing for those Python versions is disabled for now until I get a chance to dig in / report the issue if it's not on my end
    • Python 3.7 and Python 3.8 are testing serialization with the transformed dataclasses just fine though

PRs

  • REF/ENH: round-trippable Python dataclasses for structured text grammar by @klauer in #9
  • ENH: initial attempts at code summary layer, sphinx domain by @klauer in #12
  • ENH: dependencies, first pass at serialization, and more by @klauer in #19

Full Changelog: v0.1.7...v0.3.0