forked from FooSoft/anki-connect
-
Notifications
You must be signed in to change notification settings - Fork 0
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
[pull] master from FooSoft:master #30
Open
pull
wants to merge
133
commits into
ankicommunity:master
Choose a base branch
from
FooSoft:master
base: master
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Open
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Like Edit Current, but: * has a Preview button to preview all cards for this note * has a Browse button to open the browser with these * has Previous/Back buttons to navigate the history of the dialog * has no Close button bar
The method was failing due to Anki API changes. Also, make it mandatory to call the method with `cardsToo=True`, since deleting decks on Anki >= 2.1.28 without cards is no longer supported, and the deprecated `decks.rem()` method on Anki >= 2.1.45 ignores keyword arguments.
I think this was a typo?
This method was broken and there are no issues regarding it on GitHub.
Don't start the web server if imported not from inside Anki Make sure Anki Connect instance is not garbage collected. This kills the timer that's responsible for the web server.
* make previewer use a more generic Adapter to flip through cards; * return Previewer from `show_preview()` for testing, * as well as Edit dialog from `open_dialog_and_show_note_with_id`; * disable/enable `Edit` editor buttons more reliably; * a few minor changes
So that it is importable by tests
Makes Pycharm happy
Previously, tests were run against Anki launched by user. Now, * most tests run against isolated Anki in current process; * tests in `test_server.py` launch another Anki in a separate process and run a few commands to test the server; * nearly all tests were preserved in the sense that what was being tested is tested still. A few tests in `test_graphical.py` are skipped due to a problem with the method tests, see the comments; * tests can be run: * In a single profile, using --no-tear-down-profile-after-each-test; * In a single app instance, but with the profile being torn down after each test--default; * In separate processes, using --forked.
The tests can be run now using `tox` against multiple Anki versions; see instructions in `tox.ini`. The tests depend on `pytest-anki` that had to be slightly modified to remove the upper constraint on Anki version, as well as to remove a few dependencies that are not essential to using it.
The functionality was broken, creating a dialog that was not, in fact, closing after adding a card. See the deleted comment in `test_graphical.py`
It turns out that `pytest-anki` does what we are trying to do already. Note that `empty_anki_session_started` creates a temporary user too. We are “overwriting“ it in `profile_created_and_loaded` by calling `temporary_user`. It seems that doing this is safe.
Before, pressing the Browse button would only show browser with the cards or notes corresponding to the currently edited note. Now, it shows all cards or notes from the dialog history, in reverse order (last seen on top), with the currently edited note or its cards selected.
Waitress is a WSGI server that Anki starts to serve css etc to its web views. It seems to have a race condition issue; the main loop thread is trying to `select.select` the sockets which a worker thread is closing because of a dead connection. This makes waitress skip actually closing the sockets.
* requestPermission: change Ignore button to checkbox * Update requestPermission documentation - describe the possible results - document ignoreOriginList
* require Python 3.10 * prevent Anki from doing backups, again * restore cwd that deck exporter changes for some wild reason
* Import things from `aqt.qt` not `PyQt5`/`PyQt6` * When testing with Qt6, disable Anki's Qt5 compatibility mode * Depend on `pytest-anki` that is also Qt version agnostic
Also add a few tests for the buttons to make sure that they get actually added and enabled/disabled.
Consolidate Anki version checks across files
Environmental variables set in `setenv` also affect pip invocations. `HOME` determines where pip is placing its cache. Setting HOME to anything virtual env-specific means that every virtual environment is created with its own cache. This wastes time, data and disk space.
Something in Anki is setting stdout to Null. This is a problem because Anki itself is writing to it, particularly when printing warnings about the deprecated methods that we are using. This patches Anki using the same method that the upcoming Anki 2.1.51 is using.
Fix tests and some of the code to work with Anki 2.1.50
… modelTemplateRemove
Added various actions relating to model templates
add `guiUndo` action for undo review
add new action: answerCards
Updated Python example code to use 127.0.0.1 instead of localhost
Correct JSON MIME type (Fixes #393)
Add a method to bring up Import File dialog
The README previously sort of covered this, but in particular it was not obvious to me that the request parameter that corresponded to enabling `apiKey` is called `key`, and not `apiKey`, which ultimately made me have to look at the source code to figure this out (even though the word `key` is mentioned elsewhere on the page, it still wasn't very easy to make the connection). This section puts all the required information in one spot.
Make it slightly clearer how to enable authentication.
add link to Anki docs in overview
Update README.md
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
See Commits and Changes for more details.
Created by
pull[bot] (v2.0.0-alpha.1)
Can you help keep this open source service alive? 💖 Please sponsor : )