r"""
        Save traced modules information to a `JSON`_ file.

        If the file exists it is overwritten

        :param callables_fname: File name
        :type  callables_fname: :ref:`FileName`

        :raises: RuntimeError (Argument \\`fname\\` is not valid)

def save(self, callables_fname):
        r"""
        Save traced modules information to a `JSON`_ file.

        If the file exists it is overwritten

        :param callables_fname: File name
        :type  callables_fname: :ref:`FileName`

        :raises: RuntimeError (Argument \\`fname\\` is not valid)
        """
        # Validate file name
        _validate_fname(callables_fname)
        # JSON keys have to be strings but the reverse callables dictionary
        # keys are tuples, where the first item is a file name and the
        # second item is the starting line of the callable within that file
        # (dictionary value), thus need to convert the key to a string
        items = self._reverse_callables_db.items()
        fdict = {
            "_callables_db": self._callables_db,
            "_reverse_callables_db": dict([(str(k), v) for k, v in items]),
            "_modules_dict": self._modules_dict,
            "_fnames": self._fnames,
            "_module_names": self._module_names,
            "_class_names": self._class_names,
        }
        with open(callables_fname, "w") as fobj:
            json.dump(fdict, fobj)