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

Android table missing_value #1879

Closed
drkousek opened this issue Apr 17, 2023 · 0 comments · Fixed by #1913
Closed

Android table missing_value #1879

drkousek opened this issue Apr 17, 2023 · 0 comments · Fixed by #1913
Labels
android The issue relates to Android mobile support. bug A crash or error in behavior.

Comments

@drkousek
Copy link

Describe the bug

Missing_value in Table does not work on Android as intended.

Steps to reproduce

Step1: Use table in your project
Step2: Use more columns in your table than is in your data
Step3: get error 04-17 08:55:26.553 3636 3636 E AndroidRuntime: Caused by: com.chaquo.python.PyException: AttributeError: 'Row' object has no attribute 'short'

#this throws error on Android, but runs on Windows
self.data = [("root%s" % i, "value %s" % i) for i in range(1, 10)]
#this does throw error and runs on Android too
#self.data = [("root%s" % i, "value %s" % i, "short %s" % i) for i in range(1, 10)]

self.left_container = toga.Table(headings=["source", "number", "short"], data=self.data, on_select=self.get_file_content_and_display, missing_value="")

Expected behavior

App won't throw error and will fill missing values with blank string.

Screenshots

No response

Environment

  • Operating System: Windows 10
  • Python version: 3.10.10
  • Software versions:
    • Briefcase: 0.3.14
    • Toga: 0.3.1

Logs


Additional context

No response

@drkousek drkousek added the bug A crash or error in behavior. label Apr 17, 2023
@freakboy3742 freakboy3742 added the android The issue relates to Android mobile support. label Apr 17, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
android The issue relates to Android mobile support. bug A crash or error in behavior.
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants