64bit / async-openai

Rust library for OpenAI
https://docs.rs/async-openai
MIT License
1.11k stars 166 forks source link

Fix new lines issue from contribution from multiple operating systems #259

Open 64bit opened 2 weeks ago

64bit commented 2 weeks ago

The line endings have changed from ~LF to CRLF~ CRLF to LF. git diff -R will show the change.

It looks like there's some inconsistency on that front, might be worth a separate issue/PR to cleanup:

eric@io ~/src/code/rust/async-openai/async-openai/src/types (response_format_json_schema)> file *
assistant.rs:        ASCII text, with very long lines (502)
assistant_file.rs:   ASCII text
assistant_impls.rs:  ASCII text
assistant_stream.rs: ASCII text
audio.rs:            ASCII text, with very long lines (353), with CRLF line terminators
batch.rs:            ASCII text
chat.rs:             ASCII text, with very long lines (506)
common.rs:           ASCII text, with CRLF line terminators
completion.rs:       Unicode text, UTF-8 text, with very long lines (569), with CRLF line terminators
embedding.rs:        ASCII text, with very long lines (460), with CRLF line terminators
file.rs:             ASCII text, with very long lines (388)
fine_tuning.rs:      ASCII text, with CRLF line terminators
image.rs:            ASCII text, with CRLF line terminators
impls.rs:            ASCII text
message.rs:          ASCII text
message_file.rs:     ASCII text
mod.rs:              ASCII text
model.rs:            ASCII text, with CRLF line terminators
moderation.rs:       ASCII text, with very long lines (344), with CRLF line terminators
run.rs:              ASCII text, with very long lines (358)
step.rs:             ASCII text
thread.rs:           ASCII text, with very long lines (358)
vector_store.rs:     ASCII text

Originally posted by @nytopop in https://github.com/64bit/async-openai/issues/255#issuecomment-2285288054