-
Notifications
You must be signed in to change notification settings - Fork 36
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
Add start_FABulator command to be able to run FABulator from the FABulous shell #227
Add start_FABulator command to be able to run FABulator from the FABulous shell #227
Conversation
We currently have the "-v" flag for verbose output. |
Would you then have to restart the shell with |
Btw, should it be run_FABulator or start_FABulator? |
Maybe use run_FABulator since it is more consistent.
If it does not start or some error raised then it should raise an error in the shell and show what causing the problem. What other information does the debug log include?
…________________________________
From: Jakob Ternes ***@***.***>
Sent: Saturday, August 17, 2024 1:09:20 PM
To: FPGA-Research-Manchester/FABulous ***@***.***>
Cc: King Chung ***@***.***>; Review requested ***@***.***>
Subject: Re: [FPGA-Research-Manchester/FABulous] Add start_FABulator command to be able to run FABulator from the FABulous shell (PR #227)
Btw, should it be run_FABulator or start_FABulator?
I'm probably overthinking it
—
Reply to this email directly, view it on GitHub [github.com]<https://urldefense.com/v3/__https://github.com/FPGA-Research-Manchester/FABulous/pull/227*issuecomment-2294841425__;Iw!!PDiH4ENfjr2_Jw!AQe_naAPBQ5jg1Hldn4MWhHlODCySCrCXsBx0o_gNFnbTVqQRZZkx2lQKBJmLPfbvQUrkhHSCYTg5pIaEwnMihbxWGbYzOj6$>, or unsubscribe [github.com]<https://urldefense.com/v3/__https://github.com/notifications/unsubscribe-auth/AQF2K6PJXLAXD53LU3NQWL3ZR44PBAVCNFSM6AAAAABMUTEVYSVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMZDEOJUHA2DCNBSGU__;!!PDiH4ENfjr2_Jw!AQe_naAPBQ5jg1Hldn4MWhHlODCySCrCXsBx0o_gNFnbTVqQRZZkx2lQKBJmLPfbvQUrkhHSCYTg5pIaEwnMihbxWGvZKyqk$>.
You are receiving this because your review was requested.Message ID: ***@***.***>
|
With the output of FABulator being logged to the FABulous shell, basically all sorts of user actions in FABulator are logged. Also the output of the startup procedure is logged when FABulator is started which is just a bunch of unnecessary text. Is this is similar to the other cases in which the -v option is used? Then I think this is the cleanest option. It should be documented though (I will do that), so users don't have to dig deep just to find the option to see FABulator output in the shell. |
The verbose is basically for anything that is not necessary for users. The better practice probably be a debug output that only output things that are important for debug, then one level for more detail debug and so on. But we have not done that anyway. |
I added the verbosity option and had to change the argument from |
Ideally, we should have that fixed. We can fix it later. I thought FABulator always needed the geometry to work. Is that not the case? |
You can start FABulator without having a geometry csv file. If you want to actually see the fabric in FABulator, then of course you'd have to go to File > Open and choose the geometry.csv file. We could think about also opening the file in FABulator at startup, but FABulator pretty much does that already on its own. It stores the last opened file and you can choose to automatically re-open it at startup |
When calling the command, start the GUI with the generated geometry.csv of the current project makes the best sense. If you want to start the FABulator and check other fabric geometry, you will likely run the FABulator directly without running the FABulaous CLI. We can have a toggle to enable GUI at startup, but it is probably not the default behaviour since some machines do not run any GUI. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for this! Everything looks good and works for me!
The way its currently set up, its not possible to pass program arguments at startup. That would require to build and package the application into a jar file and the run the jar file with the program argument.
We could also just assume that the user has already build and packaged FABulator into a jar and assume it exists. But since there are two ways of building and running FABulator, and the current one (which doesn't support passing program arguments) Maybe we could wait with this until the |
It is not something to worry about for now. Having the command enable the GUI accessible from the CLI is all we need. Those auto-start features can happen later. If you are happy with the current state, I will merge this. |
Added the link, I think we can merge this if the reviewers are happy as well :) |
39d59a4
into
FPGA-Research:FABulous2.0-development
The title pretty much sais it all...
I added the command in the FABulous2.0-development branch, is that correct?
Let me know if anything here should be changed.
The command basically just runs FABulator in a new process.
Before this is merged, I want to add an option to enable/disable logging to the start_FABulator command, as right now the output of FABulator is logged to the FABulous shell (Which can be very annoying if not intended).
I've pretty much got it all running locally already, but I'm not quite happy with how logging it enabled/disabled.
Ideally, you'd simpy be able to pass an additional flag such as -enable_logging, but I'm not sure how to do this in a clean way. Any suggestions are greatly appreciated!
In my quick and dirty solution, I basically just passed an optional argument to start_FABulator and checked if that argument (if it exists) == "-enable_logging".