Skip to content

ftplib error on successful carbon run #112

@ghukill

Description

@ghukill

A recent PR indicated that even successful runs of Carbon may log some errors related to the FTP file upload. Here is an example of those logs:

2023-09-20T14:35:18.299-04:00 | 2023-09-20 18:35:18,299 INFO carbon.cli.main(): Logger 'root' configured with level=INFO
-- | --
  | 2023-09-20T14:35:18.299-04:00 | 2023-09-20 18:35:18,299 INFO carbon.cli.main(): Carbon config settings loaded for environment: stage
  | 2023-09-20T14:35:18.692-04:00 | 2023-09-20 18:35:18,692 INFO carbon.database.run_connection_test(): Testing connection to the Data Warehouse
  | 2023-09-20T14:35:19.438-04:00 | 2023-09-20 18:35:19,438 INFO carbon.database.run_connection_test(): Successfully connected to the Data Warehouse: 10.2.0.5.0
  | 2023-09-20T14:35:19.477-04:00 | 2023-09-20 18:35:19,477 INFO carbon.app.run_connection_test(): Testing connection to the Symplectic Elements FTP server
  | 2023-09-20T14:35:19.578-04:00 | 2023-09-20 18:35:19,578 INFO carbon.app.run_connection_test(): Successfully connected to the Symplectic Elements FTP server
  | 2023-09-20T14:35:19.579-04:00 | 2023-09-20 18:35:19,579 INFO carbon.cli.main(): Carbon run has started.
  | 2023-09-20T14:35:43.851-04:00 | 2023-09-20 18:35:43,851 INFO carbon.app.write(): The feed has collected 19461 'people' records
  | 2023-09-20T14:35:43.852-04:00 | Exception in thread Thread-1:
  | 2023-09-20T14:35:43.852-04:00 | Traceback (most recent call last):
  | 2023-09-20T14:35:43.852-04:00 | File "/usr/local/lib/python3.11/threading.py", line 1038, in _bootstrap_inner
  | 2023-09-20T14:35:43.854-04:00 | self.run()
  | 2023-09-20T14:35:43.854-04:00 | File "/usr/local/lib/python3.11/threading.py", line 975, in run
  | 2023-09-20T14:35:43.855-04:00 | self._target(*self._args, **self._kwargs)
  | 2023-09-20T14:35:43.855-04:00 | File "/carbon/app.py", line 167, in __call__
  | 2023-09-20T14:35:43.856-04:00 | ftps.storbinary(cmd=f"STOR {self.path}", fp=self.content_feed)
  | 2023-09-20T14:35:43.856-04:00 | File "/carbon/app.py", line 67, in storbinary
  | 2023-09-20T14:35:43.856-04:00 | return self.voidresp()
  | 2023-09-20T14:35:43.856-04:00 | ^^^^^^^^^^^^^^^
  | 2023-09-20T14:35:43.856-04:00 | File "/usr/local/lib/python3.11/ftplib.py", line 259, in voidresp
  | 2023-09-20T14:35:43.856-04:00 | resp = self.getresp()
  | 2023-09-20T14:35:43.856-04:00 | ^^^^^^^^^^^^^^
  | 2023-09-20T14:35:43.856-04:00 | File "/usr/local/lib/python3.11/ftplib.py", line 252, in getresp
  | 2023-09-20T14:35:43.856-04:00 | raise error_temp(resp)
  | 2023-09-20T14:35:43.856-04:00 | ftplib.error_temp: 425 Error while transfering data: ECONNABORTED - Connection aborted
  | 2023-09-20T14:35:43.857-04:00 | 2023-09-20 18:35:43,857 INFO carbon.cli.main(): Carbon run has successfully completed.

Given that the upload is successful, it doesn't feel urgent to address this, but creating this issue to follow-up on these intermittent (?) errors.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions