Skip to content

Refactor file structure - #257

Merged
adeas31 merged 8 commits into
OpenModelica:masterfrom
syntron:refactor_file_structure
Apr 25, 2025
Merged

Refactor file structure#257
adeas31 merged 8 commits into
OpenModelica:masterfrom
syntron:refactor_file_structure

Conversation

@syntron

Copy link
Copy Markdown
Contributor

Related Issues

See #254

Purpose

Separate the differnet classes / parser files such that specific commits touch only the corresponding file.
Use init.py only for the package related definitions (public interface of the package)

Approach

  • move classes from init.py into separate files (=> OMCSession; ModelicaSystem)
  • move OMParser/init.py into OMParser.py as it is just a directory

This is splitted into several commits such that the main change (move class definitions) can easily be rebased / redone

There are some smaller changes which I would add on top of this change / after #249

@syntron
syntronforce-pushed the refactor_file_structure branch from 2c6ce23 to 5fc1d97CompareApril 17, 2025 17:11
@syntronsyntron mentioned this pull request Apr 17, 2025
@adeas31

Copy link
Copy Markdown
Member

@syntron please fix conflicts.

@syntron

syntron commented Apr 23, 2025

Copy link
Copy Markdown
ContributorAuthor

@syntron please fix conflicts.

I can do the rebase; however, my recommendation is to merge #258 (and #262) before that (will be rebased first ;-))

@syntron
syntronforce-pushed the refactor_file_structure branch from 5fc1d97 to 742ed1cCompareApril 23, 2025 17:29
@syntron

Copy link
Copy Markdown
ContributorAuthor

rebase available

@syntronsyntron mentioned this pull request Apr 23, 2025
@adeas31

Copy link
Copy Markdown
Member

#258 and #262 are merged.

reason: cleanup; no need to use a sub-module / sub-directory
* dummy entries for the classes to move from __init__.py
* dummy entries for the classes to move from __init__.py
* fix imports based on merged changes
!! only copy & paste of the class definitions - *NO* further change !!
* OMCSessionBase => OMCSession.py
* OMCSessionZMQ => OMCSession.py
* ModelicaSystem => ModelicaSystem.py
* ModelicaSystemError => ModelicaSystem.py
@syntron
syntronforce-pushed the refactor_file_structure branch from 742ed1c to 5e0569cCompareApril 24, 2025 18:24
@syntron

Copy link
Copy Markdown
ContributorAuthor

rebased again; ready for merge!

@adeas31
adeas31 self-requested a review April 25, 2025 11:21
@adeas31
adeas31 merged commit 1c50417 into OpenModelica:masterApr 25, 2025
@syntron
syntron deleted the refactor_file_structure branch April 25, 2025 19:35
@syntronsyntron mentioned this pull request Jun 14, 2025
@adeas31adeas31 modified the milestones: 5.0.0, 4.0.0Aug 18, 2025
@syntronsyntron mentioned this pull request Sep 28, 2025
Sign up for freeto join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants

@syntron@adeas31