« first day (62 days earlier)      last day (3799 days later) » 

08:18
Monking
Monking @SimonAndréForsberg
08:46
So, let's see... what should I code today?
I don't know
I've got 25 minutes to get the teachers attention and get help, before I have a meeting
1
Q: The ja_JP_JP_#u-ca-japanese locale cannot be reparsed by its own pattern using the Java 8 Date and Time API (Possible JDK bug)

skiwiI've run across a strange issue when testing some method of mine and I seem to have been able to obtain a concrete example of my issue. I am using the ja_JP_JP_#u-ca-japanese locale not able to parse a date using it's own date pattern defined by the locale. I am wondering whether I am doing som...

@skiwi Luckily, looking at the waffle I remember.
For some reason this question doesn't seem to take off
I admit it is not the issue most of the SO crowd will think "this is fun!"
@skiwi Not all your SO questions does.
I need a more attractive title
08:49
Write the title in Japanese.
Well, I expected more than 10 views and probably a santa upvote
Santa doesn't work on Stack Overflow.
On other hand, I did get the Socratic gold badge on SO
 
1 hour later…
09:56
Well, that's always something :)
I wonder if Travis will build this...
> Working on refactoring Server
It works on my machine, but I wonder if Travis might have some higher security settings
10:04
Well I'll be damned.
Good, then I can continue this work...
Does Travis run virtual machines? (I mean, not VMs like the Java VM, more like... VMWare and stuff)
Why do I get a déja vù feeling? It feels like I have written this code before...
Ah, here it is... it's not the same but pretty close
That answers that question. Good.
@SimonAndréForsberg Certified by
@SimonAndréForsberg Yes, I think (have no source) that Travis uses hundreds of VM's, puts them in a queue to build things and once finished completely reinstalls Linux and then after a few minutes puts it back in the queue
@skiwi it does seem like that, yes.
It's a really nice system they've set up
10:21
I added more drama by the way
1
Q: LocalDate and DateTimeFormatter do not work correctly with Japanese locale (Possible JDK bug)

skiwiI've run across a strange issue when testing some method of mine and I seem to have been able to obtain a concrete example of my issue. I am using the ja_JP_JP_#u-ca-japanese locale not able to parse a date using it's own date pattern defined by the locale. I am wondering whether I am doing som...

And less technical stuff in the title
I am suspecting it happens because the DateTimeFormatter returns a date format with also an Era specifier (G), but I'm not sure if the LocalDate supports that, it only has a year, month and day
@SimonAndréForsberg Without looking at the actual video or opening the link, it's about "Push button to add drama", right?
@skiwi yup :)
in The 2nd Monitor, 15 secs ago, by Simon André Forsberg
It's quite here today... We need drama!
;)
@skiwi I've never had any use for interpreting Japanese days, and I guess not so many others have either, which is why I think your question doesn't get so much attention
10:26
I'll let it live there for a bit, then I'll do some more extensive testing and submit a full bug report to the JDK team
Wow I got 6 more views already now, that's like an increase of 50%!
I need to look into Parametrized tests though
You haven't used Parametrized tests!?!??!? shocked!
I had this answer, but I needed myself to stay calm... I'm still bordering that the answer is way to simple
0
A: Parsing dates from an OCR application

EpinujThis could be solved with org.joda.time.format.DateTimeFormat. As for the tests. Do not assert in the for loop. If the assertion fails then the whole test fails. So if it fails on the first date, then you don't know anything about other dates. Use parameterized tests instead.

He does raise a valid point though, so I cannot really blame it
I have heard a lot about JodaTime, and I would not be surprised if that indeed does solve it.
Maybe I got spoiled by the CR regulars, but I'm expecting more of a CR answer
Can you run parametrized tests on a single test-method?
> Added assertion for logging in to server
10:35
I'll stick with regular JUnit though
@skiwi sure you can
If you're testing the same thing for several expected inputs/outputs, parametrized unit tests are your friend
I believe someone wrote an answer to a JDQ about that a while ago...
Not the question I was thinking about, but this will do:
6
A: Converting an integer number into its word representation

palacsintSome notes: wordForm should be StringBuilder: http://stackoverflow.com/questions/73883/string-vs-stringbuilder Actually, I'd rename it to result too to make it clear that this object stores the result of the method. Instead of the System.out.printlns, use a parametrized unit test: import stati...

10:51
@SimonAndréForsberg Is it okay to mix up parametrized methods and non-parametrized methods in a test?
Probably not...
I wouldn't recommend it
How would you solve it then?
it's possible, but then you will just do the same thing for each of the parametrized tests, which is pointless
Inner classes? Or two separate classes
separate the tests. two separate test classes
10:54
Another question
I currently support almost all locales, except a few
Does it make sense to include unit tests for the failing locales to ensure that they keep failing?
Idea behind is that they should be pulled into the supported locales as soon as possible
@skiwi I think I have seen some programmers questions about that
IMO, sounds like you don't need a test for it
if (mess.trim().isEmpty())
    continue;
Shouldn't FindBugs alert about that? ^^
@SimonAndréForsberg Not sure, depends on the settings
apparently not then
We can check out some guidelines in a few days
I got familiar with FindBugs settings yesterday
As some auto-generated classes raised FindBugs exceptions, so there was no way to go around it
Does this look okay for a test?
@RunWith(Parameterized.class)
public class DateParserAllLocalesTest {
    @Parameters(name = "{0}")
    public static Collection<Object[]> allLocales() {
        List<Locale> locales = new ArrayList<>(Arrays.asList(Locale.getAvailableLocales()));
        locales.remove(new Locale("ja", "JP", "JP"));
        locales.remove(new Locale("zh", "HK"));
        return locales.stream().map(locale -> new Object[]{locale}).collect(Collectors.toList());
    }

    @Parameter
    public Locale locale;

    @Test
11:17
hey guys
Hey @bazola
Monking @bazola
git rebase origin/ais
fatal: Needed a single revision
invalid upstream origin/ais
@skiwi That's not how I've been using it, but if that works then that looks better than how I've been using it
@bazola try git fetch
and then git rebase origin/ais
@SimonAndréForsberg It works yes... How have you been using it then?
11:24
[Cardshifter/Cardshifter] bazola pushed 19 commits to javafx
> client now gets visual update when opponent leaves
> merging branches
	@Parameterized.Parameters
	public static Collection<Object[]> getMapsToSolve() {
		List<Object[]> result = new ArrayList<Object[]>();

		for (String str : getOfficialMaps()) {
			result.add(new Object[]{ str });
		}

		return result;
	}

	public SolveTest(String map) {
		this.mapString = map;
	}
^^ like that @skiwi
@SimonAndréForsberg that worked thank you
[Cardshifter/Cardshifter] build #246 for commit 239c90c0 on branch javafx passed
Hmm... the network graph didn't end up like I expected it to, but oh well...
Do you have the commands + outputs history @bazola ?
bazs-MacBook-Air:Cardshifter baz01 baz$ git rebase origin/ais
fatal: Needed a single revision
invalid upstream origin/ais
bazs-MacBook-Air:Cardshifter baz01 baz$ git status
On branch javafx
Your branch is up-to-date with 'origin/javafx'.

nothing to commit, working directory clean
bazs-MacBook-Air:Cardshifter baz01 baz$ git rebase origin/ais
fatal: Needed a single revision
invalid upstream origin/ais
bazs-MacBook-Air:Cardshifter baz01 baz$ git fetch
remote: Counting objects: 545, done.
remote: Compressing objects: 100% (391/391), done.
11:28
Ah, I see...
@bazola When rebasing, you can ignore the "Your branch and 'origin/javafx' have diverged" and instead of doing git pull instead do git push --force
At least that's how I do it
alright, will try to remember that :) there are a lot of git commands, and it is tough to know when to perform which one
at least now I understand why the network graph ended up like that
@bazola I've learned mostly by reading some of the manual, using the commands and looking at how the network graph changes.
the AI sure is playing a lot better :)
yeah, now you actually have to think a bit when playing it
it's still quite easy to win though
i wonder why two end turn buttons are showing up now..
11:36
I noticed that when I did some refactoring. I'm not quite sure why actually, but I think it has something to do with how the available actions are sent.
weird, this seemed to come in twice:
EntityRemoveMessage [entity=40]
com.cardshifter.api.outgoing.ResetAvailableActionsMessage@3a2531e0
UseableActionMessage [id=25, action=Scrap, targetRequired=false, targetId=0]
UseableActionMessage [id=25, action=Attack, targetRequired=true, targetId=0]
UseableActionMessage [id=1, action=End Turn, targetRequired=false, targetId=0]
com.cardshifter.api.outgoing.ResetAvailableActionsMessage@636c5004
UseableActionMessage [id=25, action=Scrap, targetRequired=false, targetId=0]
UseableActionMessage [id=25, action=Attack, targetRequired=true, targetId=0]
I don't know if it should be fixed in the server or the client
But there's a ResetAvailableActionsMessage in between there so it shouldn't matter.
Or do you not care about the ResetAvailableActionsMessage ?
when that message is received, it should clear out the available actions bar
yes
so there should only be one End Turn button
@SimonAndréForsberg Ah, I prefer ot have less cluttering :)
11:40
my method wasn't doing what I thought it was
2
@SimonAndréForsberg I've learned it by practicing with it and using @Simon for debugging
11:55
> Server now shuts down in a better way when using exit command
> Moved ClientIO class and added tests for starting game
> fixed duplicate action buttons bug
[Cardshifter/Cardshifter] build #248 for commit 8d5e128c on branch javafx passed
why did I think that playing smash bros 3DS online would not be laggy..
@bazola Marketing?
lol I didn't need any marketing to buy the game, I have been playing smash bros since nintendo 64
12:38
@SimonAndréForsberg what is this Menu class you speak of in issue 48?
@bazola It seems like I'm thinking of MenuBar
And then a MenuBar contains Menu items
Menubars are regularly not the final product though... It looks fine to have them for now though
@skiwi I don't see what other options exists?
Custom art, but that's in a later phase
12:44
Or placing regular buttons at special locations
yes, indeed
I think for now a menu is easier though
For now it's fine
seems like it is not really needed at this time though? I figured I would just make 3 buttons (when there are 3 AI options), and clicking that button would launch the local client with that AI. unless the AI can be changed mid game?
@bazola for now, sure. (I'm not sure right now what other options I thought could be useful for the Menu)
I'd recommend creating them programmatically though, so that the code can be the same for when new AIs are added.
Huh, for some reason I thought for a moment that @SimonAndréForsberg made @Duga, wtf brain?
@skiwi I only helped you a little with it
You did the most of it
I know... that's why, wtf, it's Friday, brain isn't working anymore
@Duga Alarm alarm!
13:46
I still think it should raise a bigger alarm ;)
Hey guys
Stupid concurrency...
hey @Phrancis
Having trouble loading The 2nd Monitor, I have a feeling it's this stupid browser. Are you guys having issues with it?
@Phrancis still on IE?
13:49
no problems here
I did put in a ticket to update to IE 10/11, hopefully it's going to fix some issues
For some reason it's switching to Compatibility View trying to load the other room. Oh well.
I meant to ask you guys... I've been feeling kind of useless on this project lately, is there anything that I can do to help you guys? With the understanding I don't know Java or Lua :-\
@Phrancis game testing and game balancing is one thing I think you could help with
Also brainstorming and idea generating
And perhaps it's starting to be time to think about artwork / music?
OK. I have not had a chance to try the game yet... is there a compiled version available of 0.2? I can't compile it from this computer (no JDK)
@Phrancis hold on and I can give you a version 0.2.5, with a better AI
Will it run on this? ^^
14:04
@Phrancis unfortunately not :( Cardshifter requires Java 1.8 :(
Ah ok. You mean 8.1?
@Phrancis Java 8 and Java 1.8 is the same thing (don't know why they use both names)
Ah ok. Go figure :)
I'll see if this POS computer will let me update to Java 8
@skiwi Have you changed the POMs recently? mvn package doesn't work properly for me...
The JARs are not shaded, so when you start them you get a bunch of NoClassDefFoundErrors
which means that something is broken
Also, I noticed that it doesn't copy all the JARs to one targets directory
Is Java 8 supported on Windows 7?
14:10
I tried it on the JavaFX branch
@Phrancis Absolutely yes.
I'm running Windows 7 myself
Yay :D
@Phrancis that will work, yes
@Phrancis You can download version 0.2 here: github.com/Cardshifter/Cardshifter/releases
Unfortunately I'm not able to provide a new version right now, something is broken with the building process
No worries
@Phrancis Start the server first and then just start the client, then you will be connected to a game vs the old AI
@SimonAndréForsberg how to convert this line to a different AI? private final AIComponent aiComponent = new AIComponent(new CompleteIdiot());
14:20
Either I'm doing something wrong, or this computer is stupid. When I execute the server file, all it does is create a text file in the folder where I saved it...
@bazola new ScoringAI(AIs.medium()); or new ScoringAI(AIs.loser()); or new ScoringAI(AIs.idiot());
awesome thank you :)
@Phrancis it should show a console window as well... if it doesn't show a console window, run it from a console window and you should see what error occurs
@skiwi I think I found the reason for why it doesn't build properly. Apparently I am the one who broke it when I added <pluginManagement>
I'm working on it
@SimonAndréForsberg I am a bit unsure how to create the buttons programmatically. How can I find out what the available AIs are at the moment
@bazola In the client: Just add all the AIs that you know of to a List<CardshifterAI> (or a Map<String, CardshifterAI>). It's OK to define what AIs exists IMO, but hard-coding the buttons in the FXML would be good to avoid.
I believe it's much easier to change a list/map than all the buttons (plus the list/map)
14:34
alright, that will work
Well... even though the server didn't seem to do anything, I started the client afterwards and seems to be working OK
if you run the server in the console with the java -jar command, you should see all the server messages
Hmm - opponent health is in the negative but it's still playing.
@Phrancis yeah, that has been fixed in a more recent version
Oh ok :)
C:\Users\fveilleux-gaboury>java -jar
Error: -jar requires jar file specification
Usage: java [-options] class [args...]
           (to execute a class)
   or  java [-options] -jar jarfile [args...]
           (to execute a jar file)
14:43
you need to specify the filename of the server jar
(sorry all this stuff is so foreign to me!)
Including path I'm assuming?
@Phrancis unless it is in the current path, yes.
although I recommend if you run it from the correct path directly, it's easier that way
C:\Users\fveilleux-gaboury>java -jar C:\TCG\cardshifter-server-0.2.jar
[2014-10-03 10:48:16,601]  INFO MainServer [      main] (       MainServer.java:
 19) - Starting Server...
[2014-10-03 10:48:16,788] ERROR MainServer [      main] (       MainServer.java:
 37) - Initializing Error
java.net.BindException: Address already in use: JVM_Bind
        at java.net.DualStackPlainSocketImpl.bind0(Native Method)
        at java.net.DualStackPlainSocketImpl.socketBind(Unknown Source)
        at java.net.AbstractPlainSocketImpl.bind(Unknown Source)
you have to make sure to close the java server that is already running
if you don't see it anywhere, you should be able to find it in the windows task manager, possibly under processes, and it will just be called java
15:03
> Refactored pom.xml files to use <pluginManagement> tag correctly
> Fixed FindBugs warning in ZoneMessage
> Working on refactoring Server
> Added assertion for logging in to server
> Server now shuts down in a better way when using exit command
(just a rebase)
> Moved ClientIO class and added tests for starting game
> Added a test to play a game against AI Loser
> COMMIT ... ALL THE THINGS
2
DEBUG ... ALL THE TESTS!
2
15:09
@Duga No it's not. It's just a Heisenbug
do i need to put this. before everything? is it best practice to do so? does it automatically figure out that it is a class field if I don't?
@bazola what do you mean by 'before everything'?
like I have a class field private AIComponent aiChoice. I want to pass it as an argument into something. Should I put this.aiChoice or just aiChoice?
15:17
@bazola that doesn't matter. I'm not even consistent myself there
if so then for now I will always do this.
I pass in the AIComponent before the game starts. When I try to start the game over again (using the already passed in component) I get this:
Caused by: java.lang.IllegalStateException: Component net.zomis.cardshifter.ecs.ai.AIComponent@31bd020c is already connected to another entity.
	at net.zomis.cardshifter.ecs.base.Component.setEntity(Component.java:13)
	at net.zomis.cardshifter.ecs.base.Entity.addComponent(Entity.java:24)
	at com.cardshifter.fx.FXMLGameController.initializeGame(FXMLGameController.java:62)
	at com.cardshifter.fx.FXMLGameController.newGameButtonAction(FXMLGameController.java:91)
	... 53 more
@bazola You shouldn't pass in a AIComponent. It's enough if you use the existing AIComponent and call the setAI method
hmm
I can just pass a string in instead, but I figured it would be better to create the AIComponent in the client launcher and pass it in..
15:24
@bazola pass a string? create the AIComponent? Pass to where exactly?
this is the start of the single player game here:
	private AIComponent aiComponent;

//	private ScheduledExecutorService aiExecutor = Executors.newSingleThreadScheduledExecutor();

	public void acceptAIChoice(AIComponent aiChoice) {
		this.aiComponent = aiChoice;
	}

	public void initializeGame() {
		game = PhrancisGame.createGame();
		phases = ComponentRetriever.singleton(game, PhaseController.class);
		getPlayer(1).addComponent(this.aiComponent);
//		AISystem.setup(game, aiExecutor);
	}
this is what I am doing in the launcher (its not selectable just yet):
	private void createAIChoices() {
		this.aiChoices.put("Idiot", new AIComponent(new ScoringAI(AIs.loser())));
		this.aiChoices.put("Loser", new AIComponent(new ScoringAI(AIs.loser())));
		this.aiChoices.put("Medium", new AIComponent(new ScoringAI(AIs.medium())));
		localGameButton.setOnAction(this::localGameStart);

		this.aiChoice = this.aiChoices.get("Medium");
	}
OK
Hmm...
You'd want to pass the chosen AI from the launcher to the FXMLGameController, right?
I think you need to do that in a similar way to how you pass the address and port for the GameClient:
			FXMLLoader loader = new FXMLLoader(getClass().getResource("ClientDocument.fxml"));
			Parent root = (Parent)loader.load();

			GameClientController controller = loader.<GameClientController>getController();
			controller.acceptIPAndPort(ipAddress, port);
So for the FXMLGameController I think that would be something like this:
FXMLLoader loader = new FXMLLoader(getClass().getResource("ClientDocument.fxml"));
Parent root = (Parent)loader.load();
FXMLGameController controller = loader.getController();
controller.setAI(chosenAI);
controller.initializeGame();
Because the aiComponent must be initialized inside the initializeGame method
Should I log bugs / balance issues / feature requests to Github?
@Phrancis either Github, the Q&A, or chat :)
15:35
(I'll check with you all first on bugs on this release to make sure it's not fixed already)
Well, whichever is easier to keep things organized for you guys...
@Phrancis Github is a good way to keep things organized. If you are unsure about something, chat is a good place to... chat :)
And then if we want to discuss it further, Github or the Q&A can be a good place to discuss.
I do need to familiarize myself with Github - Never used it before :)
@Phrancis This page will be your friend: github.com/Cardshifter/Cardshifter/issues/new :)
If you want to see what things we are working on, I like github.com/Cardshifter/Cardshifter/network a lot (but perhaps that's because I understand what all the lines and stuff mean...)
> Sorry, your browser doesn't support the <canvas> element.
2
lol... who knew.
15:40
Oh well :)
How do you select a label for a new issue?
@Phrancis I sent you an invite to join the team, I think that's required to add labels to the issues
Labels can also be added and removed afterwards
OK how do I retrieve the invite?
@bazola I've made a couple of changes to some Server messages, so that it is possible to specify what kind of game to play and what opponent to invite. It would perhaps be handy to have a little 'Lobby' where you can find an opponent to play against (choose an AI, or human player, etc.). You want me to help you a bit in working on that? I see you have quite a lot to do
@Phrancis You should have received a notification about it on github. Look at the top right
Hmm must be a browser bug, I don't see it... can you try again? I think I cleared all my notifications by accident
15:47
@Phrancis check your e-mail. or check github.com/Cardshifter
@bazola Or perhaps we shouldn't have a 'lobby'? What do you think?
That worked thanks!
> Would it be possible to export a list of all current cards in Excel or CSV format? The purpose for this is so that I can work with Jay to start giving cards names and descriptions.
It appears the "Help Wanted" label did not attach...
@Phrancis The current cards are exactly the same as the ones you told me though :) With one minor adjustment: It is currently not required to already have an existing enchantment on a creature to enchant it with the enchantment that costs 5 scrap. (And I still have never used that enchantment yet)
But the request is still interesting, and would be useful I think...
Holy cow 134 messages?!
almost more than in The 2nd Monitor...
15:58
@skiwi WHERE HAVE YOU BEEN!?
@SimonAndréForsberg Somewhere between university and home mostly
I managed to read a part in the bus, where you blamed me for something you broke ;-)
Alright :) You've missed a bit... nothing too important though. I managed to solve the issues with Maven

« first day (62 days earlier)      last day (3799 days later) »