-
Posts
10,954 -
Joined
-
Last visited
-
Days Won
351
Everything posted by adrian
-
I haven't comprehended this is detail but in case it has any impact on the issue or @ryan's recent fix, please note this code in Tracy: https://github.com/adrianbj/TracyDebugger/blob/ae38175fe29fc7076dfa269145de98667cce76c7/TracyDebugger.module.php#L963-L966
-
Tracy error noticed in session string; can't get it to store a log?
adrian replied to BrendonKoz's topic in Tracy Debugger
The error message in the session cookie will be displayed in the console results pane on page reload - it's not logged because it will only ever be populated from code that is run in the console panel. -
Hi All, If there are any Canadians out there looking for full time work please DM me with some details of your PW experience. Experience with systems engineering and security implementation a big advantage. Cheers, Adrian
-
Tracy error noticed in session string; can't get it to store a log?
adrian replied to BrendonKoz's topic in Tracy Debugger
@BrendonKoz - the tracyCodeError cookie is only ever set by the Console Panel so I think that might not be related at all to the download issue. In fact I am not Tracy will be able to help you with that because the html download attribute isn't PHP. Or am I missing something? As for the tracy-2.x folders - each is a different version depending on the version of the PHP you are running: https://github.com/adrianbj/TracyDebugger/blob/d48ebdc0d962c34042651f82b388df93e872ab81/TracyDebugger.module.php#L355-L366 You can delete the unused ones if you want, but they'll just come back next time you update Tracy. May I ask why you want to delete them? -
I am running it on 3.0.247 without issues but let me know if you notice anything.
-
Honestly probably not that obvious so no worries at all.
-
Hi @psy - maybe I am not understanding exactly the issue. I have Tracy enabled on the frontend for superusers in development mode (with debug bar etc) and in production mode (allowing logging and reporting of errors via email/slack) for guest users. I don't think there should be any Tracy JS on the FE for guest users in production mode. Are you trying enable development mode for guest users? If so, then what you probably want it to just enable "Guest Dumps" - the button on the Selector panel. The other tool that might come in handy is the RequestLogger, but then again, I am not certain what you're actually doing - can you provide some code and context?
-
Really weird for sure but maybe the answer can be found in that function that is calling token_get_all() still - I think it should be pretty easy for you to figure out whether there is an issue reading the Functions.php file or getting the tokens from it by putting some bd() calls in the appropriate places to see where it's getting to.
-
@rick - please read this: https://processwire.com/talk/topic/29920-strange-console-panel-error/ and make sure your PHP install has token_get_all available.
-
I feel like I must be missing something very obvious, but I don't understand how you can get an undefined array key when doing an isset() on it. This is essentially what we are doing: Can you please take a look into those functions I mentioned above and figure out where they are failing to populate the ['pwFunctions'] key. I just have no idea how to reproduce and haven't had any other reports related to the API data functions in years. One final idea - I see that the line number of the error did change, so the files in /assets/cache/FileCompiler seem to be being updated, but I would maybe try deleting them all, just in case.
-
I am really baffled at the moment, but let's try to at least deal with fixing the error even if I can't figure out the actual cause. Can you please make this change in PwApiData.php and let me know if it helps. elseif($type == 'proceduralFunctions') { $proceduralFunctionsFunctions = $this->getProceduralFunctions('Functions'); $apiData = array('Functions' => isset($proceduralFunctionsFunctions['pwFunctions']) ? $proceduralFunctionsFunctions['pwFunctions'] : array()); if(file_exists($this->wire('config')->paths->core . 'FunctionsAPI.php')) $apiData += array('FunctionsAPI' => $this->getProceduralFunctions('FunctionsAPI')['pwFunctions']); } It should prevent the error, although we might end up with another one for $this->getProceduralFunctions('FunctionsAPI')['pwFunctions']) but that can be fixed the same way. I'd rather know why these aren't being populated though so if you feel like looking into the getProceduralFunctions() and getFunctionsInFile() to see where/why it's failing, that would be helpful. I can't figure out why this isn't being reported by anyone else. I thought perhaps it might be a file permission issue with reading the core Functions.php and FunctionsAPI.php files but when I made these unreadable, I got a very different error.
-
Can you please post the entire contents of what you see when you open those broken panels
-
I am sorry, I really have no idea at the moment. Could you try enabling the API Explorer panel for at least one load and see if that fixes things?
-
PW and PHP versions?
-
This is where you would tell me if deleting those got rid of that Undefined array key "pwFunctions" error 😁
-
Hi @rick - what version did you upgrade from? I am just wondering if perhaps it's a really old version and there is some cache from the PwApiData process that needs to be cleared. Could you do this search and delete all entries
-
Sorry, I don't have any ideas why the challenge is getting corrupted like that but there is something in the back of my brain saying it's seen something similar before - if I remember, I'll let you know. On a side note, have you seen this WebAuthn module: https://processwire.com/modules/tfa-web-authn/
-
@Robin S - I was just testing on a different site (where I hadn't yet checked the clear network cache) and came across the same error that @Macrura reported above. I just updated to 0.5.2 and that seems to have fixed that along with the issue I reported. Thank you!
-
Hi @psy - I don't think this is a Tracy issue. It seems like there is an unserialize call somewhere - can you see one in Tracy's callstack? Maybe you can post the entire HTML of it? Is your module trying to integrate: https://github.com/lbuchs/WebAuthn ? There are lots of results on Google about this error: https://www.google.com/search?q="the+script+tried+to+call+a+method+on+an+incomplete+object.+Please+ensure+that+the+class+definition"&oq="the+script+tried+to+call+a+method+on+an+incomplete+object.+Please+ensure+that+the+class+definition"&gs_lcrp=EgZjaHJvbWUyBggAEEUYOTIGCAEQLhhA0gEJMTM1NjlqMGoxqAIAsAIA&sourceid=chrome&ie=UTF-8 but kinda hard to figure out the cause in this case without seeing the rest of Tracy's stack trace.
-
@elabx - yeah, maybe - I think in both cases it would happen if the fieldgroup_fields table was incorrectly updated. @ryan??
-
2-stage selector not working as expected [SOLVED]
adrian replied to MarkE's topic in API & Templates
I think you've just come across another one of those cases where in-memory selectors don't match DB ones 😖 -
Anything is possible 😁, but honestly you might be better off going with Ryan's PageEditChildren pro module (part of Profields). I know it's not as quick an interface but its approach would allow for a better experience for all sorts of field types. Another option that might suit you is BCE's Lister mode - I am not sure but I think I could make it possible to turn on its inline editing mode (might require ListerPro) and it would be fairly close to what you're looking for. Otherwise, please feel free to submit a PR for adding custom fields to the editing interface. Probably only available from the separately configurable parent Settings tab and you'd probably need to limit to text and maybe textarea fields. Probably not too hard to implement.
-
Hi @virtualgadjo - in PW the system dates (created, modified, published) always return a timestamp regardless of whether outputformatting is on or not. In the latest version I have added new options for system fields to export so there are now formatted versions along with the timestamp ones. I though this was better than just using the Format Export to control this because I can see wanting these independent of whether the rest of the fields are formatted or not. Hope that helps.
-
@elvina - I am not sure if you will need textarea fields instead of text. I couldn't test text because they were broken for me in the Table GUI - I don't know why - maybe that's a question for Ryan. If you look at the code I added to support ML (https://github.com/adrianbj/TableCsvImportExport/commit/b1cf4b9d9c396f7f50e8a33a7b8ba871614a6f50), I think it should work fine for any text field. I assume you are separating the different values for each language with the multiple values separator and they are in the same order as the languages in the PW admin.
-
Does it return them with links to edit those pages, or just view them? For me it returns the view link which is fine.