Closed RyanG2016 closed 9 months ago
Hi @RyanG2016,
Have you tried the --human-readable
flag to put it in a nicer format? How does that output look for you?
@Deadpikle That makes it in a much nicer output for sure however if I use that flag, the application cannot read it. It reports Appcast is not valid. Is that expected?
Again if so, that's fine. I can just do a visual check and leave it. Just for confirmation I created one with --human-readable and one without. The one without works fine.
Ah...if the software cannot read one that is setup to be human readable, that would be a bug, as the software should be able to parse the app cast regardless. Will try to look into it today unless someone else beats me to it. Sorry about that and thanks for reporting!
@RyanG2016 I have tried to replicate your error and have been unable to, both from a unit test standpoint (https://github.com/NetSparkleUpdater/NetSparkle/blob/2a1ff4916e44670a5d15dc8d5c04217998bd49dd/src/NetSparkle.Tests.AppCastGenerator/AppCastMakerTests.cs#L636-L707) and a smoke test using one of the samples and an app cast I uploaded to one of my sites for a test.
Can you please post the debug console output that happens when you try to use the human readable one? Were you sure to upload your .signature
file to your host as well for any verification that was needed? Does it work with SignatureMode.Unsafe
but doesn't work with another SignatureMode
?
@Deadpikle I set the appcast to generate in human readable and set signaturemode to unsafe and it was able to check but when I reenabled signaturemode to strict. It failed. I regenerated appcast without human readable and it passed with both strict and unsafe. Does that help at all?
So, yeah, a human readable (formatted) app cast and a non-human readable (un-formatted) app cast have different signatures. I'm guessing the .signature
file for your app cast on your server was put up there for your unformatted app cast. When you generate an app cast that is human readable, you need to upload the new/different .signature
file to your server and overwrite the old one. The fact that SignatureMode.Unsafe
fails tells you that the issue is with the cryptographic signature.
tl;dr: Upload both the human readable app cast XML doc AND .signature
file to your server.
@RyanG2016 Have you been able to resolve the problem you had here?
@RyanG2016 I'm going to go ahead and close this issue because it seems to be an issue with not uploading the updated .signature
file and not necessarily a bug with this lib (and/or it's resolved per your lack of response). If this is not the case, please comment again or whatnot to continue discussions. :-) Thanks. Again, I appreciate your feedback and reporting the issue.
@Deadpikle Sorry for delay. The project to implement netsparkle was shelved for a while. The issue has to do with multiline .md files. I was looking through #466 which is identical to my issue and I just can't get this to work with a multiline .md file. Single line, no problems. I've tried everything I can think of. Here is the command that I'm using;
netsparkle-generate-appcast -n "My Product" -a "C:\Users\me\Desktop\Output" -e exe -b "C:\Users\me\Desktop\Output" -o windows -p "C:\Users\me\Desktop\Output" --critical-versions "1.5.12" --reparse-existing
My .md file is;
- Added: Sparkle Testing
- Another Line
- This is a multiline format test
The appcast.xml output is; (Image from notepad++ showing line breaks
This is the output from the client;
netsparkle: Downloading and checking appcast
netsparkle: About to start downloading the app cast...
netsparkle: Downloading app cast data...
netsparkle: Downloading app cast signature data...
netsparkle: Signature check of appcast failed
netsparkle: Appcast is not valid
netsparkle: No version information in app cast found
Any suggestions would be super appreciated
@Deadpikle Sorry that screenshot isn't correct. That was formatted for readability. Here is the raw file;
The only CRLF are from the .md file.
🤔 Interesting. It sounds like the signature generating functionality is not reading in the right data for creating the signature or something because it should just be generating the signature based on the output data...? Not sure here...hmm...
You have verified that the file on disk (when you generate the appcast) is the exact same as the file you upload to your server, right? And that the .signature
file is up on your server?
Needs investigation/fixing.
@Deadpikle You know one thing I didn't check if the actual transfer. I am using FileZilla to transfer local files to remove. Maybe there something happening there. I will check that now. Thx
@Deadpikle You were right and I'm sorry I didn't even think of checking this. File transfer type was set to auto. I changed to Binary and that fixed it..... Thanks for the reply. This can be closed.
No problem. :) Thanks for letting future people know what helped to fix the issue! Glad you got it working.
I have Netsparkle up and running in my Avalonia project but I am having an issue with the appcast format. I use Sparkle for macOS for another project and Sparkle generates a well formed XML that I can open and tweak as necessary and it works fine. When I open an appcast created by netsparkle-generate-appcast, the file isn't formatted and is all squished together. I can use something like XML Tools and prettify it and it looks fine but if I save it, the application can't read the file and I get an error saying can't read version. Maybe this is a non issue and I shouldn't be manually updating the appcast.xml file and letting the netsparkle-generate-appcast do all of the work and if that's the case then fine. I just don't want to get in a position where there is actually a problem with the appcast file that will cause issues.
Here is an example of an appcast generated from netsparke-generate-appcast;
Command:
Raw output:
If I prettify it to look formatted as I expect it;
and if I save this, even without making any changes, the update checking fails.
All of the documentation that refers to appcast for Netsparkle show well formed xml files. I know it shouldn't matter but I am running this from PowerShell and tried running from a command prompt just to make sure.