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

add window_specification module and move WindowSpecification definition to that #1326

Open
wants to merge 6 commits into
base: atspi
Choose a base branch
from

Conversation

junkmd
Copy link
Contributor

@junkmd junkmd commented Aug 28, 2023

The WindowSpecification is referred from both Application and Desktop, but it was defined in the base_application module.
Thus, the Desktop needs to import the WindowSpecification from base_application module. It makes an undesirable dependency.

Additionally, WindowSpecification is a concrete class, and defining it in a module named base_... feels somewhat out of place.

I moved the definition of WindowSpecification to a module named window_specification, similar to how BackEnd in the backend module.

@codecov
Copy link

codecov bot commented Aug 28, 2023

Codecov Report

Merging #1326 (4a52153) into atspi (bf7f789) will decrease coverage by 6.30%.
The diff coverage is 93.69%.

Additional details and impacted files
@@            Coverage Diff             @@
##            atspi    #1326      +/-   ##
==========================================
- Coverage   94.15%   87.86%   -6.30%     
==========================================
  Files          60       61       +1     
  Lines       23036    23040       +4     
==========================================
- Hits        21689    20243    -1446     
- Misses       1347     2797    +1450     

@junkmd junkmd closed this Sep 12, 2023
@junkmd junkmd reopened this Sep 12, 2023
@@ -162,7 +162,7 @@

Current wrapper object is used as a parent while searching in the subtree.
"""
from .base_application import WindowSpecification
from .window_specification import WindowSpecification

Check notice

Code scanning / CodeQL

Cyclic import Note

Import of module
pywinauto.window_specification
begins an import cycle.

from . import controls
from . import findbestmatch
from . import findwindows

Check notice

Code scanning / CodeQL

Cyclic import Note

Import of module
pywinauto.findwindows
begins an import cycle.
from . import findbestmatch
from . import findwindows

from . import backend as backends

Check notice

Code scanning / CodeQL

Cyclic import Note

Import of module
pywinauto.backend
begins an import cycle.
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.

None yet

1 participant