Bug 267 - wsdl fails with "Argument is out of range."
Summary: wsdl fails with "Argument is out of range."
Alias: None
Product: Class Libraries
Classification: Mono
Component: System.Web.Services ()
Version: unspecified
Hardware: PC Linux
: --- normal
Target Milestone: Untriaged
Assignee: Bugzilla
Depends on:
Reported: 2011-08-11 10:19 UTC by Mikkel Kruse Johnsen
Modified: 2015-09-23 10:46 UTC (History)
5 users (show)

Tags: WSDL
Is this bug a regression?: ---
Last known good build:

Notice (2018-05-24): bugzilla.xamarin.com is now in read-only mode.

Please join us on Visual Studio Developer Community and in the Xamarin and Mono organizations on GitHub to continue tracking issues. Bugzilla will remain available for reference in read-only mode. We will continue to work on open Bugzilla bugs, copy them to the new locations as needed for follow-up, and add the new items under Related Links.

Our sincere thanks to everyone who has contributed on this bug tracker over the years. Thanks also for your understanding as we make these adjustments and improvements for the future.

Please create a new report on GitHub or Developer Community with your current version information, steps to reproduce, and relevant error messages or log files if you are hitting an issue that looks similar to this resolved bug and you do not yet see a matching new report.

Related Links:

Description Mikkel Kruse Johnsen 2011-08-11 10:19:05 UTC
[mkj@mikkel FMK]$ wget http://triforkfaellestest.lms.trifork.com/fmk12/wsdl/MedicineCard-inline_2011_01_01.wsdl

[mkj@mikkel FMK]$ wsdl -out:FMK.cs -namespace:OpenMedicus MedicineCard-inline_2011_01_01.wsdl 
Web Services Description Language Utility
Mono Framework v4.0.30319.1
Error: Argument is out of range.
   at System.Web.Services.Description.MessageCollection.get_Item (Int32 index) [0x00000] in <filename unknown>:0 
  at System.Web.Services.Description.MessageCollection.get_Item (System.String name) [0x00000] in <filename unknown>:0 
  at System.Web.Services.Description.BasicProfileChecker.CheckR2305 (System.Web.Services.Description.ConformanceCheckContext ctx, System.Web.Services.Description.Operation value) [0x00000] in <filename unknown>:0 
  at System.Web.Services.Description.BasicProfileChecker.Check (System.Web.Services.Description.ConformanceCheckContext ctx, System.Web.Services.Description.Operation value) [0x00000] in <filename unknown>:0 
  at System.Web.Services.Description.WebServicesInteroperability.Check (System.Web.Services.Description.ConformanceCheckContext ctx, System.Web.Services.Description.ConformanceChecker checker, System.Web.Services.Description.ServiceDescription sd) [0x00000] in <filename unknown>:0 
  at System.Web.Services.Description.WebServicesInteroperability.Check (WsiProfiles claims, System.Web.Services.Description.ConformanceCheckContext ctx, IEnumerable documents) [0x00000] in <filename unknown>:0 
  at System.Web.Services.Description.WebServicesInteroperability.CheckConformance (WsiProfiles claims, System.Web.Services.Description.WebReference webReference, System.Web.Services.Description.BasicProfileViolationCollection violations) [0x00000] in <filename unknown>:0 
  at Mono.WebServices.Driver.GenerateCode (System.Web.Services.Description.WebReferenceCollection references, System.CodeDom.CodeCompileUnit codeUnit) [0x00000] in <filename unknown>:0 
  at Mono.WebServices.Driver.Run (System.String[] args) [0x00000] in <filename unknown>:0 

[mkj@mikkel FMK]$ mono --version
Mono JIT compiler version 2.10.4 (tarball Thu Aug 11 12:51:08 CEST 2011)
Copyright (C) 2002-2011 Novell, Inc, Xamarin, Inc and Contributors. www.mono-project.com
	TLS:           __thread
	SIGSEGV:       altstack
	Notifications: epoll
	Architecture:  amd64
	Disabled:      none
	Misc:          debugger softdebug 
	LLVM:          supported, not enabled.
	GC:            Included Boehm (with typed GC and Parallel Mark)
Comment 1 Mikkel Kruse Johnsen 2011-08-11 11:05:39 UTC
It works under Windows .NET, with the switch "/protocol:SOAP12".
Comment 2 Mikkel Kruse Johnsen 2011-08-11 11:30:52 UTC
Sorry It don't work on Windows with SOAP12.

I will provide a link to a working wsdl file, when I get it to work on Windows.
Comment 3 goldparrot 2013-01-06 14:37:18 UTC
I am having same problem another 1 1/2 later.
Has this been fixed.

I am running the Mono 3.0.2 Beta on OSX 10.8.2 against the SuccessFactors WSDL

Is there any update on this?  What is the correct call to make?

Comment 4 APS 2013-07-01 11:20:35 UTC
The problems is not yet solved and it happens also trying to open an asmx file.

I fixed it changing the name indexer inside mcs/class/System.Web.Services/System.Web.Services.Description/MessageCollection.cs in this way:

public Message this [string name] {
	get { 
		int index = IndexOf ((Message) Table[name]);
		if (index >= 0)
			return this[index]; 
		return null;

I'll try to provide a patch file as soon as possible.
Comment 5 Miguel de Icaza [MSFT] 2015-09-23 10:46:35 UTC
The comment #4 patch now exists in Mono in some form or shape.

I am no longer able to reproduce this with the