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

Removed redundant call to __init__() and replaced os.makdir with pat… #81

Merged
merged 1 commit into from
Mar 1, 2024

Conversation

MuditJ
Copy link
Contributor

@MuditJ MuditJ commented Feb 29, 2024

Since Parser is the main class, we dont need a call to super().init() here. Accordingly, I have also updated the docstring for this class and replaced call to os.makedir() with pathlib.Path.mkdir.

@MuditJ MuditJ changed the title Removed redundant call to __init__() and replaced os.makdirs with pat… Removed redundant call to __init__() and replaced os.makdir with pat… Feb 29, 2024
Copy link
Owner

@kraanzu kraanzu left a comment

Choose a reason for hiding this comment

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

Thanks man!
Just need to make one more change and then I can merge it :)

@@ -58,7 +55,7 @@ def _create_user_config(self) -> None:
Creates a new config
"""

os.makedirs(self.config_path, exist_ok=True)
Path(self.config_path).makedir(parents=True, exist_ok=True)
Copy link
Owner

Choose a reason for hiding this comment

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

The config_path is already a Path object so no need to wrap it inside Path :)

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Done.

@eklairs eklairs merged commit 1cfdc00 into kraanzu:develop Mar 1, 2024
2 checks passed
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.

3 participants