diff --git a/COMMITTERS.rst b/COMMITTERS.rst index d5883e1192679..16fdcf1e48e54 100644 --- a/COMMITTERS.rst +++ b/COMMITTERS.rst @@ -158,7 +158,7 @@ can become the Mentor and guide the proposed candidates on how they can become a If the committee does not have enough information, requires more time, or requires more evidence of candidate's eligibility, a mentor, who is not the proposer, is selected to help mentor the candidate - The mentor should try to remain impartial -- his/her goal is to provide the missing evidence and to + The mentor should try to remain impartial -- their goal is to provide the missing evidence and to try to coach/mentor the candidate to success. In order to re-raise a candidate vote, both Proposer and Mentor must be in favor. Again, diff --git a/airflow/models/serialized_dag.py b/airflow/models/serialized_dag.py index 98d933f29425f..a9e359e452f32 100644 --- a/airflow/models/serialized_dag.py +++ b/airflow/models/serialized_dag.py @@ -160,7 +160,7 @@ def read_all_dags(cls, session: Session = None) -> Dict[str, 'SerializedDAG']: log.debug("Deserializing DAG: %s", row.dag_id) dag = row.dag - # Sanity check. + # Coherence check if dag.dag_id == row.dag_id: dags[row.dag_id] = dag else: diff --git a/airflow/providers/amazon/aws/example_dags/example_emr_job_flow_automatic_steps.py b/airflow/providers/amazon/aws/example_dags/example_emr_job_flow_automatic_steps.py index 1470c8e8b3eac..c1467f77be183 100644 --- a/airflow/providers/amazon/aws/example_dags/example_emr_job_flow_automatic_steps.py +++ b/airflow/providers/amazon/aws/example_dags/example_emr_job_flow_automatic_steps.py @@ -44,7 +44,7 @@ 'Instances': { 'InstanceGroups': [ { - 'Name': 'Master node', + 'Name': 'Primary node', 'Market': 'SPOT', 'InstanceRole': 'MASTER', 'InstanceType': 'm1.medium', diff --git a/airflow/providers/amazon/aws/example_dags/example_emr_job_flow_manual_steps.py b/airflow/providers/amazon/aws/example_dags/example_emr_job_flow_manual_steps.py index 560e92585774c..1c67397fefbdd 100644 --- a/airflow/providers/amazon/aws/example_dags/example_emr_job_flow_manual_steps.py +++ b/airflow/providers/amazon/aws/example_dags/example_emr_job_flow_manual_steps.py @@ -48,7 +48,7 @@ 'Instances': { 'InstanceGroups': [ { - 'Name': 'Master node', + 'Name': 'Primary node', 'Market': 'SPOT', 'InstanceRole': 'MASTER', 'InstanceType': 'm1.medium', diff --git a/airflow/providers/google/cloud/hooks/cloud_memorystore.py b/airflow/providers/google/cloud/hooks/cloud_memorystore.py index 8f4165ba4675e..dc162b9f242ad 100644 --- a/airflow/providers/google/cloud/hooks/cloud_memorystore.py +++ b/airflow/providers/google/cloud/hooks/cloud_memorystore.py @@ -291,7 +291,7 @@ def failover_instance( metadata: Optional[Sequence[Tuple[str, str]]] = None, ): """ - Initiates a failover of the master node to current replica node for a specific STANDARD tier Cloud + Initiates a failover of the primary node to current replica node for a specific STANDARD tier Cloud Memorystore for Redis instance. :param location: The location of the Cloud Memorystore instance (for example europe-west1) diff --git a/airflow/providers/google/cloud/operators/cloud_memorystore.py b/airflow/providers/google/cloud/operators/cloud_memorystore.py index 9214a9211f282..d232f95738445 100644 --- a/airflow/providers/google/cloud/operators/cloud_memorystore.py +++ b/airflow/providers/google/cloud/operators/cloud_memorystore.py @@ -315,7 +315,7 @@ def execute(self, context: dict) -> None: class CloudMemorystoreFailoverInstanceOperator(BaseOperator): """ - Initiates a failover of the master node to current replica node for a specific STANDARD tier Cloud + Initiates a failover of the primary node to current replica node for a specific STANDARD tier Cloud Memorystore for Redis instance. .. seealso:: diff --git a/airflow/providers/google/cloud/operators/dataproc.py b/airflow/providers/google/cloud/operators/dataproc.py index 96d3cedfdc1f5..fb4d8ed037e27 100644 --- a/airflow/providers/google/cloud/operators/dataproc.py +++ b/airflow/providers/google/cloud/operators/dataproc.py @@ -135,14 +135,14 @@ class ClusterGenerator: :type optional_components: list[str] :param num_masters: The # of master nodes to spin up :type num_masters: int - :param master_machine_type: Compute engine machine type to use for the master node + :param master_machine_type: Compute engine machine type to use for the primary node :type master_machine_type: str - :param master_disk_type: Type of the boot disk for the master node + :param master_disk_type: Type of the boot disk for the primary node (default is ``pd-standard``). Valid values: ``pd-ssd`` (Persistent Disk Solid State Drive) or ``pd-standard`` (Persistent Disk Hard Disk Drive). :type master_disk_type: str - :param master_disk_size: Disk size for the master node + :param master_disk_size: Disk size for the primary node :type master_disk_size: int :param worker_machine_type: Compute engine machine type to use for the worker nodes :type worker_machine_type: str diff --git a/airflow/providers/yandex/operators/yandexcloud_dataproc.py b/airflow/providers/yandex/operators/yandexcloud_dataproc.py index 7150e145ccf63..84ac354e77aec 100644 --- a/airflow/providers/yandex/operators/yandexcloud_dataproc.py +++ b/airflow/providers/yandex/operators/yandexcloud_dataproc.py @@ -49,7 +49,7 @@ class DataprocCreateClusterOperator(BaseOperator): Service account can be created inside the folder. :type service_account_id: Optional[str] :param masternode_resource_preset: Resources preset (CPU+RAM configuration) - for the master node of the cluster. + for the primary node of the cluster. :type masternode_resource_preset: str :param masternode_disk_size: Masternode storage size in GiB. :type masternode_disk_size: int diff --git a/airflow/providers_manager.py b/airflow/providers_manager.py index dc92e93b59d31..9fb44f44084c7 100644 --- a/airflow/providers_manager.py +++ b/airflow/providers_manager.py @@ -107,7 +107,7 @@ def _create_customized_form_field_behaviours_schema_validator(): def _sanity_check(provider_package: str, class_name: str) -> bool: """ - Performs sanity check on provider classes. + Performs coherence check on provider classes. For apache-airflow providers - it checks if it starts with appropriate package. For all providers it tries to import the provider - checking that there are no exceptions during importing. It logs appropriate warning in case it detects any problems. @@ -121,7 +121,7 @@ def _sanity_check(provider_package: str, class_name: str) -> bool: provider_path = provider_package[len("apache-") :].replace("-", ".") if not class_name.startswith(provider_path): log.warning( - "Sanity check failed when importing '%s' from '%s' package. It should start with '%s'", + "Coherence check failed when importing '%s' from '%s' package. It should start with '%s'", class_name, provider_package, provider_path, diff --git a/airflow/utils/db.py b/airflow/utils/db.py index a5dfacfd3d427..11aabe55774b8 100644 --- a/airflow/utils/db.py +++ b/airflow/utils/db.py @@ -231,7 +231,7 @@ def create_default_connections(session=None): "InstanceCount": 1 }, { - "Name": "Slave nodes", + "Name": "Core nodes", "Market": "ON_DEMAND", "InstanceRole": "CORE", "InstanceType": "r3.2xlarge", diff --git a/airflow/utils/process_utils.py b/airflow/utils/process_utils.py index d3a707610b9e7..f8587bb6f6aaa 100644 --- a/airflow/utils/process_utils.py +++ b/airflow/utils/process_utils.py @@ -159,19 +159,19 @@ def execute_interactive(cmd: List[str], **kwargs): tty.setraw(sys.stdin.fileno()) # open pseudo-terminal to interact with subprocess - master_fd, slave_fd = pty.openpty() + primary_fd, secondary_fd = pty.openpty() try: # use os.setsid() make it run in a new process group, or bash job control will not be enabled with subprocess.Popen( - cmd, stdin=slave_fd, stdout=slave_fd, stderr=slave_fd, universal_newlines=True, **kwargs + cmd, stdin=secondary_fd, stdout=secondary_fd, stderr=secondary_fd, universal_newlines=True, **kwargs ) as proc: while proc.poll() is None: - readable_fbs, _, _ = select.select([sys.stdin, master_fd], [], []) + readable_fbs, _, _ = select.select([sys.stdin, primary_fd], [], []) if sys.stdin in readable_fbs: input_data = os.read(sys.stdin.fileno(), 10240) - os.write(master_fd, input_data) - if master_fd in readable_fbs: - output_data = os.read(master_fd, 10240) + os.write(primary_fd, input_data) + if primary_fd in readable_fbs: + output_data = os.read(primary_fd, 10240) if output_data: os.write(sys.stdout.fileno(), output_data) finally: diff --git a/docs/apache-airflow-providers-google/operators/cloud/dataproc.rst b/docs/apache-airflow-providers-google/operators/cloud/dataproc.rst index ac6cd09fee321..2ecdda657045f 100644 --- a/docs/apache-airflow-providers-google/operators/cloud/dataproc.rst +++ b/docs/apache-airflow-providers-google/operators/cloud/dataproc.rst @@ -105,7 +105,7 @@ The list currently includes Spark, Hadoop, Pig and Hive. For more information on versions and images take a look at `Cloud Dataproc Image version list `__ To submit a job to the cluster you need a provide a job source file. The job source file can be on GCS, the cluster or on your local -file system. You can specify a file:/// path to refer to a local file on a cluster's master node. +file system. You can specify a file:/// path to refer to a local file on a cluster's primary node. The job configuration can be submitted by using: :class:`~airflow.providers.google.cloud.operators.dataproc.DataprocSubmitJobOperator`. diff --git a/scripts/docker/install_airflow.sh b/scripts/docker/install_airflow.sh index e2bca4fc839a0..61a30c42c12d9 100755 --- a/scripts/docker/install_airflow.sh +++ b/scripts/docker/install_airflow.sh @@ -30,7 +30,7 @@ . "$( dirname "${BASH_SOURCE[0]}" )/common.sh" function install_airflow() { - # Sanity check for editable installation mode. + # Coherence check for editable installation mode. if [[ ${AIRFLOW_INSTALLATION_METHOD} != "." && \ ${AIRFLOW_INSTALL_EDITABLE_FLAG} == "--editable" ]]; then echo diff --git a/scripts/in_container/bin/install_aws.sh b/scripts/in_container/bin/install_aws.sh index e1e8ec3284634..33fd7ff2e1b0f 100755 --- a/scripts/in_container/bin/install_aws.sh +++ b/scripts/in_container/bin/install_aws.sh @@ -58,7 +58,7 @@ pushd "${TMP_DIR}" && unzip "${TMP_DIR}/awscliv2.zip" && cd aws && \ --bin-dir "/files/bin/" && \ popd -# Sanity check +# Coherence check if ! command -v aws > /dev/null; then echo 'Installation failed. The command "aws" was not found.' exit 1 diff --git a/scripts/in_container/bin/install_az.sh b/scripts/in_container/bin/install_az.sh index 51ef31aafb92b..e283fd95c99d3 100755 --- a/scripts/in_container/bin/install_az.sh +++ b/scripts/in_container/bin/install_az.sh @@ -61,7 +61,7 @@ chmod a+x /files/opt/az/az ln -s /files/opt/az/az "${BIN_PATH}" -# Sanity check +# Coherence check if ! command -v az > /dev/null; then echo 'Installation failed. The command "az" was not found.' exit 1 diff --git a/scripts/in_container/bin/install_gcloud.sh b/scripts/in_container/bin/install_gcloud.sh index 96d5017789893..86a6fe32f4d75 100755 --- a/scripts/in_container/bin/install_gcloud.sh +++ b/scripts/in_container/bin/install_gcloud.sh @@ -67,7 +67,7 @@ while IPS='' read -r line; do ln -sf "${line}" "/files/bin/${BIN_NAME}" done < <(find "${INSTALL_DIR}/bin/" -type f) -# Sanity check +# Coherence check if ! command -v gcloud > /dev/null; then echo 'Installation failed. The command "gcloud" was not found.' exit 1 diff --git a/scripts/in_container/bin/install_imgcat.sh b/scripts/in_container/bin/install_imgcat.sh index 66090554f11e2..96a5c10948edd 100755 --- a/scripts/in_container/bin/install_imgcat.sh +++ b/scripts/in_container/bin/install_imgcat.sh @@ -38,7 +38,7 @@ echo "Downloading from ${DOWNLOAD_URL}" curl -# --fail "${DOWNLOAD_URL}" --output "${BIN_PATH}" chmod +x "${BIN_PATH}" -# Sanity check +# Coherence check if ! command -v imgcat > /dev/null; then echo 'Installation failed. The command "imgcat" was not found.' exit 1 diff --git a/scripts/in_container/bin/install_java.sh b/scripts/in_container/bin/install_java.sh index 49c9040c1b094..8089e4338d97b 100755 --- a/scripts/in_container/bin/install_java.sh +++ b/scripts/in_container/bin/install_java.sh @@ -61,7 +61,7 @@ while IPS='' read -r line; do ln -s "${line}" "/files/bin/${BIN_NAME}" done < <(find "${INSTALL_DIR}/bin/" -type f) -# Sanity check +# Coherence check if ! command -v java > /dev/null; then echo 'Installation failed. The command "java" was not found.' exit 1 diff --git a/scripts/in_container/bin/install_kubectl.sh b/scripts/in_container/bin/install_kubectl.sh index b2604ae32e008..a74f572db52a2 100755 --- a/scripts/in_container/bin/install_kubectl.sh +++ b/scripts/in_container/bin/install_kubectl.sh @@ -46,7 +46,7 @@ echo "Downloading from ${DOWNLOAD_URL}" curl -# --fail "${DOWNLOAD_URL}" --output "${BIN_PATH}" chmod +x "${BIN_PATH}" -# Sanity check +# Coherence check if ! command -v kubectl > /dev/null; then echo 'Installation failed. The command "kubectl" was not found.' exit 1 diff --git a/scripts/in_container/bin/install_terraform.sh b/scripts/in_container/bin/install_terraform.sh index 12edbbac5d7eb..b6358e472cf50 100755 --- a/scripts/in_container/bin/install_terraform.sh +++ b/scripts/in_container/bin/install_terraform.sh @@ -47,7 +47,7 @@ curl -# --fail "${DOWNLOAD_URL}" --output "${TMP_DIR}/terraform.zip" echo "Extracting archive" unzip "${TMP_DIR}/terraform.zip" -d /files/bin -# Sanity check +# Coherence check if ! command -v terraform > /dev/null; then echo 'Installation failed. The command "terraform" was not found.' exit 1 diff --git a/tests/core/test_providers_manager.py b/tests/core/test_providers_manager.py index f0a2fc2be8ee5..07cb2af5d6444 100644 --- a/tests/core/test_providers_manager.py +++ b/tests/core/test_providers_manager.py @@ -42,7 +42,7 @@ def test_providers_are_loaded(self): version = provider_manager.providers[provider][0] assert re.search(r'[0-9]*\.[0-9]*\.[0-9]*.*', version) assert package_name == provider - # just a sanity check - no exact number as otherwise we would have to update + # just a coherence check - no exact number as otherwise we would have to update # several tests if we add new connections/provider which is not ideal assert len(provider_list) > 65 assert [] == self._caplog.records diff --git a/tests/models/test_dagbag.py b/tests/models/test_dagbag.py index adbf146c797c6..1e261c87ecb4f 100644 --- a/tests/models/test_dagbag.py +++ b/tests/models/test_dagbag.py @@ -419,7 +419,7 @@ def subdag_1(): return dag test_dag = standard_subdag() - # sanity check to make sure DAG.subdag is still functioning properly + # coherence check to make sure DAG.subdag is still functioning properly assert len(test_dag.subdags) == 2 # Perform processing dag @@ -503,7 +503,7 @@ def subdag_1(): return dag test_dag = nested_subdags() - # sanity check to make sure DAG.subdag is still functioning properly + # coherence check to make sure DAG.subdag is still functioning properly assert len(test_dag.subdags) == 6 # Perform processing dag @@ -541,7 +541,7 @@ def basic_cycle(): return dag test_dag = basic_cycle() - # sanity check to make sure DAG.subdag is still functioning properly + # coherence check to make sure DAG.subdag is still functioning properly assert len(test_dag.subdags) == 0 # Perform processing dag @@ -628,7 +628,7 @@ def subdag_1(): return dag test_dag = nested_subdag_cycle() - # sanity check to make sure DAG.subdag is still functioning properly + # coherence check to make sure DAG.subdag is still functioning properly assert len(test_dag.subdags) == 6 # Perform processing dag diff --git a/tests/models/test_dagrun.py b/tests/models/test_dagrun.py index 0da62cb649bfa..3622603cb1812 100644 --- a/tests/models/test_dagrun.py +++ b/tests/models/test_dagrun.py @@ -737,7 +737,7 @@ def test_next_dagruns_to_examine_only_unpaused(self, state): def test_no_scheduling_delay_for_nonscheduled_runs(self, stats_mock): """ Tests that dag scheduling delay stat is not called if the dagrun is not a scheduled run. - This case is manual run. Simple test for sanity check. + This case is manual run. Simple test for coherence check. """ dag = DAG(dag_id='test_dagrun_stats', start_date=days_ago(1)) dag_task = DummyOperator(task_id='dummy', dag=dag)