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

fix bug: AttributeError: 'Namespace' object has no attribute 'localfile' for fetch command #196

Closed
wants to merge 7 commits into from

Conversation

huakim
Copy link
Contributor

@huakim huakim commented May 12, 2024

No description provided.

@mcepl mcepl self-requested a review May 18, 2024 12:20
Copy link
Contributor

@mcepl mcepl left a comment

Choose a reason for hiding this comment

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

Also, please, add more to the description of this PR: I really don’t know what error it actually fixes (traceback? reproducer?) and thus I really don’t understand and cannot review how this commits helps.

py2pack/__init__.py Outdated Show resolved Hide resolved
py2pack/version.py Outdated Show resolved Hide resolved
@huakim
Copy link
Contributor Author

huakim commented May 20, 2024

Also, please, add more to the description of this PR: I really don’t know what error it actually fixes (traceback? reproducer?) and thus I really don’t understand and cannot review how this commits helps.

Steps to reproduce:

  • 1: write 'py2pack fetch py2pack' to command line
    Expected result:
    py2pack tarball is downloaded
    Current result:
    traceback (most recent call):
    AttributeError: 'Namespace' object has no attribute 'localfile' for fetch command

The reason:
the object of Argparser class does not have local and localfile attributes, if we type 'py2pack fetch'
i added workaround with try - except, but, later, workaround was deleted
then i added one function 'fetch_local_data', which will work with attributes local and localfile, if none of these flags are provided, then 'fetch_local_data' function will call 'fetch_data' function

@mcepl mcepl requested review from danigm May 20, 2024 15:41
Copy link
Contributor

@mcepl mcepl left a comment

Choose a reason for hiding this comment

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

Looks to me all right now.

@mcepl mcepl self-requested a review May 20, 2024 15:41
@mcepl
Copy link
Contributor

mcepl commented May 20, 2024

Please, rebase.

huakim and others added 2 commits May 20, 2024 19:13
fix bug: AttributeError: 'Namespace' object has no attribute 'localfi…
@huakim
Copy link
Contributor Author

huakim commented May 20, 2024

Please, rebase.

i added new branch 'main'

@huakim huakim closed this May 20, 2024
@huakim huakim reopened this May 20, 2024
@huakim huakim closed this May 20, 2024
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.

2 participants