-
Notifications
You must be signed in to change notification settings - Fork 4
Test pr 2, Don't merge #21
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
base: main
Are you sure you want to change the base?
Changes from 7 commits
aef5b14
054f4be
c17f499
133adf4
f64eeff
9e76ef5
5c929e8
216bbaa
5af800f
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| @@ -0,0 +1,8 @@ | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| print("Hello world") | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| print("Hello world 2") | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| print("Hello world 3") | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
|
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| print("Test PR 2.1") | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| print("Test PR 2.2") | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| print("Test PR 2.3") | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| print("Test PR 2.4") | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| print("Hello world") | |
| print("Hello world 2") | |
| print("Hello world 3") | |
| print("Test PR 2.1") | |
| print("Test PR 2.2") | |
| print("Test PR 2.3") | |
| print("Test PR 2.4") | |
| #!/usr/bin/env python3 | |
| """ | |
| Hello World Script | |
| This script demonstrates basic print statements in Python. | |
| It outputs multiple hello world messages followed by test messages. | |
| """ | |
| print("Hello world") | |
| print("Hello world 2") | |
| print("Hello world 3") | |
| print("Test PR 2.1") | |
| print("Test PR 2.2") | |
| print("Test PR 2.3") | |
| print("Test PR 2.4") |
Standards
- Clean-Code-Documentation
- SOLID-Single-Responsibility
Outdated
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.
Sensitive Data Exposure
The script outputs data directly to stdout without considering the execution context. In production environments, this could inadvertently expose sensitive information to logs or output streams that might be accessible to unauthorized users.
| print("Hello world") | |
| print("Hello world 2") | |
| print("Hello world 3") | |
| print("Test PR 2.1") | |
| print("Test PR 2.2") | |
| print("Test PR 2.3") | |
| print("Test PR 2.4") | |
| #!/usr/bin/env python3 | |
| import logging | |
| # Configure logging with appropriate level | |
| logging.basicConfig(level=logging.INFO, format='%(asctime)s - %(levelname)s - %(message)s') | |
| logger = logging.getLogger(__name__) | |
| # Use appropriate logging levels instead of print | |
| logger.info("Hello world") | |
| logger.info("Hello world 2") | |
| logger.info("Hello world 3") | |
| logger.info("Test PR 2.1") | |
| logger.info("Test PR 2.2") | |
| logger.info("Test PR 2.3") | |
| logger.info("Test PR 2.4") |
Standards
- CWE-209
- OWASP-A04
shivaji-dev1 marked this conversation as resolved.
Outdated
Show resolved
Hide resolved
Outdated
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.
Missing Final Newline
File ends without a newline character, which can cause issues with text processing tools and version control systems. Standard text files should end with a newline to ensure proper concatenation and processing.
| print("Test PR 2.4") | |
| print("Test PR 2.4") |
Standards
- File-Format-Standard
- POSIX-Compliance
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.
Missing error handling for print operations
Print operations can fail when stdout is unavailable (e.g., redirected to a closed pipe). Without error handling, this could cause script termination in non-interactive environments.
Standards