Wall get 27 error

Ну никак не подружусь с Wall.Get #19

Comments

var user = vk.Users.Get(@»hzzzarium», ProfileFields.All);
long userID = user.Id;
var lsW = vk.Wall.Get(userID, out cou, 1, 0, WallFilter.Owner);
var user3=vk.Users.Get(@»svetka_v_baletkah», ProfileFields.All)
var lsW1 = vk.Wall.Get(user3.ID, out cou, 1, 0, WallFilter.Owner);
оба обращения выдают исключение
«Ссылка на объект не указывает на экземпляр объекта.»
т.е.сейчас просто не удается получить вообще никакие записи со стены((
VkNet 1.0.4 установил NuGet-ом
Простите великодушно меня бестолкового — что я делаю не так.
Windows 7. VS 2012. NET Framework 4.5 (до 4.5.1 не обновлял пока)
Спасибо.

The text was updated successfully, but these errors were encountered:

Вечером постараюсь поправить.

Спасибо вам за такое терпение))

Чем больше ошибок вы найдете и занесете, тем лучше будет библиотека)
Так что спасибо вам!

Проверил ваш код, всё успешно разбирается, но есть небольшие уточнения.
Работающий код:

Здесь стоит дать небольшое пояснение. Метод Wall.Get возвращает коллекцию, в нашем случае единственную запись. И как мы видим на странице пользователя, эту запись опубликовала лично она. Поэтому у нас доступен текст сообщения ( Console.WriteLine(«Text: » + lsW[0].Text); ), а также там есть аудиозапись. Ее можно получить через свойство Attachment.Instance приведя этот объект к типу Audio как это сделано у нас. И уже потом получить свойства аудиозаписи, к примеру, ссылку для скачивания — Console.WriteLine(«MP3: » + ((Audio)lsW[0].Attachment.Instance).Url);

Второй случай немного более сложен. Здесь пользователь «репостнул» чужую заметку. В таком случае, она отображается не как заметка пользователя, а как репост (что, по-сути, правильно) и в этом случае нам нужно проверить свойство CopyHistory , если количество элементов в нём больше нуля, значит пользователь взял эту запись у кого-то другого. И доступ к ней возможен через то же свойство CopyHistory . В нашем случае мы получаем текст репостного сообщения как Console.WriteLine(lsW1[0].CopyHistory[0].Text);

Если что-то непонятно и у вас возникли еще вопросы — спрашивайте)

Источник

setMouseCallback() causes «error: (-27:Null pointer) NULL window handler» in Python / on PyPi version 4.3.0.36 #17767

Comments

System information (version)
  • OpenCV => 4.3.0.36
  • Operating System / Platform => Ubuntu 18.04 64 Bit
  • Compiler => Unknown (installed from PyPi on Python 3.6.8)
Detailed description

This is a bug triggered on cv2.setMouseCallback and seemingly the QT backend, which reports the following error when running the code below:

cv2.error: OpenCV(4.3.0) /io/opencv/modules/highgui/src/window_QT.cpp:717: error: (-27:Null pointer) NULL window handler in function ‘cvSetMouseCallback’

When running the sample code below, this error occurs sometimes when running the code, while other times the code runs just fine. I also tried adding a time.sleep(1.0) , or cv2.imshow(«image», arr) , between the cv2.namedWindow and cv2.setMouseCallback calls, but it doesn’t seem to change the symptoms.

Читайте также:  1с предприятие ошибка загрузки метаданных windows 7

I believe that this is a specific problem with the PyPi version of OpenCV 4.3.0.36 . When I installed 4.2.0.34 instead, the symptom does not occur.

Steps to reproduce
Issue submission checklist
  • I report the issue, it’s not a question
  • I checked the problem with documentation, FAQ, open issues,
    answers.opencv.org, Stack Overflow, etc and have not found solution
  • I updated to latest OpenCV version and the issue is still there
  • There is reproducer code and related data files: videos, images, onnx, etc

The text was updated successfully, but these errors were encountered:

These packages are not official.
Try to reproduce problem with build from sources or at least provide dump of cv.getBuildInformation() for mentioned versions (use . in comment to wrap huge text blocks).

I’ll try to test from build when I get some spare time over the next few weekends. In the mean while:

Build info for BROKEN version — 4.3.0.36 :

General configuration for OpenCV 4.3.0 ===================================== Version control: 4.3.0

Platform:
Timestamp: 2020-07-06T00:08:47Z
Host: Linux 4.15.0-1028-gcp x86_64
CMake: 3.17.3
CMake generator: Unix Makefiles
CMake build tool: /bin/gmake
Configuration: Release

CPU/HW features:
Baseline: SSE SSE2 SSE3
requested: SSE3
Dispatched code generation: SSE4_1 SSE4_2 FP16 AVX AVX2 AVX512_SKX
requested: SSE4_1 SSE4_2 AVX FP16 AVX2 AVX512_SKX
SSE4_1 (14 files): + SSSE3 SSE4_1
SSE4_2 (1 files): + SSSE3 SSE4_1 POPCNT SSE4_2
FP16 (0 files): + SSSE3 SSE4_1 POPCNT SSE4_2 FP16 AVX
AVX (4 files): + SSSE3 SSE4_1 POPCNT SSE4_2 AVX
AVX2 (28 files): + SSSE3 SSE4_1 POPCNT SSE4_2 FP16 FMA3 AVX AVX2
AVX512_SKX (3 files): + SSSE3 SSE4_1 POPCNT SSE4_2 FP16 FMA3 AVX AVX2 AVX_512F AVX512_COMMON AVX512_SKX

C/C++:
Built as dynamic libs?: NO
C++ standard: 11
C++ Compiler: /usr/lib/ccache/compilers/c++ (ver 9.1.1)
C++ flags (Release): -Wl,-strip-all -fsigned-char -W -Wall -Werror=return-type -Werror=non-virtual-dtor -Werror=address -Werror=sequence-point -Wformat -Werror=format-security -Wmissing-declarations -Wundef -Winit-self -Wpointer-arith -Wshadow -Wsign-promo -Wuninitialized -Winit-self -Wsuggest-override -Wno-delete-non-virtual-dtor -Wno-comment -Wimplicit-fallthrough=3 -Wno-strict-overflow -fdiagnostics-show-option -Wno-long-long -pthread -fomit-frame-pointer -ffunction-sections -fdata-sections -msse -msse2 -msse3 -fvisibility=hidden -fvisibility-inlines-hidden -O3 -DNDEBUG -DNDEBUG
C++ flags (Debug): -Wl,-strip-all -fsigned-char -W -Wall -Werror=return-type -Werror=non-virtual-dtor -Werror=address -Werror=sequence-point -Wformat -Werror=format-security -Wmissing-declarations -Wundef -Winit-self -Wpointer-arith -Wshadow -Wsign-promo -Wuninitialized -Winit-self -Wsuggest-override -Wno-delete-non-virtual-dtor -Wno-comment -Wimplicit-fallthrough=3 -Wno-strict-overflow -fdiagnostics-show-option -Wno-long-long -pthread -fomit-frame-pointer -ffunction-sections -fdata-sections -msse -msse2 -msse3 -fvisibility=hidden -fvisibility-inlines-hidden -g -O0 -DDEBUG -D_DEBUG
C Compiler: /usr/lib/ccache/compilers/cc
C flags (Release): -Wl,-strip-all -fsigned-char -W -Wall -Werror=return-type -Werror=non-virtual-dtor -Werror=address -Werror=sequence-point -Wformat -Werror=format-security -Wmissing-declarations -Wmissing-prototypes -Wstrict-prototypes -Wundef -Winit-self -Wpointer-arith -Wshadow -Wuninitialized -Winit-self -Wno-comment -Wno-strict-overflow -fdiagnostics-show-option -Wno-long-long -pthread -fomit-frame-pointer -ffunction-sections -fdata-sections -msse -msse2 -msse3 -fvisibility=hidden -O3 -DNDEBUG -DNDEBUG
C flags (Debug): -Wl,-strip-all -fsigned-char -W -Wall -Werror=return-type -Werror=non-virtual-dtor -Werror=address -Werror=sequence-point -Wformat -Werror=format-security -Wmissing-declarations -Wmissing-prototypes -Wstrict-prototypes -Wundef -Winit-self -Wpointer-arith -Wshadow -Wuninitialized -Winit-self -Wno-comment -Wno-strict-overflow -fdiagnostics-show-option -Wno-long-long -pthread -fomit-frame-pointer -ffunction-sections -fdata-sections -msse -msse2 -msse3 -fvisibility=hidden -g -O0 -DDEBUG -D_DEBUG
Linker flags (Release): -Wl,—exclude-libs,libippicv.a -Wl,—exclude-libs,libippiw.a -L/root/ffmpeg_build/lib -Wl,—gc-sections -Wl,—as-needed
Linker flags (Debug): -Wl,—exclude-libs,libippicv.a -Wl,—exclude-libs,libippiw.a -L/root/ffmpeg_build/lib -Wl,—gc-sections -Wl,—as-needed
ccache: YES
Precompiled headers: NO
Extra dependencies: ade /lib64/libpng.so /lib64/libz.so dl m pthread rt
3rdparty dependencies: ittnotify libprotobuf libjpeg-turbo libwebp libtiff libjasper IlmImf quirc ippiw ippicv

Читайте также:  Nm a273 прошивка мультиконтроллера

OpenCV modules:
To be built: calib3d core dnn features2d flann gapi highgui imgcodecs imgproc ml objdetect photo python3 stitching video videoio
Disabled: world
Disabled by dependency: —
Unavailable: java js python2 ts
Applications: —
Documentation: NO
Non-free algorithms: NO

GUI:
QT: YES (ver 4.8.7 EDITION = OpenSource)
QT OpenGL support: NO
GTK+: NO
VTK support: NO

Media I/O:
ZLib: /lib64/libz.so (ver 1.2.7)
JPEG: libjpeg-turbo (ver 2.0.4-62)
WEBP: build (ver encoder: 0x020f)
PNG: /lib64/libpng.so (ver 1.5.13)
TIFF: build (ver 42 — 4.0.10)
JPEG 2000: build Jasper (ver 1.900.1)
OpenEXR: build (ver 2.3.0)
HDR: YES
SUNRASTER: YES
PXM: YES
PFM: YES

Video I/O:
DC1394: NO
FFMPEG: YES
avcodec: YES (58.93.100)
avformat: YES (58.47.100)
avutil: YES (56.55.100)
swscale: YES (5.8.100)
avresample: NO
GStreamer: NO
v4l/v4l2: YES (linux/videodev2.h)

Parallel framework: pthreads

Trace: YES (with Intel ITT)

Other third-party libraries:
Intel IPP: 2020.0.0 Gold [2020.0.0]
at: /io/_skbuild/linux-x86_64-3.6/cmake-build/3rdparty/ippicv/ippicv_lnx/icv
Intel IPP IW: sources (2020.0.0)
at: /io/_skbuild/linux-x86_64-3.6/cmake-build/3rdparty/ippicv/ippicv_lnx/iw
Lapack: NO
Eigen: NO
Custom HAL: NO
Protobuf: build (3.5.1)

OpenCL: YES (no extra features)
Include path: /io/opencv/3rdparty/include/opencl/1.2
Link libraries: Dynamic load

Python 3:
Interpreter: /opt/python/cp36-cp36m/bin/python (ver 3.6.10)
Libraries: libpython3.6m.a (ver 3.6.10)
numpy: /opt/python/cp36-cp36m/lib/python3.6/site-packages/numpy/core/include (ver 1.11.3)
install path: python

Python (for build): /bin/python2.7

Java:
ant: NO
JNI: NO
Java wrappers: NO
Java tests: NO

Install to: /io/_skbuild/linux-x86_64-3.6/cmake-install

Build info for WORKING version — 4.2.0.34 :

General configuration for OpenCV 4.2.0 ===================================== Version control: 4.2.0

Platform:
Timestamp: 2020-04-04T14:19:38Z
Host: Linux 4.15.0-1028-gcp x86_64
CMake: 3.9.0
CMake generator: Unix Makefiles
CMake build tool: /usr/bin/gmake
Configuration: Release

CPU/HW features:
Baseline: SSE SSE2 SSE3
requested: SSE3
Dispatched code generation: SSE4_1 SSE4_2 FP16 AVX
requested: SSE4_1 SSE4_2 AVX FP16 AVX2 AVX512_SKX
SSE4_1 (14 files): + SSSE3 SSE4_1
SSE4_2 (1 files): + SSSE3 SSE4_1 POPCNT SSE4_2
FP16 (0 files): + SSSE3 SSE4_1 POPCNT SSE4_2 FP16 AVX
AVX (4 files): + SSSE3 SSE4_1 POPCNT SSE4_2 AVX

Читайте также:  Sony kdl 32cx521 прошивка

C/C++:
Built as dynamic libs?: NO
C++ Compiler: /usr/lib/ccache/compilers/c++ (ver 4.8.2)
C++ flags (Release): -Wl,-strip-all -fsigned-char -W -Wall -Werror=return-type -Werror=non-virtual-dtor -Werror=address -Werror=sequence-point -Wformat -Werror=format-security -Wmissing-declarations -Wundef -Winit-self -Wpointer-arith -Wsign-promo -Wuninitialized -Winit-self -Wno-delete-non-virtual-dtor -Wno-comment -Wno-missing-field-initializers -fdiagnostics-show-option -Wno-long-long -pthread -fomit-frame-pointer -ffunction-sections -fdata-sections -msse -msse2 -msse3 -fvisibility=hidden -fvisibility-inlines-hidden -O3 -DNDEBUG -DNDEBUG
C++ flags (Debug): -Wl,-strip-all -fsigned-char -W -Wall -Werror=return-type -Werror=non-virtual-dtor -Werror=address -Werror=sequence-point -Wformat -Werror=format-security -Wmissing-declarations -Wundef -Winit-self -Wpointer-arith -Wsign-promo -Wuninitialized -Winit-self -Wno-delete-non-virtual-dtor -Wno-comment -Wno-missing-field-initializers -fdiagnostics-show-option -Wno-long-long -pthread -fomit-frame-pointer -ffunction-sections -fdata-sections -msse -msse2 -msse3 -fvisibility=hidden -fvisibility-inlines-hidden -g -O0 -DDEBUG -D_DEBUG
C Compiler: /usr/lib/ccache/compilers/cc
C flags (Release): -Wl,-strip-all -fsigned-char -W -Wall -Werror=return-type -Werror=non-virtual-dtor -Werror=address -Werror=sequence-point -Wformat -Werror=format-security -Wmissing-declarations -Wmissing-prototypes -Wstrict-prototypes -Wundef -Winit-self -Wpointer-arith -Wuninitialized -Winit-self -Wno-comment -Wno-missing-field-initializers -fdiagnostics-show-option -Wno-long-long -pthread -fomit-frame-pointer -ffunction-sections -fdata-sections -msse -msse2 -msse3 -fvisibility=hidden -O3 -DNDEBUG -DNDEBUG
C flags (Debug): -Wl,-strip-all -fsigned-char -W -Wall -Werror=return-type -Werror=non-virtual-dtor -Werror=address -Werror=sequence-point -Wformat -Werror=format-security -Wmissing-declarations -Wmissing-prototypes -Wstrict-prototypes -Wundef -Winit-self -Wpointer-arith -Wuninitialized -Winit-self -Wno-comment -Wno-missing-field-initializers -fdiagnostics-show-option -Wno-long-long -pthread -fomit-frame-pointer -ffunction-sections -fdata-sections -msse -msse2 -msse3 -fvisibility=hidden -g -O0 -DDEBUG -D_DEBUG
Linker flags (Release): -L/root/ffmpeg_build/lib -Wl,—gc-sections
Linker flags (Debug): -L/root/ffmpeg_build/lib -Wl,—gc-sections
ccache: YES
Precompiled headers: NO
Extra dependencies: ade /opt/Qt4.8.7/lib/libQtGui.so /opt/Qt4.8.7/lib/libQtTest.so /opt/Qt4.8.7/lib/libQtCore.so /lib64/libz.so dl m pthread rt
3rdparty dependencies: ittnotify libprotobuf libjpeg-turbo libwebp libpng libtiff libjasper IlmImf quirc

OpenCV modules:
To be built: calib3d core dnn features2d flann gapi highgui imgcodecs imgproc ml objdetect photo python3 stitching video videoio
Disabled: world
Disabled by dependency: —
Unavailable: java js python2 ts
Applications: —
Documentation: NO
Non-free algorithms: NO

GUI:
QT: YES (ver 4.8.7 EDITION = OpenSource)
QT OpenGL support: NO
GTK+: NO
VTK support: NO

Media I/O:
ZLib: /lib64/libz.so (ver 1.2.3)
JPEG: libjpeg-turbo (ver 2.0.2-62)
WEBP: build (ver encoder: 0x020e)
PNG: build (ver 1.6.37)
TIFF: build (ver 42 — 4.0.10)
JPEG 2000: build (ver 1.900.1)
OpenEXR: build (ver 2.3.0)
HDR: YES
SUNRASTER: YES
PXM: YES
PFM: YES

Video I/O:
DC1394: NO
FFMPEG: YES
avcodec: YES (58.65.103)
avformat: YES (58.35.101)
avutil: YES (56.38.100)
swscale: YES (5.6.100)
avresample: NO
GStreamer: NO
v4l/v4l2: YES (linux/videodev2.h)

Parallel framework: pthreads

Trace: YES (with Intel ITT)

Other third-party libraries:
Lapack: NO
Eigen: NO
Custom HAL: NO
Protobuf: build (3.5.1)

OpenCL: YES (no extra features)
Include path: /io/opencv/3rdparty/include/opencl/1.2
Link libraries: Dynamic load

Python 3:
Interpreter: /opt/python/cp36-cp36m/bin/python (ver 3.6.10)
Libraries: libpython3.6m.a (ver 3.6.10)
numpy: /opt/python/cp36-cp36m/lib/python3.6/site-packages/numpy/core/include (ver 1.11.3)
install path: python

Python (for build): /opt/python/cp36-cp36m/bin/python

Java:
ant: NO
JNI: NO
Java wrappers: NO
Java tests: NO

Источник

Smartadm.ru
Adblock
detector