Code Monkey home page Code Monkey logo

Comments (7)

timxx avatar timxx commented on July 18, 2024

官方的c++ sdk就是这样子的,内部估计是有个静态变量,只能用一次

from pywpsrpc.

guohailin0323 avatar guohailin0323 commented on July 18, 2024

官方的c++ sdk就是这样子的,内部估计是有个静态变量,只能用一次

即使有静态变量,强杀进程后,也不存在了。
再次调用接口createEtRpcInstance、getEtApplication返回是新对象才对,返回老的理解不了。
除非强杀进程时,少杀进程了。

from pywpsrpc.

timxx avatar timxx commented on July 18, 2024

官方的c++ sdk就是这样子的,内部估计是有个静态变量,只能用一次

即使有静态变量,强杀进程后,也不存在了。
再次调用接口createEtRpcInstance、getEtApplication返回是新对象才对,返回老的理解不了。
除非强杀进程时,少杀进程了。

变量是在sdk模块的吧,这个不是wps进程加载的(python这边)
不过可以研究研究这个模块能不能卸载重新加载,估计不太好整,现在都是sip那边自动做的

from pywpsrpc.

mjTree avatar mjTree commented on July 18, 2024
   代码示例:
    hr, rpc_excel = createEtRpcInstance()
    hr, app_excel = rpc_excel.getEtApplication()
    
    # 强杀excel进程
    processName = "et"
    kill_process(processName)
    
    hr, rpc_excel1 = createEtRpcInstance()
    hr, app_excel2 = rpc_excel1.getEtApplication()
    # 返回的rpc_excel1、app_excel2还是老对象,下面这行代码必崩!!!!!!!
    app_excel2.Visible = False
    
    我猜测哪个地方有缓存
    
    
    问题二:
    createEtRpcInstance getEtApplication源码在哪里能看到
   
   【环境】 
    pywpsrpc:v2.3.9
   信创amd64
   wps:v11.1.0.11704

kill进程之后,需要把你的rpc_excel、app_excel对象回收后再去新建才行的

from pywpsrpc.

guohailin0323 avatar guohailin0323 commented on July 18, 2024
   代码示例:
    hr, rpc_excel = createEtRpcInstance()
    hr, app_excel = rpc_excel.getEtApplication()
    
    # 强杀excel进程
    processName = "et"
    kill_process(processName)
    
    hr, rpc_excel1 = createEtRpcInstance()
    hr, app_excel2 = rpc_excel1.getEtApplication()
    # 返回的rpc_excel1、app_excel2还是老对象,下面这行代码必崩!!!!!!!
    app_excel2.Visible = False
    
    我猜测哪个地方有缓存
    
    
    问题二:
    createEtRpcInstance getEtApplication源码在哪里能看到
   
   【环境】 
    pywpsrpc:v2.3.9
   信创amd64
   wps:v11.1.0.11704

kill进程之后,需要把你的rpc_excel、app_excel对象回收后再去新建才行的

试了下,是可以的

from pywpsrpc.

wenfer avatar wenfer commented on July 18, 2024

我之前也遇到过类似问题,del app_excel 后就行了

from pywpsrpc.

Teccivil avatar Teccivil commented on July 18, 2024
   代码示例:
    hr, rpc_excel = createEtRpcInstance()
    hr, app_excel = rpc_excel.getEtApplication()
    
    # 强杀excel进程
    processName = "et"
    kill_process(processName)
    
    hr, rpc_excel1 = createEtRpcInstance()
    hr, app_excel2 = rpc_excel1.getEtApplication()
    # 返回的rpc_excel1、app_excel2还是老对象,下面这行代码必崩!!!!!!!
    app_excel2.Visible = False
    
    我猜测哪个地方有缓存
    
    
    问题二:
    createEtRpcInstance getEtApplication源码在哪里能看到
   
   【环境】 
    pywpsrpc:v2.3.9
   信创amd64
   wps:v11.1.0.11704

kill进程之后,需要把你的rpc_excel、app_excel对象回收后再去新建才行的

试了下,是可以的

请问一下是用什么方式进行的回收,del吗?

from pywpsrpc.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.