Re: Dropping ibus-pinyin (or salvaging libpyzy)?

Boyuan Yang <[email protected]>
Newsgroups gmane.linux.debian.user.chinese.big5,gmane.linux.debian.user.chinese.gb
Organization Debian Project
Message-ID <[email protected]>
Hi,

在 2020-05-03星期日的 00:13 +0200,Gunnar Hjalmarsson写道:
> On 2020-04-29 08:37, Kentaro Hayashi wrote:
> > FYI: I may be wrong because I didn't know well, but It seems that
> > someone tried to port libpyzy scripts to python3.
> > 
> > https://github.com/pyzy/pyzy/pull/4
> 
> You are not wrong at all; the work has already been done, apparently.
> 
> I tested it successfully and committed it as a patch to our repo.
> 
> https://salsa.debian.org/input-method-team/libpyzy/-/commit/40dc6196
> 
> So it looks like ibus-pinyin can stay in the archive for now. :)

The package may not FTBFS, but the python script did not run successfully.
There are trackbacks like this:

make[5]: Entering directory '/<<PKGBUILDDIR>>/data/db/android'
\
rm -f android.db; \
./create_db.py ./rawdict_utf16_65105_freq.txt | /usr/bin/sqlite3 android.db ||
\
	( rm -f android.db ; exit 1 )
Traceback (most recent call last):
  File "./create_db.py", line 83, in <module>
    main()
  File "./create_db.py", line 80, in main
    create_db(sys.argv[1])
  File "./create_db.py", line 51, in create_db
    records = list(read_phrases(filename))
  File "./create_db.py", line 19, in read_phrases
    buf = file(filename).read()
NameError: name 'file' is not defined

I continued with more patching work to fix this certain issue 
https://salsa.debian.org/input-method-team/libpyzy/-/commit/736051f06ecb41aada4448f6b89413d5b18bfb46
but that is not quite complete; it's still raising exceptions elsewhere. I'd
expect more help from others on making this script runnable.

-- 
Thanks,
Boyuan Yang
signature.asc (application/pgp-signature, 833 B)
-----BEGIN PGP SIGNATURE-----

iQIzBAABCgAdFiEEfncpR22H1vEdkazLwpPntGGCWs4FAl6uIoAACgkQwpPntGGC
Ws7eRA/9EPOdOjLHr8LihBjFZCXUlDpxifjVMuQ1fR3W0pNo3iI0GjdQAZuL3Ldg
+6OVFeDEDeIvvsAkSDli3u8CA1SVLtC9BSzXxW7KMfpBatBSAFhNm0UpLlwBk/OL
67u1fIYHUKJixv2sN+eDW0AfjizmPFwPAB9sNXK9aFUCQ6DR85idjFZ2RMAmIOPs
1Y8+691VCrUBdS9ro0mI7dyljj68GJ0tvlKEYxbMiQKpPOeYQcq48ZnW0/6aqZFK
NLDoFfGHZO0v8myHe7WIEyZoxY2O5lvBIhPCRFO6L6Chx+hTDg+XXeYFVHJZj33M
TRgVo43W4HIKEtMRLvA6Rsps4um7PgGuaOyDrpQZu/5oj/YXnxLnBKB/qZNT0Ft7
DzhL1SBlDInjAfHJGtzHVnZif++smGfAoFlhs5ISDCO8shrTg3xBUDr+dlqdvT9+
ZggG6s6S4rKaHNoB4+DJYOJr5tiZVwwAv6+NT3FyKiVjjDjcFf8jUgOEXIPrVKlM
bxRlpl+8mP/0biTwlTE4+0putJ//AbZQ1FosQCaFVLpTKO5AD6XF0+aIoig/9XF/
67l87AMvMjNQDjOoPPDNwTtJA5lAmpXuRAfg07K+Jzv2rm4ngtsDPzcHhpCC3ao8
CmeQtJ7LwcQhdq8WpnMaSmsb1Gy/BKCP6ovg1nleNS/m1iPUI9A=
=9cWZ
-----END PGP SIGNATURE-----
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.