Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Cake 0.38.1 is failing to write messages to TeamCity #2790

Closed
ilnur-nazmutdinov-spark opened this issue Jun 4, 2020 · 8 comments
Closed
Assignees
Labels
Milestone

Comments

@ilnur-nazmutdinov-spark
Copy link

What You Are Seeing?

Cake is failing to write messages to TeamCity. Cake 0.37.0 works well.

What is Expected?

Cake should write messages to TeamCity successfully

What version of Cake are you using?

0.38.1

Are you running on a 32 or 64 bit system?

64

What environment are you running on? Windows? Linux? Mac?

Mac

Are you running on a CI Server? If so, which one?

TeamCity

How Did You Get This To Happen? (Steps to Reproduce)

Running cake script from TeamCity with Cake 0.38.1
We're using methods:

TeamCity.WriteStartBuildBlock
TeamCity.WriteStartProgress
TeamCity.WriteEndProgress
TeamCity.WriteEndBuildBlock
TeamCity.SetBuildNumber
TeamCity.WriteProgressMessage
TeamCity.PublishArtifacts

Output Log

All the calls has pretty the same output:

[23:26:21][Step 6/6] Executing custom task setup action (CleanArtifactsFolder)...
[23:26:21][Step 6/6] 
[23:26:21][Step 6/6] ##teamcity[compilationStarted compiler='CleanArtifactsFolder']
[23:26:23][Step 6/6] Error while parsing TeamCity service message: Incorrect property name "[0mcompilationStarted compiler": should not contain spaces. Valid service message has a form of "##teamcity[messageName name1='escaped_value' name2='escaped_value']" where escaped_value uses substitutions: '->|', [->|[, ]->|], |->||, newline->|n
[23:26:21][Step 6/6] 
[23:26:21][Step 6/6] 
[23:26:21][Step 6/6] ##teamcity[progressStart 'CleanArtifactsFolder']
[23:26:23][Step 6/6] Error while parsing TeamCity service message: Property value not found (no "=" character). Valid service message has a form of "##teamcity[messageName name1='escaped_value' name2='escaped_value']" where escaped_value uses substitutions: '->|', [->|[, ]->|], |->||, newline->|n
[23:26:21][Step 6/6] 
[23:26:21][Step 6/6] 
[23:26:21][Step 6/6] ========================================
[23:26:21][Step 6/6] CleanArtifactsFolder
[23:26:21][Step 6/6] ========================================
[23:26:21][Step 6/6] Executing task: CleanArtifactsFolder
...
[23:26:21][Step 6/6] Finished executing task: CleanArtifactsFolder
[23:26:21][Step 6/6] Executing custom task teardown action (CleanArtifactsFolder)...
[23:26:21][Step 6/6] 
[23:26:21][Step 6/6] ##teamcity[progressFinish 'CleanArtifactsFolder']
[23:26:23][Step 6/6] Error while parsing TeamCity service message: Property value not found (no "=" character). Valid service message has a form of "##teamcity[messageName name1='escaped_value' name2='escaped_value']" where escaped_value uses substitutions: '->|', [->|[, ]->|], |->||, newline->|n
[23:26:21][Step 6/6] 
[23:26:21][Step 6/6] 
[23:26:21][Step 6/6] ##teamcity[compilationFinished compiler='CleanArtifactsFolder']
[23:26:23][Step 6/6] Error while parsing TeamCity service message: Incorrect property name "[0mcompilationFinished compiler": should not contain spaces. Valid service message has a form of "##teamcity[messageName name1='escaped_value' name2='escaped_value']" where escaped_value uses substitutions: '->|', [->|[, ]->|], |->||, newline->|n
[23:26:25][Step 6/6] ##teamcity[buildNumber '1.0.0_1332']
[23:26:28][Step 6/6] Error while parsing TeamCity service message: Property value not found (no "=" character). Valid service message has a form of "##teamcity[messageName name1='escaped_value' name2='escaped_value']" where escaped_value uses substitutions: '->|', [->|[, ]->|], |->||, newline->|n
[08:35:45][Step 6/6] ##teamcity[progressMessage 'Uploading to TestFlight']
[08:35:48][Step 6/6] Error while parsing TeamCity service message: Property value not found (no "=" character). Valid service message has a form of "##teamcity[messageName name1='escaped_value' name2='escaped_value']" where escaped_value uses substitutions: '->|', [->|[, ]->|], |->||, newline->|n
[08:46:52][Step 6/6] ##teamcity[publishArtifacts './artifacts']
[08:46:52][Step 6/6] Error while parsing TeamCity service message: Property value not found (no "=" character). Valid service message has a form of "##teamcity[messageName name1='escaped_value' name2='escaped_value']" where escaped_value uses substitutions: '->|', [->|[, ]->|], |->||, newline->|n
@gep13
Copy link
Member

gep13 commented Jun 4, 2020

@patriksvensson is it possible that this is as a result of the changes for the ANSI support?

@patriksvensson
Copy link
Member

@gep13 It might be if TC use the log instead of the console. I will take a look at it.

@patriksvensson
Copy link
Member

@gep13 Yes, that seems to be the case. We will probably need to write messages like this using the console directly instead of using a logger.

@patriksvensson
Copy link
Member

@gep13 @ilnur-nazmutdinov-spark I will create a fix for this later today. Both wife and kid are sick so I will try to fix it as soon as I get some time.

@gep13
Copy link
Member

gep13 commented Jun 4, 2020

@patriksvensson that would be great, thank you, but remember, family first. If you can keep me posted, I can work on putting out a patch release once a PR is up.

@gep13 gep13 added the Bug label Jun 4, 2020
@gep13 gep13 added this to the v0.38.2 milestone Jun 4, 2020
@bjorkstromm
Copy link
Member

IIRC, we used to use console, but then facing problems with tests. #766

@patriksvensson
Copy link
Member

@gep13 Awesome. Will keep you updated.

@gep13 gep13 closed this as completed Jun 9, 2020
gep13 pushed a commit that referenced this issue Jun 9, 2020
gep13 added a commit that referenced this issue Jun 9, 2020
* hotfix/0.38.2:
  (build) Updated version and release notes.
  GH-2790: Don't write CI service messages using log
@cake-build-bot
Copy link

🎉 This issue has been resolved in version v0.38.2 🎉

The release is available on:

Your GitReleaseManager bot 📦🚀

gep13 added a commit that referenced this issue Jun 9, 2020
* hotfix/0.38.2:
  (build) Updated version and release notes.
  GH-2790: Don't write CI service messages using log
  Revert "Merge pull request #2590 from GeertvanHorrik/patch-2"
  Update confusing GitVersionVerbosity docs
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging a pull request may close this issue.

5 participants