tconbeer / harlequin

The SQL IDE for Your Terminal.
https://harlequin.sh
MIT License
3.55k stars 77 forks source link

Add number separators to query history results #437

Closed tconbeer closed 7 months ago

tconbeer commented 7 months ago

image

just a tweak to the f-string here: https://github.com/tconbeer/harlequin/blob/a78944fafca3c52498b053c473f83f6a1a663d1b/src/harlequin/history.py#L26

code-master-ajay commented 7 months ago

@tconbeer can i take this up ?

tconbeer commented 7 months ago

Yes please!!

tconbeer commented 7 months ago

Some help here, but you may get stuck on the snapshot tests, which is totally fine. If I have time I'll try to record a short video on how to update those.

https://harlequin.sh/docs/contributing/index

tconbeer commented 7 months ago

@code-master-ajay Walkthrough video has been added to that page in the docs, including a walkthrough of the process for updating snapshot tests, which I think you'll have to do after you make this change. (lmk if you get stuck, though)

code-master-ajay commented 7 months ago

Thanks a lot @tconbeer will do this asap.

code-master-ajay commented 7 months ago

Hi @tconbeer , i followed your Walkthrough video, but when i run the make command i get this error in mypy section

=================================================== 148 passed, 3 deselected in 108.40s (0:01:48) ====================================================
mypy
src/harlequin/plugins.py:9:1: error: Cannot find implementation or library stub for module named "importlib_metadata"  [import-not-found]
src/harlequin/plugins.py:9:1: note: See https://mypy.readthedocs.io/en/stable/running_mypy.html#missing-imports
src/harlequin/cli.py:24:1: error: Cannot find implementation or library stub for module named "importlib_metadata"  [import-not-found]
tests/conftest.py:15:1: error: Cannot find implementation or library stub for module named "importlib_metadata"  [import-not-found]
tests/conftest.py:77: error: Unused "type: ignore" comment  [unused-ignore]
tests/conftest.py:84: error: Unused "type: ignore" comment  [unused-ignore]
tests/conftest.py:91: error: Unused "type: ignore" comment  [unused-ignore]
Found 6 errors in 3 files (checked 63 source files)
make: *** [Makefile:6: check] Error 1

I tried running :

poetry add importlib_metadata

But it is already present in the toml file, can you help me out here

OS: Ubuntu 22 python : 3.10

Upon further investigation i think the stub for " importlib_metadata " is not present, not sure if this is the reason.

tconbeer commented 7 months ago

re: mypy, this happens because there is a setting to tell mypy to lint for Python 3.8, but you're running Python 3.10; importlib_metadata is a backport that is only installed on older pythons, so mypy expects it (since it's linting against 3.8), but can't find it.