Search Results

Search found 186 results on 8 pages for 'michal burak'.

Page 6/8 | < Previous Page | 2 3 4 5 6 7 8  | Next Page >

  • How to set timeout with python-mechanize?

    - by Michal Cihar
    I'm using python-mechanize to scrape some web sites, which sometime simply don't respond to requests and these requests stay open too long, so I need to limit timeout for these requests. While using urlopen method, the timeout can be set using timeout parameter, but I have not found easy way for doing it with high level API such as submit or click methods. Ideally the timeout would be set just once for whole browser class and all calls would honor that. It would be probably possible to customize this by passing custom request_class to every click and submit call, but this would just pollute the code, so I'm looking for nicer solution for setting timeout for mechanize's browser class (and no, I don't want to change default socket timeout using socket.setdefaulttimeout).

    Read the article

  • Hessian on Windows Phone 7/ Silverlight ??

    - by Michal
    Hi, I'm using hessian protocol for communication betwee server (java) and various client applications. Now I started to develop Windows Phone 7 client. I downloaded hessian C# implementation but it does not compile for windows phone 7/silverlight. Does anyone managed to make it work on WP7/Silverlight? It's looks like there is many thing to be done/changed to make it work, which I'd like to avoid if it has been done by someone already. Thanks.

    Read the article

  • Caching generated QR Code

    - by Michal K
    I use zxing to encode a qr code and store it as a bitmap and then show it in ImageView. Since the image generation time is significant I'm planning to move it to a separate thread (AsyncTaskLoader will be fine I think). The problem is - it's an image and I know that to avoid memory leaks one should never store a strong reference to it in an Activity. So how would you do it? How to cache an image to survive config changes (phone rotation) and generally avoid generating it onCreate()? Just point me in the right direction, please.

    Read the article

  • How to transform SoapFault to SoapMessage via Interceptor in CXF?

    - by Michal Mech
    I have web-service created and configured via Spring and CXF. See beans below: <?xml version="1.0" encoding="UTF-8"?> <beans <!-- ommited -->> <import resource="classpath:META-INF/cxf/cxf.xml" /> <import resource="classpath:META-INF/cxf/cxf-extension-soap.xml" /> <import resource="classpath:META-INF/cxf/cxf-servlet.xml" /> <bean id="internalActService" class="package.InternalActServiceImpl" /> <jaxws:endpoint implementor="#internalActService" address="/InternalActService"> <jaxws:properties> <entry key="schema-validation-enabled" value="true" /> </jaxws:properties> <jaxws:outFaultInterceptors> <bean class="package.InternalActServiceFaultOutInterceptor" /> </jaxws:outFaultInterceptors> </jaxws:endpoint> </beans> As can you see I added schema validation to my web service. But CXF throws SoapFault when request is not corresponding with schema. I want to send to the client SoapMessage instead of SoapFault, that's why I added outFaultInterceptors. My question is how to transform SoapFault to SoapMessage? I've made few tries but I don't know how to implement outFaultInterceptor.

    Read the article

  • Facebooker Session is not created when config.cache_classes = true

    - by Michal
    I am using Facebooker (along with devise & devise_facebook_connectable). The problem is that user can't sign in with Facebook Connect in production environment unless I set config.cache_classes to false (which I don't want to do in production obviously). When cache_classes = true, Facebooker::Session.current is nil. Trying to set it manually creates other problems, so I assume it's not the solution. Using Rails 2.3.8 (tried on 2.3.5 too) and Facebooker 1.0.70 (tries on 1.0.69 too) and passenger 2.2.11. Any hints?

    Read the article

  • Make Sphinx generate RST class documentation from pydoc

    - by Michal Cihar
    I'm currently migrating all existing (incomplete) documentation to Sphinx. The problem is that the documentation uses Python docstrings (the module is written in C, but it probably does not matter) and the class documentation must be converted into a form usable for Sphinx. There is sphinx.ext.autodoc, but it automatically puts current docstrings to the document. I want to generate source (RST) file based on current docstrings, which I could edit and improve manually. How would you transform docstrings into RST for Sphinx?

    Read the article

  • SQL GROUP BY - also SELECT not-constant columns

    - by Michal Kosek
    can someone please help me with this query? I have 2 tables in my database: log_visitors: -------------------- id | host_id log_access: -------------------- visitor | document | timestamp "log_access.visitor" links to "log_visitors.id" Currently, I'm using this query: SELECT log_visitors.host_id , MIM(log_access.timestamp) AS min_timestamp FROM log_access INNER JOIN log_visitors ON (log_access.visitor = log_visitors.id) GROUP BY log_visitors.host_id; to get "MIN(timestamp)" for each "host_id" in the database. HERE'S MY QUESTION: I also need to get "document" for that access with that timestamp... I can't simply add "log_access.document" into SELECT list, since it's not constant and I am not grouping by document... Any ideas?

    Read the article

  • Scala on the CLR

    - by Michal Bendowski
    The Scala homepage says that Scala 1.4 was runnable on the .NET framework - what is the status of Scala on the CLR now? Is anyone working on it? I think it would make a great GUI tool combined with GTK# and Mono...

    Read the article

  • Make Sphinx generate me rst for class documentation from pydoc

    - by Michal Cihar
    I'm currently in process of migrating existing (non complete) documentation to Sphinx. The final goal is to have all documentation in Sphinx. The problem I'm facing right now is that I have some documentation using Python docstrings (well the module is actually written in C, but it probably does not matter) and I would like to generate class documentation in form usable for Sphinx from these docstrings. I know there is sphinx.ext.autodoc, but it automatically puts current docstrings to the document. I rather want to generate source (rst) file based on current docstrings, which I could edit and improve manually. So is there some way to turn existing docstrings into rst form which Sphinx consumes?

    Read the article

  • What are the virtues of using XML comments in .NET?

    - by Michal Czardybon
    I can't understand the virtues of using XML comments. I know they can be converted into nice documentation external to the code, but the same can be achieved with the much more concise DOxygen syntax. In my opinion the XML comments are wrong, because: They obfuscate the comments and the code in general. (They are more difficult to read by humans). Less code can be viewed on a single screen, because "summary" and "/summary" take additional lines. They suggest that all method parameters have to be commented, whereas 90% of them are obvious and SHOULD be left not commented. The only problem I have with this is that my point of view seems to be in minority. Why?

    Read the article

  • How to organize makefiles / solutions etc. in multiplatform projects?

    - by Michal Czardybon
    I have a project which can be compiled with Visual Studio, GCC and with some embedded compilers. Sources are shared, but each platform requires separate makefiles, project files, solutions etc. There are two ways I can organize them: Intermixed in a single hierarchy of folders With separate folders for platform-dependent files The first solution creates some confusion about which file belongs to which platform, but the second causes some repetition of the folders structure (some compilers require each project to have a separate folder). Which do you think is better?

    Read the article

  • Problem with displaying graphs on a Qt canvas

    - by Michal Nowotka
    Let's say I'm a Qt newbie. I want a good Qt library for displaying simple graphs. I've found the quanava library. But there is a problem. When I compiled a basic example it looks like graph edges are not painted properly when moving nodes. I don't have any idea where is a bug but this code seems to be rather simple. I think this is a problem with paint method in NodeItem class. Maybe someone has already solved this problem because this library is quite popular.

    Read the article

  • Changing the color of dot depending from value on Morris js graph

    - by Michal Lipa
    Im rendering graph by morris js. Im using data from mysql database by JSON. Everything works fine, but I would like to add one more feature to the graph. (change dot color if there is something in buy action). My JSON: [{"longdate":"2014-08-20 18:20:01","price":"1620","action":"buy"},{"longdate":"2014-08-20 18:40:01","price":"1640","action":""},{"longdate":"2014-08-20 19:00:01","price":"1620","action":""}] So I would like to change dot color for values with buy action. My code for graph: $.getJSON('results.json', function(day_data) { Morris.Line({ element: 'graph', data: day_data, xkey: 'longdate', ykeys: ['price'], labels: ['Cena'], lineColors: lineColor, pointSize: 0, hoverCallback: function(index, options, content) { var date = "<b><font color='black'>Data: "+day_data[index]['longdate']+"</font></b><br>"; var param1 = "<font color='"+lineColor[0]+"'>Cena - "+day_data[index]['price']+"</font><br>"; return date+param1; }, xLabelFormat : function (x) { return changeDateFormat(x); } /*My TRIAL if(action == 'buy'){ pointSize: 4, lineColors: green, } */ }); }); So my code doesnt work, how can I make this working?

    Read the article

  • Do you know of a log4net appender which rolls on date, but let's you limit the total number of files

    - by Michal Drozdowicz
    Hi, I need to define an appender for log4net in a way that I get one log file for each day, but the total number of files are limited to, let's say, 30. That is I want to keep only the logs not older then 30 days, delete the older ones. I've tried doing it with RollingFileAppender, but it seems that specifying a limit of files to keep is not supported. Do you know of an alternative solution that I could use?

    Read the article

  • Linq Expression Trees in Compact Framework.

    - by Michal Drozdowicz
    The lack of expression trees in Compact Framework has bugged me for some time now, but I haven't really looked for a solution. Today, I've found a blog post about an alternative System.Linq.Expressions built on top of Mono System.Core and used e.g. by db4o (you can find it here). My question is - have you used this library and if so, what were your experiences with it (especially regarding performance)?

    Read the article

  • jsf icefaces basic problem with displaying value

    - by michal
    Hi All, I don't know what I'm doing wrong.I'm using icefaces and have basic controller: public class TestingController { private String name; public String submit() { setName("newName"); return null; } public void setName(String name) { this.name = name;} public String getName() { return name; } } --------and view: <ice:inputText id="inp" value="#{testController.name}" /> <br> <ice:commandButton id="submit" value="SUBMIT" action="#{testController.submit}" /> When I submit the form after first displaying the page..the input is set to newName, next I clear the inputText to "". and submit again but the name is not set to newName again as I would expect but it's empty. thank you in advance for you help.

    Read the article

  • jquery lightbox inline - without popup

    - by Michal
    i like jquery lightbox control looks nice and shows me a title one 1 of x images etc. I need exactly the same thing but without pop up. So whas is now visible after i click thumnail of image i want it to by visible as inline content somewhere on my page with first image loaded and then i could just use next prev. of course in this case, close would not be applicable. Does anybode know such a jquery plugin or how to change lightbox to work withoud popup? Thanks.

    Read the article

  • MapView without extending MapActivity

    - by Michal Dymel
    Is there a way to display a MapView without extending MapActivity? I have other Activity class which I'm extending and I would prefer not to change that... I've seen that you can inflate using MapActivity, but didn't find any spec/examples on how to do it.

    Read the article

  • Does "epsilon" really guarantees anything in floating-point computations?!

    - by Michal Czardybon
    To make the problem short let's say I want to compute expression: a / (b - c) on float's. To make sure the result is meaningful, I can check if 'b' and 'c' are inequal: float eps = std::numeric_limits<float>::epsilon(); if ((b - c) > EPS || (c - b) > EPS) { return a / (b - c); } but my tests show it is not enough to guarantee either meaningful results nor not failing to provide a result if it is possible. Case 1: a = 1.0f; b = 0.00000003f; c = 0.00000002f; Result: The if condition is NOT met, but the expression would produce a correct result 100000008 (as for the floats' precision). Case 2: a = 1e33f; b = 0.000003; c = 0.000002; Result: The if condition is met, but the expression produces not a meaningful result +1.#INF00. I found it much more reliable to check the result, not the arguments: const float INF = numeric_limits<float>::infinity(); float x = a / (b - c); if (-INF < x && x < INF) { return x; } But what for is the epsilon then and why is everyone saying epsilon is good to use?

    Read the article

  • getResourceAsStream not loading resource

    - by Michal Gorecki
    The project that I am currently working on utilizes an old application contained within a .jar file. One of the responsibilities of this application is that it updates the database when changes to the configuration files are made. Every time I try to run this file (which is a simple Ant Task extension), I get an exception thrown early in the process. I decompiled the Java file responsible, and found that the exception being thrown happens here. I do not know what the issue is, as "hibernate.cfg.xml" is contained within the same .jar file as the .class throwing the exception. ClassLoader loader = Thread.currentThread().getContextClassLoader(); InputStream in = loader.getResourceAsStream("hibernate.cfg.xml"); if (in == null) { throw new RuntimeException("Couldn't find built in hibernate config"); } If anyone has any ideas, even pointing me in the right direction, I would be grateful. Of course, any solution will have to be external, as the client already has this build of the program in production use.

    Read the article

  • named/bind zone file parser in C#

    - by Michal Rogozinski
    Hi, I'm looking for a bind/named zone file parser in .NET C#. If there is anything I could import/convert I would be interested too. Unfortunately there's not much, or I'm having troubles finding it. My goal is to make sure a zone file is syntax-errors-free before I push it to the server. I'd appreciate any help or hints. Thanks

    Read the article

  • When using SQL Compact on Windows Mobile, do you store the sdf file on a storage card?

    - by Michal Drozdowicz
    Having had some Sql Compact db corruption issues in the past and gone through the article on these, I got the idea that storing the database sdf file on a storage card significantly increases the risk of data loss due to db corruption. Do you store the sdf file on a storage card? Have you had any issues caused by it? What should I pay attention to when recommending a particular brand or model of an SD card wrt the stability and security for use with SQL Compact?

    Read the article

< Previous Page | 2 3 4 5 6 7 8  | Next Page >