Skip to content

use custom log_file name as per the user setting #861

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

Open
wants to merge 4 commits into
base: rolling
Choose a base branch
from

Conversation

Tanishq30052002
Copy link

@Tanishq30052002 Tanishq30052002 marked this pull request as draft April 20, 2025 00:54
@Tanishq30052002 Tanishq30052002 force-pushed the accept_custom_log_file_name branch from 6b255cd to 1aa1d17 Compare April 20, 2025 00:54
@Tanishq30052002 Tanishq30052002 marked this pull request as ready for review April 20, 2025 01:06
Copy link
Contributor

@fujitatomoya fujitatomoya left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

test would be ideal to make sure the specified log file name is generated with ros2 launch --log-file-name command.

@Tanishq30052002
Copy link
Author

Tanishq30052002 commented Apr 21, 2025

test would be ideal to make sure the specified log file name is generated with ros2 launch --log-file-name command.

@fujitatomoya
I am not clear what you mean here.

@Tanishq30052002 Tanishq30052002 force-pushed the accept_custom_log_file_name branch 3 times, most recently from d2a724e to 82fffba Compare April 22, 2025 17:30
@christophebedard
Copy link
Member

Also, please take a look at the test results here: https://build.ros2.org/job/Rpr__launch__ubuntu_noble_amd64/164/testReport/. There are some flake8 linter issues and some test failures that seem to be related to your change. You can run the tests locally

@Tanishq30052002 Tanishq30052002 force-pushed the accept_custom_log_file_name branch 3 times, most recently from da8048e to 4905088 Compare April 25, 2025 10:45
@Tanishq30052002
Copy link
Author

Tanishq30052002 commented Apr 25, 2025

@christophebedard i have reolved all the issues and resolved the failing test.

@fujitatomoya can you please review it once again?

Copy link
Contributor

@fujitatomoya fujitatomoya left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@Tanishq30052002 thanks for working on this, had a couple of minor comments.

@fujitatomoya
Copy link
Contributor

test would be ideal to make sure the specified log file name is generated with ros2 launch --log-file-name command.

@fujitatomoya I am not clear what you mean here.

i am just suggesting unit tests for CI/CD to make sure nothing is broken during development.
since this PR changes LaunchService and LaunchConfig, i think we can add test to ensure file_name is properly handled in those classes. and as user interface, that would be nice to add test to https://github.com/ros2/launch_ros/tree/rolling/ros2launch/test. but i do not see any actually test cases exist for using ros2launch, so this one is probably nice to have.

@Tanishq30052002 Tanishq30052002 force-pushed the accept_custom_log_file_name branch 4 times, most recently from 2007297 to 035e6c4 Compare April 26, 2025 09:30
@Tanishq30052002
Copy link
Author

am just suggesting unit tests for CI/CD to make sure nothing is broken during development.
since this PR changes LaunchService and LaunchConfig, i think we can add test to ensure file_name is properly handled in those classes. and as user interface, that would be nice to add test to

ok, sounds good. I will create test for the same.
currently functionality is working and it is working as expected with failing any current tests

@Tanishq30052002 Tanishq30052002 force-pushed the accept_custom_log_file_name branch 2 times, most recently from 853dee5 to b11f212 Compare April 26, 2025 22:52
@Tanishq30052002
Copy link
Author

Tanishq30052002 commented Apr 27, 2025

am just suggesting unit tests for CI/CD to make sure nothing is broken during development.
since this PR changes LaunchService and LaunchConfig, i think we can add test to ensure file_name is properly handled in those classes. and as user interface, that would be nice to add test to

ok, sounds good. I will create test for the same. currently functionality is working and it is working as expected with failing any current tests

@fujitatomoya i have written tests for launch service and launch config. you may review it once and let me know if something more can be added.

Copy link
Contributor

@fujitatomoya fujitatomoya left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@Tanishq30052002 we are getting closer, and thanks for being patient and iterating with me. I have only a couple of minor things, could you please have a look? (thanks for adding test though.)

@Tanishq30052002 Tanishq30052002 force-pushed the accept_custom_log_file_name branch from b11f212 to 7006931 Compare April 30, 2025 15:43
@Tanishq30052002 Tanishq30052002 force-pushed the accept_custom_log_file_name branch 2 times, most recently from 46082df to b9992a3 Compare April 30, 2025 17:14
Copy link
Contributor

@fujitatomoya fujitatomoya left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@Tanishq30052002 i am not convinced to take this current change. please review my comments and let's not break the user space.

@Tanishq30052002
Copy link
Author

@Tanishq30052002 i am not convinced to take this current change. please review my comments and let's not break the user space.

I got your point, I will try to resolve these issues

@Tanishq30052002 Tanishq30052002 force-pushed the accept_custom_log_file_name branch from 1b6812c to 836e4b1 Compare May 2, 2025 17:02
@Tanishq30052002 Tanishq30052002 force-pushed the accept_custom_log_file_name branch 2 times, most recently from ee23578 to 7d10346 Compare May 6, 2025 17:45
@Tanishq30052002 Tanishq30052002 marked this pull request as draft May 6, 2025 17:51
@Tanishq30052002 Tanishq30052002 force-pushed the accept_custom_log_file_name branch from 7d10346 to fed5e2c Compare May 6, 2025 18:34
@Tanishq30052002 Tanishq30052002 force-pushed the accept_custom_log_file_name branch from fed5e2c to 7f3f0cc Compare May 6, 2025 19:07
@Tanishq30052002
Copy link
Author

@fujitatomoya i have reverted back changes and also squash multiple commits to keep the history clean.
Also there are some changes in test of logging which are neccessory for testing cutom file name logging.

Signed-off-by: Tanishq Chaudhary <[email protected]>
@Tanishq30052002 Tanishq30052002 marked this pull request as ready for review May 6, 2025 19:18
Sign up for free to 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.

Consider providing user control of log file base names
3 participants