Publisher does not support the Fluid field type. Please do not contact asking when support will be available.

If you purchased an add-on from expressionengine.com, be sure to visit boldminded.com/claim to add the license to your account here on boldminded.com.

Ticket: Entries fail to import because of missing IP Address

Status Resolved
Add-on / Version DataGrab 4.2.2
Severity
EE Version 7.2.16

Doug Black

May 22, 2023

Set up multiple imports, but all would fail according to the debugging because of a missing IP Address.

In `/modes/datagrab_model.php` @ line 810, I added:

$data['ip_address'] = "127.0.0.1";

Similar to what was in the comment import, and it worked.

Is there another way that IP address needs to be brought in?

#1

BoldMinded (Brian)

May 22, 2023

Shouldn’t EE be setting a default IP? This is the first time I’ve seen an error report like this, so I’m wondering what is unique to your environment or import process to fail when it works for everyone else. What was the actual message in the log file?

#2

Doug Black

May 22, 2023

As far as I know it should be setting it by default.

The actual message (paraphrasing as I fixed it temporarily) “ip_address DOES NOT HAVE A DEFAULT VALUE”. Happened during the entry creation part.dring the

#3

BoldMinded (Brian)

May 22, 2023

Can you try this instead?

if (!array_key_exists('ip_address', $data)) {
            $data['ip_address'] = '127.0.0.1';
        }
#4

Doug Black

May 22, 2023

That definitely worked for me with no issue!

#5

BoldMinded (Brian)

May 22, 2023

Great, I’ll include this in the v5 release. Thanks for pointing it out.

Login to reply