Wedge

Public area => The Pub => Importing into Wedge => Topic started by: Leftie on May 7th, 2014, 12:00 AM

Title: Importing from SMF 2.0.7 - "Cannot set time limit"
Post by: Leftie on May 7th, 2014, 12:00 AM
Using the SMF 2.0 to Wedge importer (downloaded today) with the newest nightly build of Wedge.
The importer fails at "step=1", with the following error:

Code: [Select]
Message: set_time_limit(): Cannot set time limit due to system policy
Trace: set_time_limit(): Cannot set time limit due to system policy
Line: 1513
File: /<redacted path>/import.php

I'm guessing it is some sort of DB authorization that's missing, but I don't know enough about this stuff to know where to start looking. Would anyone care to enlighten me?
Title: Re: Importing from SMF 2.0.7 - "Cannot set time limit"
Post by: Leftie on June 10th, 2014, 01:03 PM
Thanks @foo for this post(http://wedge.org/pub/8656/moving-from-smf-2-rc5-to-wedge-alpha-a-success-story/), thus providing the hints I needed to get my old SMF forum imported into my Wedge install.

However, I'm now facing a new problem, and I'm not sure where the error really lies.
After the import, whenever I generate a new page (as an admin user), I get a new entry (or two) in the Error Log of one of the following types:

Code: [Select]
index.php?action=admin;area=logs;sa=errorlog
8: Undefined index: homepage
Admin.php
Line: 71
Code: [Select]
index.php?action=admin;area=featuresettings;sa=b…
8: Undefined index: homepage_desc
ManageSettings.php
Line: 87

The error manifests as a missing menu item as well as a missing page in the Admin panel (see attached images).
I do have a custom homepage entry, but I've checked the database, and it's unaltered since before the import.

Any help in correcting this would be greatly appreciated.
Title: Re: Importing from SMF 2.0.7 - "Cannot set time limit"
Post by: Infernus on June 10th, 2014, 01:52 PM
Looks like you are missing translations for this strings(or whatever it could be) that doesn't exists in default wedge repository. Is it a plugin, or what is it, that modified these files where error occurred?

I think it's safe to remove those strings, until they are not bound to anything. But best would be to restore these files from github.
Title: Re: Importing from SMF 2.0.7 - "Cannot set time limit"
Post by: Nao on June 10th, 2014, 02:15 PM
Purge cache (Admin menu). If this doesn't fix it, make sure the language files are up to date.
Title: Re: Importing from SMF 2.0.7 - "Cannot set time limit"
Post by: Leftie on June 10th, 2014, 02:51 PM
:oops:
Purging the cache solved it, of course.
I've read it so many times on this forum, but still I managed to completely forget it.

Jot this down as PICNIC or PEBKAC then :whistle:
Title: Re: Importing from SMF 2.0.7 - "Cannot set time limit"
Post by: Nao on June 10th, 2014, 05:10 PM
I checked out the importer script, and it IS using the @ error suppress command for set_time_limit() (as this would normally bypass any errors from the server), which implies that your host is a bad one that doesn't care that tons of scripts will never install without making changes to them. Great...
Title: Re: Importing from SMF 2.0.7 - "Cannot set time limit"
Post by: Nao on June 15th, 2014, 01:54 AM
I'm wondering if doing a function_exists or is_callable call on 'set_time_limit' would result in a positive or negative result from your server, Leftie...?

Do you know how to test that?
Title: Re: Importing from SMF 2.0.7 - "Cannot set time limit"
Post by: Leftie on June 17th, 2014, 10:30 AM
Let's start with what I do know how to do, so this doesn't make me look like a complete idiot ::)
I know how to code (java, C, assembly, perl, bash) and use functions from different APIs.

I haven't done any web-related coding though, so I'm unsure of how to get the output I'm looking for. That is; how do I display the return value in a usable manner? I do understand what you're asking for, and realize that it's probably less than five lines of code, but if you could whip up a test for me, I'll be glad to run it for you :)