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

Trim extra non-ascii characters that can arise from manually editing … #463

Merged
merged 3 commits into from
Oct 27, 2023

Conversation

adam-talos
Copy link
Contributor

@adam-talos adam-talos commented Sep 30, 2021

…sequence number files.

When we run into sequence. number issues and want to fix the issue on the server, if you edit the sequence number files with something like vi, it may add a newline or carriage return even if you don't mean to and QuickFIX will not honor the sequence number.

This fix trims the extra junk off the end so that QuickFIX can read the new value without needing to do a "truncate -s -1" or similar hackery.

links to issue #464

@adam-talos
Copy link
Contributor Author

The CI failure looks unrelated to the change. The build timed out doing a lint check.

@ackleymi ackleymi force-pushed the TrimNumbersFromSequenceStore branch from 44584a9 to 0d3cdca Compare May 8, 2023 02:30
@ackleymi ackleymi force-pushed the TrimNumbersFromSequenceStore branch from 0d3cdca to 4883356 Compare May 8, 2023 04:16
@ackleymi
Copy link
Member

On a re-run it does kick out

filestore.go:225: File is not gofmt-ed with -s (gofmt)
if targetSeqNum, err := strconv.Atoi(strings.Trim(string(targetSeqNumBytes),"\r\n")); err == nil {

Give that a quick fix and I will merge!

@ackleymi
Copy link
Member

@adam-talos thanks 👍

@ackleymi ackleymi merged commit 2feb378 into quickfixgo:main Oct 27, 2023
12 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants