<commit_before>'use strict';

var debug = require('debug')('ftp-stream');
var deferred = require('deferred-stream');
var FtpClient = require('ftp');
var File = require('vinyl');
var async = require('async');

function _streamFtpGet(ftpConnectOptions, files, deferredStream) {
      var c = new FtpClient();
      c.on('error', function(e) {
		deferredStream.emit('error', e);
	});

      c.on('ready', function() {
        debug('ready to download %s', files);
<commit_msg>add debug on error<commit_after>'use strict';

var debug = require('debug')('ftp-stream');
var deferred = require('deferred-stream');
var FtpClient = require('ftp');
var File = require('vinyl');
var async = require('async');

function _streamFtpGet(ftpConnectOptions, files, deferredStream) {
      var c = new FtpClient();
      c.on('error', function(e) {
                debug('Connection Error: %s', e);
		deferredStream.emit('error', e);
	});

      c.on('ready', function() {
        debug('ready to download %s', files);

{'fraction_non_alphanumeric': 0.17582417582417584, 'fraction_numerical': 0.0, 'mean_word_length': 4.273684210526316, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 2, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '6290426', 'n_tokens_mistral': 319, 'n_tokens_neox': 301, 'n_words': 79}