Skip to content

Commit

Permalink
Merge branch 'main' into add-flwr-log
Browse files Browse the repository at this point in the history
  • Loading branch information
tanertopal authored Sep 9, 2024
2 parents 157aaf0 + 00b384b commit f6a105a
Show file tree
Hide file tree
Showing 3 changed files with 26 additions and 6 deletions.
2 changes: 0 additions & 2 deletions .github/workflows/e2e.yml
Original file line number Diff line number Diff line change
Expand Up @@ -146,8 +146,6 @@ jobs:
if: ${{ github.repository == 'adap/flower' && !github.event.pull_request.head.repo.fork && github.actor != 'dependabot[bot]' }}
run: |
python -m pip install https://${{ env.ARTIFACT_BUCKET }}/py/${{ needs.wheel.outputs.dir }}/${{ needs.wheel.outputs.short_sha }}/${{ needs.wheel.outputs.whl_path }}
- name: Install e2e components
run: pip install .
- name: Download dataset
if: ${{ matrix.dataset }}
run: python -c "${{ matrix.dataset }}"
Expand Down
28 changes: 25 additions & 3 deletions doc/source/contributor-how-to-build-docker-images.rst
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ Before we can start, we need to meet a few prerequisites in our local developmen
default values, others must be specified when building the image. All available build arguments for
each image are listed in one of the tables below.

Building the base image
Building the Base Image
-----------------------

.. list-table::
Expand Down Expand Up @@ -65,6 +65,10 @@ Building the base image
- The Flower package to be installed.
- No
- ``flwr`` or ``flwr-nightly``
* - ``FLWR_VERSION_REF``
- A `direct reference <https://packaging.python.org/en/latest/specifications/version-specifiers/#direct-references>`_ without the ``@`` specifier. If both ``FLWR_VERSION`` and ``FLWR_VERSION_REF`` are specified, the ``FLWR_VERSION_REF`` has precedence.
- No
- `Direct Reference Examples`_

The following example creates a base Ubuntu/Alpine image with Python ``3.11.0``,
pip :substitution-code:`|pip_version|`, setuptools :substitution-code:`|setuptools_version|`
Expand All @@ -84,8 +88,8 @@ and Flower :substitution-code:`|stable_flwr_version|`:
In this example, we specify our image name as ``flwr_base`` and the tag as ``0.1.0``. Remember that the build arguments as well
as the name and tag can be adapted to your needs. These values serve as examples only.

Building the SuperLink/SuperNode or ServerApp image
---------------------------------------------------
Building a Flower Binary Image
------------------------------

.. list-table::
:widths: 25 45 15 15
Expand Down Expand Up @@ -130,3 +134,21 @@ After creating the image, we can test whether the image is working:
.. code-block:: bash
$ docker run --rm flwr_superlink:0.1.0 --help
Direct Reference Examples
-------------------------

.. code-block:: bash
:substitutions:
# main branch
git+https://github.com/adap/flower.git@main
# commit hash
git+https://github.com/adap/flower.git@1187c707f1894924bfa693d99611cf6f93431835
# tag
git+https://github.com/adap/flower.git@|stable_flwr_version|
# artifact store
https://artifact.flower.ai/py/main/latest/flwr-|stable_flwr_version|-py3-none-any.whl
2 changes: 1 addition & 1 deletion src/py/flwr/client/client_app.py
Original file line number Diff line number Diff line change
Expand Up @@ -41,11 +41,11 @@ def _alert_erroneous_client_fn() -> None:

def _inspect_maybe_adapt_client_fn_signature(client_fn: ClientFnExt) -> ClientFnExt:
client_fn_args = inspect.signature(client_fn).parameters
first_arg = list(client_fn_args.keys())[0]

if len(client_fn_args) != 1:
_alert_erroneous_client_fn()

first_arg = list(client_fn_args.keys())[0]
first_arg_type = client_fn_args[first_arg].annotation

if first_arg_type is str or first_arg == "cid":
Expand Down

0 comments on commit f6a105a

Please sign in to comment.