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

Bugfix for term.split_seqs('term.right(3)') #197 #199

Merged
merged 7 commits into from
Jun 10, 2021
Merged

Conversation

jquast
Copy link
Owner

@jquast jquast commented Mar 6, 2021

In version 1.18.0 and earlier,

   >> term.split_seqs(term.move_right(333) + 'xyz', maxsplit=1)
   ['\x1b[333C', '333', 'xyz']

This is a bug (#197) it duplicates the matched parameter, this is now corrected:

   ['\x1b[3C', 'xyz']

Also,

In version 1.18.0 and earlier,

>> term.split_seqs(term.move_right(333) + 'xyz', maxsplit=1)
['\x1b[333C', '333', 'xyz']

This is a bug, it duplicates the matched parameter, this is
now corrected:

['\x1b[3C', 'xyz']

Previously, we documented "same arguments as "re.split", so
we must also implement maxsplit and flags.

Also,
- fix flake8 linting of tests by moving fixtures to conftest.py,
  fixes "unused" or "re-definition from import" errors.
- version stamp blessed/__init__.py like a codegen step i guess
- remove run_codecov.py, its been fixed upstream
  codecov/codecov-python#158 (comment)
@jquast jquast requested review from haliphax and avylove March 6, 2021 16:56
.travis.yml Show resolved Hide resolved
blessed/terminal.py Outdated Show resolved Hide resolved
tox.ini Show resolved Hide resolved
@@ -0,0 +1,24 @@
#!/usr/bin/env python3
Copy link
Collaborator

@avylove avylove Mar 6, 2021

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Probably better than maintaining it in two places, but what is version.json used for? I typically set __version__ in __init__.py and parse it in setup.py.

Copy link
Owner Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@codecov
Copy link

codecov bot commented Mar 6, 2021

Codecov Report

Merging #199 (19171d5) into master (b6025ec) will decrease coverage by 0.06%.
The diff coverage is 90.90%.

Impacted file tree graph

@@            Coverage Diff             @@
##           master     #199      +/-   ##
==========================================
- Coverage   95.68%   95.61%   -0.07%     
==========================================
  Files           9        9              
  Lines         996     1004       +8     
  Branches      160      163       +3     
==========================================
+ Hits          953      960       +7     
  Misses         40       40              
- Partials        3        4       +1     
Impacted Files Coverage Δ
blessed/_capabilities.py 100.00% <ø> (ø)
blessed/terminal.py 98.67% <90.00%> (-0.21%) ⬇️
blessed/__init__.py 77.77% <100.00%> (ø)

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 b6025ec...19171d5. Read the comment docs.

@avylove
Copy link
Collaborator

avylove commented Mar 7, 2021

I guess this needs to be updated too
https://github.com/jquast/blessed/blob/master/blessed/terminal.pyi#L91

@haliphax
Copy link
Collaborator

haliphax commented Mar 7, 2021

Going to pull this down and give it a shot this evening. Thanks! 🤘

Copy link
Collaborator

@haliphax haliphax left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Confirmed!

@avylove
Copy link
Collaborator

avylove commented Mar 14, 2021

@avylove avylove merged commit 2d75fdc into master Jun 10, 2021
@avylove avylove deleted the supersplit branch June 10, 2021 12:24
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.

3 participants