Skip to main content

Under the hood

Default runtime environments

For each language, Datagrok uses a predefined header and creates an environment with the set of pre-installed packages.

import os
import io
import json
import pandas as pd
import requests
from datetime import datetime, timedelta
from datagrok_api import DatagrokClient

# Platform automatically initializes datagrok_api client with the current user's token and correct server URL:
grok = DatagrokClient(...)

Environment isolation

You can specify an environment for the script to use, including the language version and a set of libraries.

Datagrok uses Conda as the environment management system. A Conda environment:

  • isolates each script run,
  • resolves dependencies,
  • and takes time to be created before a script run.

Later, the script uses the pre-created environment with no delay for resolving dependencies.

In Datagrok, Conda environment configuration can be specified either right inside the script or as part of a package.

See also: