WhiteCoreSim / WhiteCore-Dev

WhiteCoreSim - Software to create your own virtual world
BSD 3-Clause "New" or "Revised" License
27 stars 34 forks source link

Parcel sales not working #61

Closed emperorstarfinder closed 9 years ago

emperorstarfinder commented 9 years ago

One of the region owners on my grid just stumbled on this one.

They set the parcel sale price to 1 and then set for sale to anyone. The person purchasing the parcel could not purchase the parcel. They then went and tried to set to sale to specific person and same thing. I looked in the logs on the two consoles (WhiteCore.Server.exe and WhiteCore.exe) and found no actual error message.

fly-man- commented 9 years ago

Well, that's odd as I just used my Region Owner to sell a parcel to 1 of my co-developers and it worked without an issue.

1) The person needs to be standing INSIDE the parcel he wants to sell 2) Currency needs to allow parcel sales 3) The person buying needs to be standing INSIDE the parcel he wants to buy

emperorstarfinder commented 9 years ago

It is odd because al 3 questions are yes. Additionally they were able to set the land for sale but the person buying the land was unable to buy the land. I apologize I was tired when I added the report and didnt put that part in. However when the region service starts up it does throw this error:

Jul 16 09:13:24 - [WebUtils]: request failed: System.UriFormatException: Invalid URI: The format of the URI could not be determined. at System.Uri.CreateThis(String uri, Boolean dontEscape, UriKind uriKind) at System.Net.WebRequest.Create(String requestUriString) at WhiteCore.Framework.Utilities.WebUtils.ServiceOSDRequest(String url, Byte[] buffer, String method, Int32 timeout) in C:\Users\compdev2\Desktop\Repository\Development\WhiteCore-Dev\WhiteCore\Framework\Utilities\WebUtils.cs:line 233 to CurrencyServerURI Jul 16 09:13:24 - [WebUtils]: request failed: System.UriFormatException: Invalid URI: The format of the URI could not be determined. at System.Uri.CreateThis(String uri, Boolean dontEscape, UriKind uriKind) at System.Net.WebRequest.Create(String requestUriString) at WhiteCore.Framework.Utilities.WebUtils.ServiceOSDRequest(String url, Byte[] buffer, String method, Int32 timeout) in C:\Users\compdev2\Desktop\Repository\Development\WhiteCore-Dev\WhiteCore\Framework\Utilities\WebUtils.cs:line 233 to CurrencyServerURI Jul 16 09:13:24 - [WebUtils]: request failed: System.UriFormatException: Invalid URI: The format of the URI could not be determined. at System.Uri.CreateThis(String uri, Boolean dontEscape, UriKind uriKind) at System.Net.WebRequest.Create(String requestUriString) at WhiteCore.Framework.Utilities.WebUtils.ServiceOSDRequest(String url, Byte[] buffer, String method, Int32 timeout) in C:\Users\compdev2\Desktop\Repository\Development\WhiteCore-Dev\WhiteCore\Framework\Utilities\WebUtils.cs:line 233 to CurrencyServerURI Jul 16 09:13:24 - [WebUtils]: request failed: System.UriFormatException: Invalid URI: The format of the URI could not be determined. at System.Uri.CreateThis(String uri, Boolean dontEscape, UriKind uriKind) at System.Net.WebRequest.Create(String requestUriString) at WhiteCore.Framework.Utilities.WebUtils.ServiceOSDRequest(String url, Byte[] buffer, String method, Int32 timeout) in C:\Users\compdev2\Desktop\Repository\Development\WhiteCore-Dev\WhiteCore\Framework\Utilities\WebUtils.cs:line 233 to CurrencyServerURI Jul 16 09:13:24 - [WebUtils]: request failed: System.UriFormatException: Invalid URI: The format of the URI could not be determined. at System.Uri.CreateThis(String uri, Boolean dontEscape, UriKind uriKind) at System.Net.WebRequest.Create(String requestUriString) at WhiteCore.Framework.Utilities.WebUtils.ServiceOSDRequest(String url, Byte[] buffer, String method, Int32 timeout) in C:\Users\compdev2\Desktop\Repository\Development\WhiteCore-Dev\WhiteCore\Framework\Utilities\WebUtils.cs:line 233 to CurrencyServerURI Jul 16 09:13:24 - [GRID INFO SERVICE]: Cannot get grid info from config source, using minimal defaults

but yet currency clearly is working.

fly-man- commented 9 years ago

That means that some of the values are not being read correctly.

Try to setup the correct values in the GridLogin and see if that solves the case

emperorstarfinder commented 9 years ago

Okay checking this out GridLogin there is no actual GridLogin.ini so I am guessing you mean Grid/ServerConfiguration/Login.ini. The settings are correct so far as I can tell. The Economy url is set correctly in GridInfoService.ini as well

Also did infinite regions get removed? when I update or create regions it doesnt ask if I want to make the region an infinite region. Thats a feature that is liked on my grid.

greythane commented 9 years ago

Infinte regions are there but you need to choose 'custom' for your region info.. the other options are presets to provide for the standard configurations.

emperorstarfinder commented 9 years ago

Thanks got the infinite regions and the max prim issue fixed. I am so tired from not much sleep this week didn't even see the Custom option during region creation LOL.

Anyway after I fixed that I also redid Economy.ini in both grid and sim directories in config and double checked the settings in Login.ini and GridInfo.ini etc and still have that pesky message being thrown when i start the region console.

emperorstarfinder commented 9 years ago

Seeing this when making purchases in-world as well however it appears the purchases are going through.

Jul 29 09:06:49 - [MySQLDataLoader] ExecuteNonQuery(insert into simple_currency values (?A,?B,?C,?D,?E,?F)), MySql.Data.MySqlClient.MySqlException (0x80004005): Duplicate entry 'd2a144ef-3cec-4a3c-b1bb-526fe73e3928' for key 'PRIMARY' at MySql.Data.MySqlClient.MySqlStream.ReadPacket() at MySql.Data.MySqlClient.NativeDriver.GetResult(Int32& affectedRow, Int32& insertedId) at MySql.Data.MySqlClient.Driver.NextResult(Int32 statementId, Boolean force) at MySql.Data.MySqlClient.MySqlDataReader.NextResult() at MySql.Data.MySqlClient.MySqlCommand.ExecuteReader(CommandBehavior behavior) at MySql.Data.MySqlClient.MySqlCommand.ExecuteNonQuery() at MySql.Data.MySqlClient.MySqlHelper.ExecuteNonQuery(MySqlConnection connection, String commandText, MySqlParameter[] commandParameters) at MySql.Data.MySqlClient.MySqlHelper.ExecuteNonQuery(String connectionString, String commandText, MySqlParameter[] parms) at WhiteCore.DataManager.MySQL.MySQLDataLoader.ExecuteNonQuery(String connStr, String sql, Dictionary2 parameters, Boolean spamConsole) in C:\Users\compdev2\Desktop\Repository\Development\WhiteCore-Dev\WhiteCore\DataManagerPlugins\MySQL\MySQLDataManager.cs:line 141 Jul 29 09:06:49 - [MySQLDataLoader] ExecuteNonQuery(insert into simple_currency values (?A,?B,?C,?D,?E,?F)), MySql.Data.MySqlClient.MySqlException (0x80004005): Duplicate entry 'd2a144ef-3cec-4a3c-b1bb-526fe73e3928' for key 'PRIMARY' at MySql.Data.MySqlClient.MySqlStream.ReadPacket() at MySql.Data.MySqlClient.NativeDriver.GetResult(Int32& affectedRow, Int32& insertedId) at MySql.Data.MySqlClient.Driver.NextResult(Int32 statementId, Boolean force) at MySql.Data.MySqlClient.MySqlDataReader.NextResult() at MySql.Data.MySqlClient.MySqlCommand.ExecuteReader(CommandBehavior behavior) at MySql.Data.MySqlClient.MySqlCommand.ExecuteNonQuery() at MySql.Data.MySqlClient.MySqlHelper.ExecuteNonQuery(MySqlConnection connection, String commandText, MySqlParameter[] commandParameters) at MySql.Data.MySqlClient.MySqlHelper.ExecuteNonQuery(String connectionString, String commandText, MySqlParameter[] parms) at WhiteCore.DataManager.MySQL.MySQLDataLoader.ExecuteNonQuery(String connStr, String sql, Dictionary2 parameters, Boolean spamConsole) in C:\Users\compdev2\Desktop\Repository\Development\WhiteCore-Dev\WhiteCore\DataManagerPlugins\MySQL\MySQLDataManager.cs:line 141

emperorstarfinder commented 9 years ago

This bug found for currency when buying/ selling objects:

Aug 03 04:51:51 - [LLCLIENTVIEW]: Caught exception while processing OpenMetaverse.Packets.ObjectBuyPacket for Emperor Starfinder, Object reference not set to an instance of an object. at WhiteCore.ScriptEngine.DotNetEngine.ScriptEngine.findPrim(UUID objectID) in C:\Users\compdev2\Desktop\Repository\Development\WhiteCore-Dev\WhiteCore\DotNetEngine\ScriptEngine.cs:line 1344 at WhiteCore.ScriptEngine.DotNetEngine.EventManager.money(UUID primID, UUID agentID, Int32 amount) in C:\Users\compdev2\Desktop\Repository\Development\WhiteCore-Dev\WhiteCore\DotNetEngine\EventManager.cs:line 267 at WhiteCore.Framework.Modules.ObjectPaid.Invoke(UUID objectID, UUID agentID, Int32 amount) at Simple.Currency.SimpleCurrencyModule.FireObjectPaid(UUID objectID, UUID agentID, Int32 amount) in C:\Users\compdev2\Desktop\Repository\Development\WhiteCore-Dev\WhiteCore\Modules\Avatar\Currency\Simple.CurrencyModule.cs:line 171 at Simple.Currency.SimpleCurrencyModule.Transfer(UUID toID, UUID fromID, UUID toObjectID, String toObjectName, UUID fromObjectID, String fromObjectName, Int32 amount, String description, TransactionType type) in C:\Users\compdev2\Desktop\Repository\Development\WhiteCore-Dev\WhiteCore\Modules\Avatar\Currency\Simple.CurrencyModule.cs:line 194 at WhiteCore.Modules.Entities.BuySell.BuySellModule.ObjectBuy(IClientAPI remoteClient, UUID sessionID, UUID groupID, UUID categoryID, UInt32 localID, Byte saleType, Int32 salePrice) in C:\Users\compdev2\Desktop\Repository\Development\WhiteCore-Dev\WhiteCore\Modules\World\Entities\BuySell\BuySellModule.cs:line 326 at WhiteCore.ClientStack.LLClientView.HandleObjectBuy(IClientAPI sender, Packet Pack) in C:\Users\compdev2\Desktop\Repository\Development\WhiteCore-Dev\WhiteCore\ClientStack\LLClientView.cs:line 10453 at WhiteCore.ClientStack.LLClientView.ProcessSpecificPacketAsync(Object state) in C:\Users\compdev2\Desktop\Repository\Development\WhiteCore-Dev\WhiteCore\ClientStack\LLClientView.cs:line 730

greythane commented 9 years ago

The SimpleCurrency module has an issue with trying to query the grid server for info before initialisation has completed... this is giving the 'CurrencyServerURI errors at startup. A 'fix' has been applied but needs additional testing

emperorstarfinder commented 9 years ago

Okay now the parcel sale in the viewer says There has been an error while fetching land buying information. However no actual debug logging error given.

fly-man- commented 9 years ago

That message makes me believe that you don't have currency setup the right way. Please check if the currencyURL is being send to the viewer.

greythane commented 9 years ago

I have just done some checks... Retrieving the parcel sales details appears to work only on a couple of viewers (windows).. Firestorm & Angstrom.. fails in Kokua, CoolViewer & Singularity .. update... finally found the problem and it is related to legacy calls to 'land tool.php' as wells the economy configuration setup ... correction shortly

emperorstarfinder commented 9 years ago

I saw your discussion with fly-man in IRC.

The default helper port (which viewers apparently use for economy) is not 8000 TCP/UDP but 8002 TCP/UDP. In Economy.ini you have a default server port of 0.

This is because both opensim and even LL use the default port of 8002 with their economy helper as it is the technical login port the viewers use as the login service is listening on port 8002 by default.

I tried changing this and testing with all current viewers (Firestorm, Singularity, Kokua) as you should be to as Angstrom and Astra are both viewers that are way out of date.

I always try to stay within one to two versions older in viewers when testing. As from two versions old to most current your bound to get a better idea of what is going on. Both Angstrom and Astra have not been actively developed since the earlier days of aurora and were developed from what I read specifically for aurora. So seeing you have codebase from aurora they will work to a degree. Ideally though you want to be targeting support for the viewers that are current.

The end result is this does not appear to work. So in the end there is a default port that needs to be set somewhere namely the default port in Economy.ini.

This probably should default to say Port 8000 TCP/UDP for grid and maybe 9000 TCP/UDP if its just a standalone region and not in grid mode.

Then you need to tell the viewer what port to use for Economy. In a sense you actually would be creating an economy server using simplecurrency.

Also when I test I should note I am using the x64 bit version of the current viewers. So this might also be something with the x64 bit versions though I doubt this. When a bug is reported now we will have to know if testing and initial bug is on x86 or x64 bit version of the viewer.

emperorstarfinder commented 9 years ago

Confirmed Port 8008 set in GridInfoService.ini and Economy.ini as DefaultServerPort = 8008 works

fly-man- commented 9 years ago

@emperorstarfinder I thought so. The problem is that not everyone uses the currency more intensively as I do as most of the things I see in SimpleCurrency I want to change in AdvancedCurrency.

greythane commented 9 years ago

This appears to be more of problem with the setup of the currency module rather than specific problems with parcel sales. Several improvements have been made to the SimpleCurrency configuration setup so this will be closed until some additional problem, if any , is reported.

emperorstarfinder commented 9 years ago

Well I think for 0.9.3 we should have a look at AdvancedCurrency and see what we can do there. I am all for helping on that as well.

@greythane I think we are going to find that viewers are looking for currency on port 8008. The reason your seeing the whole piece about landtools.php is because thats referring to the old stardust module. After Revolution indicated he wanted to integrate it into simple currency (i am skeptical of that approach) skidz stopped working on Stardust. I have been told he was focusing more on his content in secondlife and when he came back to it aurora-sim had gone cold. In either case stardust currency would be out of date now anyways.

Also if we use lets say simplecurrency as the currency module that runs by default when the release versions of whitecore are downloaded you can really get rid of BasicCurrency as it really wouldn't be needed i wouldn't think. AdvancedCurrency could handle more of what would be needed by those doing a full fledged production level virtual world (i.e. grids). However both should still be compatible and usable with the webui.