jmerle / competitive-companion

Browser extension which parses competitive programming problems
https://chromewebstore.google.com/detail/competitive-companion/cjnmckjndlpiamhfimnnjmnckgghkjbl
MIT License
887 stars 112 forks source link

Should support for Codeforces problems with only PDF statements be added? #215

Closed user202729 closed 2 years ago

user202729 commented 2 years ago

Some problems e.g. https://codeforces.com/gym/103492/problem/H have the statement directly link to a PDF, which breaks the Codeforces contest parser.

Of course in this case it's not possible to parse sample test cases, but for parsing the problem do you think it would be a good idea to

jmerle commented 2 years ago

We do have a way to read PDFs in the extension (readPdf) which is used for UVa Online Judge and ICPC Live Archive problems, but it seems like the structure of the Codeforces PDFs cannot be parsed well enough for this function to be useful.

Taking the available information from the contest page as you suggest sounds like a good idea, I've implemented that in https://github.com/jmerle/competitive-companion/commit/2d932d1c4a0cf7d118ee7def85c1170b1ca805ed.

For consistency I won't be changing the URL though, as for all parsed problems the URL is the link to the problem itself, not to its submission page. If tools like cpbooster cannot handle certain problem URLs I consider that a bug in the external tools themselves.