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

PyAutoGUI controller #21

Merged
merged 20 commits into from
Oct 23, 2020
Merged

Conversation

pevogam
Copy link
Member

@pevogam pevogam commented Oct 2, 2020

Add PyAutoGUI screen controller refactoring current controller state

@pevogam pevogam mentioned this pull request Oct 2, 2020
@lgtm-com
Copy link

lgtm-com bot commented Oct 2, 2020

This pull request introduces 1 alert when merging 8a98505 into 4090679 - view on LGTM.com

new alerts:

  • 1 for 'import *' may pollute namespace

@codecov
Copy link

codecov bot commented Oct 2, 2020

Codecov Report

Merging #21 into master will increase coverage by 5.03%.
The diff coverage is 91.51%.

Impacted file tree graph

@@            Coverage Diff             @@
##           master      #21      +/-   ##
==========================================
+ Coverage   80.21%   85.25%   +5.03%     
==========================================
  Files          16       17       +1     
  Lines        4387     4400      +13     
==========================================
+ Hits         3519     3751     +232     
+ Misses        868      649     -219     
Impacted Files Coverage Δ
guibot/desktopcontrol.py 0.00% <0.00%> (-61.73%) ⬇️
guibot/guibot.py 0.00% <ø> (ø)
guibot/guibot_proxy.py 0.00% <0.00%> (ø)
guibot/guibot_simple.py 0.00% <0.00%> (ø)
guibot/region.py 83.43% <60.00%> (+0.16%) ⬆️
guibot/config.py 81.77% <71.42%> (ø)
guibot/controller.py 93.98% <93.98%> (ø)
guibot/finder.py 88.95% <100.00%> (-0.29%) ⬇️
guibot/inputmap.py 98.41% <100.00%> (+18.09%) ⬆️
guibot/match.py 91.89% <100.00%> (ø)
... and 4 more

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update dd17e65...908ff41. Read the comment docs.

@pevogam pevogam changed the title Pyautogui controller PyAutoGUI controller Oct 2, 2020
@pevogam pevogam force-pushed the pyautogui-controller branch from 8a98505 to 932d057 Compare October 20, 2020 12:03
@lgtm-com
Copy link

lgtm-com bot commented Oct 20, 2020

This pull request introduces 1 alert when merging 932d057 into dd17e65 - view on LGTM.com

new alerts:

  • 1 for 'import *' may pollute namespace

@pevogam pevogam force-pushed the pyautogui-controller branch 14 times, most recently from 65bd61e to 41b56f1 Compare October 22, 2020 13:41
This includes dropping the platform-specific "desktop" in favor of
the more platform-generic "display" for the DC backends as we could
technically manipulate Android or other devices.
The controllers hierarchy taxonomy is now more readable and clearer,
also in better accordance with the finder class hierarchy.
This requires also adding the necessary input (key, modifier, and
mouse button) maps for the backend, in this case keyword strings.
The region tests that were the only ones doing this before only
tested the default backend thus leaving a big gap in covering the
alternatives that we compensate for here.
The default number of clicks should be one corresponding to a
single click and writing unit tests for all backends revealed it
wasn't so for some backends until now.
@pevogam pevogam force-pushed the pyautogui-controller branch from 41b56f1 to b87396d Compare October 22, 2020 17:17
This and the lack fo setting the base attribute was all discovered
from the new unit tests.
Some methods with modifier args used a default None while others
were still requiring the argument to be explicitly set, even if
again to None.
It is simpler to just require a NOOP sync instead of requiring it
for some backends and not for others, thus confusing the users and
requiring them to know internal behaviors.
The following subbranch completes the unit test coverage undertaking
from all recent branches by adding a final set of base unit tests for
the display controllers.
An issue has been reported as the scrot support on Fedora is
significantly lacking.
These coordinates are using during mouse initialization and are
currently considered eligible.
This controller contains additional dependencies we haven't fully
handled, hasn't been thoroughly tested, and is even unfinished,
but contains valuable code that could be an example for how to
derive a custom controller backend.
@pevogam pevogam force-pushed the pyautogui-controller branch from b87396d to 908ff41 Compare October 23, 2020 09:16
@pevogam pevogam merged commit 45349b9 into intra2net:master Oct 23, 2020
@pevogam pevogam deleted the pyautogui-controller branch October 23, 2020 11:48
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

Successfully merging this pull request may close these issues.

1 participant