Skip to content
Snippets Groups Projects

Update stubs.

Open Penny Madysa requested to merge nmadysa/pjlsa:update-stubs into master
1 unresolved thread

Procedure was as follows:

  1. install latest commit of cmmnbuild-dep-manager
  2. run lsa_stubgen.py
  3. run black .

Motivation for this PR is the lack of stub for ContextService.findPatterns().

Merge request reports

Loading
Loading

Activity

Filter activity
  • Approvals
  • Assignees & reviewers
  • Comments (from bots)
  • Comments (from users)
  • Commits & branches
  • Edits
  • Labels
  • Lock status
  • Mentions
  • Merge request status
  • Tracking
607 """
608 public interface JapcService extends cern.lsa.client.common.CommonJapcService
609
610 Bridge between JAPC and LSA parameters.
611 """
612 ...
613
614 class KnobService(cern.lsa.client.common.CommonKnobService):
615 """
616 public interface KnobService extends cern.lsa.client.common.CommonKnobService
617
618 Service for knob related operations.
619 """
620 ...
621
622 class LhcService:
  • Hmm, we can not do this - there is evidently a clash with CERN specific stubs. For example, we do not have the methods related to patterns, or ApplicationService - instead we have accelerator specific services.

    Probably we are getting to the limit of what we can do with static (in-repo) stubs... should we try to generate them on the fly as a release step, or even at install time?

  • Both release-time and install-time generation would likely make this much less of an issue.

    Personally, I'm leaning more towards release-time codegen. It would look identical to CERN users and since GSI has to maintain a parallel version of pjlsa anyway, it's not an additional maintenance burden for us.

    Hooking into the install process, on the other hand, is tricky and makes installation slower and more fragile. It also permanently ties us to using setup.py instead of/in addition to pyproject.toml.

  • I agree, let's start with release-time for the moment. This would mean installing cmmnbuild-dep-manager[stubgen] in the pipeline and run lsa_stubgen before building the sdist and wheel. Would you have time to try implementing it?

    Edited by Michi Hostettler
  • Please register or sign in to reply
Please register or sign in to reply
Loading