CamilleTeruel opened a new issue, #5471:
URL: https://github.com/apache/incubator-devlake/issues/5471

   ### Search before asking
   
   - [X] I had searched in the 
[issues](https://github.com/apache/incubator-devlake/issues?q=is%3Aissue) and 
found no similar feature requirement.
   
   
   ### Use case
   
   Pydevlake has to replicate all the domain layer models that exist on go side.
   Right now, there are some CODE, CROSSDOMAIN and DEVOPS models implemented, 
but many are missing.
   When a domain model changes on go side, devs have to modify the 
corresponding python model as well.
   It would be better if the python models were generated from go ones.
   
   Cons:
   - The maintainance burden of the code generator may be higher than 
duplicating domain model changes on both python and go side. So the generator 
code should be clear.
   
   ### Description
   
   The go code for domain models is structured enough to be easily parsed and 
converted to python equivalent.
   The generator would follow 3 distinct steps:
   - Parsing go code from `backend/core/models/domainlayer/devops` (using e.g. 
tree-sitter-go)
   - Converting the ASTs into a simple Table/Column metamodel
   - Generate python code from the metamodel
   
   
   ### Related issues
   
   _No response_
   
   ### Are you willing to submit a PR?
   
   - [ ] Yes I am willing to submit a PR!
   
   ### Code of Conduct
   
   - [X] I agree to follow this project's [Code of 
Conduct](https://www.apache.org/foundation/policies/conduct)
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to