_
in the relevant fields before export. Anyway, glad to hear that you solved it.
@romagnolimarco Thanks, good suggestion. How does this line look before "Then you may need to adjust…":
After running these commands, return to the initial shell by executing
exit
or pressing Ctrl+D.
Regarding the second question, there already is a note about prerequisites.py
in the end.
isolate-check-environment
script. Is there antoher option?
Hello! My name is Mihai Tuțu and I am a teacher at a private school back in Romania. Because CMS is highly popular in the competitions my students go to, I want to implement it for practice contests. I have read much of the documentation and this communication channel, but still I have some questions.
For a contest of 3 hours with 40 participants, with solutions in C / C++, is one computer with CMS installed enough? What physical resources should this computer have?
Thanks!
@goldenskygiang To create a custom language, you need to add a language plugin, which will return compilation and evaluation commands for the language. See https://github.com/cms-dev/cms/blob/master/cms/grading/language.py#L29 for the interface and https://github.com/cms-dev/cms/tree/master/cms/grading/languages for examples.
About task types, you can see https://cms.readthedocs.io/en/latest/Task%20types.html to get a general understanding and then look at https://github.com/cms-dev/cms/tree/master/cms/grading/tasktypes for implementation examples.
If your tasks will have text inputs and text outputs, then likely you don't need a new task type, Batch should do fine.
Hi CMS Community. I have been using CMS to bootstrap another idea. At the moment, I stumbled with the challenge of integrating other applications alongside all the CMS core ones. So I wanted to ask, how much complex do you think would be migrating CMS into gRPC? and could you give me some pointers where I should look at?
I am aware there is a custom RPC server implementation and models somewhere but I cannot spot them.
is it already? are you still using cmsmake? @stefano-maggiolo (4 year old message)
Will task-maker be updated anymore? :( Ever since I saw the 'new cmsmake' advertisement, I've been using task-maker. But the current source throws some error that I had to fix myself to install (last year ... now I have to figure out again). It would be so nice if you guys could update the software to use new packages / fix the errors.
could you give us more info on it? is it actively developed? is it stable and used in production? does it aim at fully replacing the old one?
anyway yes, AFAIK the answer to all those question is yes
"contest_listen_address": [""], "contest_listen_port": [8888],
to have lists of the same length of the number of CWSs (first CWS will listen to the first address/port, etc) - note that if you add nginx in front, you can put the listen address to localhost as noted in the commentpriority
field for each contest, which will dictate which one gets loaded when no choice is made by the user at the service launch. The field can be easily modified from the details page in the admin panel. The highest priority contest will be made the default contest, instead of it always being the last one in the list. I would appreciate feedback on this feature and whether it can be merged into the main branch. Thank you :)
Hi all, in our system we frequently see the typical SQLAlchemy "TimeoutError: QueuePool limit of size 5 overflow 10 reached, connection timed out, timeout 60" errors, and we wonder what is the root cause and the best fix. It happens at the start of the contest in the ContestWebServer and at the end of the contest in the AdminWebServer.
In the last contest we had 1 CWS and 1 AWS, for 40 contestants and 5 administrators.
What we found about this issue:
https://cms.readthedocs.io/en/v1.4/Troubleshooting.html#servers
cms-dev/cms#1119
cms-dev/cms#969
https://docs.sqlalchemy.org/en/14/core/pooling.html
I think it would help to increase the number of ContestWebServers, in one of the above issues it is written that "Each CWS can have at most 15 simultaneous connections to the database open at any time". So, would it make sense to have like (number_of_contestants / 15) ContestWebServers, or what is the rule of thumb?
But it would not solve the same thing happening at the AWS at the end of the contest (or is it common to have multiple AdminWebServers?)
What about increasing the SQLAlchemy pool size from the default 5 in the create_engine call here: https://github.com/cms-dev/cms/blob/v1.4.rc1/cms/db/__init__.py#L93 ?
I made some observations about the logs for more information, I will put them in replies.
Hello!
I have been trying to setup CMS for quite some time now across 3 different machines and everywhere I got some form of error.
Currently I am trying to set it up on Ubuntu machine and can't use "cmsInitDB" due to the following error: ImportError: No module named coros
If helpful, when I run: pip show gevent, it shows gevent's version is 21.12.0.
I have followed this document: https://docs.google.com/document/d/1lFnUv2rexxKfFkp4RKZLfPMeJ0ZbMd6IUdTlJzkOq7c/edit
How can I possibly resolve this?
Thank you in advance!
Dear All~ :)Does anyone know how to make "Allowed programming language Python 3/PyPy"?
How can I make "Python 3 / PyPy" for contest?
I made with
How can I make "Python 3 / PyPy" for contest evaluation?
Is there any documentation for adding new languages(Python 3 / PyPy)?
Thank you All
Hyun-seok
Hi! I'm trying to create a communication task with a lot of user processes (I tried 70 to begin with).
As I noted in #1207, it doesn't work for tasks with more than 9 user processes due to duplicate box_ids being used in Sandbox.py.
I changed Sandbox.py to allocate 75 box_id's to each worker shard (it does not overflow from 1000 as I'm only using workers 0-3).
Now I can evaluate tasks with up to 29 user processes, but not 30. When the system tries to evaluate a submission with 30 user processes, it keeps going until the wall clock limit, then it is killed.
29 user processes is executed in less than a second, 30 doesn't finish even when the time limit is a few minutes.
I tried to inspect the sandbox logs, it appears that 29 user logs are executed without a problem, one user log gets wall timeout, and the manager gets a segfault.
Do you have any idea what could cause this?
This is the log file of Worker 0: https://www.toptal.com/developers/hastebin/uqevegadod.yaml
Let me know if any other logs would help.
Thanks!
Hello. I have installed the CMS on Arch last night, in a python environment, just as in the instructions. Everything starts fine, both admin and contest interface on ports 8888 and 8889. But when testing a submission, I get the isolate error. I have read a lot on this problem and I checked the following:
When running the exact instruction of isolate that gives an error, it says I need to cleanup the box-id first, as it is already in use. Upon doing so and retrying to run the instruction, I get the same.
This is the full error:
2022-07-20 14:45:24,725 - ERROR [Worker,6] Worker failed: Failed to initialize sandbox with command: isolate --cg --box-id=70 --init (error 2).
Traceback (most recent call last):
File "/home/mihai/downloads/cms/lib/python3.6/site-packages/cms-1.4rc1-py3.6.egg/cms/service/Worker.py", line 127, in execute_job_group
task_type.execute_job(job, self.file_cacher)
File "/home/mihai/downloads/cms/lib/python3.6/site-packages/cms-1.4rc1-py3.6.egg/cms/grading/tasktypes/abc.py", line 235, in execute_job
self.compile(job, file_cacher)
File "/home/mihai/downloads/cms/lib/python3.6/site-packages/cms-1.4rc1-py3.6.egg/cms/grading/tasktypes/Batch.py", line 231, in compile
sandbox = create_sandbox(file_cacher, name="compile")
File "/home/mihai/downloads/cms/lib/python3.6/site-packages/cms-1.4rc1-py3.6.egg/cms/grading/tasktypes/util.py", line 71, in create_sandbox
sandbox = Sandbox(file_cacher, name=name)
File "/home/mihai/downloads/cms/lib/python3.6/site-packages/cms-1.4rc1-py3.6.egg/cms/grading/Sandbox.py", line 944, in __init__
self.initialize_isolate()
File "/home/mihai/downloads/cms/lib/python3.6/site-packages/cms-1.4rc1-py3.6.egg/cms/grading/Sandbox.py", line 1420, in initialize_isolate
"(error %d)" % (pretty_print_cmdline(init_cmd), ret))
cms.grading.Sandbox.SandboxInterfaceException: Failed to initialize sandbox with command: isolate --cg --box-id=70 --init (error 2)
I am out of ideas... Can you please help me?