databrickslabs / databrickslabs/pytester

Ability to rewrite code with mock database names

Open
#7 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
Python
Stars
139
Forks
16
PR merge metrics
No merged PRs in 30d

Description

People want develop on an existing db and test on isolated db. Let's make it simpler

make_database() is lenghty to write, so it may be easier to write "spark.table('abc.xyz')" and let it be rewritten with spark.table(f'{make_database()}.xyz') for the runtime

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

No file or test is named; start by locating make_database() and the spark.table(...) handling. Define how literal database names such as abc.xyz are rewritten for runtime isolation, then add coverage for the shown example and verify the resulting behavior.

Written by the indexing model from the issue text.

Assessment

Tech stack
python, spark
Domain
databases, testing
Issue type
Feature
Difficulty
5/5
Estimated time
Over a week
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.