NASA-AMMOS / NASA-AMMOS/AIT-GUI

AttributeError: 'AITDBResult' object has no attribute 'get_points'

Open
#258 4 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
JavaScript
Stars
31
Forks
15
Avg merge
1m
Merged PRs (30d)
1

Description

Description

 Traceback (most recent call last):
   File "/home/ait/.local/lib/python3.10/site-packages/bottle.py", line 876, in _handle
     return route.call(**args)
   File "/home/ait/.local/lib/python3.10/site-packages/bottle.py", line 1756, in wrapper
     rv = callback(*a, **ka)
   File "/home/ait/.local/lib/python3.10/site-packages/ait/gui/__init__.py", line 1286, in handle_playback_range_get
    packets = list(playback.dbconn.query("SHOW MEASUREMENTS").get_points())
 AttributeError: 'AITDBResult' object has no attribute 'get_points'
Versions
  • ait-core: 2.5.0
  • ait-gui: 2.4.1
  • influxdb: 5.3.1

Fix

Add .results before all uses of .get_points() to return ResultSet, e.g.:

list(playback.dbconn.query("SHOW MEASUREMENTS").results.get_points())

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start in ait/gui/init.py at handle_playback_range_get and search the repository for other uses of get_points() on database query results. Update the affected calls to use the query's results before get_points(), then verify the playback range path no longer raises the reported AttributeError.

Written by the indexing model from the issue text.

Assessment

Tech stack
python
Domain
backend, database
Issue type
Bug
Difficulty
2/5
Estimated time
1-3 hours
Activity status
Stale
Clarity
Clearly specified
Newbie friendliness
50/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.