cblanken
a611f4a7e7
Fixup board_randomizer typehints
...
Invalid `list[str]` type hints were causing errors in the downstream Boggler Flask app
2024-06-14 10:31:17 -04:00
cblanken and GitHub
e183ce07c0
Update README.md
2024-04-13 10:19:20 -04:00
cblanken and GitHub
09e6f4a672
Update README.md
...
- Fix bad link to wordlists
- Add license link
2024-02-14 22:49:13 -05:00
cblanken
9036848168
Add collapsible sections to README usage section
2023-08-22 19:06:17 -04:00
cblanken
a78b277516
Update CLI usage and output in README
2023-08-22 18:57:12 -04:00
cblanken
a2630ed82e
Initial blacken reformat
2023-08-22 16:56:59 -04:00
cblanken
ab2869b858
Ignore board files for blacken pre-commit
2023-08-22 16:56:18 -04:00
cblanken
d282cd3676
Install pre-commit and default blacken format hook
2023-08-22 16:53:38 -04:00
cblanken
995a7f42c1
Update build instructions
2023-08-21 18:45:31 -04:00
cblanken
b4d7237c1f
Add rich table output to default output
2023-06-02 22:56:24 -04:00
cblanken
3b79ca7519
Update solved 4x4 board tests - check paths
...
- 4x4 board solving tests now checks for the original order of the words as well as the
exact path for each
2023-05-31 18:08:05 -04:00
cblanken
9e2cd55741
Add function docstrings for board tests
2023-05-31 18:07:40 -04:00
cblanken
c0fe222832
Add tests for parsing board input files
2023-05-30 19:35:23 -04:00
cblanken
6771ec9205
Add mypy fix some typing errors
2023-05-29 21:25:38 -04:00
cblanken
e1981c44de
Use pathlib to handle paths instead of os.path
...
- Replaces all instances of os.path objects with pathlib.Path
2023-05-26 11:50:30 -04:00
cblanken
02bb7c4262
Replace log format strings with lazy formatting
...
- Pylint recommends to use lazy formatting (%s) for logging functions
2023-05-26 11:27:47 -04:00
cblanken
da00afb395
Add JSON output option
2023-05-26 11:27:47 -04:00
cblanken
afaa378131
Add clean text output option
...
- Output valid words for the provided board in a normal text format, one word per line
- Select between just word output and word+path output for easier post-processing
- Also includes sort and de-duplication options
2023-05-26 11:26:06 -04:00
cblanken
daebee948a
Add pylint to dev depencies
2023-05-24 22:18:50 -04:00
cblanken
2bc9d9fb9e
Add argument parsing to main module
2023-05-24 19:20:30 -04:00
cblanken
7500720992
Refactor 4x4 board test to use pytest fixtures
...
- Update missing symoblic link to boggler src files to access wordlists
2023-05-24 17:37:51 -04:00
cblanken
d81f5e28cc
Replace unittest with pytest
...
- Pytest requires test modules to start with the "test_" prefix. The new
test_solve_4x4_board.py module replaces the functional_tests.py module
2023-05-24 16:18:40 -04:00
cblanken
a0d60d280c
Add poetry script to run main boggler script
...
- Also correct import for boggler_utils to be relative in __main__.py so it can be run
as module with `python -m boggler`
2023-05-24 12:15:18 -04:00
cblanken
ac58828521
Move source files for consistency with Poetry
...
- By default Poetry build packages into "./packagename/packagename" instead of
"./packagename/src/packagename", this commit reflects that structure even though
poetry _could_ build normally from the original structure
2023-05-24 12:10:32 -04:00
cblanken
59c5beb491
Update project config to use poetry
2023-05-24 11:00:52 -04:00
cblanken
49cf552cc1
Merge branch 'main' into dev
2023-04-24 20:47:41 -04:00
cblanken
f0cee00bef
Update README.md
2023-04-24 19:25:18 -04:00
cblanken and GitHub
843e167bf4
Update README.md
2023-03-30 19:08:47 -04:00
cblanken
1a1f5acb17
Fix memory warnings/errors/leaks per valgrind
2023-03-30 12:06:13 -04:00
cblanken
2f795be626
Add debug information to compilation flags
2023-03-30 12:05:23 -04:00
cblanken
6f4d4a69a0
Add WordTree data structure and helper functions
2023-03-28 19:05:08 -04:00
cblanken
82991e96e7
Add BoardCell struct
2023-03-27 16:32:11 -04:00
cblanken
1386e1cace
Add Makefile
2023-03-24 18:27:44 -04:00
cblanken
8c9ed00826
Initial C implementation commit with Board struct
2023-03-24 18:25:56 -04:00
cblanken
c09dce4bd6
Add basic solved board tests
2023-03-23 14:19:28 -04:00
cblanken
a37548a4ee
Merge branch 'main' into dev
2023-03-23 12:46:02 -04:00
cblanken
1dc118e953
Fix boggle tree missing multi-letter nodes
...
The BoggleTree object when inserting nodes did not properly check for nodes
with values of more than 1 letter. Therefore, any words with "qu" after the
root would not be included in the solved board. As of now, only nodes with
a maximum of 2 letters are accounted for, 3+ letter nodes won't be checked.
2023-03-23 12:42:40 -04:00
cblanken
6d3a58595c
Replace print(s) with logging functions
2023-03-22 16:25:37 -04:00
cblanken
8b9dc89420
Update README with build instructions
2023-03-13 21:53:03 -04:00
cblanken
a80111072f
Bump release version
v2.0.1
2022-12-30 20:55:44 -05:00
cblanken
fa01d442a5
Fix bug in board randomizer
...
- The board randomizer did not account for dice files that don't contain an exact integer squared number of dice. For example the 5x5 dice file contains 26 possible dice since 1 extra die is provided.
- The fix takes the square root of the number of dice and takes the floor of that number as the total number of dice to choose.
2022-12-30 19:54:00 -05:00
cblanken
733c1474b0
Add 5x5 dice file
2022-12-30 19:51:41 -05:00
cblanken
54f79c0afe
Remove dead code from boggler.py
2022-11-16 20:37:30 -05:00
cblanken
9f364ee90e
Remove old dictionary word prefix lists
2022-11-16 20:36:55 -05:00
cblanken
e219954ba6
Add function to flatten boggle board results into 1D list
2022-10-10 12:00:42 -04:00
cblanken
f4accfe959
Update wordlist splitting script
...
- use ripgrep to exclude proper nouns (with capitals) output only the
capture group
2022-09-28 13:01:39 -04:00
cblanken
bc70b88bf7
Bump version 2.0.0
v2.0.0
2022-09-26 11:44:51 -04:00
cblanken
21aab46b96
Refactor board_randomizer
...
- Make file read separate and return "dice" or a list of strings from
dice handling functions for use in downstream programs
2022-09-26 11:40:36 -04:00
cblanken
f18c30cb60
Rename Super Big Boggle dice file
2022-09-23 10:20:48 -04:00
cblanken
da915b723c
Update wordlist splitting script
...
- Force lowercase on split
- Only match single (non compound) words
- Don't match punctuation
- Sort and uniquify
2022-09-23 10:20:48 -04:00