Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > comp.lang.php > #9674

Re: Parsing mbox files with Windows Php

From Jerry Stuckle <jstucklex@attglobal.net>
Newsgroups comp.lang.php
Subject Re: Parsing mbox files with Windows Php
Date 2013-05-27 19:50 -0400
Organization A noiseless patient Spider
Message-ID <ko0r7m$t5t$1@dont-email.me> (permalink)
References (6 earlier) <knvmru$ssb$1@speranza.aioe.org> <knvon4$o27$1@dont-email.me> <ko00e1$qd3$1@speranza.aioe.org> <ko0oj6$iat$1@dont-email.me> <ko0r1t$4tm$1@speranza.aioe.org>

Show all headers | View raw


On 5/27/2013 7:42 PM, Christoph Becker wrote:
> Jerry Stuckle wrote:
>> On 5/27/2013 12:08 PM, Christoph Becker wrote:
>>> Jerry Stuckle wrote:
>>> On 5/27/2013 9:25 AM, Christoph Becker wrote:
>>>> Jerry Stuckle wrote:
>>>>>
>>>>> Chuck has posted the code that fails on Windows, but works on Linux,
>>>>> and
>>>>> posted the according error messages.
>>>>>
>>>>
>>>> He has not posted matching code and error messages.
>>>
>>> In <news:knreb5$roc$1@dont-email.me> Chuck Anderson wrote:
>>>
>>>> I have tried:
>>>> imap_open('localhost/imap/mboxfiles/Trash', '', ''); // equivalent of
>>>> being relative to $HOME on *nix
>>>> imap_open('/imap/mboxfiles/Trash', '', ''); // absolute path from
>>>> document root
>>>> imap_open('mboxfiles/Trash', '', ''); // relative path
>>>> imap_open('c:/localhost/imap/mboxfiles/Trash', '', ''); // real path
>>>> on disk
>>>>
>>>> On Windows I always get these two errors (the file path changes
>>>> accordingly):
>>>>
>>>> - Warning: imap_open(): Couldn't open stream localhost/utilities
>>>> /imap/eml/Trash in localhost\utilities\imap\imap_save_mbox_file.php
>>>> on line 127
>>>>
>>>> - Notice: Unknown: Can't open  mailbox localhost/utilities/imap/eml
>>>> /Trash: no such mailbox (errflg=2) in Unknown on line 0
>>> '
>>
>> And none of the purported statements he tried line up with the purported
>> results he posted.  However, I guess that's a bit beyond your level of
>> comprehension.
>
> Indeed, the paths don't line up--thank you for making me aware of it, as
> I have not checked that in the first place.  However, let's concentrate
> on my own test below.
>

You are not the OP.  I really don't care about your tests.  They may or 
may not apply to the OP's problem.

>>>>>> Also, that bug is over six years old.  I have no idea if the bug still
>>>>>> exists or not.  However, I do not consider a bug that old to still be
>>>>>> valid until proven so.
>>>>>
>>>>> The issue's state was changed to "not a bug" in 2006 already.  I
>>>>> consider this to be correct, but not for the reason given in the
>>>>> comments.  IMO the valid reason to see it as "not a bug" is, that it's
>>>>> not documented that imap_open() can be used for mbox *files*.
>>>>>
>>>>
>>>> Correction - not a PHP bug.  I have seen no reference to any bug being
>>>> pursued in IMAP code.
>>>
>>> As I said before, the reported bug[1] was set to "not a bug".
>>>
>>
>> Again, your comprehension is lacking.  It was set as not a PHP bug.
>> However, once again, there is no indication this is the same problem as
>> a reported bug over six years old.
>>
>>>>> However, the issue does still exist, even with the latest c-client
>>>>> library, which is from 2007.
>>>>>
>>>>
>>>> And your proof that it exists in his copy of the code is?
>>>
>>> Actually I was wrong.  I tested with some recent PHP version (5.4.7),
>>> and there the problem occured; but now I have checked the IMAP version
>>> in use, and it is 2007e, despite the latest version is 2007f, for
>>> whatever reason.
>>>
>>
>> No!  You, wrong?  Can't be!
>
> Of course that can be.  I am human, and humans make mistakes sometimes.
>   And of course, I'm able to admit, when I have done so.
>
>>> However, I made the following test script:
>>>
>>> | $mbox = imap_open($_SERVER['DOCUMENT_ROOT'] . '/imap/mbox', '', '');
>>> | var_dump($mbox);
>>>
>>> On my local Windows XP machine with PHP 5.4.7 this prints:
>>>
>>> | Warning: imap_open(): Couldn't open stream C:/xampp/htdocs
>>> | /exp/imap/mbox in C:\xampp\htdocs\exp\imap\index.php on line 5
>>> | boolean false
>>> | Notice: Unknown: Can't open mailbox C:/xampp/htdocs/exp/imap/mbox:
>>> | no such mailbox (errflg=2) in Unknown on line 0
>>>
>>
>> Not having any idea how your system is set up, I would say your test is
>> worthless.
>
> Which information do you require?  It's hard for me to recognize all
> *necessary* information.
>

The only worthwhile test is the one that duplicates the OP's problem. 
So far I haven't seen enough information to do that.

> However, you might consider to run the test yourself on a system of your
> choice.
>

I will - WHEN I have sufficient information.

>>> On a Linux server with PHP 5.3.5 (IMAP version 2007e) it prints:
>>>
>>> | resource(2) of type (imap)
>>>
>>
>> See above.
>>
>>> Of course that is no proof, that imap_open() can't open an mbox file on
>>> Windows, but it is some evidence at least.
>>>
>>>> Unlike you, I'm not willing to jump to conclusions based on over six
>>>> year old bug reports.  I prefer to identify the problem.  It may or may
>>>> not be as you claim.
>>>
>>> [1] <https://bugs.php.net/bug.php?id=39880>
>>>
>>
>> Unlike you, I'm not willing to jump to conclusions based on over six
>> year old bug reports.  I prefer to identify the problem.  It may or may
>> not be as you claim.
>
> I also prefer to identify the problem; unfortunately my limited
> knowledge and time make that hard to accomplish.  If you like, you may
> help out.
>

Then I suggest you increase both your knowledge and your time.  That's 
what you need to do to help others (I've been doing it for over 25 years).

I will help the OP identify his problem.  I will NOT jump to the 
conclusion that a six-year-old bug report is his trouble.

-- 
==================
Remove the "x" from my email address
Jerry Stuckle
JDS Computer Training Corp.
jstucklex@attglobal.net
==================

Back to comp.lang.php | Previous | Next — Previous in thread | Next in thread | Find similar | Unroll thread


Thread

Parsing mbox files with Windows Php Chuck Anderson <cycletourist@invalid.invalid> - 2013-05-24 15:57 -0600
  Re: Parsing mbox files with Windows Php Christoph Becker <cmbecker69@gmx.de> - 2013-05-25 00:40 +0200
    Re: Parsing mbox files with Windows Php Chuck Anderson <cycletourist@invalid.invalid> - 2013-05-24 21:17 -0600
    Re: Parsing mbox files with Windows Php Thomas 'PointedEars' Lahn <PointedEars@web.de> - 2013-05-25 09:30 +0200
      Re: Parsing mbox files with Windows Php Christoph Becker <cmbecker69@gmx.de> - 2013-05-25 16:19 +0200
        Re: Parsing mbox files with Windows Php Thomas 'PointedEars' Lahn <PointedEars@web.de> - 2013-05-25 17:19 +0200
          Re: Parsing mbox files with Windows Php Christoph Becker <cmbecker69@gmx.de> - 2013-05-25 17:48 +0200
            Re: Parsing mbox files with Windows Php Thomas 'PointedEars' Lahn <PointedEars@web.de> - 2013-05-25 20:09 +0200
  Re: Parsing mbox files with Windows Php Jerry Stuckle <jstucklex@attglobal.net> - 2013-05-24 19:16 -0400
    Re: Parsing mbox files with Windows Php Chuck Anderson <cycletourist@invalid.invalid> - 2013-05-24 17:40 -0600
    Re: Parsing mbox files with Windows Php "Peter H. Coffin" <hellsop@ninehells.com> - 2013-05-25 10:50 -0500
  Re: Parsing mbox files with Windows Php Luuk <luuk@invalid.lan> - 2013-05-25 18:08 +0200
  Re: Parsing mbox files with Windows Php "Peter H. Coffin" <hellsop@ninehells.com> - 2013-05-25 11:14 -0500
    Re: Parsing mbox files with Windows Php Chuck Anderson <cycletourist@invalid.invalid> - 2013-05-25 16:39 -0600
      Re: Parsing mbox files with Windows Php Jerry Stuckle <jstucklex@attglobal.net> - 2013-05-26 23:11 -0400
        Re: Parsing mbox files with Windows Php Christoph Becker <cmbecker69@gmx.de> - 2013-05-27 14:13 +0200
          Re: Parsing mbox files with Windows Php Jerry Stuckle <jstucklex@attglobal.net> - 2013-05-27 08:49 -0400
            Re: Parsing mbox files with Windows Php Christoph Becker <cmbecker69@gmx.de> - 2013-05-27 15:25 +0200
              Re: Parsing mbox files with Windows Php Jerry Stuckle <jstucklex@attglobal.net> - 2013-05-27 10:01 -0400
                Re: Parsing mbox files with Windows Php Christoph Becker <cmbecker69@gmx.de> - 2013-05-27 18:08 +0200
                Re: Parsing mbox files with Windows Php Jerry Stuckle <jstucklex@attglobal.net> - 2013-05-27 19:05 -0400
                Re: Parsing mbox files with Windows Php Christoph Becker <cmbecker69@gmx.de> - 2013-05-28 01:42 +0200
                Re: Parsing mbox files with Windows Php Jerry Stuckle <jstucklex@attglobal.net> - 2013-05-27 19:50 -0400
                Re: Parsing mbox files with Windows Php Christoph Becker <cmbecker69@gmx.de> - 2013-05-29 00:17 +0200
        Re: Parsing mbox files with Windows Php Chuck Anderson <cycletourist@invalid.invalid> - 2013-05-27 17:51 -0600
          Re: Parsing mbox files with Windows Php (correction - ignore previous) Chuck Anderson <cycletourist@invalid.invalid> - 2013-05-27 18:20 -0600
      Re: Parsing mbox files with Windows Php "Peter H. Coffin" <hellsop@ninehells.com> - 2013-05-27 10:22 -0500
        Re: Parsing mbox files with Windows Php Chuck Anderson <cycletourist@invalid.invalid> - 2013-05-27 21:15 -0600
          Re: Parsing mbox files with Windows Php Jerry Stuckle <jstucklex@attglobal.net> - 2013-05-28 12:23 -0400
            Re: Parsing mbox files with Windows Php Chuck Anderson <cycletourist@invalid.invalid> - 2013-05-28 17:56 -0600
              Re: Parsing mbox files with Windows Php Jerry Stuckle <jstucklex@attglobal.net> - 2013-05-28 22:27 -0400
              Re: Parsing mbox files with Windows Php Christoph Becker <cmbecker69@gmx.de> - 2013-05-29 15:23 +0200
          Re: Parsing mbox files with Windows Php Christoph Becker <cmbecker69@gmx.de> - 2013-05-29 00:08 +0200

csiph-web