Home / GitHub Page

Week 7,8: Project Search Engine

I refactored the search implementation PR. It’s almost ready to be merged.

Doings some manual testing on the CliClient uncovered a problem. It turns out we can’t begin the search query with a ‘-’ in the CliClient. So queries like -tag:tag1 won’t work.

Searching using :search "-tag:tag1" will cause the error
Missing required argument: pattern

I’m finding to hard to fix the issue since I can’t figure out how to attach a debugger to the process. Any suggestions?

I also made a PR for the new ranking function, Okapi BM25.

You can use reg.logger().info(...) to log to log.txt in the profile directory. It seems you’ll need to check cliUtils.makeCommandArgs and perhaps handle parsing differently so that text inside quotes is not treated as a command line flag.

Maybe there’s simply a yargs parser option for this?