Satnogs Client Develompment Error Version

After a standard installation of satnogs with an Ansible I decided to test satnogs-client build from source in virtualenv environment. I followed this guide from docs.

I got stuck at this error that I can’t get through. I thought that maybe satnogs_cw_decoder.py is misconfigured so I compiled all satnogs-flowgraphs and replaced files.

  File "/usr/bin/satnogs_cw_decoder.py", line 459, in <module>
    main()
  File "/usr/bin/satnogs_cw_decoder.py", line 444, in main
    tb = top_block_cls(antenna=options.antenna, bb_freq=options.bb_freq, bfo_freq=options.bfo_freq, bw=options.bw, dc_removal=options.dc_removal, decoded_data_file_path=options.decoded_data_file_path, dev_args=options.dev_args, doppler_correction_per_sec=options.doppler_correction_per_sec, enable_iq_dump=options.enable_iq_dump, file_path=options.file_path, gain=options.gain, gain_mode=options.gain_mode, iq_file_path=options.iq_file_path, lo_offset=options.lo_offset, other_settings=options.other_settings, ppm=options.ppm, rigctl_port=options.rigctl_port, rx_freq=options.rx_freq, samp_rate_rx=options.samp_rate_rx, soapy_rx_device=options.soapy_rx_device, stream_args=options.stream_args, tune_args=options.tune_args, udp_IP=options.udp_IP, udp_port=options.udp_port, waterfall_file_path=options.waterfall_file_path, wpm=options.wpm)
  File "/usr/bin/satnogs_cw_decoder.py", line 121, in __init__
    self.satnogs_waterfall_sink_0 = satnogs.waterfall_sink(audio_samp_rate, rx_freq, 10, 1024, waterfall_file_path, 1)
  File "/usr/lib/python3/dist-packages/satnogs/satnogs_swig0.py", line 5179, in make
    return _satnogs_swig0.waterfall_sink_make(samp_rate, center_freq, rps, fft_size, filename, mode)
RuntimeError: Could not create file for writing
satnogsclient.observer.observer - INFO - Tracking stopped.
satnogsclient.observer.worker - INFO - Tracking stopped.
satnogsclient.scheduler.tasks - INFO - Trying to GET observation jobs from the network
satnogsclient.observer.worker - INFO - Tracking stopped.
satnogsclient.observer.observer - INFO - Observation Finished
satnogsclient.observer.observer - INFO - Executing post-observation script.
satnogsclient.observer.observer - ERROR - Failed to rename encoded file
satnogsclient.observer.observer - ERROR - Failed to rename data file
satnogsclient.observer.observer - INFO - Creating waterfall plot.
satnogsclient.observer.waterfall - INFO - Read waterfall file
satnogsclient.observer.observer - ERROR - No waterfall data file found</msg> 

I can post the whole log, but this part seems to be enough.

Has this error happened to anyone else? The individual tests of these modules were successful and created an .ogg file.

Looks like a permissions error, but odd that it worked for the .ogg. I have a feeling the waterfall file is initially written to a temporary .dat then later converted to a png in a different directory? The .ogg may go straight to the latter? In which case, look at the permissions for the waterfall sink’s directory.

It worked when the flowgraph was executed by the user, maybe that satnogs user has a different approach. I had a similar error and decided to add satnogs to sudo group and ensure that it is in dialout to be able to use sdr correctly.

You are ritht @mat, waterfall.dat is saved in /tmp, which has all the editing rights. The file itself is owned by root for r/w and r for others. I changed permissions to .py files in usr/local/bin and /usr/bin and for satnogs_swig0.py. Also, dist-packages didn’t have write permission so I added it. No change in the output so far.