Skip to content

Commit

Permalink
Remove: feed self test check (#896)
Browse files Browse the repository at this point in the history
The feed self test is not performed anymore. This remove the dependency from ospd-openvas to the sync script
However, the OSP 'check_feed' command still returns the elements with default values, for backward comaptibility, since gvmd still expects them.
``` xml
<self_test_exit_error>0</self_test_exit_error>
<self_test_error_msg/>
```
  • Loading branch information
jjnicola committed May 8, 2023
1 parent 6e4ae24 commit 51ee063
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 83 deletions.
9 changes: 4 additions & 5 deletions ospd_openvas/daemon.py
Expand Up @@ -53,7 +53,6 @@
from ospd_openvas.openvas import NASLCli, Openvas
from ospd_openvas.vthelper import VtHelper
from ospd_openvas.messaging.mqtt import MQTTClient, MQTTDaemon, MQTTSubscriber
from ospd_openvas.feed import Feed

SENTRY_DSN_OSPD_OPENVAS = environ.get("SENTRY_DSN_OSPD_OPENVAS")
if SENTRY_DSN_OSPD_OPENVAS:
Expand Down Expand Up @@ -655,10 +654,10 @@ def check_feed_self_test(self) -> Dict:
else:
feed_status["lockfile_in_use"] = '1'

feed = Feed()
_exit_error, _error_msg = feed.perform_feed_sync_self_test_success()
feed_status["self_test_exit_error"] = str(_exit_error)
feed_status["self_test_error_msg"] = _error_msg
# The feed self test is not performed any more, but the following
# entries are kept for backward compatibility.
feed_status["self_test_exit_error"] = "0"
feed_status["self_test_error_msg"] = None

return feed_status

Expand Down
36 changes: 0 additions & 36 deletions ospd_openvas/feed.py

This file was deleted.

42 changes: 0 additions & 42 deletions tests/test_feed.py

This file was deleted.

0 comments on commit 51ee063

Please sign in to comment.