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

F.write #2

Open
QGB opened this issue Mar 10, 2019 · 0 comments
Open

F.write #2

QGB opened this issue Mar 10, 2019 · 0 comments

Comments

@QGB
Copy link
Owner

QGB commented Mar 10, 2019

b:\qgb\babun\cygwin\bin\qgb\f.py(372)write()
-> f=py.open(file,mod,encoding=encoding)
(Pdb) mod
'w'
(Pdb) !f=py.open(file,mod,encoding=encoding)
*** FileNotFoundError: [Errno 2] No such file or directory: 'g:/test/gt'
这是因为没有 test 文件夹
(Pdb) !f=py.open('g:/test/',mod,encoding=encoding)
*** OSError: [Errno 22] Invalid argument: 'g:/test/'
(Pdb) !f=py.open('g:/test',mod,encoding=encoding)
(Pdb) !f
<_io.TextIOWrapper name='g:/test' mode='w' encoding='utf-8'>
(Pdb) !f.close
<built-in method close of _io.TextIOWrapper object at 0x000001CC2C293480>
(Pdb)

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

No branches or pull requests

1 participant