potiuk opened a new pull request, #32748:
URL: https://github.com/apache/airflow/pull/32748

   Workaround an issue with installing pymssql on ARM architecture triggered by 
Cython 3.0.0 release as of 18 July 2023. The problem is that pip uses latest 
Cython to compile pymssql and since we are using setuptools, there is no easy 
way to fix version of Cython used to compile packages.
   
   This triggers a problem with newer `pip` versions that have build isolation 
enabled by default because There is no (easy) way to pin build dependencies for 
dependent packages. If a package does not have  limit on build dependencies, it 
will use the latest version of them to build that particular package.
   
   The workaround to the problem suggest in the last thread by Pradyun Gedam - 
pip maintainer - is to use PIP_CONSTRAINT environment variable and constraint 
the version of Cython used while installing the package. Which is precisely 
what we are doing here.
   
   Note that it does not work if we pass ``--constraint`` option to pip because 
it will not be passed to the package being build in isolation. The fact that 
the PIP_CONSTRAINT env variable works in the isolation is a bit of side-effect 
on how env variables work and that they are passed to subprocesses as pip 
launches a subprocess `pip` to build the package.
   
   This is a temporary solution until the issue is resolved in pymssql or 
Cython.
   
   Issues/discussions that track it:
   
   * https://github.com/cython/cython/issues/5541
   * https://github.com/pymssql/pymssql/pull/827
   * https://discuss.python.org/t/no-way-to-pin-build-dependencies/29833
   
   Since we have to change Dockerfile around installing `pip`, also version of 
`pip` has been upgraded to latest - 23.2
   
   <!--
    Licensed to the Apache Software Foundation (ASF) under one
    or more contributor license agreements.  See the NOTICE file
    distributed with this work for additional information
    regarding copyright ownership.  The ASF licenses this file
    to you under the Apache License, Version 2.0 (the
    "License"); you may not use this file except in compliance
    with the License.  You may obtain a copy of the License at
   
      http://www.apache.org/licenses/LICENSE-2.0
   
    Unless required by applicable law or agreed to in writing,
    software distributed under the License is distributed on an
    "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
    KIND, either express or implied.  See the License for the
    specific language governing permissions and limitations
    under the License.
    -->
   
   <!--
   Thank you for contributing! Please make sure that your code changes
   are covered with tests. And in case of new features or big changes
   remember to adjust the documentation.
   
   Feel free to ping committers for the review!
   
   In case of an existing issue, reference it using one of the following:
   
   closes: #ISSUE
   related: #ISSUE
   
   How to write a good git commit message:
   http://chris.beams.io/posts/git-commit/
   -->
   
   ---
   **^ Add meaningful description above**
   
   Read the **[Pull Request 
Guidelines](https://github.com/apache/airflow/blob/main/CONTRIBUTING.rst#pull-request-guidelines)**
 for more information.
   In case of fundamental code changes, an Airflow Improvement Proposal 
([AIP](https://cwiki.apache.org/confluence/display/AIRFLOW/Airflow+Improvement+Proposals))
 is needed.
   In case of a new dependency, check compliance with the [ASF 3rd Party 
License Policy](https://www.apache.org/legal/resolved.html#category-x).
   In case of backwards incompatible changes please leave a note in a 
newsfragment file, named `{pr_number}.significant.rst` or 
`{issue_number}.significant.rst`, in 
[newsfragments](https://github.com/apache/airflow/tree/main/newsfragments).
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to