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

Impossible to reproduce example from "Basic Usage 2", using @handcalcs() generates a function that doesn't output anything #189

Open
ragdollfun opened this issue Nov 5, 2023 · 4 comments

Comments

@ragdollfun
Copy link

I'm trying to reproduce the example from "Basic Usage 2: As a decorator on your functions, @handcalc()", but the variable vals is empty in my case.

Using @handcalc(jupyter_display=True) does render the LaTeX formulas correctly, but the value of vals is None.

@scote89
Copy link

scote89 commented Nov 10, 2023

Same here,
image

@connorferster
Copy link
Owner

@ragdollfun and @scote89

It goes like this:
image

Thanks for pointing out that the return statement is missing from the example. On a previous version of handcalcs, the locals() dictionary was returned without having to use the return statement. That is no longer the case.

I have just updated the example.

@gusto475
Copy link

Hi Connor. Simple question. It is possible to add comments to functions with decorators? Thanks.

@DonCammne
Copy link

Yes, by using """comments""'.

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

5 participants