-
Notifications
You must be signed in to change notification settings - Fork 3
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
what board am I API endpoint #131
Comments
Once this is done, open a new issue for adjusting the "game" client accordingly. |
This also has implications for the experimental-point-control branch/map controller, as that is currently hardcoded to swtbahn-full -> can be made more flexible. |
The config.bahn file actually has the info we want - it starts with However, this name of the "module" in the BahnDSL config is not included by the BahnDSL compiler/generator in any of the other files, except for in form of a comment in the first line of a file (see this for example). One option would be to parse the comment of one (or more?) of the yaml config files, before starting the parser for the actual yaml contents. But this is pretty fragile and relies on the comment being there; a user (e.g., a new hiwi) would not expect that changing a comment in a yaml file could change how the system behaves. I can see two valid options: Either the name of the model railway being "served" has to be provided as a command line parameter when starting the server, or we must change BahnDSL to include the module name, in e.g., the extras_config.yml. However, I'm not sure how much work this would cause in BahnDSL, as I'm not too familiar with that codebase. I'll have a look and then decide. |
I got BahnDSL dev environment set up, and prototyped a little. Its pretty easy to add the name of the module defined in config.bahn in any of the yaml outputs. For the prototype, I put it into the extras_config.yaml like The problem: I'm not a maintainer for BahnDSL (thats Tri and Eugene only) and I have no idea how to do these releases and so on. Will ask Eugene how we want to resolve that. |
You can make a pull request over in https://github.com/trinnguyen/bahndsl and let @trinnguyen or I merge it into master. I'm only a contributor so @trinnguyen has to give you permission to do releases. |
Thanks a lot! |
Add an endpoint that returns the name of the model railway (e.g., swtbahn-full), here called "board" or "platform". Not to be confused with a "bidib board" or a platform in the sense of a station platform.
This name is currently not defined in the config files; one workaround could be to use the name of the folder the config files are located in.
The text was updated successfully, but these errors were encountered: