Delivery Issues

How to solve delivery problems in the Management Console

Xandy Strydom avatar
Written by Xandy Strydom
Updated this week

What are Delivery Issues?

A delivery issue (also referred to as a delivery error or delivery problem) is an error occurs after a form is submitted, and prevents your completed submission from delivering to a specific destination.


Where to find Delivery Issues?

If you have any delivery problems, a red notification will display on your Management Console's Home page, after the page has fully loaded. Click on "view issues" and a new page displaying your issues will load.

A Delivery Error is unique to a specific 'delivery job'. A delivery error will be created for each destination that has an issue for a specific submission ID. You could for example have a form with 3 destinations that have different issues in each of the 3 templates. In this case 3 different delivery errors would occur relating to 1 submission to a form.

When resending a Submission with a delivery error (from the Webstore), an additional 'delivery job' will be triggered and therefore create an additional delivery error if there is a problem.

The error message will include the following details:

  • Name and link to Form

  • Name and link to Destination

  • Name and link to Submitter (Device/Webforms User)

  • Submission ID

  • Submission Time (time the specific delivery job was triggered)

  • Next Delivery Attempt

  • Error Message with details on what is causing the issue


Options:

  • Retry: Retry the same Destination delivery attempt (delivery job)

  • Redirect: Choose a different destination

  • Edit Submission Values: View & edit submission values before retrying

  • Raw XML: View raw XML submission data.

  • Destroy: Permanently remove this specific destination's delivery job.
    This will not delete the original submission from the database. You can also resend the submission to this destination again from your form's database.

Note: You may not see all the button options if your Organization or User Role does not have permission. Contact support@devicemagic.com if you have any questions.


How do I solve these issues?

Below is a list with errors and solutions to help you solve these issue. This list is supplied as a "self-help" method.

Note: If you come across an error that is not yet on this list, please reach out to support@devicemagic.com.


Errors and Solutions:

DestinationDelivery::DestinationBusyError: Destination delivery 34970898 is currently delivering. Retry later.

  • This means the destination is busy but the submission will keep retrying.

  • This error usually resolves itself over time.


DropboxAuthError: User is not authenticated.

  • Please remove your Dropbox account and re-add it.

  • Please ensure that your username/password is correct and follow the instructions.


EmailAddressError: EmailTransport with ID 931805 has address 'myemail@domain.comon Email::AmazonSESEmailService bounce list

  • This error occurs when an email address has been bouncing emails.

  • Contact support@devicemagic.com to remove the email from the Bounce list.

  • Please check that there are no typos in the email address.


EmailAddressError: EmailTransport with ID 123456 has empty address list

  • This means you have an email address field in your form and when the form was submitted, it had no value.

  • Edit the submissions to contain a value for this field and click "Retry" on the delivery error.


Error Message: #<EmailAddressError: EmailTransport with ID 123456 has invalid address 'value' (showing first 123 characters)>

  • Issue: Trying to deliver to a 'value' that is not an email address.

  • Check Destination Settings "Destination Form Field".

  • This should only contain fields that will have an email address value.

  • Check article on how to use Destination Form fields.

  • Fix 1: Edit the field value to be a valid email address.

  • Fix 2: Remove any Destination Form Fields in your Destination Settings, that will not produce email address values.


Errno::ETIMEDOUT: Connection timed out - connect(2) for "115.112.206.109" port 22

  • Can’t find destination server running at specified URL + port.

  • Is this HTTP(s) destination? Make sure server has endpoint provided in destination settings and that it accepts requests on provided port.


Errno::ECONNREFUSED: Failed to open TCP connection to 197.81.199.35:4002 (Connection refused - connect(2) for "197.81.199.35" port 4002)

  • Can’t find destination server running at specified URL + port.

  • Is this HTTP(s) destination? Make sure server has endpoint provided in destination settings and that it accepts requests on provided port.


Error Message: #<Liquid::ArgumentError: Liquid error: Error in {% if fields.Question Name %}..{%endif%}: Liquid error: Unknown operator of>

  • An if statement (usually in a custom template) is trying to use an invalid field identifier.

  • This is usually due to unwanted spaces in the identifier or missing underscores.

  • For example, change {% if fields.Question Name %} to {% if fields.Question_Name %}.


Error Message: #<Liquid::ArgumentError: Liquid error: Unknown operator _>

  • An if statement (usually in a custom template) is trying to use "_" (underscore) as an operator.

  • Usually due to an unwanted space in a field identifier. Remove the space.


Error Message: #<Date::Error: Error in {{fields.repeat_group[5].Date_Question|date_time_format: "%Y" }}: Error applying option Word/options/date time format to field fields.repeat_group[5].Date_Question: invalid date>

  • This error is usually due to an invalid date format in the submission.

  • Date formats will need to be: yyyy-mm-dd

  • The example issue above shows a [5]: Check the 6th repeat group item for the invalid date.


Format::PdfFormat::WordToPdfConversionError: Conversion from Word to PDF failed with with error 'Conversion error. Internal exception


GoogleDrive::Error: Response code 400 while uploading file:Malformed multipart body

  • Unsupported characters in the file name.

  • Make sure data used in the file name does not contain special characters such as quotation marks.


GoogleDrive::ResponseCodeError: Response code 400 for put https://spreadsheets.google.com/feeds/worksheets/15DhcBQMy38x4uX6GNU2vrncIKAJ2uL_BfqK1_VRKX9w/private/full/oftup64: [Line 5, Column 43, element gs:colCount] The count must be specified.


GoogleDrive::Error: Response code 403 while uploading file:


GoogleDrive::DriveHelper::BlankFolderError: Error creating folder path ' /DeviceMagic/'. Tried to create a blank folder in folder path '/DeviceMagic'. Please check your folder path or repair the submission.

  • Some part of folder/file name is empty.

  • Make sure folder name is valid and contains no empty placeholders.


Error Message: #<RuntimeError: Failed to create directory - code 10

  • The folder path/file name may have an outdated placeholder - update placeholders to existing ones.

  • A folder path/file name placeholder question used may not have a submission value - Edit submission to insert a required value.

  • Make sure folder path/file name values are valid.


GoogleSpreadsheet::GoogleSpreadsheetError: Old Google Spreadsheet connections are being discontinued by Google. Please visit https://devicemagic.zendesk.com/hc/en-us/articles/204201708 to see how to upgrade to a Google Spreadsheet Destination - Error message: GData::Client::AuthorizationError - request error 401: HTML


Error Message: #<Google::Apis::RateLimitError: RESOURCE_EXHAUSTED


Error Message: Failed to retrieve Google Map


Magick::ImageMagickError: no decode delegate for this image format `' @ error/blob.c/BlobToImage/364

  • Attempting to dispatch an unsupported file type to an Image field (i.e. .pdf, etc.)


Error Message: #<Magick::ImageMagickError: attempt to perform an operation not allowed by the security policy `PDF' @ error/constitute.c/IsCoderAuthorized/449>

  • An invalid Image file type has been uploaded.

  • Only JPEG, PNG, BMP and GIF image files are accepted currently.

  • Make a copy of the form on the device and submit a valid file type.

  • Take a screenshot of the PDF if necessary.


Error Message: #<ActiveRecord::RecordInvalid: Validation failed: Name can't be blank>

  • The field used to create the Dispatch Name is blank.

  • Edit the Submission in the form's Device Magic Database, so that it contains a value for the field needed to populate the Dispatch Name. The field name can be found in your Dispatch Destination Settings.


Error Message: Expected(200) <=> Actual(403 Forbidden)

  • If the Form, Destinations, Submitter and Submission ID is unknown.

  • Fix: Wait a while and click "Retry". The delivery will process on its own in time.


Error Message: #<Excon::Error::Forbidden: Expected(200) <=> Actual(403 Forbidden)

  • Values being used in a Custom File Name may contain unwanted spaces before or after the value.

  • Punctuation used in these values/file name can also cause this issue.

  • Remove spaces and punctuation, then try and resend.


Net::HTTPServerException: 400 "Bad Request"


Net::HTTPFatalError: 500 "Internal Server Error"


Net::HTTPServerException: 404 "Not Found"


Error Message: #<Net::HTTPClientException: 404 "Not Found">


Net::HTTPServerException: 405 "Method Not Allowed"

  • Is this HTTP(s) destination? This error occurs when the web server is configured in a way that does not allow Device Magic to POST to it.

  • You may want to whitelist these IP addresses.


Net::HTTPServerException: 401 "Unauthorized"


Net::HTTPServerException: 413 "Request Entity Too Large"


Net::OpenTimeout: execution expired


Net::SMTPFatalError: Device Magic failed to send the email. 554 Message rejected: Stream is more than 10485760 bytes long. 

  • Is this custom SMTP details?

  • Message/attachments too big for email provider.


Net::SMTPAuthenticationError: Failed to send using custom SMTP details. Please check them. 535-5.7.8 Username and Password not accepted.

  • Username and password for the Destination were not accepted.

  • Always ensure that you manually type these details in as copy and paste has been known to cause errors.


NoMethodError: undefined method `gsub' for nil:NilClass


NoMethodError: undefined method `-' for nil:NilClass

  • This is usually a mistake on the template with one of your FOR loops or IF statement, where the % sign is at the beginning or the end of the statement is missing.

  • If you cannot find the problem, please contact support@devicemagic.com.


OAuth2::Error: invalid_grant: Invalid refresh token

  • Invalid refresh token.

  • Re-auth whatever destination/provider is causing this.


OnlyOneRefresher::RefreshBlockError: Only one delivery can refresh the Account token at a time. Please retry in a few minutes.

  • Trying to refresh token, but already being refreshed.

  • Wait, retry later.


Error Message: #<DropboxApi::Errors::ExpiredAccessTokenError: invalid_access_token/..>

  • Issue: Your Dropbox authentication token has expired.

  • Fix: Re-select the Dropbox account in the Destination Settings or add a new account in the Destination Settings.


Error Message: #<DropboxApi::Errors::HttpError: HTTP 401: {"error_summary": "invalid_access_token/.", "error": {".tag": "invalid_access_token"}}>

  • Issue: Your Dropbox authentication token has expired.

  • Fix: Re-select the Dropbox account in the Destination Settings or add a new account in the Destination Settings.


RuntimeError: Pdf format is not allowed on a free plan. Please upgrade to get access to this feature.

  • If you are a paying customer, check to see if your last payment has gone through and then contact support@devicemagic.com.

  • If you were a trial customer, your trial has ended.


Error Message: #<RuntimeError: Delivery with ID 123456789 cannot deliver this submission because org is running in limited functionality mode - Only submissions from the primary device are allowed.>

  • Your trial / subscription is no longer active.

  • If you are a paying customer, check to see if your last payment has gone through and then contact support@devicemagic.com.

  • If you were a trial customer, your trial has ended.


Error Message: #<Nokogiri::XML::XPath::SyntaxError: ERROR: Undefined namespace prefix: /w:document/w:body>

  • Check the template uploaded to your destination settings.

  • The template file uploaded to a PDF/Word destination will need to be a .docx file type.


RuntimeError: Missing endfor for 'for each' placeholder: {%for units_item in fields.Units%}>

  • Make sure you have included a for loop end for each for loop in your template

  • For more info and examples, please see this article.


RuntimeError: Sms transport is not allowed on a free plan. Please upgrade to get access to this feature.

  • If you are a paying customer, check to see if your last payment has gone through and then contact support@devicemagic.com.

  • If you were a trial customer, your trial has ended.


RuntimeError: Destination no longer exists. This error is permanent. Please redirect the job.

  • This means the destination the data is being sent to no longer exists (the destination was manually deleted).

  • Click the redirect button to send your submission data to a different destination.


RuntimeError: Connection no longer exists. This error is permanent. Please redirect the job.

  • Connections in general no longer exists.

  • Please click on redirect to send your submission data to a different destination.


RuntimeError: Submission 39585346 has image identifiers in payload but is missing image data.


RuntimeError: Delivery contains invalid numbers:

  • This relates to a phone number field in your form that was entered wrong.

  • Edit the submission values to fix the issue.


RuntimeError: For loop start and end mismatch - start is in table row but no end: {% for Sfoto in fields.Photos %}

RuntimeError: Error in {%for units_item in fields.Units%}..{%endfor%}: If start and end are in different containers for if {%for units_item in fields.Units%}>

  • This means that your For Loop statement has a start - end mismatch.

  • Please check your template to ensure these placeholders are correct.

  • For tables: The forloop start and for loop end will need to formatted to one of the following:
    - Both start and end in same cell.

    - Start in first column of row, end in last column of same row.

    - Both start and end outside of the table.

  • For more info and examples, please see this article.


RuntimeError: Failing delivery due to delivery only partially succeeding. Expected 4792, got 4786. Rolling back and retrying later.

  • Delivery expected not equal to delivery delivered.

  • This error can occur when the Google Sheet has been edited.

  • Remove any filtering from your Google Sheet and click "Retry" on delivery error.

  • Change the Spreadsheet Name in the Destination Settings and "Retry" deliver error to create a new Sheet.

  • If problem persists, contact support@devicemagic.com.


Signet::AuthorizationError: Authorization failed. Server message:


Trying to upload file with name Example.PNG for organization 12345 and Pending Submission 12345678 but file_name already exists with different data. Please use force_upload to upload it anyway or overwrite to replace the data.

  • Trying to upload image with same name but different data (Is this Zapier?).

  • Retry (if persists, contact support@devicemagic.com).


Failed to send using custom SMTP details. Please check them.

  • Check that the SMTP settings are correct.


Error Message: #<Net::SMTPFatalError: Failed to send using custom SMTP details. Please check them. 550 Stop! You are sending too fast

  • Check that the SMTP settings are correct.

  • If correct, check that your email service provider is not queuing/limiting the number of emails being processed.


Error Message: #<RuntimeError: Failing delivery due to delivery only partially succeeding.

  • Click "Retry" on the the Delivery Error.

  • If Google Sheet is very large, try moving some submission rows to another tab in the sheet.

  • If any filtering has been added to Google Sheet, remove all filtering.

  • If issue persists, please contact support@devicemagic.com.


Error Message: #<Errno::ENOTTY: Inappropriate ioctl for device>

  • Indicates that the Username and Password fields for a SFTP Destination have incorrect information or are out of date.

  • Enter/Re-enter username and password information into SFTP Destination and click update destination.


Error Message: #<NoMethodError: undefined method `[]' for nil:NilClass>

  • General: A needed value is missing in order to create the file / folder path / sheet name / submission row.

  • Dispatch Destination: You may be using an out-dated placeholder, a different form version's placeholder or there is a formatting issue.

  • Google Sheet Destination: Re-save your form in the Form Designer to create a new form version, send a new submission to create a new tab in your Google Sheet.


Error Message: #<NoMethodError: undefined method `<=' for nil:NilClass>

  • This error can be caused by an empty submission value that is needed for a Destination Rule condition.

  • Add an additional Destination Rule Condition at the top of your conditions list to check if the field "is not null".

  • Instead of '<=' , other undefined methods could be any like the following: 'include?' , '>=' , '>', '<', 'start_with?' etc.


Error Message: #<OAuth2::Error: {"code"=>"invalidRequest", "message"=>"The provided name cannot contain any illegal characters."

or

Error Message: #<OAuth2::Error: <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN""http://www.w3.org/TR/html4/strict.dtd">

  • One of the submission values used to generate the file name or folder path contains a period "." or colon ":" character.

  • OneDrive does not support these characters when creating folder names currently.

  • Edit your submission value to remove the period or colon ":" characters, and Retry the submission from the delivery error page.


Error Message: #<OAuth2::Error: invalid_grant: [ID]: The provided grant has expired due to it being revoked, a fresh auth token is needed. The user might have changed or reset their password.

  • Navigate to your Destination Settings.

  • At Step 3, click the authentication button to re-authenticate your account.

  • Save the Destination.

  • Click "Retry" on the Delivery Errors.


Error Message: #<RuntimeError: OnedriveTransport with ID 1234 has no Microsoft Account>

  • Please re-authorize your Onedrive account in your Destination Settings.


Error Message: #<OAuth2::Error: #<OAuth2::SnakyHash code="quotaLimitReached" inner_error=#<OAuth2::SnakyHash client_request_id="1a2b3c4d" date="2024-02-20T19:20:50" request_id="123456"> message="Quota limit reached">

  • Onedrive storage has been exceeded.

  • Clear storage in your Onedrive account.

  • Click "Retry" on Delivery Errors.


Error Message: #<StandardError: Organization SMS credit limit reached!>

  • You've reached your SMS credit limit for the month.

  • Retry the deliveries in the next month or contact support@devicemagic.com.


Error Message: #<IOError: closed stream>

  • Click "Retry" on the delivery error.

  • This issue should resolve itself in time.


Error Message: #<Format::PdfFormat::WordToPdfConversionError: Word to PDF converter request failed with with response 401 Unauthorized>


Error Message: #<RuntimeError: Sub Form 'Subform_Name' was not found in the form 'Form_Name'. Please check the form's dispatch destination placeholders for text containing: "subform.placeholder}}" and update as required.>

  • This issue typically occurs if there is a nested subform that was not active due to 'only-when' rules and the original submissions is being re-dispatched.

  • Use the information in the error to find the placeholder for the subform in the dispatch destination

  • Note the placeholder/s from the nested sub-form

  • Delete the placeholder/s from the nested sub-form and save the destination

  • Retry the failed delivery

  • If the delivery works correct add all placeholders back to the destination

  • If the delivery fails again repeat the above steps with the placeholder information from the current error


Error Message: Net::SMTPSyntaxError: 501 Invalid RCPT TO address provided

  • Unwanted ASCII symbols in emails address.

  • Unwanted space in or at the end of an email address.

  • Remove spaces & symbols



Error Message: #<Sequel::DatabaseConnectionError: TinyTds::Error: Unable to connect: Adaptive Server is unavailable or does not exist

  • Make sure your SQL server is accessible from outside your network.

  • Check/Adjust the firewall settings.

  • Allow the IP addresses in this article.


Error Message: #<Sequel::DatabaseError: TinyTds::Error: Invalid object name

  • Navigate to your SQL Destination Settings.

  • Check that the table name is selected, and reselect if necessary.

  • Save the destination and click "Retry" on delivery errors.

  • Reach out to support@devicemagic.com if you continue to have issues.


Error Message: #<Sequel::DatabaseConnectionError: Mysql2::Error: Bad handshake>

  • The MySQL version is not supported.

  • Please migrated to a newer version of MySQL.

  • Our recommendation is MySQL version 5.7 or more.

  • The MySQL server should support connections encrypted using TLSv1.2 protocol.

  • Retry the delivery error after making adjustments.


Error Message: #<Zip::Error: Zip end of central directory signature not found>

  • Incorrect file type uploaded for PDF or Word destination

  • Only .docx file types can be used for PDF or Word templates

  • Upload the correct file type and 'Retry'


Error Message: #<Mongo::Error::MaxBSONSize: The document exceeds maximum allowed BSON object size after serialization

  • Device Magic Destination maximum submission size of 16mb has been exceeded.

  • Device Magic Database Submissions are limited to < 16mb each.

  • View "Raw XML" on Delivery Error to gather submission values.


Error Message: #<Magick::ImageMagickError: Unsupported feature: Unsupported codec (4.3000) `/tmp/magick-ABC123' @ error/heic.c/IsHEIFSuccess/135>

  • The iOS is taking photos in an HEIF format instead of a JPEG format.

  • Images will need to be in a jpeg format in order to process.

  • In your iOS device's “Settings” menu, find “Camera.”, then select “Formats”. Change “High Efficiency,” (HEIC files) to “Most Compatible,” (JPEGs).

  • Make a copy of the submission in your device's Submissions tab, and resubmit the form.


Error Message: #<Net::HTTPServerException: 413 "Request Entity Too Large">

  • Maximum Submission payload size of 5GB has been exceeded.

  • Submissions are limited to < 5GB each.

  • View "Raw XML" on Delivery Error to gather submission values.


Error Message: #<EOFError: end of file reached>

  • If you are using an HTTP(S) Destination, it is likely your server not accepting the request.

  • Check your Firewall rules to see if it is able to accept requests, especially ones with large payloads.


Error Message: #<RuntimeError: Failed to post file to slack - channel_not_found">

Ask customer to try the following

  • Go to slack workspace

  • Go into the target channel

  • Type /invite @Device Magic

  • Hit Retry the request


Error Message: #<List::EntryError: Could not find all list entries to update, column identifier: Your_Column_ID, in list: Your_List_Name.>

If you are using a List Destination to update a row in an existing List:

  • Check if the value submitted for the Column ID exists in both the submission & List.
    Fix: Add value to List and retry delivery error.

  • Check that the Column ID value does not have any trailing spaces in both the submission & List.
    Fix: Edit values to have no trailing spaces.

  • Check for duplicate rows containing the same Column ID value in your List.
    Fix: Duplicate Column ID rows will need to be removed and then delivery retried.


Error Message: #<DeviceMagic::TypeConverter::UnknownType: DeviceMagic::TypeConverter::UnknownType>

  • If you are using a Calculated Question to pull answers from inside a Repeat Group, surround your expression with the CONCATENATE function to fix this issue.
    For example: CONCATENATE(Group[COUNT(Group) - 1]/Summary)

  • Use CONCATENATE() around any other associated expressions.


Error Message: Mysql2::Error: Deadlock found when trying to get lock; try restarting transaction

  • Check if statements in custom template for invalid field identifiers.

  • Reached out to support@devicemagic.com if you continue to have issues.


Error Message: #<Net::SSH::Exception: could not settle on host_key algorithm>

  • Check that the SFTP server key expected and encryption algorithm match.

  • Generate a new key pair.


If your delivery issue is not listed above, please contact support for further assistance at support@devicemagic.com.


Other Useful Articles:

Did this answer your question?