RunestoneInteractive / RunestoneServer

Interactive books for computer science and mathematics
http://runestoneinteractive.org
Other
575 stars 503 forks source link

lintAfterSave hanging on some code; leaving dead processes that eventually make server stop responding #559

Closed presnick closed 5 years ago

presnick commented 9 years ago

lintAfterSave is hanging, but only on some code. It is called in ajax/runlog each time the user runs some code. When enough of the processes are left hanging, the server stops responding to all web requests.

I hadn't noticed the problem before, but it's happening when we run the code that defines very nested dictionaries, in runestone/static/pip2/NestedData/DebuggingNestedData.html

There may be something wrong with that code (though it runs fine). pylint shouldn't hang, though.

Is there something special I need in my pylintrc file? Or something else about my server configuration that could cause this problem?

For now, I have commented out the call to lintAfterSave. The Code Coach hasn't been working on my site anyway, so that isn't a great loss. Perhaps all will be solved once I get this figured out and I will have Code Coach available for my students as well.

bnmnetp commented 9 years ago

Have you tried to run pylint from the command line on any of the code that is causing the hang? Does it generate an excessive amount of output?

What else about code coach has not been working for you?

presnick commented 9 years ago

After running ps, here's an example of a process that didn't complete: /usr/bin/python /usr/local/bin/pylint /tmp/13564:de069ad8-f39d-448d-a1e4-fb0a8d5eecfbextract_nested_data_1.py --msg-template={C}: {symbol}: {msg_id}:{line:3d},{column}: {obj}: {msg} --reports=n --rcfile=/home/www-data/web2py/applications/runestone/pylintrc

I tried running that command directly from the command line and it does return. Below I have pasted in the contents of extract_nested_data_1.py, then the output from running it from the command line, and then the contents of my pylintrc file

----------output from pylint--------------

***** Module {symbol}: F: ***** Module {msg_id}:{line:3d},{column}: F: ***** Module {obj}: F: ***** Module {msg} F: ***** Module 13564:de069ad8-f39d-448d-a1e4-fb0a8d5eecfbextract_nested_data_1 C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: C: W: W:

----------------------------contents of .py file, basically just a big dictionary literal, some twitter data---------

res = { "search_metadata": { "count": 3, "completed_in": 0.015, "max_id_str": "536624519285583872", "since_id_str": "0", "next_results": "?max_id=536623674942439424&q=University%20of%20Michigan&count=3&include_entities=1", "refresh_url": "?since_id=536624519285583872&q=University%20of%20Michigan&include_entities=1", "since_id": 0, "query": "University+of+Michigan", "max_id": 536624519285583872 }, "statuses": [ { "contributors": None, "truncated": False, "text": "RT @mikeweber25: I'm decommiting from the university of Michigan thank you Michigan for the love and support I'll remake my decision at the\u2026", "in_reply_to_status_id": None, "id": 536624519285583872, "favorite_count": 0, "source": "<a href=\"http://twitter.com/download/iphone\" rel=\"nofollow\">Twitter for iPhone", "retweeted": False, "coordinates": None, "entities": { "symbols": [], "user_mentions": [ { "id": 1119996684, "indices": [ 3, 15 ], "id_str": "1119996684", "screen_name": "mikeweber25", "name": "Mikey" } ], "hashtags": [], "urls": [] }, "in_reply_to_screen_name": None, "in_reply_to_user_id": None, "retweet_count": 2014, "id_str": "536624519285583872", "favorited": False, "retweeted_status": { "contributors": None, "truncated": False, "text": "I'm decommiting from the university of Michigan thank you Michigan for the love and support I'll remake my decision at the army bowl", "in_reply_to_status_id": None, "id": 536300265616322560, "favorite_count": 1583, "source": "<a href=\"http://twitter.com/download/iphone\" rel=\"nofollow\">Twitter for iPhone", "retweeted": False, "coordinates": None, "entities": { "symbols": [], "user_mentions": [], "hashtags": [], "urls": [] }, "in_reply_to_screen_name": None, "in_reply_to_user_id": None, "retweet_count": 2014, "id_str": "536300265616322560", "favorited": False, "user": { "follow_request_sent": False, "profile_use_background_image": True, "profile_text_color": "666666", "default_profile_image": False, "id": 1119996684, "profile_background_image_url_https": "https://abs.twimg.com/images/themes/theme9/bg.gif", "verified": False, "profile_location": None, "profile_image_url_https": "https://pbs.twimg.com/profile_images/534465900343083008/A09dIq1d_normal.jpeg", "profile_sidebar_fill_color": "252429", "entities": { "description": { "urls": [] } }, "followers_count": 5444, "profile_sidebar_border_color": "FFFFFF", "id_str": "1119996684", "profile_background_color": "C0DEED", "listed_count": 36, "is_translation_enabled": False, "utc_offset": None, "statuses_count": 6525, "description": "Mike Weber (U.S Army All American) DETROIT CTSENIOR State Champion", "friends_count": 693, "location": "", "profile_link_color": "0084B4", "profile_image_url": "http://pbs.twimg.com/profile_images/534465900343083008/A09dIq1d_normal.jpeg", "following": False, "geo_enabled": False, "profile_banner_url": "https://pbs.twimg.com/profile_banners/1119996684/1416261575", "profile_background_image_url": "http://abs.twimg.com/images/themes/theme9/bg.gif", "name": "Mikey", "lang": "en", "profile_background_tile": False, "favourites_count": 1401, "screen_name": "mikeweber25", "notifications": False, "url": None, "created_at": "Fri Jan 25 18:45:53 +0000 2013", "contributors_enabled": False, "time_zone": None, "protected": False, "default_profile": False, "is_translator": False }, "geo": None, "in_reply_to_user_id_str": None, "lang": "en", "created_at": "Sat Nov 22 23:28:41 +0000 2014", "in_reply_to_status_id_str": None, "place": None, "metadata": { "iso_language_code": "en", "result_type": "recent" } }, "user": { "follow_request_sent": False, "profile_use_background_image": True, "profile_text_color": "333333", "default_profile_image": False, "id": 2435537208, "profile_background_image_url_https": "https://abs.twimg.com/images/themes/theme1/bg.png", "verified": False, "profile_location": None, "profile_image_url_https": "https://pbs.twimg.com/profile_images/532694075947110400/oZEP5XNQ_normal.jpeg", "profile_sidebar_fill_color": "DDEEF6", "entities": { "description": { "urls": [] } }, "followers_count": 161, "profile_sidebar_border_color": "C0DEED", "id_str": "2435537208", "profile_background_color": "C0DEED", "listed_count": 0, "is_translation_enabled": False, "utc_offset": None, "statuses_count": 524, "description": "Delasalle '17 Baseball & Football.", "friends_count": 255, "location": "", "profile_link_color": "0084B4", "profile_image_url": "http://pbs.twimg.com/profile_images/532694075947110400/oZEP5XNQ_normal.jpeg", "following": False, "geo_enabled": False, "profile_banner_url": "https://pbs.twimg.com/profile_banners/2435537208/1406779364", "profile_background_image_url": "http://abs.twimg.com/images/themes/theme1/bg.png", "name": "Andrew Brooks", "lang": "en", "profile_background_tile": False, "favourites_count": 555, "screenname": "31brooks", "notifications": False, "url": None, "created_at": "Wed Apr 09 14:34:41 +0000 2014", "contributors_enabled": False, "time_zone": None, "protected": False, "default_profile": True, "is_translator": False }, "geo": None, "in_reply_to_user_id_str": None, "lang": "en", "created_at": "Sun Nov 23 20:57:10 +0000 2014", "in_reply_to_status_id_str": None, "place": None, "metadata": { "iso_language_code": "en", "result_type": "recent" } }, { "contributors": None, "truncated": False, "text": "RT @Plantedd: The University of Michigan moved a big Bur Oak yesterday. 65ft tall. 350+ tons. http://t.co/v2Y6vl3f9e", "in_reply_to_status_id": None, "id": 536624216305848320, "favorite_count": 0, "source": "<a href=\"http://tapbots.com/tweetbot\" rel=\"nofollow\">Tweetbot for i\u039fS", "retweeted": False, "coordinates": None, "entities": { "symbols": [], "user_mentions": [ { "id": 462890283, "indices": [ 3, 12 ], "id_str": "462890283", "screen_name": "Plantedd", "name": "David Wong" } ], "hashtags": [], "urls": [], "media": [ { "source_status_id_str": "526276522374889472", "expanded_url": "http://twitter.com/Plantedd/status/526276522374889472/photo/1", "display_url": "pic.twitter.com/v2Y6vl3f9e", "url": "http://t.co/v2Y6vl3f9e", "media_url_https": "https://pbs.twimg.com/media/B021tLsIYAADq21.jpg", "source_status_id": 526276522374889472, "id_str": "526276519308845056", "sizes": { "small": { "h": 191, "resize": "fit", "w": 340 }, "large": { "h": 576, "resize": "fit", "w": 1024 }, "medium": { "h": 337, "resize": "fit", "w": 600 }, "thumb": { "h": 150, "resize": "crop", "w": 150 } }, "indices": [ 94, 116 ], "type": "photo", "id": 526276519308845056, "media_url": "http://pbs.twimg.com/media/B021tLsIYAADq21.jpg" } ] }, "in_reply_to_screen_name": None, "in_reply_to_user_id": None, "retweet_count": 27, "id_str": "536624216305848320", "favorited": False, "retweeted_status": { "contributors": None, "truncated": False, "text": "The University of Michigan moved a big Bur Oak yesterday. 65ft tall. 350+ tons. http://t.co/v2Y6vl3f9e", "in_reply_to_status_id": None, "id": 526276522374889472, "favorite_count": 25, "source": "<a href=\"http://twitter.com/download/iphone\" rel=\"nofollow\">Twitter for iPhone", "retweeted": False, "coordinates": None, "entities": { "symbols": [], "user_mentions": [], "hashtags": [], "urls": [], "media": [ { "expanded_url": "http://twitter.com/Plantedd/status/526276522374889472/photo/1", "display_url": "pic.twitter.com/v2Y6vl3f9e", "url": "http://t.co/v2Y6vl3f9e", "media_url_https": "https://pbs.twimg.com/media/B021tLsIYAADq21.jpg", "id_str": "526276519308845056", "sizes": { "small": { "h": 191, "resize": "fit", "w": 340 }, "large": { "h": 576, "resize": "fit", "w": 1024 }, "medium": { "h": 337, "resize": "fit", "w": 600 }, "thumb": { "h": 150, "resize": "crop", "w": 150 } }, "indices": [ 80, 102 ], "type": "photo", "id": 526276519308845056, "media_url": "http://pbs.twimg.com/media/B021tLsIYAADq21.jpg" } ] }, "in_reply_to_screen_name": None, "in_reply_to_user_id": None, "retweet_count": 27, "id_str": "526276522374889472", "favorited": False, "user": { "follow_request_sent": False, "profile_use_background_image": True, "profile_text_color": "333333", "default_profile_image": False, "id": 462890283, "profile_background_image_url_https": "https://abs.twimg.com/images/themes/theme1/bg.png", "verified": False, "profile_location": None, "profile_image_url_https": "https://pbs.twimg.com/profile_images/1791926707/Plantedd_Logo__square__normal.jpg", "profile_sidebar_fill_color": "DDEEF6", "entities": { "url": { "urls": [ { "url": "http://t.co/ZOnsCHvoKt", "indices": [ 0, 22 ], "expanded_url": "http://www.plantedd.com", "display_url": "plantedd.com" } ] }, "description": { "urls": [] } }, "followers_count": 2598, "profile_sidebar_border_color": "C0DEED", "id_str": "462890283", "profile_background_color": "C0DEED", "listed_count": 61, "is_translation_enabled": False, "utc_offset": 0, "statuses_count": 8157, "description": "Hello, I'm the supervillain behind Plantedd. We're an online market for plant lovers plotting to take over the world by making it simple to find and buy plants.", "friends_count": 2664, "location": "UK", "profile_link_color": "0084B4", "profile_image_url": "http://pbs.twimg.com/profile_images/1791926707/Plantedd_Logo__square__normal.jpg", "following": False, "geo_enabled": False, "profile_banner_url": "https://pbs.twimg.com/profile_banners/462890283/1398254314", "profile_background_image_url": "http://abs.twimg.com/images/themes/theme1/bg.png", "name": "David Wong", "lang": "en", "profile_background_tile": False, "favourites_count": 371, "screen_name": "Plantedd", "notifications": False, "url": "http://t.co/ZOnsCHvoKt", "created_at": "Fri Jan 13 13:46:46 +0000 2012", "contributors_enabled": False, "time_zone": "Edinburgh", "protected": False, "default_profile": True, "is_translator": False }, "geo": None, "in_reply_to_user_id_str": None, "possibly_sensitive": False, "lang": "en", "created_at": "Sun Oct 26 07:37:55 +0000 2014", "in_reply_to_status_id_str": None, "place": None, "metadata": { "iso_language_code": "en", "result_type": "recent" } }, "user": { "follow_request_sent": False, "profile_use_background_image": True, "profile_text_color": "2A48AE", "default_profile_image": False, "id": 104940733, "profile_background_image_url_https": "https://abs.twimg.com/images/themes/theme17/bg.gif", "verified": False, "profile_location": None, "profile_image_url_https": "https://pbs.twimg.com/profile_images/2878477539/78e20432088b5ee2addc9ce3362fd461_normal.jpeg", "profile_sidebar_fill_color": "6378B1", "entities": { "description": { "urls": [] } }, "followers_count": 149, "profile_sidebar_border_color": "FBD0C9", "id_str": "104940733", "profile_background_color": "0C003D", "listed_count": 18, "is_translation_enabled": False, "utc_offset": 0, "statuses_count": 16031, "description": "Have you any dreams yo'd like to sell?", "friends_count": 248, "location": "", "profile_link_color": "0F1B7C", "profile_image_url": "http://pbs.twimg.com/profile_images/2878477539/78e20432088b5ee2addc9ce3362fd461_normal.jpeg", "following": False, "geo_enabled": False, "profile_banner_url": "https://pbs.twimg.com/profile_banners/104940733/1410032966", "profile_background_image_url": "http://abs.twimg.com/images/themes/theme17/bg.gif", "name": "Heather", "lang": "en", "profile_background_tile": False, "favourites_count": 777, "screen_name": "froyoho", "notifications": False, "url": None, "created_at": "Thu Jan 14 21:37:54 +0000 2010", "contributors_enabled": False, "time_zone": "London", "protected": False, "default_profile": False, "is_translator": False }, "geo": None, "in_reply_to_user_id_str": None, "possibly_sensitive": False, "lang": "en", "created_at": "Sun Nov 23 20:55:57 +0000 2014", "in_reply_to_status_id_str": None, "place": None, "metadata": { "iso_language_code": "en", "result_type": "recent" } }, { "contributors": None, "truncated": False, "text": "RT @NotableHistory: Madonna, 18 year old freshman at the University of Michigan, 1976 http://t.co/x2dm1G67ea", "in_reply_to_status_id": None, "id": 536623674942439425, "favorite_count": 0, "source": "<a href=\"http://twitter.com/download/android\" rel=\"nofollow\">Twitter for Android", "retweeted": False, "coordinates": None, "entities": { "symbols": [], "user_mentions": [ { "id": 844766941, "indices": [ 3, 18 ], "id_str": "844766941", "screen_name": "NotableHistory", "name": "OnThisDay & Facts" } ], "hashtags": [], "urls": [], "media": [ { "source_status_id_str": "536610190334779392", "expanded_url": "http://twitter.com/NotableHistory/status/536610190334779392/photo/1", "display_url": "pic.twitter.com/x2dm1G67ea", "url": "http://t.co/x2dm1G67ea", "media_url_https": "https://pbs.twimg.com/media/B3EXbQkCMAEipwM.jpg", "source_status_id": 536610190334779392, "id_str": "536235587703812097", "sizes": { "small": { "h": 487, "resize": "fit", "w": 340 }, "large": { "h": 918, "resize": "fit", "w": 640 }, "medium": { "h": 860, "resize": "fit", "w": 600 }, "thumb": { "h": 150, "resize": "crop", "w": 150 } }, "indices": [ 86, 108 ], "type": "photo", "id": 536235587703812097, "media_url": "http://pbs.twimg.com/media/B3EXbQkCMAEipwM.jpg" } ] }, "in_reply_to_screen_name": None, "in_reply_to_user_id": None, "retweet_count": 9, "id_str": "536623674942439425", "favorited": False, "retweeted_status": { "contributors": None, "truncated": False, "text": "Madonna, 18 year old freshman at the University of Michigan, 1976 http://t.co/x2dm1G67ea", "in_reply_to_status_id": None, "id": 536610190334779392, "favorite_count": 13, "source": "<a href=\"https://ads.twitter.com\" rel=\"nofollow\">Twitter Ads", "retweeted": False, "coordinates": None, "entities": { "symbols": [], "user_mentions": [], "hashtags": [], "urls": [], "media": [ { "expanded_url": "http://twitter.com/NotableHistory/status/536610190334779392/photo/1", "display_url": "pic.twitter.com/x2dm1G67ea", "url": "http://t.co/x2dm1G67ea", "media_url_https": "https://pbs.twimg.com/media/B3EXbQkCMAEipwM.jpg", "id_str": "536235587703812097", "sizes": { "small": { "h": 487, "resize": "fit", "w": 340 }, "large": { "h": 918, "resize": "fit", "w": 640 }, "medium": { "h": 860, "resize": "fit", "w": 600 }, "thumb": { "h": 150, "resize": "crop", "w": 150 } }, "indices": [ 66, 88 ], "type": "photo", "id": 536235587703812097, "media_url": "http://pbs.twimg.com/media/B3EXbQkCMAEipwM.jpg" } ] }, "in_reply_to_screen_name": None, "in_reply_to_user_id": None, "retweet_count": 9, "id_str": "536610190334779392", "favorited": False, "user": { "follow_request_sent": False, "profile_use_background_image": True, "profile_text_color": "333333", "default_profile_image": False, "id": 844766941, "profile_background_image_url_https": "https://pbs.twimg.com/profile_background_images/458461302696837121/rGlGdWsc.png", "verified": False, "profile_location": None, "profile_image_url_https": "https://pbs.twimg.com/profile_images/481243404320251905/gCr1cVP2_normal.png", "profile_sidebar_fill_color": "DDFFCC", "entities": { "url": { "urls": [ { "url": "http://t.co/9fTPk5A4wh", "indices": [ 0, 22 ], "expanded_url": "http://notablefacts.com/", "display_url": "notablefacts.com" } ] }, "description": { "urls": [] } }, "followers_count": 73817, "profile_sidebar_border_color": "FFFFFF", "id_str": "844766941", "profile_background_color": "9AE4E8", "listed_count": 485, "is_translation_enabled": False, "utc_offset": -21600, "statuses_count": 38841, "description": "On This Day in History, Historical Pictures & other Interesting Facts....Historyfollower@gmail.com", "friends_count": 43594, "location": "", "profile_link_color": "0084B4", "profile_image_url": "http://pbs.twimg.com/profile_images/481243404320251905/gCr1cVP2_normal.png", "following": False, "geo_enabled": False, "profile_banner_url": "https://pbs.twimg.com/profile_banners/844766941/1411076349", "profile_background_image_url": "http://pbs.twimg.com/profile_background_images/458461302696837121/rGlGdWsc.png", "name": "OnThisDay & Facts", "lang": "en", "profile_background_tile": True, "favourites_count": 1383, "screen_name": "NotableHistory", "notifications": False, "url": "http://t.co/9fTPk5A4wh", "created_at": "Tue Sep 25 03:08:59 +0000 2012", "contributors_enabled": False, "time_zone": "Central Time (US & Canada)", "protected": False, "default_profile": False, "is_translator": False }, "geo": None, "in_reply_to_user_id_str": None, "possibly_sensitive": False, "lang": "en", "created_at": "Sun Nov 23 20:00:13 +0000 2014", "in_reply_to_status_id_str": None, "place": None, "metadata": { "iso_language_code": "en", "result_type": "recent" } }, "user": { "follow_request_sent": False, "profile_use_background_image": True, "profile_text_color": "333333", "default_profile_image": False, "id": 818185729, "profile_background_image_url_https": "https://abs.twimg.com/images/themes/theme1/bg.png", "verified": False, "profile_location": None, "profile_image_url_https": "https://pbs.twimg.com/profile_images/486215801498640384/rz9o7LnF_normal.jpeg", "profile_sidebar_fill_color": "DDEEF6", "entities": { "description": { "urls": [] } }, "followers_count": 302, "profile_sidebar_border_color": "C0DEED", "id_str": "818185729", "profile_background_color": "C0DEED", "listed_count": 0, "is_translation_enabled": False, "utc_offset": None, "statuses_count": 395, "description": "Formerly with California Dept of General Services, now freelancing around the Sacramento area...", "friends_count": 1521, "location": "Citrus Heights, CA", "profile_link_color": "0084B4", "profile_image_url": "http://pbs.twimg.com/profile_images/486215801498640384/rz9o7LnF_normal.jpeg", "following": False, "geo_enabled": True, "profile_banner_url": "https://pbs.twimg.com/profile_banners/818185729/1383764759", "profile_background_image_url": "http://abs.twimg.com/images/themes/theme1/bg.png", "name": "M Duncan", "lang": "en", "profile_background_tile": False, "favourites_count": 6544, "screen_name": "MDuncan95814", "notifications": False, "url": None, "created_at": "Tue Sep 11 21:02:09 +0000 2012", "contributors_enabled": False, "time_zone": None, "protected": False, "default_profile": True, "is_translator": False }, "geo": None, "in_reply_to_user_id_str": None, "possibly_sensitive": False, "lang": "en", "created_at": "Sun Nov 23 20:53:48 +0000 2014", "in_reply_to_status_id_str": None, "place": None, "metadata": { "iso_language_code": "en", "result_type": "recent" } } ] }

----------------------------the pylintrc file-------------------

This pylintrc file will use the default settings except for the

naming conventions, which will allow for camel case naming as found

in Java code or several libraries such as PyQt, etc.

[BASIC]

Regular expression which should only match correct module names

module-rgx=(([a-z][a-z0-9]*)|([A-Z][a-zA-Z0-9]+))$

Regular expression which should only match correct class names

class-rgx=[A-Z][a-zA-Z0-9]+$

Regular expression which should only match correct function names

function-rgx=[a-z_][a-zA-Z0-9]*$

Regular expression which should only match correct method names

method-rgx=[a-z_][a-zA-Z0-9]*$

Regular expression which should only match correct argument names

argument-rgx=[a-z][a-zA-Z0-9]*$

Regular expression which should only match correct variable names

variable-rgx=[a-z][a-zA-Z0-9]*$

Regular expression matching correct constant names

const-rgx=(([a-zA-Z][a-zA-Z0-9])|(.))$

[MESSAGES CONTROL]

disable=C0103,C0111,C0325

[General] init-hook='import sys; sys.path.append("site-packages")'

presnick commented 9 years ago

Symptoms of Code Coach not working:

It shows a canvas for the code coach, but it's blank. Chrome debugger console shows four errors. 3 missing files: -- static/overview/_static/diff_match_patch.js -- static/overview/_static/merge.css -- static/overview/_static/merge.js One other error: diffviewer?divid=ex_opt_params_1:99 Uncaught TypeError: undefined is not a function

Seems to be somewhere in here...

.function displayCoachData () { var value, orig1, orig2, dv, hilight= true; var target = document.getElementById("diffviewer"); orig1 = diffdata.code[diffcount-1]; value = orig1; orig2 = diffdata.code[diffcount]; panes = 2; target.innerHTML = ""; dv = CodeMirror.MergeView(target, { value: value, origLeft: panes == 3 ? orig1 : null, orig: orig2, lineNumbers: true, mode: "python", highlightDifferences: hilight });

bnmnetp commented 9 years ago

Ugh. Those files should not be under overview/_static I think I threw them in there during some hack session and that is where they stayed. Probably if you built overview that would fix it for the short term. If not, I should fix it the right way.

bnmnetp commented 9 years ago

On the other hand, it looks like your views/diffviewer.html is different from mine. Mine actually loads the three missing files from the correct place. Also you should verify that you have them in common/{js,css}

presnick commented 9 years ago

We have replicated this problem on a new server, so it seems to be a real problem, probably a bug in how we invoke pylint or the pylintrc. Or maybe it's a problem with longer-running lint that the ajax call has ended and isn't receiving response data from pylint?

Perhaps the solution is to run it using scheduler instead?

For now, we have hacked our server to kill the task if it runs for more than 5 seconds. We did that by renaming original pylint to pylint.real, then making the pylint file be as follows...

!/bin/bash

timeout 5 /usr/local/bin/pylint.real "$@"presnick@resnick-runestone1:/usr/local/bin$