Hello Sven,

I had some time to look further into this issue.

On Thu, Oct 10, 2013 at 9:08 PM, Sven Van Caekenberghe <sven@stfx.eu> wrote:
Manfred,

On 10 Oct 2013, at 20:17, Manfred Kr�hnert <mkroehnert42@googlemail.com> wrote:

> Hi again,
>
> the webdav share is located on an OwnCloud instance.
> It is possible to get a directory listing of the specific directory with the following ZnClient request:
>
> ZnClient new username: 'X' password: 'Y'; get: 'https://owncloud.server.de/remote.php/webdav/monticello'

Excellent, that means that it fundamentally works !

Maybe you can try the same for accessing an actual .mcz file, just to be sure.

If I add a '/MyPackage-MK.1.mcz' to the URL and inspect the result it shows a big ByteArray instance.
Which should mean that the file can get accessed remotely via WebDAV.
> In a Pharo 2.0 image do the following steps:
>
> * MonticelloBrowser: select package
> * MonticelloBrowser->'+Repository'
> * add location: 'https://owncloud.server.de/remote.php/webdav/monticello' username: 'X' password: 'Y'
> * MonticelloBrowser->'Open'
>
> * ProgressBar with the following name shows up:
> � � 'Loading all file names from https://owncloud.server.de/remote.php/webdav/monticello'
> It gets interrupted by a PreDebugWindow with title
> � � 'MCRepositoryError: Could not access https://owncloud.server.de/remote.php/webdav/monticello: ZnHttpUnsuccessful: 404 Not Found'
>
> Opening the Debugger gives the following stacktrace
>
> MCHttpRepository>>loadAllFileNames in Block: [:exception | (exception className beginsWith: 'Zn...etc...
> BlockClosure>>cull:
> ...
> ZnClient>>execute

Have a look at MCHTTPRepository>>#loadAllFileNames and notice how a query parameter is added, maybe that is the culprit ? Also, a trailing slash is added, that could be a problem for the server as well.

What I found out is that line 11 of MCHTTPRepository>>#loadAllFileNames is apparently causing the problem:

queryAt: 'C' put: 'M;O=D'; "legacy that some servers maybe expect"


When I access the following URL with ZnClient it returns a 404 error (does not exist):

ZnClient new username: 'X' password: 'Y'; get: 'https://owncloud.server.de/remote.php/webdav/monticello/?C=M%3BO%3DD'

This 404 is the exception which is thrown and caught by the debugger.
I took the query from the http client request which I inspected in the debugger.

When the 'queryAt:...' line is commented out the contents of the repository is shown when I choose 'Open' on the specific repository in MonticelloBrowser.
Maybe this is an issue with the WebDAV implementation of OwnCloud (version�5.0.10 in this case).


The next strange thing here is that all entries in the opened browser are prefixed with 'remote.php/webdav/monticello/'.
And they are all marked in a bold font which means completely new to the system if I remember correctly.
Then I checked the MD5 sums of the .mcz files and the ones from the package cache have a different checksum than the one on the webdav share.
Although I used the MonticelloBrowser 'Copy' action.

Best,
Manfred

Else, you will have to look at the stack trace in the debugger and try to understand what is going on.

Sven

> Trying to copy .mcz files to the new repository afterwards triggers the same error.
> However, the selected .mcz file gets copied to the WebDAV share.
>
> The used operating system is OS X 10.6.8.
> The 'System Reporter' shows the following info:
>
> Image:
> Pharo2.0
> Latest update: #20616
>
> VM:
> Mac Cocoa Cog 5.8b12 21-Sep-10
> Jenkins build #14535
>
> Thanks,
> Manfred
>
>
>
>
> On Thu, Oct 10, 2013 at 4:00 PM, Manfred Kr�hnert <mkroehnert42@googlemail.com> wrote:
> Hello Sven,
>
>
> On Thu, Oct 10, 2013 at 3:50 PM, Sven Van Caekenberghe <sven@stfx.eu> wrote:
> Hi Manfred,
>
> On 10 Oct 2013, at 15:41, Manfred Kr�hnert <mkroehnert42@googlemail.com> wrote:
>
> > Hi everyone,
> >
> > I am one of the guys helping Nico with Amber.
> >
> > Now, I recently started to experiment with Pharo for a small project.
> > After some reading and experimenting I was able to get something running thanks to the good documentation available.
> >
> > While I was on the go I tried to save my code with Monticello on a private WebDAV share.
> > However, the server is only accessible via HTTPS which resulted in an error accessing it from the Monticello browser.
> >
> > Now my question is if HTTPS is supported by Montichello or not.
> > Since the server is accessed with username/password I'd rather not use plain HTTP.
> >
> > Best,
> > Manfred
>
> It should work. But I am not aware of any official, public repositories that run HTTPS, so its hard to test. I also understand that it could be difficult to give stack traces, but details are necessary to make any progress on helping you.
>
> One thing you could try is to access the repository directly: i.e. create a ZnClient that tries to read the listing or a specific package.
>
> Sven
>
> thanks for the initial info that it should work.
>
> I would have given further details but currently I can't access the machine where I tried it.
> I'll try your suggestion and provide a more detailed report as soon as possible.
>
> Best,
> Manfred
>
>