Jump to content

adrian

PW-Moderators
  • Posts

    10,902
  • Joined

  • Last visited

  • Days Won

    349

Everything posted by adrian

  1. I would put Tracy in Strict Mode (you can toggle this via the button in the Panel Selector). This way you'll get the Tracy "bluescreen" which will show you a full stack trace so you can figure out what line in your module is causing the problem, rather than the final WireDatabasePDO.php as reported in the warning. The warning is clear that you are providing an array instead of a string, but this will help you figure out where this is happening.
  2. Hey @bernhard - I think it could be a very useful action actually. These are the sorts of things that I come across fairly regularly and an action makes it so much easier. Would you like to create an action and submit a PR?
  3. I'm old school in this regard, but I install all the bits I need via homebrew. Here is a pretty nice guide to getting things up and running: https://getgrav.org/blog/macos-sierra-apache-mysql-vhost-apc
  4. I am surprised you are seeing trashed pages returned in a find call in the first place. Are you using "include=all" in the selector as well - I think that is the only way it will return trashed items.
  5. Another one for you: On the Input tab of a Page Reference field with an AsmSelect inputfield, choose custom for the label field. This enables the "Custom page label format" field, but see how it's below the "Max Limit of Items" option. On UikIt with the newish "percentage" inputfield column widths option.
  6. Been meaning to report this for a while. When the ASM search box option is enabled, the width of the dropdown is too narrow and look item titles wrap which looks ugly and confusing. I am seeing this in the UikIt theme - not sure about the others. Thanks for taking a look!
  7. Good to know - I haven't enabled that section in my RequestInfo panel in forever - I guess that's why I am not seeing the issue with repeater fields. Thanks for narrowing it down.
  8. I guess it's a matter of figuring out what part of that panel is causing the problem. It will most likely be the "Field List & Values" section. So you could try disabling that section only in the module config settings. If everything is still fine with the panel enabled, but that section disabled, then we need to figure out what bit of code in that section is causing the problem. Here's the code for that section: https://github.com/adrianbj/TracyDebugger/blob/2689b8ccc57bd5776a21cf6413a400c68d71a555/panels/RequestInfoPanel.php#L450-L473 In particular I would recommend looking through the getFieldArray() method that it calls. If you feel up to investigating the cause, that would be greatly appreciated. Otherwise, I will need to get some more details about that repeater field, because I have many sites with lots of repeater fields and haven't noticed a problem, so would need to be able to reproduce to debug. Thanks for your help so far.
  9. Hi @vmo - thanks for the hard work narrowing it down to repeaters on the homepage. I have no idea why though at this point. I think the one thing you missed in your debugging was unchecking all the debugbar panels. It would be helpful to know if that helps. If it does, try to narrow it down it a particular panel - most likely the RequestInfo panel. If that doesn't help, then sure send me the zip - I might not have time to look for a little while though.
  10. Glad you like it - thanks for letting me ? @Robin S - I haven't forgotten about your request for validation - just no time at the moment - sorry!
  11. Hi @vmo - sorry I don't have any idea why you'd be getting a 404. Can you try unchecking all panels via the Panel Selector and see if that helps. Also, do older versions of Tracy work any better? Is this a local or server install? What OS are you running? Apache or Nginx? Could you try another install on the same server? Could you try the Module Disabler panel to disable all other modules to see if there is a conflict?
  12. This is when AdminActions (https://processwire.com/talk/topic/14921-admin-actions/) comes in handy: I will get around to providing this as a proof of concept action at some point, but this is what my import page looks like: This has been working great for me because I get to tweak the SQL queries (that I use to generate the CSV files that this action uses) and easily re-import. Just name the CSV files to match the template and this list is automatically generated: It also makes it easy to test with importing a few, many, all, or a selected one: I am going to use this for all my future site migrations.
  13. @MarcoPLY - I haven't used it in a while and unfortunately I don't have time to offer any support, but take a look at: https://github.com/nicoknoll/MigratorWordpress
  14. Me again ? From what I can tell, the find() method only works with recurring dates, or single date events that had the repeat toggle on at some point such that the "dates" json property is populated even if repeat is no longer on. Is there a way to find single date, non-repeating events? This is obviously a critical feature, but from what I can tell the find method's converted selector before being passed to $pages->find only looks for W months/years. Thanks for any help to explain what I am missing here.
  15. Not sure if this is expected or not, but after doing a $recurme->find() and iterating through the returned pages I get this error because there is an image field on the event page. Error: Exception: New page '//' must be saved before files can be accessed from it The "fix" is to do $event->original so I am getting the original page object but this seems like it should not be unnecessary. Any thoughts or am I doing something wrong?
  16. Hey @bernhard - regarding your fd() idea - is there a major difference between it and using l() which already dumps to Tracy log files?
  17. @joshuag - I wanted to point out that the module is generating an invalid RRULE. The RRULE should not include DTSTART, but it should be separate. Instead of this: WKST=MO;FREQ=WEEKLY;DTSTART=20180611T093000Z;INTERVAL=1;BYDAY=MO;UNTIL=20180831T235900Z it should be: DTSTART:20180611T093000Z RRULE:FREQ=WEEKLY;UNTIL=20180831T235900Z;BYDAY=MO The spec also has a separate DTEND which might be worth including. Thanks for looking into fixing this! PS - Have you considered making use of either: https://github.com/rlanvin/php-rrule or https://github.com/simshaun/recurr to do some of the heavy lifting for you? Just out of interest, I am using php-rrule to present the RRULE as a human readable phrase. The recurr library also offers this, but doesn't seem to be as good yet.
  18. Sorry, me again. If you have a non-recurring event and don't specify an end time, both timeEnd and timeEndUnix are populated with midnight. This isn't very helpful when you are trying to format an event and deciding if you need: 9:00 am - 2pm VS 9:00 am Again, it looks like I need to parse the json to see if the end time is actually set or not. Let me know if that doesn't make sense? Thanks again! I am ending up with something like this: $event = $recurme->event($page); $startDate = json_decode($page->event_dates)->startDate echo date('F jS Y', $startDate); if(!$event->allDay) { echo date('g:i a', $startDate); if(json_decode($page->event_dates)->timeEnd != '') { echo ' - ' . date('g:i a', $event->timeEndUnix); } }
  19. Also, with that same setup: it seems there is no way to get the start time via the API because the $event object looks like this. If I try to get the time from the start_date it returns midnight which makes sense, but why is there no timeStart and/or timeStartUnix? Just to follow up, it looks like the only way I can actually the start date (timestamp) is with this: json_decode($page->event_dates)->startDate Is that the only way when it's not a recurring event?
  20. I guess this is a feature request, or maybe I am missing an option, but at the moment I can do: $event = $recurme->event($page); to get the event for the current page, but if I want to render the calendar with just this event, I can't simply do: echo $recurme->renderCalendar($event, $options) Instead, I have to do: $options = array( 'month' => date('m', $event->start_date), 'year' => date('Y', $event->start_date), 'selector' => 'id='.$page->id, 'cache' => false, 'mini' => true ); echo $recurme->renderCalendar($options); using "selector" to get the events for this page. Or is there a better way?
  21. @joshuag - not sure if this is a bug or just an inconsistency, but when setting up a recurring date if you specify the start date before the first day that the rrule settings allow, the calendar will show an entry for that start date, but the results in the admin won't show it. See the entry on the 5th - should that be there?
  22. I am probably missing something, but https://gitlab.com/baumrock/RockFinder/blob/master/ProcessRockFinder.info.php shows: 'version' => 1, Sorry, I see that: https://gitlab.com/baumrock/RockFinder/blob/master/RockFinder.info.php is 103 BTW - I would recommend string version numbers.
  23. Actually thinking about this a little more - maybe the disabler should be turned into a panel with more options: 1) Disable Tracy all pages 2) Disable Tracy this page And have Once and Sticky buttons to determine how long it's disabled for. How does this sound compared to the get variable approach?
  24. Hey @bernhard - sorry for the recent silence. I am back in the office this week, but triaging work stuff first. Will try to take a good look at your other suggestions as soon as I can. Regarding disabling Tracy on certain pages, that is what the "No debug bar in selected templates" setting is for. It seems to work fine here - is it not working for you? That said, I can also see having a tracy=0 get variable as a useful addition for sure. I'll add that soon. Regarding the performance issue - could you narrow down which panel is the cause? I am constantly on the lookout for ways to improve performance, so it would be helpful if I could reproduce to see if something can be improved.
×
×
  • Create New...