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

Support Anki 2.1.0 #92

Open
nicolas-raoul opened this issue Oct 4, 2016 · 11 comments
Open

Support Anki 2.1.0 #92

nicolas-raoul opened this issue Oct 4, 2016 · 11 comments

Comments

@nicolas-raoul
Copy link

I am testing Anki 2.1.0, and when trying to install the Replay buttons on card add-on I get:

An error occurred in an add-on.
Please post on the add-on forum:
https://anki.tenderapp.com/discussions/add-ons

Caught exception:
  File "aqt/addons.py", line 172, in accept
  File "aqt/addons.py", line 136, in install
<class 'TypeError'>: initial_value must be str or None, not bytes

Any chance you have a 2.1.0-compatible version around? :-)
Thanks a lot!

@ospalh
Copy link
Owner

ospalh commented Oct 4, 2016

The time i tried to run Anki 2.1, it didn’t work, because i couldn’t find a pyaudiopackage.
Once i’ve got that fixed, i’ll update the add-ons.

@ospalh
Copy link
Owner

ospalh commented Oct 4, 2016

While there is a Fedora pyaudio packages, that’s for Python2, not Python3.
So, i guess i have to set up a Python virtual environment just to run Anki. Great. 😩
Edit: corrected OS package status

ospalh added a commit that referenced this issue Oct 4, 2016
This will not fix issue #92, but is needed for Anki 2.1.
@ospalh
Copy link
Owner

ospalh commented Oct 4, 2016

Looks like the downloader from Anki itself is broken and mixes up bytes that is, octet streams where non-ASCII characters are represented (as several bytes) in some encoding, and strings which operates by characters.

And at the moment i started trying to fix other peoples code. 😠 (Not directed at you.)

One unrelated problem problem is i did explicit Qt_4_ imports. I started a new branch that says “Qt_5_” in that spot.

@ospalh
Copy link
Owner

ospalh commented Oct 4, 2016

Maybe i am trying to fix other peoples code that those other people have already fixed themselves. Did you try downloading add-ons with an Anki version from after 2 August? ankitects/anki@54ea891 seems relevant, as that is about bytes vs. strings in the line you mentioned.

@nicolas-raoul
Copy link
Author

I am actually using the latest alpha, but I realize now that it is very
old: http://ankisrs.net/download/mirror/alpha/ so it does not include the
fix.
I will try to compile Anki from source.

On Tue, Oct 4, 2016 at 10:52 PM, ospalh [email protected] wrote:

Maybe i am trying to fix other peoples code that those other people have
already fixed themselves. Did you try downloading add-ons with an Anki
version from after 2 August? ankitects/anki@54ea891
ankitects/anki@54ea891
seems relevant, as that is about bytes vs. strings in the line you
mentioned.


You are receiving this because you authored the thread.
Reply to this email directly, view it on GitHub
#92 (comment),
or mute the thread
https://github.com/notifications/unsubscribe-auth/AAGFBgcyr7gjHxsg5nPGpW5Uc1EgukzLks5qwloogaJpZM4KNiFV
.

@ospalh
Copy link
Owner

ospalh commented Oct 5, 2016

Oh well.
I have some good news and some bad news.
Good news: I got Anki 2.1 to run.
Bad news: It keep crashing during start up or after a few seconds. So i can’t do any serious add-on testing.

@ospalh ospalh added this to the Python 3 milestone Dec 30, 2016
@ospalh ospalh self-assigned this Dec 30, 2016
@smls
Copy link

smls commented Jun 17, 2017

Have you tried again recently?

Anki 2.1.0a14 seems perfectly stable for me on Arch Linux.
(The build script used to install the package can be found here in the Arch User Repository. Note that all the python-* package names refer to the Python 3 versions.)

@marciomazza
Copy link
Contributor

Please remember what I did in PR #95
(branch https://github.com/ospalh/anki-addons/tree/develop-anki21)

@nataelj
Copy link

nataelj commented Sep 7, 2018

Is there still any plan to update this?

@ospalh
Copy link
Owner

ospalh commented Sep 7, 2018

See here
That’s a bit out of date.
New developments:

  • Just recently i merged a pull request and now the deck name in title add-on works, too.
  • The furikanji add-on works, too. (I think nobody but me wants that. Whatever.)
  • The colorful toolbar add-on works in a basic fashion

I don’t work hard on this. At the moment i am busy with other projects. It may be years or longer (i.e. never) until i get to the other yellow add-ons. Anki 2.1 works OK for me at the moment with the add-ons as i have ported them, so you may have more luck learning Python 3 than waiting for me to do much. There are two or three add-ons i may spent some time on. Maybe in 2019.

I haven’t added Anki vocabulary notes in years and personally have no need for the audio downloader. That, and the legal grey area and general hackish nature means that i, probably, won’t port that one any time soon.

@honmashinsei
Copy link

honmashinsei commented May 4, 2019

I would be super grateful if you could find the time to port Anki Audio Downloader to Anki 2.1. I love the 2.0 version for JapanesePod101 audio to add to my JP flashcards. Thanks.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

6 participants