Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Latest jinja2 (2.9.5) brakes ddl codegen #32

Closed
davidslac opened this issue Mar 13, 2017 · 0 comments
Closed

Latest jinja2 (2.9.5) brakes ddl codegen #32

davidslac opened this issue Mar 13, 2017 · 0 comments

Comments

@davidslac
Copy link
Collaborator

ana-1.2.2 has jinjai2 2.9.5. When psddlc from the psddl repo is used to generate the pdsdata code with it, the code is incorrect. You see a generated line that looks like

* var = ...

instead of

Evr::OuputMapV2 * var = ...

so that typename is gettting lost as a template parameter for the code generation.

The jinjai2 2.7 to 2.8 introduced a bug that was very difficult to track down. I don't know that we should spend that much time with this bug. Two options

Special Environment for DDL

Then we can always have the latest jinja2 in ana-current.

We'dl make a special environment with jinjai2 2.8 to compile the DDL, but development and testing should be done in ana-current. I think this environment needs

  1. scons
  2. psana-conda
  3. maybe cython

I guess I'll put in all the build dependencies of psana-conda. I'll have to make the envs.sh files to set environment variables also. We'll call the environment

ddl

and put it in all six, dev/prod rhel5/6/7. We may have to periodically update psana-conda for these environments. We should probably pin jinjai in them?

Pin Jinja

Or should I just pin jinja2 to 2.8.1? Downgrading jinja2 to 2.8.1 introduced no other changes in packages, for ana-1.2.2, so I think I'll do that.

davidslac added a commit that referenced this issue Mar 13, 2017
This is a hackfix that closes issue #32. Ideally, we replace the DDL with google protocol buffers, or put in a rigorous jinja2 vs DDL test and update psddl as jinja2 changes.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant