prisma-client-py icon indicating copy to clipboard operation
prisma-client-py copied to clipboard

fix(generator): write using utf-8

Open AmaseCocoa opened this issue 1 year ago • 2 comments

Change Summary

Changed to explicitly use utf-8 in packaged_schema.write_text to avoid UnicodeEncodeError that cp932 may cause in Japanese Windows environment.

Unit Test is currently under construction :)

Checklist

  • [ ] Unit tests for the changes exist
  • [ ] Tests pass without significant drop in coverage
  • [ ] Documentation reflects changes where applicable
  • [ ] Test snapshots have been updated if applicable

Agreement

By submitting this pull request, I confirm that you can use, modify, copy and redistribute this contribution, under the terms of your choice.

AmaseCocoa avatar Aug 10 '24 10:08 AmaseCocoa

~~For some reason it seems to contain commit for pull request #1002 :(~~ I forgot that I committed to main by mistake, it seems it has already been Revert.

AmaseCocoa avatar Aug 10 '24 10:08 AmaseCocoa

@RobertCraigie Sorry, is there already a test related to prisma.generator.Generate?

AmaseCocoa avatar Sep 24 '24 09:09 AmaseCocoa