[Widelands-dev] [Merge] lp:~widelands-dev/widelands/bug_1566720_set_origin into lp:widelands

2016-04-07 Thread noreply
The proposal to merge lp:~widelands-dev/widelands/bug_1566720_set_origin into 
lp:widelands has been updated.

Status: Needs review => Merged

For more details, see:
https://code.launchpad.net/~widelands-dev/widelands/bug_1566720_set_origin/+merge/291207
-- 
Your team Widelands Developers is subscribed to branch 
lp:~widelands-dev/widelands/bug_1566720_set_origin.

___
Mailing list: https://launchpad.net/~widelands-dev
Post to : widelands-dev@lists.launchpad.net
Unsubscribe : https://launchpad.net/~widelands-dev
More help   : https://help.launchpad.net/ListHelp


Re: [Widelands-dev] [Merge] lp:~widelands-dev/widelands/python3 into lp:widelands

2016-04-07 Thread Tino
Review: Resubmit

Ok, please have another look on linux.
-- 
https://code.launchpad.net/~widelands-dev/widelands/python3/+merge/291236
Your team Widelands Developers is subscribed to branch 
lp:~widelands-dev/widelands/python3.

___
Mailing list: https://launchpad.net/~widelands-dev
Post to : widelands-dev@lists.launchpad.net
Unsubscribe : https://launchpad.net/~widelands-dev
More help   : https://help.launchpad.net/ListHelp


Re: [Widelands-dev] [Merge] lp:~widelands-dev/widelands/bug_1566720_set_origin into lp:widelands

2016-04-07 Thread GunChleoc
Review: Approve

LGTM. All other uses of map->get_width() seem to be OK. This was a classic 
indexing error.

@bunnybot merge
-- 
https://code.launchpad.net/~widelands-dev/widelands/bug_1566720_set_origin/+merge/291207
Your team Widelands Developers is subscribed to branch 
lp:~widelands-dev/widelands/bug_1566720_set_origin.

___
Mailing list: https://launchpad.net/~widelands-dev
Post to : widelands-dev@lists.launchpad.net
Unsubscribe : https://launchpad.net/~widelands-dev
More help   : https://help.launchpad.net/ListHelp


Re: [Widelands-dev] [Merge] lp:~widelands-dev/widelands/bug-1543001-eris into lp:widelands

2016-04-07 Thread GunChleoc
The highest Lua version available on my system is 5.2. Ubuntu introduced Lua 
with version 15.04, but I usually only use long term releases, which means that 
I will have to wait until 16.04 comes out in order to switch to Lua 5.3.
-- 
https://code.launchpad.net/~widelands-dev/widelands/bug-1543001-eris/+merge/291294
Your team Widelands Developers is requested to review the proposed merge of 
lp:~widelands-dev/widelands/bug-1543001-eris into lp:widelands.

___
Mailing list: https://launchpad.net/~widelands-dev
Post to : widelands-dev@lists.launchpad.net
Unsubscribe : https://launchpad.net/~widelands-dev
More help   : https://help.launchpad.net/ListHelp


[Widelands-dev] [Merge] lp:~widelands-dev/widelands/python3 into lp:widelands

2016-04-07 Thread bunnybot
Continuous integration builds have changed state:

Travis build 980. State: errored. Details: 
https://travis-ci.org/widelands/widelands/builds/121409569.
Appveyor build 813. State: success. Details: 
https://ci.appveyor.com/project/widelands-dev/widelands/build/_widelands_dev_widelands_python3-813.
-- 
https://code.launchpad.net/~widelands-dev/widelands/python3/+merge/291236
Your team Widelands Developers is subscribed to branch 
lp:~widelands-dev/widelands/python3.

___
Mailing list: https://launchpad.net/~widelands-dev
Post to : widelands-dev@lists.launchpad.net
Unsubscribe : https://launchpad.net/~widelands-dev
More help   : https://help.launchpad.net/ListHelp


[Widelands-dev] [Merge] lp:~widelands-dev/widelands/bug_1566720_set_origin into lp:widelands

2016-04-07 Thread bunnybot
Continuous integration builds have changed state:

Travis build 978. State: passed. Details: 
https://travis-ci.org/widelands/widelands/builds/121359254.
Appveyor build 811. State: success. Details: 
https://ci.appveyor.com/project/widelands-dev/widelands/build/_widelands_dev_widelands_bug_1566720_set_origin-811.
-- 
https://code.launchpad.net/~widelands-dev/widelands/bug_1566720_set_origin/+merge/291207
Your team Widelands Developers is requested to review the proposed merge of 
lp:~widelands-dev/widelands/bug_1566720_set_origin into lp:widelands.

___
Mailing list: https://launchpad.net/~widelands-dev
Post to : widelands-dev@lists.launchpad.net
Unsubscribe : https://launchpad.net/~widelands-dev
More help   : https://help.launchpad.net/ListHelp


Re: [Widelands-dev] [Merge] lp:~widelands-dev/widelands/bug-1543001-eris into lp:widelands

2016-04-07 Thread Miroslav Remák
We're going to break savegame compatibility for this release anyway. What's 
holding us from updating to Lua 5.3 eris?
-- 
https://code.launchpad.net/~widelands-dev/widelands/bug-1543001-eris/+merge/291294
Your team Widelands Developers is requested to review the proposed merge of 
lp:~widelands-dev/widelands/bug-1543001-eris into lp:widelands.

___
Mailing list: https://launchpad.net/~widelands-dev
Post to : widelands-dev@lists.launchpad.net
Unsubscribe : https://launchpad.net/~widelands-dev
More help   : https://help.launchpad.net/ListHelp


[Widelands-dev] [Merge] lp:~widelands-dev/widelands/bug-1543001-eris into lp:widelands

2016-04-07 Thread GunChleoc
GunChleoc has proposed merging lp:~widelands-dev/widelands/bug-1543001-eris 
into lp:widelands.

Commit message:
Updated Eris to version 1.1.0.

Requested reviews:
  Widelands Developers (widelands-dev)
Related bugs:
  Bug #1543001 in widelands: "Update Eris for build 19"
  https://bugs.launchpad.net/widelands/+bug/1543001

For more details, see:
https://code.launchpad.net/~widelands-dev/widelands/bug-1543001-eris/+merge/291294

I just dumped the files and updated the readme. As long as we don't change to a 
newer Lua version, savegames should be compatible. I did a quick test with my 
long Trident of Fire savegame, and it loaded with no issues.
-- 
Your team Widelands Developers is requested to review the proposed merge of 
lp:~widelands-dev/widelands/bug-1543001-eris into lp:widelands.
=== modified file 'src/third_party/eris/README.eris'
--- src/third_party/eris/README.eris	2014-02-22 14:47:28 +
+++ src/third_party/eris/README.eris	2016-04-07 18:16:25 +
@@ -1,11 +1,11 @@
 This directory contains a verbatim copy of Eris by Florian Nücke.
 
 URL: https://github.com/fnuecke/eris
-VERSION: 2e39ecc7dcb73120dde775929227fa661fbc6bc0
+VERSION: 1.1.0 for Lua 5.2.4
 
 We use this for heavy persistence and it also brings with it the Lua version
 that we use in Widelands. The Widelands Team wishes to expresses total and
 complete gratitude to the authors of Eris for making it available under the MIT
-License. 
+License.
 
-- SirVer, in behalf of the Widelands Team

=== modified file 'src/third_party/eris/eris.c'
--- src/third_party/eris/eris.c	2014-07-25 11:14:03 +
+++ src/third_party/eris/eris.c	2016-04-07 18:16:25 +
@@ -1,6 +1,6 @@
 /*
-Eris - Heavy-duty persistence for Lua 5.2.2 - Based on Pluto
-Copyright (c) 2013 by Florian Nuecke.
+Eris - Heavy-duty persistence for Lua 5.2.4 - Based on Pluto
+Copyright (c) 2013-2015 by Florian Nuecke.
 
 Permission is hereby granted, free of charge, to any person obtaining a copy
 of this software and associated documentation files (the "Software"), to deal
@@ -121,6 +121,7 @@
 #define eris_reallocvector luaM_reallocvector
 /* lobject.h */
 #define eris_ttypenv ttypenv
+#define eris_clLvalue clLvalue
 #define eris_setnilvalue setnilvalue
 #define eris_setclLvalue setclLvalue
 #define eris_setobj setobj
@@ -176,6 +177,47 @@
 
 /*
 ** 
+** Language strings for errors.
+** 
+*/
+
+#define ERIS_ERR_CFUNC "attempt to persist a light C function (%p)"
+#define ERIS_ERR_COMPLEXITY "object too complex"
+#define ERIS_ERR_HOOK "cannot persist yielded hooks"
+#define ERIS_ERR_METATABLE "bad metatable, not nil or table"
+#define ERIS_ERR_NOFUNC "attempt to persist unknown function type"
+#define ERIS_ERR_READ "could not read data"
+#define ERIS_ERR_SPER_FUNC "%s did not return a function"
+#define ERIS_ERR_SPER_LOAD "bad unpersist function (%s expected, returned %s)"
+#define ERIS_ERR_SPER_PROT "attempt to persist forbidden table"
+#define ERIS_ERR_SPER_TYPE "%d not nil, boolean, or function"
+#define ERIS_ERR_SPER_UFUNC "invalid restore function"
+#define ERIS_ERR_SPER_UPERM "bad permanent value (%s expected, got %s)"
+#define ERIS_ERR_SPER_UPERMNIL "bad permanent value (no value)"
+#define ERIS_ERR_STACKBOUNDS "stack index out of bounds"
+#define ERIS_ERR_TABLE "bad table value, got a nil value"
+#define ERIS_ERR_THREAD "cannot persist currently running thread"
+#define ERIS_ERR_THREADCI "invalid callinfo"
+#define ERIS_ERR_THREADCTX "bad C continuation function"
+#define ERIS_ERR_THREADERRF "invalid errfunc"
+#define ERIS_ERR_THREADPC "saved program counter out of bounds"
+#define ERIS_ERR_TRUNC_INT "int value would get truncated"
+#define ERIS_ERR_TRUNC_SIZE "size_t value would get truncated"
+#define ERIS_ERR_TYPE_FLOAT "unsupported lua_Number type"
+#define ERIS_ERR_TYPE_INT "unsupported int type"
+#define ERIS_ERR_TYPE_SIZE "unsupported size_t type"
+#define ERIS_ERR_TYPEP "trying to persist unknown type %d"
+#define ERIS_ERR_TYPEU "trying to unpersist unknown type %d"
+#define ERIS_ERR_UCFUNC "bad C closure (C function expected, got %s)"
+#define ERIS_ERR_UCFUNCNULL "bad C closure (C function expected, got null)"
+#define ERIS_ERR_USERDATA "attempt to literally persist userdata"
+#define ERIS_ERR_WRITE "could not write data"
+#define ERIS_ERR_REF "invalid reference #%d. this usually means a special "\
+  "persistence callback of a table referenced said table "\
+  "(directly or indirectly via an upvalue)."
+
+/*
+** 
 ** Constants, settings, types and forward declarations.
 ** 
 */
@@ -266,6 +308,12 @@
 #define BUFFIDX 3
 #define PATHIDX 4
 
+/* Table indices for upvalue tables, keeping track of upvals to open. */
+#define U

[Widelands-dev] [Merge] lp:~widelands-dev/widelands/bug-1395322-tool3 into lp:widelands

2016-04-07 Thread noreply
The proposal to merge lp:~widelands-dev/widelands/bug-1395322-tool3 into 
lp:widelands has been updated.

Status: Needs review => Merged

For more details, see:
https://code.launchpad.net/~widelands-dev/widelands/bug-1395322-tool3/+merge/290829
-- 
Your team Widelands Developers is subscribed to branch 
lp:~widelands-dev/widelands/bug-1395322-tool3.

___
Mailing list: https://launchpad.net/~widelands-dev
Post to : widelands-dev@lists.launchpad.net
Unsubscribe : https://launchpad.net/~widelands-dev
More help   : https://help.launchpad.net/ListHelp


Re: [Widelands-dev] [Merge] lp:~widelands-dev/widelands/bug-1395322-tool3 into lp:widelands

2016-04-07 Thread GunChleoc
Thanks for testing & review :)

@bunnybot merge
-- 
https://code.launchpad.net/~widelands-dev/widelands/bug-1395322-tool3/+merge/290829
Your team Widelands Developers is subscribed to branch 
lp:~widelands-dev/widelands/bug-1395322-tool3.

___
Mailing list: https://launchpad.net/~widelands-dev
Post to : widelands-dev@lists.launchpad.net
Unsubscribe : https://launchpad.net/~widelands-dev
More help   : https://help.launchpad.net/ListHelp


Re: [Widelands-dev] [Merge] lp:~widelands-dev/widelands/python3 into lp:widelands

2016-04-07 Thread GunChleoc
On my system. this will start the Widelands main screen for each test instead 
of going to the scenario. Python 2.7
-- 
https://code.launchpad.net/~widelands-dev/widelands/python3/+merge/291236
Your team Widelands Developers is subscribed to branch 
lp:~widelands-dev/widelands/python3.

___
Mailing list: https://launchpad.net/~widelands-dev
Post to : widelands-dev@lists.launchpad.net
Unsubscribe : https://launchpad.net/~widelands-dev
More help   : https://help.launchpad.net/ListHelp


Re: [Widelands-dev] [Merge] lp:~widelands-dev/widelands/python3 into lp:widelands

2016-04-07 Thread Tino
Review: Needs Fixing

Hm, I did run the test with both Python 2/3 without these errors, but perhaps I 
aborted them too early.
Or the test do not currently run on windows?

I'll check this later today...
-- 
https://code.launchpad.net/~widelands-dev/widelands/python3/+merge/291236
Your team Widelands Developers is subscribed to branch 
lp:~widelands-dev/widelands/python3.

___
Mailing list: https://launchpad.net/~widelands-dev
Post to : widelands-dev@lists.launchpad.net
Unsubscribe : https://launchpad.net/~widelands-dev
More help   : https://help.launchpad.net/ListHelp


Re: [Widelands-dev] [Merge] lp:~widelands-dev/widelands/python3 into lp:widelands

2016-04-07 Thread Klaus Halfmann
Mhh, even using python 2.7 does not work, it just gets stuck in the splasg 
screeen?
Was there some change in the Lua Binding?
-- 
https://code.launchpad.net/~widelands-dev/widelands/python3/+merge/291236
Your team Widelands Developers is requested to review the proposed merge of 
lp:~widelands-dev/widelands/python3 into lp:widelands.

___
Mailing list: https://launchpad.net/~widelands-dev
Post to : widelands-dev@lists.launchpad.net
Unsubscribe : https://launchpad.net/~widelands-dev
More help   : https://help.launchpad.net/ListHelp


Re: [Widelands-dev] [Merge] lp:~widelands-dev/widelands/python3 into lp:widelands

2016-04-07 Thread Klaus Halfmann
OK, thas as far as I came, too but now I get
$ ./regression_test.py -b ./widelands 
...
File "./regression_test.py", line 103, in run_widelands
  stdout_file.write(line)
TypeError: must be str, not bytes

I used 
   print(line, flush=True)
for
   stdout_file.write(line)
   stdout_file.flush()

but this in not python2.7 compatible :-(

In addition I used 

< "Widelands exited abnormally. %s" % common_msg
---
> "Widelands exited abnormally. " + common_msg

< "Not all tests pass. %s." % common_msg
---
> "Not all tests pass. " + common_msg

but perhaos that .format() aproach is more compatible
-- 
https://code.launchpad.net/~widelands-dev/widelands/python3/+merge/291236
Your team Widelands Developers is requested to review the proposed merge of 
lp:~widelands-dev/widelands/python3 into lp:widelands.

___
Mailing list: https://launchpad.net/~widelands-dev
Post to : widelands-dev@lists.launchpad.net
Unsubscribe : https://launchpad.net/~widelands-dev
More help   : https://help.launchpad.net/ListHelp


Re: [Widelands-dev] [Merge] lp:~widelands-dev/widelands/python3 into lp:widelands

2016-04-07 Thread Klaus Halfmann
Looks like you know more about python than I do,
lets check this ...
-- 
https://code.launchpad.net/~widelands-dev/widelands/python3/+merge/291236
Your team Widelands Developers is requested to review the proposed merge of 
lp:~widelands-dev/widelands/python3 into lp:widelands.

___
Mailing list: https://launchpad.net/~widelands-dev
Post to : widelands-dev@lists.launchpad.net
Unsubscribe : https://launchpad.net/~widelands-dev
More help   : https://help.launchpad.net/ListHelp


[Widelands-dev] [Merge] lp:~widelands-dev/widelands/python3 into lp:widelands

2016-04-07 Thread Tino
Tino has proposed merging lp:~widelands-dev/widelands/python3 into lp:widelands.

Commit message:
Add a compatibility layer to regression_test.py to allow running with python 2 
and 3

Requested reviews:
  Widelands Developers (widelands-dev)
Related bugs:
  Bug #1566876 in widelands: "regression_test.py fails with Python 3.4.4"
  https://bugs.launchpad.net/widelands/+bug/1566876

For more details, see:
https://code.launchpad.net/~widelands-dev/widelands/python3/+merge/291236

Add a compatibility layer to regression_test.py to allow running with python 2 
and 3
-- 
Your team Widelands Developers is requested to review the proposed merge of 
lp:~widelands-dev/widelands/python3 into lp:widelands.
=== modified file 'regression_test.py'
--- regression_test.py	2016-02-04 12:21:58 +
+++ regression_test.py	2016-04-07 11:51:58 +
@@ -12,6 +12,22 @@
 import unittest
 import platform
 
+#Python2/3 compat code for iterating items
+try:
+dict.iteritems
+except AttributeError:
+# Python 3
+def itervalues(d):
+return iter(d.values())
+def iteritems(d):
+return iter(d.items())
+else:
+# Python 2
+def itervalues(d):
+return d.itervalues()
+def iteritems(d):
+return d.iteritems()
+		
 def datadir():
 return os.path.join(os.path.dirname(__file__), "data")
 
@@ -76,7 +92,7 @@
 '--disable_fx=true',
 '--disable_music=true',
 '--language=en_US' ]
-args += [ "--%s=%s" % (key, value) for key, value in wlargs.iteritems() ]
+args += [ "--%{}=%{}".format(key, value) for key, value in iteritems(wlargs) ]
 
 widelands = subprocess.Popen(
 args, shell=False, stdout=subprocess.PIPE, stderr=subprocess.STDOUT)
@@ -214,7 +230,7 @@
 args = parse_args()
 
 WidelandsTestCase.path_to_widelands_binary = args.binary
-print "Using '%s' binary." % args.binary
+print("Using '{}' binary.".format(args.binary)) 
 WidelandsTestCase.do_use_random_directory = not args.nonrandom
 WidelandsTestCase.keep_output_around = args.keep_around
 

___
Mailing list: https://launchpad.net/~widelands-dev
Post to : widelands-dev@lists.launchpad.net
Unsubscribe : https://launchpad.net/~widelands-dev
More help   : https://help.launchpad.net/ListHelp


[Widelands-dev] [Merge] lp:~widelands-dev/widelands/python3 into lp:widelands

2016-04-07 Thread Tino
The proposal to merge lp:~widelands-dev/widelands/python3 into lp:widelands has 
been updated.

Commit Message changed to:

Add a compatibility layer to regression_test.py to allow running with python 2 
and 3

For more details, see:
https://code.launchpad.net/~widelands-dev/widelands/python3/+merge/291236
-- 
Your team Widelands Developers is requested to review the proposed merge of 
lp:~widelands-dev/widelands/python3 into lp:widelands.

___
Mailing list: https://launchpad.net/~widelands-dev
Post to : widelands-dev@lists.launchpad.net
Unsubscribe : https://launchpad.net/~widelands-dev
More help   : https://help.launchpad.net/ListHelp


Re: [Widelands-dev] [Merge] lp:~widelands-dev/widelands/bug-1395322-tool3 into lp:widelands

2016-04-07 Thread Miroslav Remák
See diff comments, otherwise LGTM.

Diff comments:

> 
> === modified file 'src/editor/ui_menus/tool_change_height_options_menu.h'
> --- src/editor/ui_menus/tool_change_height_options_menu.h 2016-04-06 
> 09:23:04 +
> +++ src/editor/ui_menus/tool_change_height_options_menu.h 2016-04-07 
> 06:07:24 +
> @@ -21,8 +21,9 @@
>  #define WL_EDITOR_UI_MENUS_TOOL_CHANGE_HEIGHT_OPTIONS_MENU_H
>  
>  #include "editor/ui_menus/tool_options_menu.h"
> +#include "ui_basic/box.h"
>  #include "ui_basic/button.h"

You can remove this include.

> -#include "ui_basic/textarea.h"
> +#include "ui_basic/spinbox.h"
>  
>  class EditorInteractive;
>  struct EditorIncreaseHeightTool;
> 
> === modified file 'src/editor/ui_menus/tool_noise_height_options_menu.h'
> --- src/editor/ui_menus/tool_noise_height_options_menu.h  2016-04-06 
> 09:23:04 +
> +++ src/editor/ui_menus/tool_noise_height_options_menu.h  2016-04-07 
> 06:07:24 +
> @@ -23,6 +23,9 @@
>  #include "editor/ui_menus/tool_options_menu.h"
>  #include "ui_basic/button.h"
>  #include "ui_basic/textarea.h"

You can remove these two includes.

> +#include "ui_basic/box.h"
> +#include "ui_basic/button.h"

And this one.

> +#include "ui_basic/spinbox.h"
>  
>  class EditorInteractive;
>  struct EditorNoiseHeightTool;


-- 
https://code.launchpad.net/~widelands-dev/widelands/bug-1395322-tool3/+merge/290829
Your team Widelands Developers is subscribed to branch 
lp:~widelands-dev/widelands/bug-1395322-tool3.

___
Mailing list: https://launchpad.net/~widelands-dev
Post to : widelands-dev@lists.launchpad.net
Unsubscribe : https://launchpad.net/~widelands-dev
More help   : https://help.launchpad.net/ListHelp


[Widelands-dev] [Merge] lp:~widelands-dev/widelands/string-fixes into lp:widelands

2016-04-07 Thread noreply
The proposal to merge lp:~widelands-dev/widelands/string-fixes into 
lp:widelands has been updated.

Status: Needs review => Merged

For more details, see:
https://code.launchpad.net/~widelands-dev/widelands/string-fixes/+merge/291154
-- 
Your team Widelands Developers is subscribed to branch 
lp:~widelands-dev/widelands/string-fixes.

___
Mailing list: https://launchpad.net/~widelands-dev
Post to : widelands-dev@lists.launchpad.net
Unsubscribe : https://launchpad.net/~widelands-dev
More help   : https://help.launchpad.net/ListHelp


Re: [Widelands-dev] [Merge] lp:~widelands-dev/widelands/string-fixes into lp:widelands

2016-04-07 Thread GunChleoc
@bunnybot merge
-- 
https://code.launchpad.net/~widelands-dev/widelands/string-fixes/+merge/291154
Your team Widelands Developers is subscribed to branch 
lp:~widelands-dev/widelands/string-fixes.

___
Mailing list: https://launchpad.net/~widelands-dev
Post to : widelands-dev@lists.launchpad.net
Unsubscribe : https://launchpad.net/~widelands-dev
More help   : https://help.launchpad.net/ListHelp


Re: [Widelands-dev] [Merge] lp:~widelands-dev/widelands/string-fixes into lp:widelands

2016-04-07 Thread Miroslav Remák
Review: Approve

LGTM.
-- 
https://code.launchpad.net/~widelands-dev/widelands/string-fixes/+merge/291154
Your team Widelands Developers is subscribed to branch 
lp:~widelands-dev/widelands/string-fixes.

___
Mailing list: https://launchpad.net/~widelands-dev
Post to : widelands-dev@lists.launchpad.net
Unsubscribe : https://launchpad.net/~widelands-dev
More help   : https://help.launchpad.net/ListHelp


Re: [Widelands-dev] [Merge] lp:~widelands-dev/widelands/bug-1395322-tool3 into lp:widelands

2016-04-07 Thread kaputtnik
Review: Approve testing

I think it's good to go now :-)
-- 
https://code.launchpad.net/~widelands-dev/widelands/bug-1395322-tool3/+merge/290829
Your team Widelands Developers is subscribed to branch 
lp:~widelands-dev/widelands/bug-1395322-tool3.

___
Mailing list: https://launchpad.net/~widelands-dev
Post to : widelands-dev@lists.launchpad.net
Unsubscribe : https://launchpad.net/~widelands-dev
More help   : https://help.launchpad.net/ListHelp