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

fatbuildrctl crash when preferences file not present #130

Closed
rezib opened this issue Jul 26, 2023 · 0 comments
Closed

fatbuildrctl crash when preferences file not present #130

rezib opened this issue Jul 26, 2023 · 0 comments
Assignees
Labels
bug Something isn't working
Milestone

Comments

@rezib
Copy link
Contributor

rezib commented Jul 26, 2023

When user preferences file is not present, fatbuildrctl crashes due to undefined UserPreferences.tokens_dir attribute. For example:

$ fatbuildrctl images create
Traceback (most recent call last):
  File "/usr/bin/fatbuildrctl", line 33, in <module>
    sys.exit(load_entry_point('Fatbuildr==2.0.0', 'console_scripts', 'fatbuildrctl')())
             ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/lib/python3/dist-packages/fatbuildr/cli/__init__.py", line 34, in run
    cls()
  File "/usr/lib/python3/dist-packages/fatbuildr/cli/fatbuildrctl.py", line 437, in __init__
    args.func(args)
  File "/usr/lib/python3/dist-packages/fatbuildr/cli/fatbuildrctl.py", line 503, in _run_images
    selected_formats = self.connection.pipelines_formats()
                       ^^^^^^^^^^^^^^^
  File "/usr/lib/python3/dist-packages/fatbuildr/cli/fatbuildrctl.py", line 458, in connection
    self.uri, ClientTokensManager(self.prefs.tokens_dir).load(self.uri)
                                  ^^^^^^^^^^^^^^^^^^^^^
AttributeError: 'UserPreferences' object has no attribute 'tokens_dir'
@rezib rezib added the bug Something isn't working label Jul 26, 2023
@rezib rezib added this to the v2.1.0 milestone Jul 26, 2023
@rezib rezib self-assigned this Jul 26, 2023
@rezib rezib closed this as completed in 611305a Jul 26, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

1 participant