__init__.py 1.3 KB

12345678910111213141516171819202122232425262728293031323334
  1. # Copyright Materialize, Inc. and contributors. All rights reserved.
  2. #
  3. # Use of this software is governed by the Business Source License
  4. # included in the LICENSE file at the root of this repository.
  5. #
  6. # As of the Change Date specified in that file, in accordance with
  7. # the Business Source License, use of this software will be governed
  8. # by the Apache License, Version 2.0.
  9. """Package `materialize` is the top-level Python package for Materialize, Inc.
  10. While the primary product, [materialized][], is written in Rust, various demos and
  11. build tools are written in Python. This package enables the sharing of code
  12. between those scripts.
  13. Consider writing additional Python code when:
  14. * You are writing scripts intended to be run by users of Materialize, not
  15. developers, e.g. automation for a complicated demo. We can reasonably ask
  16. users to install Python 3.6+. A Rust toolchain is a much bigger ask.
  17. * You are about to write a large Bash script.
  18. * You've already written a Bash script whose complexity and maintainability
  19. has deteriorated as the script's responsibilities have grown.
  20. [materialized]: https://dev.materialize.com/api/rust/materialized/index.html
  21. """
  22. import os
  23. from pathlib import Path
  24. MZ_ROOT = Path(os.environ["MZ_ROOT"])
  25. """The absolute path to the root of the Materialize repository."""