eastgenomics / Ploutos

Code for the DNAnexus billing project.
MIT License
4 stars 0 forks source link

error when populating tar table #55

Open JasonLing95 opened 9 months ago

JasonLing95 commented 9 months ago

see below error message

Exception while running run() in 'scripts.populate_db'
Traceback (most recent call last):
  File "Ploutos/manage.py", line 22, in <module>
    main()
  File "Ploutos/manage.py", line 18, in main
    execute_from_command_line(sys.argv)
  File "/usr/local/lib/python3.8/site-packages/django/core/management/__init__.py", line 446, in execute_from_command_line
    utility.execute()
  File "/usr/local/lib/python3.8/site-packages/django/core/management/__init__.py", line 440, in execute
    self.fetch_command(subcommand).run_from_argv(self.argv)
  File "/usr/local/lib/python3.8/site-packages/django_extensions/management/email_notifications.py", line 65, in run_from_argv
    super().run_from_argv(argv)
  File "/usr/local/lib/python3.8/site-packages/django/core/management/base.py", line 402, in run_from_argv
    self.execute(*args, **cmd_options)
  File "/usr/local/lib/python3.8/site-packages/django_extensions/management/email_notifications.py", line 77, in execute
    super().execute(*args, **options)
  File "/usr/local/lib/python3.8/site-packages/django/core/management/base.py", line 448, in execute
    output = self.handle(*args, **options)
  File "/usr/local/lib/python3.8/site-packages/django_extensions/management/utils.py", line 62, in inner
    ret = func(self, *args, **kwargs)
  File "/usr/local/lib/python3.8/site-packages/django_extensions/management/commands/runscript.py", line 281, in handle
    run_script(script_mod, *script_args)
  File "/usr/local/lib/python3.8/site-packages/django_extensions/management/commands/runscript.py", line 159, in run_script
    exit_code = mod.run(*script_args)
  File "/app/Ploutos/scripts/populate_db.py", line 370, in run
    populate_tars_table()
  File "/app/Ploutos/scripts/populate_db.py", line 338, in populate_tars_table
    "size": project["size"],
KeyError: 'size'
JasonLing95 commented 8 months ago

can't re-create the issue even when running runscript populate_db. Issue seems to be a one-off instance - could include some kind of try clause to check for empty dnanexus result return