Skip to content

Commit

Permalink
Refactor to pass linting, coverage and type checks.
Browse files Browse the repository at this point in the history
  • Loading branch information
namcsi committed Jul 16, 2023
1 parent 8b25a0e commit d6c3bd5
Show file tree
Hide file tree
Showing 11 changed files with 367 additions and 139 deletions.
1 change: 1 addition & 0 deletions .pylintrc
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,7 @@ ignore-signatures=yes
argument-rgx=^[a-z][a-z0-9]*((_[a-z0-9]+)*_?)?$
variable-rgx=^[a-z][a-z0-9]*((_[a-z0-9]+)*_?)?$
class-naming-style=any
class-const-naming-style=PascalCase

# Good variable names which should always be accepted, separated by a comma.
good-names=_,M,N,B,A,Nn,Bn,An
4 changes: 2 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -10,8 +10,8 @@ applications where reasoning about ASP programs is required.

Reflection is the reverse operation of reification, i.e. transforming
a set of facts encoding an asp program into it's string
representation. This operation can be used to derive new programs
which may then e.g. be passed along to an ASP solver.
representation. This operation can be used to derive new program
strings which may then e.g. be passed along to an ASP solver.

An application `renopro` implements which makes use of both
reification and reflection is syntactic transformation of input
Expand Down
1 change: 1 addition & 0 deletions setup.cfg
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,7 @@ install_requires =
clingo
clorm
thefuzz
python-Levenshtein

[options.packages.find]
where = src
Expand Down
24 changes: 18 additions & 6 deletions src/renopro/__main__.py
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
"""
The main entry point for the application.
"""

from .utils.logger import setup_logger
from .utils.parser import get_parser

Expand All @@ -12,12 +11,25 @@ def main():
"""
parser = get_parser()
args = parser.parse_args()
log = setup_logger("main", args.log)
setup_logger("main", args.log)
# rast = ReifiedAST()
# if args.reify:
# if args.files:
# rast.reify_files(args.files)
# if args.string:
# rast.reify_string(args.string)
# print(rast.reified_string_doc)

# elif args.reflect:
# if args.files:
# rast.add_reified_files(args.files)
# if args.string:
# rast.add_reified_string(args.string)
# rast.reflect()
# print(rast.program_string)

log.info("info")
log.warning("warning")
log.debug("debug")
log.error("error")
# elif args.transform:
# pass


if __name__ == "__main__":
Expand Down
Loading

0 comments on commit d6c3bd5

Please sign in to comment.