Skip to content
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

[Bug]: Profiler console output contains invalid characters #41577

Closed
HindujaB opened this issue Oct 26, 2023 · 3 comments · Fixed by #41823
Closed

[Bug]: Profiler console output contains invalid characters #41577

HindujaB opened this issue Oct 26, 2023 · 3 comments · Fixed by #41823
Assignees
Labels
OS/Windows Team/jBallerina All the issues related to BIR, JVM backend code generation and runtime Type/Bug

Comments

@HindujaB
Copy link
Contributor

Description

$subject

Steps to Reproduce

Create a bal package and run bal profile.

Screenshot (2)

Note the ? character in the console output.

Affected Version(s)

2201.8.2

OS, DB, other environment details and versions

Windows 10

Related area

-> Runtime

Related issue(s) (optional)

No response

Suggested label(s) (optional)

No response

Suggested assignee(s) (optional)

No response

@HindujaB HindujaB added Type/Bug Team/jBallerina All the issues related to BIR, JVM backend code generation and runtime OS/Windows labels Oct 26, 2023
@gabilang gabilang moved this to Planned for Sprint in Ballerina Team Main Board Dec 12, 2023
@gabilang gabilang moved this from Planned for Sprint to In Progress in Ballerina Team Main Board Dec 14, 2023
@gabilang
Copy link
Contributor

It's due to the code-page used in windows CMD is 437 by default. This code-page prevents to show the Unicode characters properly. If we change the code-page to 65001, it will show the Unicode characters properly.

We can change the code-page of the windows CMD by using the command chcp 65001.

@gabilang gabilang moved this from In Progress to PR Sent in Ballerina Team Main Board Dec 18, 2023
@gabilang
Copy link
Contributor

In order to keep a consistent terminal/cmd output pattern across platforms, we can use a character which is supported in the code-page 437 for bulleting or we can remove the bullets.
As per an offline discussion, we decided to not to use bullets instead use right indentation.
The output log is going to look as follows,

================================================================================
Ballerina Profiler: Profiling...
================================================================================
Note: This is an experimental feature, which supports only a limited set of functionality.
[1/6] Initializing...
[2/6] Copying executable...
[3/6] Performing analysis...
[4/6] Instrumenting functions...
      Instrumented module count: 44
      Instrumented function count: 3981
[5/6] Running executable...

Copy link

github-actions bot commented Jan 3, 2024

This issue is NOT closed with a proper Reason/ label. Make sure to add proper reason label before closing. Please add or leave a comment with the proper reason label now.

      - Reason/EngineeringMistake - The issue occurred due to a mistake made in the past.
      - Reason/Regression - The issue has introduced a regression.
      - Reason/MultipleComponentInteraction - Issue occured due to interactions in multiple components.
      - Reason/Complex - Issue occurred due to complex scenario.
      - Reason/Invalid - Issue is invalid.
      - Reason/Other - None of the above cases.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
OS/Windows Team/jBallerina All the issues related to BIR, JVM backend code generation and runtime Type/Bug
Projects
Archived in project
Development

Successfully merging a pull request may close this issue.

2 participants