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

Plotting area in SymPy Gamma always shows an Error #70

Closed
ashutoshsaboo opened this issue Mar 16, 2016 · 5 comments
Closed

Plotting area in SymPy Gamma always shows an Error #70

ashutoshsaboo opened this issue Mar 16, 2016 · 5 comments

Comments

@ashutoshsaboo
Copy link
Contributor

This gets displayed in the area where the plot() graphs are generally displayed.

This happens in case of all the queries, in this query as well - plot(sin(x) + cos(2x)). Error shown below. Is there some problem with my installation, or is it an internal issue only? I've followed the installation steps from this link - https://github.com/ashutoshsaboo/sympy_gamma .

I've followed the steps till - Uploading to GAE (Manually) only. As in I haven't followed any steps beyond that title, mentioned in the above link. So, is that causing the issue? Or what is it that's causing this issue?

Plot:
plot(sin(x) + cos(2*x))
There was an error in Gamma. For referencethe last five traceback entries are: Traceback (most recent call last):
  File "/home/ashutoshsaboo/sympy_gamma/app/views.py", line 278, in eval_card
    result = g.eval_card(card_name, expression, variable, parameters)
  File "/home/ashutoshsaboo/sympy_gamma/app/logic/logic.py", line 322, in eval_card
    result = card.eval(evaluator, components, parameters)
  File "/home/ashutoshsaboo/sympy_gamma/app/logic/resultsets.py", line 98, in eval
    return self.card_info['eval_method'](evaluator, components, parameters)
  File "/home/ashutoshsaboo/sympy_gamma/app/logic/resultsets.py", line 562, in eval_plot
    series = series.get_segments()
  File "/home/ashutoshsaboo/sympy_gamma/sympy/sympy/plotting/plot.py", line 457, in get_segments
    sample([self.start, f_start], [self.end, f_end], 0)
AttributeError: 'NoneType' object has no attribute 'random'
@ashutoshsaboo
Copy link
Contributor Author

Even a simple command like - plot sin(x) produces this exact, same error.

@asmeurer
Copy link
Member

Yes, I noticed this too. This seems related to the Phantom.js failure. It does work on the live website, though.

@asmeurer
Copy link
Member

Sometimes these differences between local behavior and the behavior on the App Engine are due to library differences (like a different version of some library on your local machine than what is on the App Engine). The App Engine SDK doesn't provide a full emulation of the App Engine. Another common difference is that the App Engine removes several libraries from the standard library for sandboxing purposes.

One way to test this would be to create and upload your own custom instance of SymPy Gamma on the App Engine (it is free). You may also want to debug the code to see what the AttributeError is coming from.

@ashutoshsaboo
Copy link
Contributor Author

This issue is fixed and resolved at PR #72 . @asmeurer Sir, please review the PR.

Thanks! 😄

@ashutoshsaboo
Copy link
Contributor Author

Since #73 is merged, hence I'm closing this issue! 😄

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

2 participants