- File Permissions: The GitLab runner might not have the necessary permissions to write to the directory where the diary file is being saved. Ensure that the directory where you are trying to save the diary file is writable by the GitLab runner. You can modify the permissions or choose a directory with appropriate permissions.
- File Paths: The file path used in the `diary` function might be incorrect or not accessible in the GitLab environment. Use absolute paths instead of relative paths. Ensure that the path exists in the GitLab runner's environment. You can print the current working directory in your script to verify it.
- MATLAB Environment: The MATLAB environment in the GitLab runner might be different from your local environment, causing unexpected behavior. Check the MATLAB version and any environment variables that might affect the script's execution. Ensure consistency between local and CI environments.
- GitLab Runner Configuration: The configuration of the GitLab runner might restrict certain operations or not initialize the environment properly. Review the runner's configuration and logs for any errors or warnings. Ensure that the runner is set up to support MATLAB execution.
Matlab logging problem.
조회 수: 1 (최근 30일)
이전 댓글 표시
I am using diary in matlab to log the message. When I am runing that script throught the python in local system, the logging of message is taking place. But when the same script is run throught the Gitlab pipeline the logging is not taking place.
Please tell me what might be the problem for this and how can I overcome this problem.
Thank you.
댓글 수: 0
답변 (1개)
Prateekshya
2024년 8월 30일
Hello Mahesh,
When using MATLAB's `diary` function to log messages, and it works locally but not in a GitLab CI/CD pipeline, following can be the potential issues:
If you are still unable to resolve the error, please create a ticket in MathWorks Technical Support. I hope this helps!
댓글 수: 0
참고 항목
카테고리
Help Center 및 File Exchange에서 Scope Variables and Generate Names에 대해 자세히 알아보기
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!