Show Posts

This section allows you to view all posts made by this member. Note that you can only see posts made in areas you currently have access to.


Messages - Tony

Pages: 1 [2] 3 4 ... 37
16
Help and Support / Re: Reloading causes failure of catching exceptions
« on: January 05, 2017, 05:20:52 PM »
Hi,

I've just uploaded a new beta release that addresses that warnings you were getting with sqlalchemy.

Sqlalchemy has several circular dependencies between its modules and packages, so including it in the list of deep-reloadable packages (either by adding it to deep_reload_include, or by removing that list and not adding it to deep_reload_exclude) will cause a number of warnings to be written to the log (warnings about circular dependencies, not the KeyError you saw). If it's not being reloaded (as in your case) there now won't be any warnings or errors.

You can download the new build from the place as before:
https://beta.pyxll.com/download.html#standalone (username: pyxll, password: pyxll)

Please let me know if you have any more problems!

Best regards,
Tony

17
Help and Support / Re: List type annotation in Python3 generates error
« on: January 04, 2017, 09:27:56 AM »
Hi,

currently you have to use the old style string signatures for array types. See https://www.pyxll.com/docs/userguide/udfs.html#using-arrays or the examples for details.

Alternatively, you can simply omit the type information and it will default to 'var', which can accept an array.

Note that List[int] would be technically the wrong type even if it did work for arrays, since the actual type is a list of lists of ints rather than a simple list of ints (as it's a 2d range of data).

I will look at the best way to provide array type information using type hints for a future release, but for now please try providing a signature string or removing the type hint. If you provide a signature string, then any type hints will be ignored, so you can use both if you require the type hint for any other reason.

Best regards,
Tony

18
Help and Support / Re: Download latest version
« on: January 04, 2017, 09:22:57 AM »
Hi,

you can download it from here:
https://www.pyxll.com/download.html#standalone

There's a link to this page on the main pyxll.com home page (see 'downloads' at the top).

Best regards,
Tony

19
Help and Support / Re: Reloading causes failure of catching exceptions
« on: January 03, 2017, 11:43:59 AM »
Hi,

ah, I had forgotten that you already had a,b and in deep_reload_include - so in that case adding sqlalchemy to deep_reload_exclude would not have any effect.

You can now actually specify both, but it won't help you in this case. No matter how you set them, you will get those warnings in the log, but as you have found it shouldn't actually stop anything from working as sqlalchemy is already being excluded from the set of modules that are reloaded.

For now you will just have to ignore the warnings, but I will continue to look into this.

Best regards,
Tony

20
Help and Support / Re: Reloading causes failure of catching exceptions
« on: January 03, 2017, 10:26:15 AM »
Hi,

thanks for that, I'll look into it.

The reason it happens before reloading is because that's when it builds the dependency map, when the modules are first imported. That's what it uses later when doing the deep reload.

For now, you can add sqlalchemy to the "deep_reload_exclude" list, but I will look into it and figure out what's going wrong.

Best regards,
Tony

21
Help and Support / Re: Reloading causes failure of catching exceptions
« on: December 30, 2016, 11:35:12 AM »
Hi,

sorry this has taken so long to resolve. There were a couple of issues to do with relative imports and how the dependency map is updated when reloading.

These problems have now been fixed, and in my testing your test case works (hopefully your real-life case will too).

Please could you try the new beta release 3.1.2.beta, which you can download from:
https://beta.pyxll.com/download.html#standalone (username: pyxll, password: pyxll)

Nothing else has changed except for the deep reloading behaviour.

Once you've had a chance to try this out, if you could confirm this fixes your problem I will include these changes in the next main release (or I can do a patch release with just these changes).

I also added a new option "deep_reload_print_graph". If enabled (set to 1) then when reloading it will log the dependency graph used to determine the order in which the modules are reloaded.

Best regards,
Tony

22
Help and Support / Re: Reloading causes failure of catching exceptions
« on: December 22, 2016, 03:59:43 PM »
Apologies for the delay. It's not a simple fix unfortunately, but we are working on it.

Best regards,
Tony

23
Help and Support / Re: Excel 2013 crashing when installing Add-In
« on: December 22, 2016, 03:57:47 PM »
For anyone else coming across this post...

The issue was that the Anaconda version of Python was failing to start because it couldn't determine where Python had been installed. Setting "executable" to the full path to python.exe in the pyxll.cfg file resolved the issue,

Code: [Select]
[PYTHON]
executable = c:\Users\xxx\Anaconda3\python.exe

It seems to be an issue specific to Anaconda, as the problem did not occur with the same version of Python downloaded from python.org.

24
Help and Support / Re: Excel 2013 crashing when installing Add-In
« on: December 16, 2016, 09:05:36 PM »
Thanks for that - I've got an idea where to start looking now. It's unusual to want to install pyxll on a server, but there's no reason why it shouldn't work so I'll need to reproduce the problem and debug it.

I'll let you know as soon as I've found anything.

Best regards,
Tony

25
Help and Support / Re: Excel 2013 crashing when installing Add-In
« on: December 16, 2016, 08:35:35 PM »
Hi,

is anything written to the log file before the crash? Please can you try setting the log level to debug in your pyxll.cfg file?

Code: [Select]
[LOG]
verbosity = debug

If it's crashing before the log file is created, could you also try setting the environment variable PYXLL_DEBUG_LOG=<filename, e.g. c:\temp\pyxll.log. That will enable pyxll to log what it's doing earlier when it's being loaded, which could help track down what's gone wrong. You will have to set the environment variable in your computer's settings, it's not enough to set it in the pyxll config file.

Best regards,
Tony

26
Help and Support / Re: Reloading causes failure of catching exceptions
« on: December 11, 2016, 06:02:11 PM »
Hi,

I have reproduced this incorrect behaviour and will release a fix as soon as possible.

Thanks for bringing this to my attention, and for your sample code demonstrating the problem.

Best regards,
Tony

27
Help and Support / Re: Reloading causes failure of catching exceptions
« on: December 08, 2016, 12:19:48 PM »
Hi,

reloading can be tricky. If you change your project structure after first starting Excel that can mess things up as the dependencies that were discovered previously (and are used for deep reloading) may now be invalid.

If you start Excel and modify code, deep reloading *should* work; if you change the imports or package structure you may need to restart.

If you change the log level to "debug" it will give more information about the order in which the modules are being reloaded. If the c_exception module is being reloaded *after* b.py then I think that would explain what you're seeing. Could have a look and see if that is the case please?

The example you've given looks like it should work to me, and so it seems likely that it's be problem with the deep reloading feature. If you could just confirm that it's not a problem due to the package structure changing after Excel has started then I will try and reproduce the problem using your well explained test case.

Best regards,
Tony

28
Help and Support / Re: Is auto_resize in xl_func async?
« on: December 07, 2016, 09:28:31 AM »
Hi,

yes, that is the expected behaviour. The resize happens on the main thread, after the calculation has completed.

Try calling the VBA function 'DoEvents' between those two lines. That should allow the resizing to happen before your second line.

https://msdn.microsoft.com/en-us/library/office/gg264522.aspx

Best regards,
Tony

29
News / Version 3.1.1 Released
« on: December 06, 2016, 12:23:30 PM »
Patch release

  • Fix problem when recalculating from a ribbon function.
  • The deep reload feature no longer tries to reload standard modules or those with c extensions.
  • Fix xl_app to work with xlwings 0.10.0.


30
Help and Support / Re: Problem with 3.1.0
« on: December 05, 2016, 07:05:04 PM »
Hi Janson,

I've released 3.3.1, which includes these changes to exclude the standard python modules and c extensions when doing a deep reload.

You can see the list of changes in this new release here:
https://www.pyxll.com/changelog.html

I also documented the deep_reload_include and deep_reload_exclude options here:
https://www.pyxll.com/docs/userguide/config.html#pyxll-settings

Please let me know if you have any more problems.

Best regards,
Tony

Pages: 1 [2] 3 4 ... 37