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

QFileDialog.getSaveFileName and getOpenFileName return tuple not str #962

Closed
sparkalive opened this issue Sep 23, 2020 · 0 comments · Fixed by #963
Closed

QFileDialog.getSaveFileName and getOpenFileName return tuple not str #962

sparkalive opened this issue Sep 23, 2020 · 0 comments · Fixed by #963

Comments

@sparkalive
Copy link

getSaveFileName and getOpenFileName returns a tuple(file path and selected filter) in Qt5 and Qt.py, but rez gui is expecting the return value is a string.

Example errors:

Traceback (most recent call last):
  File "rezgui/windows/ContextSubWindow.py", line 101, in save_context_as
    self._save_context_as()
  File "rezgui/windows/ContextSubWindow.py", line 134, in _save_context_as
    self.context_model.save(filepath)
  File "rezgui/models/ContextModel.py", line 151, in save
    self._context.save(filepath)
  File "rez/resolved_context.py", line 541, in save
    with open(path, 'w') as f:
IOError: [Errno 2] No such file or directory: "(u'maya-2018', u'Context files (*.rxt)')"
@sparkalive sparkalive changed the title QFileDialog.getSaveFileName and getOpenFileName returns tuple not str QFileDialog.getSaveFileName and getOpenFileName return tuple not str Sep 23, 2020
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 a pull request may close this issue.

1 participant